feat✨ 添加api管理功能
This commit is contained in:
1 parent
cd29c1728d
commit
e091603bc8
3 files changed
+191
No files matched your search
@@ -0,0 +1,34 @@
|
||||
package models
|
||||
|
||||
import (
|
||||
// "gorm.io/gorm"
|
||||
|
||||
"go-admin/common/models"
|
||||
)
|
||||
|
||||
type SysApi struct {
|
||||
models.Model
|
||||
|
||||
Name string `json:"name" gorm:"type:varchar(128);comment:名称"`
|
||||
Title string `json:"title" gorm:"type:varchar(128);comment:标题"`
|
||||
Path string `json:"path" gorm:"type:varchar(128);comment:地址"`
|
||||
Paths string `json:"paths" gorm:"type:varchar(128);comment:Paths"`
|
||||
Action string `json:"action" gorm:"type:varchar(16);comment:类型"`
|
||||
ParentId string `json:"parentId" gorm:"type:smallint(6);comment:按钮id"`
|
||||
Sort string `json:"sort" gorm:"type:tinyint(4);comment:排序"`
|
||||
models.ModelTime
|
||||
models.ControlBy
|
||||
}
|
||||
|
||||
func (SysApi) TableName() string {
|
||||
return "sys_api"
|
||||
}
|
||||
|
||||
func (e *SysApi) Generate() models.ActiveRecord {
|
||||
o := *e
|
||||
return &o
|
||||
}
|
||||
|
||||
func (e *SysApi) GetId() interface{} {
|
||||
return e.Id
|
||||
}
|
||||
Reference in new issue
Block a user