Documentation ¶
Index ¶
- Constants
- func Base(path string) string
- func CleanDir(path string) string
- func Cleanse(path string) string
- func Dir(path string) string
- func DirCleanse(dir string) string
- func FileCleanse(filename string) string
- func FileNoExt(filepath string) string
- func FileRewrite(filename string) string
- func Split(path string) (dir, file string)
- type ById
- type ByPath
- type ByUId
- type ByUIdTitle
- type Path
Constants ¶
View Source
const PathSeparator = string(os.PathSeparator)
Variables ¶
This section is empty.
Functions ¶
Types ¶
type ById ¶
type ById struct { Id int `json:"id"` IdStr string `json:"idStr"` Title string //PrePath string `json:"prePath" comment:""` TimeStr string FileName string `json:"fileName"` }
year/key_date_title/filename
type ByUId ¶
type ByUId struct { UserId int `json:"userId"` UserIdStr string `json:"userIdStr"` Id int `json:"id"` IdStr string `json:"idStr"` Time time.Time `json:"pubAt" gorm:"type:timestamptz(0);default:0001-01-01 00:00:00"` TimeStr string `json:"pubAtStr" comment:"20230321"` FileName string `json:"fileName"` }
userId/year/time_userId_key_filename
type ByUIdTitle ¶
userId/date_key_title/time_userId_key_filename
func (*ByUIdTitle) Path ¶
func (d *ByUIdTitle) Path() string
Click to show internal directories.
Click to hide internal directories.