update
This commit is contained in:
1 parent
0690285147
commit
5618cd2738
154 files changed
+5021
-3161
No files matched your search
@@ -2,20 +2,19 @@ package model
|
||||
|
||||
import (
|
||||
"time"
|
||||
|
||||
)
|
||||
|
||||
// ResourceModel 资源模型 (CMDB 模型定义)
|
||||
type ResourceModel struct {
|
||||
ID uint `gorm:"primarykey" json:"id"`
|
||||
Name string `gorm:"size:64;not null" json:"name"`
|
||||
Code string `gorm:"size:64;uniqueIndex;not null" json:"code"`
|
||||
Description string `gorm:"size:500" json:"description"`
|
||||
Type string `gorm:"size:32;default:normal" json:"type"` // normal, parent
|
||||
Attributes string `gorm:"type:text" json:"attributes"` // JSON 数组
|
||||
Icon string `gorm:"size:64" json:"icon"`
|
||||
CreatedAt time.Time `json:"created_at"`
|
||||
UpdatedAt time.Time `json:"updated_at"`
|
||||
ID uint `gorm:"primarykey" json:"id"`
|
||||
Name string `gorm:"size:64;not null" json:"name"`
|
||||
Code string `gorm:"size:64;uniqueIndex;not null" json:"code"`
|
||||
Description string `gorm:"size:500" json:"description"`
|
||||
Type string `gorm:"size:32;default:normal" json:"type"` // normal, parent
|
||||
Attributes string `gorm:"type:text" json:"attributes"` // JSON 数组
|
||||
Icon string `gorm:"size:64" json:"icon"`
|
||||
CreatedAt time.Time `json:"created_at"`
|
||||
UpdatedAt time.Time `json:"updated_at"`
|
||||
}
|
||||
|
||||
func (ResourceModel) TableName() string {
|
||||
|
||||
Reference in new issue
Block a user