contract.go 1.2 KB

123456789101112131415161718192021222324252627
  1. /*
  2. * @description:合同 视图
  3. * @Author: CP
  4. * @Date: 2020-11-11 11:19:30
  5. * @FilePath: \construction_management\web\viewmodels\contract.go
  6. */
  7. package viewmodels
  8. import (
  9. "time"
  10. )
  11. type Contracts struct {
  12. Id string `form:"id" json:"id" `
  13. TreeId string `xorm:"not null default 0 comment('树ID') INT(11)"`
  14. ContractsType int `xorm:"not null comment('合同类型(1收入合同2支出合同)') TINYINT(1)"`
  15. ProjectId string `xorm:"not null default 0 comment('项目ID') INT(11)"`
  16. BidsectionId string `xorm:"comment('标段ID') INT(11)"`
  17. Name string `xorm:"not null comment('名称') VARCHAR(64)"`
  18. Code string `xorm:"comment('合同编号') VARCHAR(32)"`
  19. Price string `xorm:"not null comment('合同金额 0') DECIMAL(12,2)"`
  20. Returned string `xorm:"not null comment('回款总金额 0') DECIMAL(12,2)"`
  21. Paid string `xorm:"not null default 0.00 comment('合同已支付金额 0') DECIMAL(12,2)"`
  22. Status int `xorm:"not null comment('合同状态 0') TINYINT(1)"`
  23. CreateTime time.Time `xorm:"comment('创建时间') DATETIME"`
  24. UpdateTime time.Time `xorm:"not null default 'CURRENT_TIMESTAMP' comment('更新时间') TIMESTAMP"`
  25. }