feat:完善项目
This commit is contained in:
22
app/common/model/manage_material.go
Normal file
22
app/common/model/manage_material.go
Normal file
@ -0,0 +1,22 @@
|
||||
package model
|
||||
|
||||
// ManageMaterial 维修器材数据模型
|
||||
type ManageMaterial struct {
|
||||
Model
|
||||
ModelTenant
|
||||
SupplierID uint64 `gorm:"column:supplier_id;type:int;default:0;comment:供应商ID" json:"supplier_id"`
|
||||
Title string `gorm:"column:title;type:varchar(100);default:null;comment:名称" json:"title"`
|
||||
Image
|
||||
Unit int `gorm:"column:unit;type:tinyint(1);default:0;comment:单位" json:"unit"`
|
||||
Remark string `gorm:"column:remark;type:varchar(255);default:null;comment:备注" json:"remark"`
|
||||
ModelDeleted
|
||||
ModelAt
|
||||
}
|
||||
|
||||
func (m *ManageMaterial) TableName() string {
|
||||
return "manage_material"
|
||||
}
|
||||
|
||||
func NewManageMaterial() *ManageMaterial {
|
||||
return &ManageMaterial{}
|
||||
}
|
21
app/common/model/manage_material_purchase.go
Normal file
21
app/common/model/manage_material_purchase.go
Normal file
@ -0,0 +1,21 @@
|
||||
package model
|
||||
|
||||
// ManageMaterialPurchase 维修器材采购数据明细
|
||||
type ManageMaterialPurchase struct {
|
||||
Model
|
||||
OrderNo string `gorm:"column:order_no;type:varchar(20);default:null;comment:采购单号" json:"order_no"`
|
||||
MaterialID uint64 `gorm:"column:material_id;type:int(6);default:0;comment:器材ID" json:"material_id"`
|
||||
Price float64 `gorm:"column:price;type:decimal(10,2);default:0;comment:采购单价" json:"price"`
|
||||
Number int `gorm:"column:number;type:int(6);default:0;comment:采购数量" json:"number"`
|
||||
Remark string `gorm:"column:remark;type:varchar(255);default:null;comment:采购备注" json:"remark"`
|
||||
ModelDeleted
|
||||
ModelAt
|
||||
}
|
||||
|
||||
func (m *ManageMaterialPurchase) TableName() string {
|
||||
return "manage_material_purchase"
|
||||
}
|
||||
|
||||
func NewManageMaterialPurchase() *ManageMaterialPurchase {
|
||||
return &ManageMaterialPurchase{}
|
||||
}
|
20
app/common/model/manage_material_warehouse.go
Normal file
20
app/common/model/manage_material_warehouse.go
Normal file
@ -0,0 +1,20 @@
|
||||
package model
|
||||
|
||||
// ManageMaterialWarehouse 维修器材采购入库明细
|
||||
type ManageMaterialWarehouse struct {
|
||||
Model
|
||||
OrderNo string `gorm:"column:order_no;type:varchar(20);default:null;comment:采购单号" json:"order_no"`
|
||||
MaterialPurchaseID uint64 `gorm:"column:material_purchase_id;type:int(11);default:0;comment:器材采购ID" json:"material_purchase_id"`
|
||||
Number int `gorm:"column:number;type:int(6);default:0;comment:入库数量" json:"number"`
|
||||
Remark string `gorm:"column:remark;type:varchar(255);default:null;comment:入库备注" json:"remark"`
|
||||
ModelDeleted
|
||||
ModelAt
|
||||
}
|
||||
|
||||
func (m *ManageMaterialWarehouse) TableName() string {
|
||||
return "manage_material_warehouse"
|
||||
}
|
||||
|
||||
func NewManageMaterialWarehouse() *ManageMaterialWarehouse {
|
||||
return &ManageMaterialWarehouse{}
|
||||
}
|
15
app/common/model/manage_material_work.go
Normal file
15
app/common/model/manage_material_work.go
Normal file
@ -0,0 +1,15 @@
|
||||
package model
|
||||
|
||||
type ManageMaterialWork struct {
|
||||
Model
|
||||
ModelDeleted
|
||||
ModelAt
|
||||
}
|
||||
|
||||
func (m *ManageMaterialWork) TableName() string {
|
||||
return "manage_material_work"
|
||||
}
|
||||
|
||||
func NewManageMaterialWork() *ManageMaterialWork {
|
||||
return &ManageMaterialWork{}
|
||||
}
|
16
app/common/model/work_instance.go
Normal file
16
app/common/model/work_instance.go
Normal file
@ -0,0 +1,16 @@
|
||||
package model
|
||||
|
||||
type WorkInstance struct {
|
||||
Model
|
||||
Title string `json:"title"`
|
||||
ModelDeleted
|
||||
ModelAt
|
||||
}
|
||||
|
||||
func (m *WorkInstance) TableName() string {
|
||||
return "manage_instance"
|
||||
}
|
||||
|
||||
func NewWorkInstance() *WorkInstance {
|
||||
return &WorkInstance{}
|
||||
}
|
15
app/common/model/work_schedule.go
Normal file
15
app/common/model/work_schedule.go
Normal file
@ -0,0 +1,15 @@
|
||||
package model
|
||||
|
||||
type WorkSchedule struct {
|
||||
Model
|
||||
ModelDeleted
|
||||
ModelAt
|
||||
}
|
||||
|
||||
func (m *WorkSchedule) TableName() string {
|
||||
return "work_schedule"
|
||||
}
|
||||
|
||||
func NewWorkSchedule() *WorkSchedule {
|
||||
return &WorkSchedule{}
|
||||
}
|
Reference in New Issue
Block a user