|
@@ -419,6 +419,7 @@ type CompanyContractRespInit struct {
|
|
|
ContractCode string `description:"合同编码"`
|
|
|
StartDate string `description:"合同开始时间"`
|
|
|
EndDate string `description:"合同结束时间"`
|
|
|
+ MaxEndDate string `description:"合同结束时间"`
|
|
|
Money float64 `description:"合同金额"`
|
|
|
PayMethod string `description:"支付方式"`
|
|
|
PayChannel string `description:"支付渠道"`
|
|
@@ -436,7 +437,7 @@ type CompanyContractRespInit struct {
|
|
|
func GetCompanyContracListInit(condition string, pars []interface{}) (items []*CompanyContractRespInit, err error) {
|
|
|
o := orm.NewOrm()
|
|
|
sql := `SELECT
|
|
|
- MAX( company_contract_id ) AS max_company_contract_id,
|
|
|
+ MAX( a.end_date ) AS max_end_date,
|
|
|
COUNT(a.company_id) AS cc ,
|
|
|
a.*
|
|
|
FROM
|
|
@@ -476,7 +477,7 @@ WHERE
|
|
|
1 = 1 -- AND b.company_name LIKE "%上海亘%"
|
|
|
|
|
|
AND c.product_id = 2 -- AND b.company_name LIKE "%上海亘%"
|
|
|
-
|
|
|
+
|
|
|
AND c.product_id = 2
|
|
|
AND a.not_renewal_hide = 0
|
|
|
AND a.STATUS = 1
|