|
@@ -392,7 +392,9 @@ type IncrementalList struct {
|
|
|
RegionType string `description:"企业客户所属区域;可选范围:国内,海外"`
|
|
|
SellerId int `description:"归属销售id"`
|
|
|
SellerName string `description:"归属销售名称"`
|
|
|
- ShareSeller string `description:"共享销售员"`
|
|
|
+ SellerNameLast string `description:"合同到期之前最后所属归属销售名称"`
|
|
|
+ ShareSeller string `description:"合同到期之前最后所属共享销售员"`
|
|
|
+ ShareSellerLast string `description:"共享销售员"`
|
|
|
ExpireDay string `description:"剩余可用天数"`
|
|
|
PermissionList []*company.CompanyReportPermission `description:"产品权限"`
|
|
|
Count int `json:"-" description:"合同数"`
|
|
@@ -410,6 +412,7 @@ type IncrementalList struct {
|
|
|
IsUserMaker int `description:"近四周之内是否包含决策人互动过 ,0否,1是"`
|
|
|
SellerNameInit string `description:"权益初始化销售"`
|
|
|
SellerIdInit int `description:"权益初始化销售ID"`
|
|
|
+ SellerIdLast int `description:"合同到期之前最后所属销售ID"`
|
|
|
ShareSellerInit string `description:"共享销售员"`
|
|
|
}
|
|
|
|
|
@@ -930,7 +933,7 @@ func GetIncrementalCompanyListByOperationRecordMerge(condition string, pars []in
|
|
|
o := orm.NewOrm()
|
|
|
|
|
|
|
|
|
- sql := `SELECT a.company_contract_id,a.contract_type ,a.company_product_id ,a.contract_code ,a.pay_method ,a.pay_channel ,a.package_difference ,a.company_id, a.start_date, a.end_date, a.money, b.company_name, a.seller_id_last as seller_id, c.seller_name_last as seller_name, c.share_seller_last as share_seller, a.product_id, a.product_name, a.create_time, b.region_type, c.renewal_reason, c.renewal_todo, c.status FROM company_contract a
|
|
|
+ sql := `SELECT a.company_contract_id,a.contract_type ,a.company_product_id ,a.contract_code ,a.pay_method ,a.pay_channel ,a.package_difference ,a.company_id, a.start_date, a.end_date, a.money, b.company_name, a.seller_id_last as seller_id, a.seller_name_last as seller_name, a.share_seller_last as share_seller, a.product_id, a.product_name, a.create_time, b.region_type, c.renewal_reason, c.renewal_todo, c.status FROM company_contract a
|
|
|
RIGHT JOIN company b ON a.company_id = b.company_id
|
|
|
JOIN company_product c ON b.company_id = c.company_id
|
|
|
AND a.product_id = c.product_id where 1=1 `
|