|
|
@@ -1,5 +1,15 @@
|
|
|
package com.uas.sso.util;
|
|
|
|
|
|
+import com.alibaba.fastjson.JSON;
|
|
|
+import com.alibaba.fastjson.JSONObject;
|
|
|
+import com.uas.sso.AccountConfig;
|
|
|
+import com.uas.sso.ResultWrap;
|
|
|
+import com.uas.sso.common.util.HttpUtil;
|
|
|
+import com.uas.sso.entity.UserSpaceView;
|
|
|
+import com.uas.sso.entity.UserView;
|
|
|
+import org.springframework.ui.ModelMap;
|
|
|
+import org.springframework.util.StringUtils;
|
|
|
+
|
|
|
/**
|
|
|
* 客户端使用,操作企业资料、用户资料
|
|
|
*
|
|
|
@@ -8,442 +18,84 @@ package com.uas.sso.util;
|
|
|
*/
|
|
|
public class AccountUtils {
|
|
|
|
|
|
+ /**
|
|
|
+ * 企业解除绑定的应用
|
|
|
+ *
|
|
|
+ * @author wangmh
|
|
|
+ * @date 2018/1/26 16:34
|
|
|
+ * @param spaceUU 企业uu号
|
|
|
+ * @param appId 应用id
|
|
|
+ * @throws Exception
|
|
|
+ */
|
|
|
+ public static void unbindApp(Long spaceUU, String appId) throws Exception {
|
|
|
+ String saveUrl = AccountConfig.getSpaceSaveUrl();
|
|
|
+ if (!StringUtils.isEmpty(saveUrl)) {
|
|
|
+ ModelMap formData = new ModelMap();
|
|
|
+ formData.put("_operate", "unbind");
|
|
|
+ formData.put("spaceUU", spaceUU);
|
|
|
+ formData.put("appId", appId);
|
|
|
+ HttpUtil.ResponseWrap res = HttpUtil.doPost(saveUrl, formData);
|
|
|
+ if (!res.isSuccess()) {
|
|
|
+ throw new Exception(res.getContent());
|
|
|
+ } else {
|
|
|
+ ResultWrap result = JSON.parseObject(res.getContent(), ResultWrap.class);
|
|
|
+ if (!result.isSuccess()) {
|
|
|
+ throw new Exception(result.getErrMsg());
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 企业开通应用
|
|
|
+ * @param spaceUU 企业uu号
|
|
|
+ * @param appId 应用id
|
|
|
+ * @throws Exception
|
|
|
+ */
|
|
|
+ public static void bindApp(Long spaceUU, String appId) throws Exception {
|
|
|
+ String saveUrl = AccountConfig.getSpaceSaveUrl();
|
|
|
+ if (!StringUtils.isEmpty(saveUrl)) {
|
|
|
+ ModelMap formData = new ModelMap();
|
|
|
+ formData.put("_operate", "bind");
|
|
|
+ formData.put("spaceUU", spaceUU);
|
|
|
+ formData.put("appId", appId);
|
|
|
+ HttpUtil.ResponseWrap res = HttpUtil.doPost(saveUrl, formData);
|
|
|
+ if (!res.isSuccess()) {
|
|
|
+ throw new Exception(res.getContent());
|
|
|
+ } else {
|
|
|
+ ResultWrap result = JSON.parseObject(res.getContent(), ResultWrap.class);
|
|
|
+ if (!result.isSuccess()) {
|
|
|
+ throw new Exception(result.getErrMsg());
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 用户解除绑定企业
|
|
|
+ * @param userUU 用户uu号
|
|
|
+ * @param spaceUU 企业uu号
|
|
|
+ * @throws Exception
|
|
|
+ */
|
|
|
+ public static void unbindUserSpace(Long userUU, Long spaceUU) throws Exception {
|
|
|
+ String saveUrl = AccountConfig.getUserSaveUrl();
|
|
|
+ if (!StringUtils.isEmpty(saveUrl)) {
|
|
|
+ ModelMap formData = new ModelMap();
|
|
|
+ formData.put("_operate", "unbind");
|
|
|
+ formData.put("userUU", userUU);
|
|
|
+ formData.put("spaceUU", spaceUU);
|
|
|
+ HttpUtil.ResponseWrap res = HttpUtil.doPost(saveUrl, formData);
|
|
|
+ if (!res.isSuccess()) {
|
|
|
+ throw new Exception(res.getContent());
|
|
|
+ } else {
|
|
|
+ ResultWrap result = JSON.parseObject(res.getContent(), ResultWrap.class);
|
|
|
+ if (!result.isSuccess()) {
|
|
|
+ throw new Exception(result.getErrMsg());
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
/// 之后方法会恢复并修改
|
|
|
-// /**
|
|
|
-// * 修改用户信息
|
|
|
-// *
|
|
|
-// * @param user
|
|
|
-// * @param userDetail
|
|
|
-// * @return
|
|
|
-// * @throws Exception
|
|
|
-// */
|
|
|
-// public static List<User> saveUser(User user, UserDetail userDetail) throws Exception {
|
|
|
-// String saveUrl = AccountConfig.getUserSaveUrl();
|
|
|
-// if (!StringUtils.isEmpty(saveUrl)) {
|
|
|
-// JSONObject formData = new JSONObject();
|
|
|
-// if (userDetail != null) {
|
|
|
-// formData = JSON.parseObject(JSON.toJSONString(userDetail));
|
|
|
-// }
|
|
|
-// if (user != null) {
|
|
|
-// if (user.getUid() == null) {
|
|
|
-// user.setUid(userDetail.getMobile());
|
|
|
-// }
|
|
|
-// if (user.getSecondUID() == null) {
|
|
|
-// user.setSecondUID(userDetail.getEmail());
|
|
|
-// }
|
|
|
-// if (user.getAppId() != null && user.getDialectUID() != null) {
|
|
|
-// if (user.getAppId().equals("b2b") || user.getAppId().equals("mall")) {
|
|
|
-// user.setSalt(user.getDialectUID());
|
|
|
-// }
|
|
|
-// }
|
|
|
-// formData.putAll(JSON.parseObject(JSON.toJSONString(user)));
|
|
|
-// }
|
|
|
-// ResponseWrap res = HttpUtil.doPost(saveUrl, formData);
|
|
|
-// if (!res.isSuccess())
|
|
|
-// throw new Exception(res.getContent());
|
|
|
-// else {
|
|
|
-// ResultWrap result = JSON.parseObject(res.getContent(), ResultWrap.class);
|
|
|
-// if (result.isError()) {
|
|
|
-// throw new Exception(result.getErrMsg());
|
|
|
-// } else {
|
|
|
-// return JSON.parseArray(JSON.toJSONString(result.getContent()), User.class);
|
|
|
-// }
|
|
|
-// }
|
|
|
-// }
|
|
|
-// return null;
|
|
|
-// }
|
|
|
-//
|
|
|
-// /**
|
|
|
-// * 修改用户信息
|
|
|
-// *
|
|
|
-// * @param dialectUID
|
|
|
-// * 个人唯一标识
|
|
|
-// * @param spaceDialectUID
|
|
|
-// * 企业唯一标识
|
|
|
-// * @param userDetail
|
|
|
-// * 个人详细信息
|
|
|
-// * @return
|
|
|
-// * @throws Exception
|
|
|
-// */
|
|
|
-// public static List<User> saveUser(Object dialectUID, Object spaceDialectUID, UserDetail userDetail) throws Exception {
|
|
|
-// User user = new User();
|
|
|
-// user.setAppId(SSOHelper.getSSOService().getConfig().getAppName());
|
|
|
-// user.setDialectUID(dialectUID.toString());
|
|
|
-// if (spaceDialectUID != null) {
|
|
|
-// user.setSpaceDialectUID(spaceDialectUID.toString());
|
|
|
-// }
|
|
|
-// return saveUser(user, userDetail);
|
|
|
-// }
|
|
|
-//
|
|
|
-// /**
|
|
|
-// * 保存与当前应用无关的用户信息,借用appId=sso
|
|
|
-// *
|
|
|
-// * @param uid
|
|
|
-// * @param spaceUID
|
|
|
-// * @param userDetail
|
|
|
-// * @return
|
|
|
-// * @throws Exception
|
|
|
-// */
|
|
|
-// public static List<User> saveCustUser(Object uid, Object spaceUID, UserDetail userDetail) throws Exception {
|
|
|
-// User user = new User();
|
|
|
-// user.setAppId(AccountConfig.ACCOUNT_CENTER);
|
|
|
-// user.setDialectUID(uid.toString());
|
|
|
-// user.setSpaceUID(spaceUID.toString());
|
|
|
-// return saveUser(user, userDetail);
|
|
|
-// }
|
|
|
-//
|
|
|
-// /**
|
|
|
-// * 添加用户信息
|
|
|
-// *
|
|
|
-// * @param dialectUID
|
|
|
-// * 个人唯一标识
|
|
|
-// * @param spaceDialectUID
|
|
|
-// * 企业唯一标识
|
|
|
-// * @param userDetail
|
|
|
-// * 个人详细信息
|
|
|
-// * @param noEncryPwd
|
|
|
-// * 明文密码
|
|
|
-// * @return
|
|
|
-// * @throws Exception
|
|
|
-// */
|
|
|
-// public static List<User> addUser(Object dialectUID, Object spaceDialectUID, UserDetail userDetail, String noEncryPwd) throws Exception {
|
|
|
-// User user = new User();
|
|
|
-// user.setAppId(SSOHelper.getSSOService().getConfig().getAppName());
|
|
|
-// user.setDialectUID(dialectUID.toString());
|
|
|
-// if (spaceDialectUID != null) {
|
|
|
-// user.setSpaceDialectUID(spaceDialectUID.toString());
|
|
|
-// }
|
|
|
-// user.setPassword(noEncryPwd);
|
|
|
-// return saveUser(user, userDetail);
|
|
|
-// }
|
|
|
-//
|
|
|
-// /**
|
|
|
-// * 修改手机号
|
|
|
-// * @param oldTel
|
|
|
-// * @param newTel
|
|
|
-// * @return
|
|
|
-// * @throws Exception
|
|
|
-// */
|
|
|
-// public static List<User> updateTel (String oldTel, String newTel) throws Exception {
|
|
|
-// String saveUrl = AccountConfig.getUserSaveUrl();
|
|
|
-// if (!StringUtils.isEmpty(saveUrl)) {
|
|
|
-// saveUrl = saveUrl + "/updateTel";
|
|
|
-// JSONObject formData = new JSONObject();
|
|
|
-// formData.put("oldTel", oldTel);
|
|
|
-// formData.put("newTel", newTel);
|
|
|
-// formData.put("appId", SSOHelper.getSSOService().getConfig().getAppName());
|
|
|
-// ResponseWrap res = HttpUtil.doPost(saveUrl, formData);
|
|
|
-// if (!res.isSuccess()) {
|
|
|
-// throw new Exception(res.getContent());
|
|
|
-// } else {
|
|
|
-// ResultWrap result = JSON.parseObject(res.getContent(), ResultWrap.class);
|
|
|
-// if (result.isError()) {
|
|
|
-// throw new Exception(result.getErrMsg());
|
|
|
-// } else {
|
|
|
-// return JSON.parseArray(JSON.toJSONString(result.getContent()), User.class);
|
|
|
-// }
|
|
|
-// }
|
|
|
-// }
|
|
|
-// return null;
|
|
|
-// }
|
|
|
-//
|
|
|
-// /**
|
|
|
-// * 修改邮箱
|
|
|
-// * @param oldTel
|
|
|
-// * @param newEmail
|
|
|
-// * @return
|
|
|
-// * @throws Exception
|
|
|
-// */
|
|
|
-// public static List<User> updateEmail (String oldTel, String newEmail) throws Exception {
|
|
|
-// String saveUrl = AccountConfig.getUserSaveUrl();
|
|
|
-// if (!StringUtils.isEmpty(saveUrl)) {
|
|
|
-// saveUrl = saveUrl + "/updateEmail";
|
|
|
-// JSONObject formData = new JSONObject();
|
|
|
-// formData.put("oldTel", oldTel);
|
|
|
-// formData.put("newEmail", newEmail);
|
|
|
-// formData.put("appId", SSOHelper.getSSOService().getConfig().getAppName());
|
|
|
-// ResponseWrap res = HttpUtil.doPost(saveUrl, formData);
|
|
|
-// if (!res.isSuccess()) {
|
|
|
-// throw new Exception(res.getContent());
|
|
|
-// } else {
|
|
|
-// ResultWrap result = JSON.parseObject(res.getContent(), ResultWrap.class);
|
|
|
-// if (result.isError()) {
|
|
|
-// throw new Exception(result.getErrMsg());
|
|
|
-// } else {
|
|
|
-// return JSON.parseArray(JSON.toJSONString(result.getContent()), User.class);
|
|
|
-// }
|
|
|
-// }
|
|
|
-// }
|
|
|
-// return null;
|
|
|
-// }
|
|
|
-//
|
|
|
-// public static List<UserSpace> saveUserSpace(UserSpace space, UserSpaceDetail spaceDetail) throws Exception {
|
|
|
-// String saveUrl = AccountConfig.getSpaceSaveUrl();
|
|
|
-// if (!StringUtils.isEmpty(saveUrl)) {
|
|
|
-// JSONObject formData = new JSONObject();
|
|
|
-// if (spaceDetail != null) {
|
|
|
-// formData = JSON.parseObject(JSON.toJSONString(spaceDetail));
|
|
|
-// }
|
|
|
-// if (space != null) {
|
|
|
-// if (space.getUid() == null) {
|
|
|
-// space.setUid(spaceDetail.getBusinessCode());
|
|
|
-// }
|
|
|
-// formData.putAll(JSON.parseObject(JSON.toJSONString(space)));
|
|
|
-// }
|
|
|
-// ResponseWrap res = HttpUtil.doPost(saveUrl, formData);
|
|
|
-// if (!res.isSuccess())
|
|
|
-// throw new Exception(res.getContent());
|
|
|
-// else {
|
|
|
-// ResultWrap result = JSON.parseObject(res.getContent(), ResultWrap.class);
|
|
|
-// if (result.isError()) {
|
|
|
-// throw new Exception(result.getErrMsg());
|
|
|
-// } else {
|
|
|
-// return JSON.parseArray(JSON.toJSONString(result.getContent()), UserSpace.class);
|
|
|
-// }
|
|
|
-// }
|
|
|
-// }
|
|
|
-// return null;
|
|
|
-// }
|
|
|
-//
|
|
|
-// public static List<UserSpace> saveUserSpace(Object dialectUID, UserSpaceDetail spaceDetail) throws Exception {
|
|
|
-// UserSpace userSpace = new UserSpace();
|
|
|
-// userSpace.setAppId(SSOHelper.getSSOService().getConfig().getAppName());
|
|
|
-// userSpace.setDialectUID(dialectUID.toString());
|
|
|
-// return saveUserSpace(userSpace, spaceDetail);
|
|
|
-// }
|
|
|
-//
|
|
|
-// /**
|
|
|
-// * 解除绑定的应用
|
|
|
-// *
|
|
|
-// * @param userSpace
|
|
|
-// * @throws Exception
|
|
|
-// */
|
|
|
-// public static void unbindUserSpace(UserSpace userSpace) throws Exception {
|
|
|
-// String saveUrl = AccountConfig.getSpaceSaveUrl();
|
|
|
-// if (!StringUtils.isEmpty(saveUrl)) {
|
|
|
-// JSONObject formData = JSON.parseObject(JSON.toJSONString(userSpace));
|
|
|
-// formData.put("_operate", "unbind");
|
|
|
-// ResponseWrap res = HttpUtil.doPost(saveUrl, formData);
|
|
|
-// if (!res.isSuccess())
|
|
|
-// throw new Exception(res.getContent());
|
|
|
-// }
|
|
|
-// }
|
|
|
-//
|
|
|
-// /**
|
|
|
-// * 解除绑定的应用
|
|
|
-// *
|
|
|
-// * @param uid
|
|
|
-// * @throws Exception
|
|
|
-// */
|
|
|
-// public static void unbindUserSpace(String uid) throws Exception {
|
|
|
-// unbindUserSpace(SSOHelper.getSSOService().getConfig().getAppName(), uid);
|
|
|
-// }
|
|
|
-//
|
|
|
-// /**
|
|
|
-// * 解除绑定的应用
|
|
|
-// *
|
|
|
-// * @param appId
|
|
|
-// * @param uid
|
|
|
-// * @throws Exception
|
|
|
-// */
|
|
|
-// public static void unbindUserSpace(String appId, String uid) throws Exception {
|
|
|
-// UserSpace userSpace = new UserSpace();
|
|
|
-// userSpace.setAppId(appId);
|
|
|
-// userSpace.setUid(uid);
|
|
|
-// unbindUserSpace(userSpace);
|
|
|
-// }
|
|
|
-//
|
|
|
-// /**
|
|
|
-// * 解除绑定的云账号
|
|
|
-// *
|
|
|
-// * @param user
|
|
|
-// * @throws Exception
|
|
|
-// */
|
|
|
-// public static void unbindUser(User user) throws Exception {
|
|
|
-// String saveUrl = AccountConfig.getUserSaveUrl();
|
|
|
-// if (!StringUtils.isEmpty(saveUrl)) {
|
|
|
-// JSONObject formData = JSON.parseObject(JSON.toJSONString(user));
|
|
|
-// formData.put("_operate", "unbind");
|
|
|
-// ResponseWrap res = HttpUtil.doPost(saveUrl, formData);
|
|
|
-// if (!res.isSuccess())
|
|
|
-// throw new Exception(res.getContent());
|
|
|
-// }
|
|
|
-// }
|
|
|
-//
|
|
|
-// /**
|
|
|
-// * 解除绑定的云账号
|
|
|
-// *
|
|
|
-// * @param dialectUID
|
|
|
-// * @param spaceDialectUID
|
|
|
-// * @throws Exception
|
|
|
-// */
|
|
|
-// public static void unbindUser(Object dialectUID, Object spaceDialectUID) throws Exception {
|
|
|
-// User user = new User();
|
|
|
-// user.setAppId(SSOHelper.getSSOService().getConfig().getAppName());
|
|
|
-// user.setDialectUID(dialectUID.toString());
|
|
|
-// if (spaceDialectUID != null) {
|
|
|
-// user.setSpaceDialectUID(spaceDialectUID.toString());
|
|
|
-// }
|
|
|
-// unbindUser(user);
|
|
|
-// }
|
|
|
-//
|
|
|
-// /**
|
|
|
-// * 校验密码
|
|
|
-// *
|
|
|
-// * @param user
|
|
|
-// * @throws Exception
|
|
|
-// */
|
|
|
-// public static boolean checkPassword(User user) throws Exception {
|
|
|
-// String saveUrl = AccountConfig.getUserSaveUrl();
|
|
|
-// if (!StringUtils.isEmpty(saveUrl)) {
|
|
|
-// JSONObject formData = JSON.parseObject(JSON.toJSONString(user));
|
|
|
-// formData.put("_operate", "check");
|
|
|
-// ResponseWrap res = HttpUtil.doGet(saveUrl, formData);
|
|
|
-// if (!res.isSuccess())
|
|
|
-// throw new Exception(res.getContent());
|
|
|
-// else {
|
|
|
-// ResultWrap result = JSON.parseObject(res.getContent(), ResultWrap.class);
|
|
|
-// if (!result.isSuccess())
|
|
|
-// throw new Exception(result.getErrMsg());
|
|
|
-// else
|
|
|
-// return true;
|
|
|
-// }
|
|
|
-// }
|
|
|
-// return false;
|
|
|
-// }
|
|
|
-//
|
|
|
-// /**
|
|
|
-// * 校验密码
|
|
|
-// *
|
|
|
-// * @param dialectUID
|
|
|
-// * @param spaceDialectUID
|
|
|
-// * @param password
|
|
|
-// * @throws Exception
|
|
|
-// */
|
|
|
-// public static boolean checkPassword(Object dialectUID, Object spaceDialectUID, String password) throws Exception {
|
|
|
-// User user = new User();
|
|
|
-// user.setAppId(SSOHelper.getSSOService().getConfig().getAppName());
|
|
|
-// user.setDialectUID(dialectUID.toString());
|
|
|
-// if (spaceDialectUID != null) {
|
|
|
-// user.setSpaceDialectUID(spaceDialectUID.toString());
|
|
|
-// }
|
|
|
-// user.setPassword(password);
|
|
|
-// return checkPassword(user);
|
|
|
-// }
|
|
|
-//
|
|
|
-// /**
|
|
|
-// * 校验密码
|
|
|
-// *
|
|
|
-// * <pre>
|
|
|
-// * 全匹配模式
|
|
|
-// * </pre>
|
|
|
-// *
|
|
|
-// * @param user
|
|
|
-// * @throws Exception
|
|
|
-// */
|
|
|
-// public static boolean fuzzyCheckPassword(User user) throws Exception {
|
|
|
-// String saveUrl = AccountConfig.getUserSaveUrl();
|
|
|
-// if (!StringUtils.isEmpty(saveUrl)) {
|
|
|
-// JSONObject formData = JSON.parseObject(JSON.toJSONString(user));
|
|
|
-// formData.put("_operate", "fuzzyCheck");
|
|
|
-// ResponseWrap res = HttpUtil.doGet(saveUrl, formData);
|
|
|
-// if (!res.isSuccess())
|
|
|
-// throw new Exception(res.getContent());
|
|
|
-// else {
|
|
|
-// ResultWrap result = JSON.parseObject(res.getContent(), ResultWrap.class);
|
|
|
-// if (!result.isSuccess())
|
|
|
-// throw new Exception(result.getErrMsg());
|
|
|
-// else
|
|
|
-// return true;
|
|
|
-// }
|
|
|
-// }
|
|
|
-// return false;
|
|
|
-// }
|
|
|
-//
|
|
|
-// /**
|
|
|
-// * 校验密码
|
|
|
-// *
|
|
|
-// * <pre>
|
|
|
-// * 全匹配模式
|
|
|
-// * </pre>
|
|
|
-// *
|
|
|
-// * @param dialectUID
|
|
|
-// * @param spaceDialectUID
|
|
|
-// * @param password
|
|
|
-// * @throws Exception
|
|
|
-// */
|
|
|
-// public static boolean fuzzyCheckPassword(Object dialectUID, Object spaceDialectUID, String password) throws Exception {
|
|
|
-// User user = new User();
|
|
|
-// user.setAppId(SSOHelper.getSSOService().getConfig().getAppName());
|
|
|
-// user.setDialectUID(dialectUID.toString());
|
|
|
-// if (spaceDialectUID != null) {
|
|
|
-// user.setSpaceDialectUID(spaceDialectUID.toString());
|
|
|
-// }
|
|
|
-// user.setPassword(password);
|
|
|
-// return fuzzyCheckPassword(user);
|
|
|
-// }
|
|
|
-//
|
|
|
-// /**
|
|
|
-// * 重置密码
|
|
|
-// *
|
|
|
-// * @param user
|
|
|
-// * @throws Exception
|
|
|
-// */
|
|
|
-// public static void resetPassword(User user) throws Exception {
|
|
|
-// String saveUrl = AccountConfig.getUserSaveUrl();
|
|
|
-//// saveUrl = saveUrl + "/resetPwd";
|
|
|
-// if (!StringUtils.isEmpty(saveUrl)) {
|
|
|
-// JSONObject formData = JSON.parseObject(JSON.toJSONString(user));
|
|
|
-// formData.put("_operate", "reset");
|
|
|
-// ResponseWrap res = HttpUtil.doGet(saveUrl, formData);
|
|
|
-// if (!res.isSuccess())
|
|
|
-// throw new Exception(res.getContent());
|
|
|
-// else {
|
|
|
-// ResultWrap result = JSON.parseObject(res.getContent(), ResultWrap.class);
|
|
|
-// if (!result.isSuccess())
|
|
|
-// throw new Exception(result.getErrMsg());
|
|
|
-// }
|
|
|
-// }
|
|
|
-// }
|
|
|
-//
|
|
|
-// /**
|
|
|
-// * 重置密码
|
|
|
-// *
|
|
|
-// * @param dialectUID
|
|
|
-// * 应用自己的用户唯一标识
|
|
|
-// * @param spaceDialectUID
|
|
|
-// * 企业唯一标识
|
|
|
-// * @param noEncryPwd
|
|
|
-// * 新密码(明文)
|
|
|
-// * @throws Exception
|
|
|
-// */
|
|
|
-// public static void resetPassword(Object dialectUID, Object spaceDialectUID, String noEncryPwd) throws Exception {
|
|
|
-// User user = new User();
|
|
|
-// user.setAppId(SSOHelper.getSSOService().getConfig().getAppName());
|
|
|
-// user.setDialectUID(dialectUID.toString());
|
|
|
-// if (spaceDialectUID != null) {
|
|
|
-// user.setSpaceDialectUID(spaceDialectUID.toString());
|
|
|
-// }
|
|
|
-// user.setPassword(noEncryPwd);
|
|
|
-// resetPassword(user);
|
|
|
-// }
|
|
|
-//
|
|
|
-// /**
|
|
|
-// * 重置密码
|
|
|
-// *
|
|
|
-// * @param mobile
|
|
|
-// * 手机号
|
|
|
-// * @param noEncryPwd
|
|
|
-// * 新密码(明文)
|
|
|
-// * @throws Exception
|
|
|
-// */
|
|
|
-// public static void resetPassword(String mobile, String noEncryPwd) throws Exception {
|
|
|
-// User user = new User();
|
|
|
-// user.setAppId(SSOHelper.getSSOService().getConfig().getAppName());
|
|
|
-// user.setUid(mobile);
|
|
|
-// user.setPassword(noEncryPwd);
|
|
|
-// resetPassword(user);
|
|
|
-// }
|
|
|
//
|
|
|
// /**
|
|
|
// * 获取校验码
|