Commit 14da758b by ddx

清除cookie适配新的md5

parent 267c694d
......@@ -50,9 +50,9 @@ public class FileTest {
// String accessKeyID = "bwgf-limit";
// static String accessKeySecret = "qixiangyuns@21$&!";
// static String host = "http://127.0.0.1:8767";
static String host = "http://127.0.0.1:8767";
// static String host = "https://api.taxservices.cn";
static String host = "http://101.201.74.244:8767";
// static String host = "http://101.201.74.244:8767";
// static String host = "http://bwtoken.invservice.cn:7779";
......
......@@ -878,7 +878,31 @@ public class TkTokenServiceImpl implements TkTokenService {
try {
String newUserInfo = "";
if(null != cookieReq.getUserInfoJson()) {
newUserInfo = JSON.parseObject(JSON.toJSONString(cookieReq.getUserInfoJson()), TaxUserInfo.class).toString();
JSONObject loginInfoJson = JSON.parseObject(JSON.toJSONString(cookieReq.getUserInfoJson()));
TaxUserInfo bean;
String loginType = "";
if (loginInfoJson.containsKey("loginType")) {
loginType = loginInfoJson.getString("loginType");
}
if ("b".equals(loginType)) {
bean = new TaxUserInfo();
if (loginInfoJson.containsKey("password")) {
bean.setPassword(loginInfoJson.getString("password"));
}
if (loginInfoJson.containsKey("username")) {
bean.setUsername(loginInfoJson.getString("username"));
}
if (loginInfoJson.containsKey("phone")) {
bean.setPhone(loginInfoJson.getString("phone"));
}
if (loginInfoJson.containsKey("userType")) {
bean.setUserType(loginInfoJson.getString("userType"));
}
newUserInfo= bean.toString();
}else {
newUserInfo = JSON.parseObject(JSON.toJSONString(cookieReq.getUserInfoJson()), TaxUserInfo.class).toString();
}
logger.info(uuId + " cleanCookie taxno is " + taxno + ", newUserInfo is " + newUserInfo);
} else {
String oldUserInfo = cookieReq.getUserInfo();
if (StringUtils.isNotEmpty(oldUserInfo)) {
......
......@@ -13,8 +13,8 @@ import java.util.Map;
public class TokenUnitTest {
// static String host = "http://47.94.208.133:8762";
// static String host = "http://127.0.0.1:8762";
static String host = "https://api.xfapiao.com";
static String host = "http://127.0.0.1:8762";
// static String host = "https://api.xfapiao.com";
String accessKeyID = "eyongyou";
static String accessKeySecret = "yongyou!@#566ccd";
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment