From ff3e203423f296965472d1f09347cda5cfe3a786 Mon Sep 17 00:00:00 2001 From: zhangqian <zhangqian@123.com> Date: 星期五, 11 八月 2023 11:37:19 +0800 Subject: [PATCH] update --- model/serviceContract.go | 10 ++++++---- 1 files changed, 6 insertions(+), 4 deletions(-) diff --git a/model/serviceContract.go b/model/serviceContract.go index 1ecbb1a..94acee1 100644 --- a/model/serviceContract.go +++ b/model/serviceContract.go @@ -18,6 +18,7 @@ Number string `json:"number" gorm:"column:number;type:varchar(255);comment:鍚堝悓缂栧彿"` MemberId int `json:"memberId" gorm:"column:member_id;type:int;comment:璐熻矗浜篿d"` ContactId int `json:"contactId" gorm:"column:contact_id;type:int;comment:鑱旂郴浜篿d"` + Contact Contact `json:"contact" gorm:"foreignKey:ContactId"` SaleChanceId int `json:"saleChanceId" gorm:"column:sale_chance_id;type:int;comment:閿�鍞満浼歩d"` SaleChance SaleChance `json:"SaleChance" gorm:"foreignKey:SaleChanceId"` SalesDetailsId int `json:"salesDetailsId" gorm:"column:sales_details_id;type:int;comment:鍚堝悓璁㈠崟id"` @@ -26,9 +27,9 @@ Quotation Quotation `json:"quotation" gorm:"foreignKey:QuotationId"` ServiceContractTypeId int `json:"serviceContractTypeId" gorm:"column:service_contract_type_id;type:int;comment:鍚堝悓绫诲瀷id"` ServiceContractType ServiceContractType `json:"serviceContractType" gorm:"foreignKey:ServiceContractTypeId"` - SignTime string `json:"signTime" gorm:"column:sign_time;type:datetime;comment:绛剧害鏃堕棿"` - StartTime string `json:"startTime" gorm:"column:start_time;type:datetime;comment:寮�濮嬫椂闂�"` - EndTime string `json:"endTime" gorm:"column:end_time;type:datetime;comment:缁撴潫鏃堕棿"` + SignTime string `json:"signTime" gorm:"column:sign_time;type:varchar(255);comment:绛剧害鏃堕棿"` + StartTime string `json:"startTime" gorm:"column:start_time;type:varchar(255);comment:寮�濮嬫椂闂�"` + EndTime string `json:"endTime" gorm:"column:end_time;type:varchar(255);comment:缁撴潫鏃堕棿"` ServiceContractStatusId int `json:"serviceContractStatusId" gorm:"column:service_contract_status_id;type:int;comment:鍚堝悓鐘舵�乮d"` ServiceContractStatus ServiceContractStatus `json:"serviceContractStatus" gorm:"foreignKey:ServiceContractStatusId"` ServiceTimes int `json:"serviceTimes" gorm:"column:service_times;type:int;comment:鏈嶅姟娆℃暟"` @@ -115,7 +116,8 @@ Preload("Products"). Preload("Client"). Preload("ServiceContractType"). - Preload("ServiceContractStatus") + Preload("ServiceContractStatus"). + Preload("Contact") } return db -- Gitblit v1.8.0