Merge branch 'open_v2' into 'master'

企业用户入口修改评估传参

See merge request !1029
This commit is contained in:
2024-12-09 16:21:24 +08:00
2 changed files with 17 additions and 6 deletions
@@ -267,11 +267,22 @@ public class UserController {
try { try {
FjtUsers user = usersInfoService.getUser(mobile); FjtUsers user = usersInfoService.getUser(mobile);
if(user == null) { if(user == null) {
long userId = usersInfoService.addUser(mobile, "", weiXinId); String cookieUserId = CookieUtils.getCookieValue(request, "login_user_id");
if(userId == 0){ if(StringUtils.isNotBlank(cookieUserId)){
return resultModel; long userId = Long.valueOf(cookieUserId);
user = fjtUsersService.findById(Long.valueOf(userId));
} }
CookieUtils.setCookie("login_user_id", userId + "", "/", 60 * 60 * 24 *7, response); if(user!=null){
usersInfoService.bindWeiXin(weiXinId, user.getId());
CookieUtils.setCookie("login_user_id", user.getId() + "", "/", 60 * 60 * 24 *7, response);
}else{
long userId = usersInfoService.addUser(mobile, "", weiXinId);
if(userId == 0){
return resultModel;
}
CookieUtils.setCookie("login_user_id", userId + "", "/", 60 * 60 * 24 *7, response);
}
} else { } else {
usersInfoService.bindWeiXin(weiXinId, user.getId()); usersInfoService.bindWeiXin(weiXinId, user.getId());
CookieUtils.setCookie("login_user_id", user.getId() + "", "/", 60 * 60 * 24 *7, response); CookieUtils.setCookie("login_user_id", user.getId() + "", "/", 60 * 60 * 24 *7, response);
@@ -54,7 +54,7 @@ $(function () {
if ($("#t").val() != "c") { if ($("#t").val() != "c") {
saveCookie(id, name, addr, region) saveCookie(id, name, addr, region)
} }
if ($("#t").val() == "b") { if ($("#t").val() == "b" || $("#t").val() == "gb") {
location.href = "districtDetail?id=" + id+"&city="+city location.href = "districtDetail?id=" + id+"&city="+city
} else if ($("#t").val() == "c") { } else if ($("#t").val() == "c") {
$('#districtSearch').val(name) $('#districtSearch').val(name)
@@ -122,7 +122,7 @@ function resumeHistory() {
$("#searchSpan ul").empty().append(content).find("li>a.item-link").click(function () { $("#searchSpan ul").empty().append(content).find("li>a.item-link").click(function () {
var li = $(this).parent() var li = $(this).parent()
var id = $(li).attr("data-id") var id = $(li).attr("data-id")
if ($("#t").val() == "b") { if ($("#t").val() == "b"||$("#t").val() == "gb") {
location.href = "districtDetail?id=" + id+"&city="+city location.href = "districtDetail?id=" + id+"&city="+city
} else if ($("#t").val() == "c") { } else if ($("#t").val() == "c") {
location.href = "../ccbRent/index?city="+city location.href = "../ccbRent/index?city="+city