Roc 4 luni în urmă
părinte
comite
ec1cc06563
1 a modificat fișierele cu 1 adăugiri și 1 ștergeri
  1. 1 1
      models/company_contract/company_contract.go

+ 1 - 1
models/company_contract/company_contract.go

@@ -91,7 +91,7 @@ func GetAfterCompanyContractListByCompanyIdListAndEndDate(endDate string, compan
 // GetLastContractListByEndDate 通过最近一份合同的日期获取早于该合同的最晚一份合同
 func GetLastContractListByEndDate(companyId, productId int, endDate string) (item *CompanyContract, err error) {
 	o := orm.NewOrm()
-	sql := "SELECT * FROM company_contract where company_id = ? AND product_id= ? end_date < ? AND status = 1 ORDER BY end_date desc"
+	sql := "SELECT * FROM company_contract where company_id = ? AND product_id= ? AND end_date < ? AND status = 1 ORDER BY end_date desc"
 	err = o.Raw(sql, companyId, productId, endDate).QueryRow(&item)
 
 	return