|
@@ -37,16 +37,16 @@ public class WXCpUserUtil {
|
|
|
|
|
|
public static String createOrUpdate(String userId, String name, Long[] firstOrgWxIdList,
|
|
|
Long[] secondOrgWxIdList, Long[] thirdOrgWxIdList, Long[] fourthOrgWxIdList, String position,
|
|
|
- String mobile, String gender, String email, String telephone) {
|
|
|
+ String mobile, String gender, String email, String telephone, String firstOrgName) {
|
|
|
WxCpUser user = getById(userId);
|
|
|
try {
|
|
|
if (user == null) {
|
|
|
user = getUser(userId, name, firstOrgWxIdList, secondOrgWxIdList, thirdOrgWxIdList, fourthOrgWxIdList,
|
|
|
- position, mobile, gender, email, telephone);
|
|
|
+ position, mobile, gender, email, telephone, firstOrgName);
|
|
|
userService.create(user);
|
|
|
} else {
|
|
|
user = getUser(userId, name, firstOrgWxIdList, secondOrgWxIdList, thirdOrgWxIdList, fourthOrgWxIdList,
|
|
|
- position, mobile, gender, email, telephone);
|
|
|
+ position, mobile, gender, email, telephone, firstOrgName);
|
|
|
userService.update(user);
|
|
|
}
|
|
|
return "SUCCESS";
|
|
@@ -57,7 +57,7 @@ public class WXCpUserUtil {
|
|
|
|
|
|
private static WxCpUser getUser(String userId, String name, Long[] firstOrgWxIdList, Long[] secondOrgWxIdList,
|
|
|
Long[] thirdOrgWxIdList, Long[] fourthOrgWxIdList, String position, String mobile, String gender,
|
|
|
- String email, String telephone) throws WxErrorException {
|
|
|
+ String email, String telephone, String firstOrgName) throws WxErrorException {
|
|
|
WxCpUser user = new WxCpUser();
|
|
|
if (Tools.notEmpty(userId)) {
|
|
|
user.setUserId(userId);
|