|
|
|
@@ -31,7 +31,7 @@ import java.util.List; |
|
|
|
*/ |
|
|
|
@RestController |
|
|
|
@RequestMapping("/api/cuser") |
|
|
|
@Api(description = "B端来源用户") |
|
|
|
@Api(description = "B端来源会员") |
|
|
|
public class WxCUserController extends BaseController { |
|
|
|
private final Logger logger = LoggerFactory.getLogger(this.getClass()); |
|
|
|
|
|
|
|
@@ -116,11 +116,21 @@ public class WxCUserController extends BaseController { |
|
|
|
if(!byPhone.isEmpty()){ |
|
|
|
//更新会员信息 |
|
|
|
WxCUserBasicInfo wxCUserBasicInfo = byPhone.get(0); |
|
|
|
wxCUserBasicInfo.setName(wxCUserFromBDto.getName()); |
|
|
|
wxCUserBasicInfo.setBirthdate(wxCUserFromBDto.getBirthdate()); |
|
|
|
wxCUserBasicInfo.setSex(wxCUserFromBDto.getSex() ); |
|
|
|
wxCUserBasicInfo.setAddress(wxCUserFromBDto.getAddress()); |
|
|
|
wxCUserBasicInfo.setPhone(wxCUserFromBDto.getPhone()); |
|
|
|
if(!StringUtils.isEmpty(wxCUserFromBDto.getName())){ |
|
|
|
wxCUserBasicInfo.setName(wxCUserFromBDto.getName()); |
|
|
|
} |
|
|
|
if(wxCUserFromBDto!=null){ |
|
|
|
wxCUserBasicInfo.setBirthdate(wxCUserFromBDto.getBirthdate()); |
|
|
|
} |
|
|
|
if(wxCUserFromBDto.getSex()!=null){ |
|
|
|
wxCUserBasicInfo.setSex(wxCUserFromBDto.getSex() ); |
|
|
|
} |
|
|
|
if(!StringUtils.isEmpty(wxCUserFromBDto.getAddress())){ |
|
|
|
wxCUserBasicInfo.setAddress(wxCUserFromBDto.getAddress()); |
|
|
|
} |
|
|
|
if(!StringUtils.isEmpty(wxCUserFromBDto.getPhone())){ |
|
|
|
wxCUserBasicInfo.setPhone(wxCUserFromBDto.getPhone()); |
|
|
|
} |
|
|
|
wxCUserBasicInfo.setUpdateDate(new Date()); |
|
|
|
wxCUserBasicInfoService.update(wxCUserBasicInfo); |
|
|
|
wxScoreRulesService.addScore(EnumScoreType.COMPLETE_INFO, wxCUserBasicInfo); |
|
|
|
@@ -159,11 +169,21 @@ public class WxCUserController extends BaseController { |
|
|
|
} |
|
|
|
}else{ |
|
|
|
WxCUserBasicInfo wxCUserBasicInfo = wxCUserBasicInfoService.getById(wxCUserFromB.getcUserId()); |
|
|
|
wxCUserBasicInfo.setName(wxCUserFromBDto.getName()); |
|
|
|
wxCUserBasicInfo.setBirthdate(wxCUserFromBDto.getBirthdate()); |
|
|
|
wxCUserBasicInfo.setSex(wxCUserFromBDto.getSex() ); |
|
|
|
wxCUserBasicInfo.setAddress(wxCUserFromBDto.getAddress()); |
|
|
|
wxCUserBasicInfo.setPhone(wxCUserFromBDto.getPhone()); |
|
|
|
if(!StringUtils.isEmpty(wxCUserFromBDto.getName())){ |
|
|
|
wxCUserBasicInfo.setName(wxCUserFromBDto.getName()); |
|
|
|
} |
|
|
|
if(wxCUserFromBDto!=null){ |
|
|
|
wxCUserBasicInfo.setBirthdate(wxCUserFromBDto.getBirthdate()); |
|
|
|
} |
|
|
|
if(wxCUserFromBDto.getSex()!=null){ |
|
|
|
wxCUserBasicInfo.setSex(wxCUserFromBDto.getSex() ); |
|
|
|
} |
|
|
|
if(!StringUtils.isEmpty(wxCUserFromBDto.getAddress())){ |
|
|
|
wxCUserBasicInfo.setAddress(wxCUserFromBDto.getAddress()); |
|
|
|
} |
|
|
|
if(!StringUtils.isEmpty(wxCUserFromBDto.getPhone())){ |
|
|
|
wxCUserBasicInfo.setPhone(wxCUserFromBDto.getPhone()); |
|
|
|
} |
|
|
|
wxCUserBasicInfoService.update(wxCUserBasicInfo); |
|
|
|
wxScoreRulesService.addScore(EnumScoreType.COMPLETE_INFO, wxCUserBasicInfo); |
|
|
|
wxCUserTagsService.triggerAssignTags(EnumAssignTagsTrigger.ASSIGN_TAGS_TRIGGER_IMPORT, wxCUserBasicInfo); |
|
|
|
|