Browse Source

客户

master
wangpengfei 8 months ago
parent
commit
a80008b9ce
  1. 11
      src/main/java/com/yxt/customer/apiadmin/CrmCustomerTempRest.java
  2. 1
      src/main/java/com/yxt/customer/biz/crmcustomer/CrmCustomerTempMapper.java
  3. 3
      src/main/java/com/yxt/customer/biz/crmcustomer/CrmCustomerTempMapper.xml
  4. 3
      src/main/java/com/yxt/customer/biz/crmcustomer/CrmCustomerTempService.java

11
src/main/java/com/yxt/customer/apiadmin/CrmCustomerTempRest.java

@ -7,9 +7,7 @@ import com.yxt.common.core.query.PagerQuery;
import com.yxt.common.core.result.ResultBean;
import com.yxt.common.core.vo.PagerVo;
import com.yxt.customer.biz.crmcustomer.*;
import com.yxt.customer.biz.crmcustomerfile.AppCrmCustomerTempArchivesDto;
import com.yxt.customer.biz.crmcustomerfile.AppCrmCustomerTempArchivesVo;
import com.yxt.customer.biz.crmcustomerfile.CrmCustomerFileService;
import com.yxt.customer.biz.crmcustomerfile.*;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.apache.commons.lang3.StringUtils;
@ -143,4 +141,11 @@ public class CrmCustomerTempRest {
@RequestParam(value = "follow_state", required = false) String follow_state) {
return crmCustomerTempService.updateRemindAndByCustomerSid(customerSid, remind_day, remind_remark, isOnRemind, isOnRemindkey, follow_state);
}
@ApiOperation("根据orgSid查询客户数量")
@GetMapping("/getCustomerByOrgSid")
public ResultBean getCustomerByOrgSid(@RequestParam("orgSid") String orgSid) {
ResultBean rb = ResultBean.fireFail();
Integer w = crmCustomerTempService.getCustomerByOrgSid(orgSid);
return rb.success().setData(w);
}
}

1
src/main/java/com/yxt/customer/biz/crmcustomer/CrmCustomerTempMapper.java

@ -36,4 +36,5 @@ public interface CrmCustomerTempMapper extends BaseMapper<CrmCustomerTemp> {
int selBySid(String customerSid);
int updateRemindAndByCustomerSid(@Param("customerSid") String customerSid, @Param("remind_day") String remind_day, @Param("remind_remark") String remind_remark, @Param("isOnRemind") String isOnRemind, @Param("isOnRemindkey") String isOnRemindkey, @Param("follow_state") String follow_state);
int getCustomerByOrgSid(@Param("orgSid") String orgSid);
}

3
src/main/java/com/yxt/customer/biz/crmcustomer/CrmCustomerTempMapper.xml

@ -31,6 +31,9 @@
from crm_customer
where sid = #{customerSid}
</select>
<select id="getCustomerByOrgSid" resultType="java.lang.Integer">
select count(a.sid) from crm_customer a LEFT JOIN ss_user.sys_organization as s ON a.useOrgSid = s.sid where s.orgSidPath like #{orgSid} and a.isDelete !='1'
</select>
<update id="updateRemindAndByCustomerSid">
UPDATE crm_customer
SET remind_day = #{remind_day},

3
src/main/java/com/yxt/customer/biz/crmcustomer/CrmCustomerTempService.java

@ -190,4 +190,7 @@ public class CrmCustomerTempService extends MybatisBaseService<CrmCustomerTempMa
public int updateRemindAndByCustomerSid(String customerSid, String remind_day, String remind_remark, String isOnRemind, String isOnRemindkey, String follow_state) {
return baseMapper.updateRemindAndByCustomerSid(customerSid, remind_day, remind_remark, isOnRemind, isOnRemindkey, follow_state);
}
public Integer getCustomerByOrgSid(String orgSid) {
return baseMapper.getCustomerByOrgSid(orgSid);
}
}

Loading…
Cancel
Save