消费者分销

This commit is contained in:
donqi 2022-07-13 23:56:31 +08:00
parent 09623068b6
commit c150b97111
3 changed files with 13 additions and 7 deletions

View File

@ -56,13 +56,17 @@ public class CustomerController extends BaseController {
@ResponseBody
public AjaxResult updateCustomer(@RequestBody Customer customer){
try {
if (customer.getCustomerPlace() != null) {
// 更新父级分销人时需要查询是否有祖父分销人并进行同步更新
Customer customerPlaceInfo = customerService.selectByCustomerId(customer.getCustomerPlace());
customer.setParentCustomerPlace(customerPlaceInfo.getCustomerPlace());
}
customerService.updateCustomer(customer);
return AjaxResult.success("更新消费者手机号成功");
}catch (Exception e){
return AjaxResult.success("更新消费者信息成功");
} catch (Exception e){
ExceptionUtil.getExceptionMessage(e);
return AjaxResult.error(e.getMessage());
}
}
}

View File

@ -161,14 +161,14 @@ public class WxController extends BaseController {
@PostMapping("/unlimited/wxacode")
@ResponseBody
public AjaxResult getUnlimitedWxacode(@RequestBody JSONObject requestObj, HttpServletRequest request) throws Exception {
public AjaxResult getUnlimitedWxacode(@RequestBody JSONObject requestObj) throws Exception {
String base64Code = null;
try {
String scene = requestObj.getString("scene");
String envVersion = requestObj.getString("env_version");
String from = request.getHeader("from");
String deptId = request.getHeader("deptId");
String from = requestObj.getString("from");
String deptId = requestObj.getString("deptId");
SysDeptConfig sysDeptConfig = sysDeptConfigService.selectByDeptId(Long.parseLong(deptId));
String token = null;

View File

@ -91,6 +91,8 @@
<if test="status != null and status != ''">status = #{status},</if>
<if test="remark != null">remark = #{remark},</if>
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
<if test="customerPlace != null">customer_place = #{customerPlace},</if>
<if test="parentCustomerPlace != null">parent_customer_place = #{parentCustomerPlace},</if>
update_time = sysdate()
</set>
where customer_id = #{customerId}