Commit e5d833c4 by wnb0128

车家智能数据服务 登录允许更新userId--think.wang

1 parent 0f0c3452
...@@ -76,7 +76,7 @@ public class RemoteProductController { ...@@ -76,7 +76,7 @@ public class RemoteProductController {
if (json.getInteger("code").equals(200)) { if (json.getInteger("code").equals(200)) {
JSONArray array = json.getJSONArray("message"); JSONArray array = json.getJSONArray("message");
if(array == null || array.size() <= 0){ if(array == null || array.size() <= 0){
return null; return array;
} }
return this.remoteDataHandle(array); return this.remoteDataHandle(array);
} }
......
...@@ -68,6 +68,7 @@ public class UserRelationController { ...@@ -68,6 +68,7 @@ public class UserRelationController {
request.setPhone(userRelation.getPhone()); request.setPhone(userRelation.getPhone());
request.setChannel(userRelation.getChannel()); //涂鸦 request.setChannel(userRelation.getChannel()); //涂鸦
SmartUserRelation user = userRelationService.getSingle(request); SmartUserRelation user = userRelationService.getSingle(request);
request.setUserId(userRelation.getUserId());
if(user != null){ if(user != null){
String tuYaId = user.getThirdId(); String tuYaId = user.getThirdId();
if(StringUtils.isEmpty(tuYaId)){ if(StringUtils.isEmpty(tuYaId)){
...@@ -75,9 +76,9 @@ public class UserRelationController { ...@@ -75,9 +76,9 @@ public class UserRelationController {
tuYaId = this.syncUser(user.getPhone(), user.getPassword()); tuYaId = this.syncUser(user.getPhone(), user.getPassword());
request.setThirdId(tuYaId); request.setThirdId(tuYaId);
request.setId(user.getId()); request.setId(user.getId());
userRelationService.updateByPrimaryKeySelective(request);
} }
} }
userRelationService.updateByPrimaryKeySelective(request);
return R.ok().data(tuYaId); return R.ok().data(tuYaId);
} }
String password = MD5.create().digestHex(Constants.DEFAULT_PASSWORD); String password = MD5.create().digestHex(Constants.DEFAULT_PASSWORD);
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!