浏览代码

fix:续约客户统计,只统计ficc的

Roc 1 年之前
父节点
当前提交
0ae588fc78
共有 1 个文件被更改,包括 2 次插入3 次删除
  1. 2 3
      models/company_contract/company_contract.go

+ 2 - 3
models/company_contract/company_contract.go

@@ -53,7 +53,7 @@ type CompanyContractPermission struct {
 // GetContractListByEndDate 通过结束日期获取当天结束的合同列表
 func GetContractListByEndDate(endDate string) (total int64, list []*CompanyContract, err error) {
 	o := orm.NewOrm()
-	sql := "SELECT * FROM company_contract where end_date = ? AND status = 1 "
+	sql := "SELECT * FROM company_contract where end_date = ? AND product_id = 1 AND status = 1 "
 	total, err = o.Raw(sql, endDate).QueryRows(&list)
 
 	return
@@ -103,7 +103,6 @@ type CompanyContractResp struct {
 	PermissionName    string    `description:"权限名"`
 }
 
-
 // 通过ID获取详情
 func GetCompanyContracDetail(condition string, pars []interface{}) (item *CompanyContractResp, err error) {
 	o := orm.NewOrm()
@@ -150,4 +149,4 @@ func UpdateCompanyContractPermissionMulti(items []*CompanyContractPermission) (e
 		}
 	}
 	return
-}
+}