refactor: reorganize modules and add Linux build tooling
This commit is contained in:
22
module/base/cloud/internal/models/cloud_note_attach.go
Normal file
22
module/base/cloud/internal/models/cloud_note_attach.go
Normal file
@@ -0,0 +1,22 @@
|
||||
package models
|
||||
|
||||
import (
|
||||
"time"
|
||||
|
||||
"git.apinb.com/bsm-sdk/core/database"
|
||||
)
|
||||
|
||||
// 笔记附件模型
|
||||
type NoteAttachment struct {
|
||||
ID uint `gorm:"primaryKey" json:"id"`
|
||||
NoteID uint `gorm:"index" json:"note_id"` // 笔记ID
|
||||
FileName string `gorm:"size:255" json:"file_name"` // 文件名
|
||||
FilePath string `gorm:"size:500" json:"file_path"` // 文件路径
|
||||
FileSize int64 `json:"file_size"` // 文件大小
|
||||
MimeType string `gorm:"size:100" json:"mime_type"` // 文件类型
|
||||
CreatedAt time.Time `json:"created_at"` // 创建时间
|
||||
}
|
||||
|
||||
func init() {
|
||||
database.AppendMigrate(&NoteAttachment{})
|
||||
}
|
||||
Reference in New Issue
Block a user