|
@@ -797,82 +797,8 @@ function loginIn_yyfnzt() {
|
|
|
})
|
|
|
return;
|
|
|
}
|
|
|
- let rows = result[0].Rows;
|
|
|
- if (type == "1") {
|
|
|
- //获取用户信息
|
|
|
- var usercode = rows[0].USERID;
|
|
|
- var unitcode = rows[0].UNIT;
|
|
|
- var username = rows[0].USERNAME;
|
|
|
- var truename = rows[0].NAME;
|
|
|
- var password = rows[0].PASSWORD;
|
|
|
- var unitname = rows[0].UNIT_NAME;
|
|
|
- var contact = rows[0].CONTACT;
|
|
|
- var sex = rows[0].SEX;
|
|
|
- var telephone = rows[0].TELPHONE;
|
|
|
- var email = rows[0].MAIL;
|
|
|
- var identify = rows[0].IS_IDENTIFY;
|
|
|
- var usertype = rows[0].TYPE;
|
|
|
- var userkeycode = rows[0]["TEMPUSERKEYCODE"];
|
|
|
- var change_time = rows[0].CHANGE_TIME;
|
|
|
- debugger
|
|
|
- //保存用户信息
|
|
|
- const loginUserInfo = {
|
|
|
- ywxt_usercode: usercode,
|
|
|
- ywxt_username: username,
|
|
|
- ywxt_unitcode: unitcode,
|
|
|
- ywxt_unitname: unitname,
|
|
|
- ywxt_contact: contact,
|
|
|
- ywxt_telephone: telephone,
|
|
|
- ywxt_email: email,
|
|
|
- ywxt_identify: identify,
|
|
|
- ywxt_userkeycode: userkeycode,
|
|
|
- ptjk_changetime: change_time,
|
|
|
- password: password
|
|
|
- }
|
|
|
- // 根据user_id获取角色
|
|
|
- localStorage.setItem('loginUserInfoSpace', JSON.stringify(loginUserInfo))
|
|
|
- loginKj_log(unitcode, usercode, "运维系统-登录", "登录系统成功", "系统登录");
|
|
|
- //空间运维系统 登录成功后 需要缓存用户权限
|
|
|
- selectUserRole(usercode, url);
|
|
|
- return;
|
|
|
- }
|
|
|
- if (type == "2") {
|
|
|
- //获取用户信息
|
|
|
- var usercode = rows[0].USERID;
|
|
|
- var username = rows[0].USERNAME;
|
|
|
- var truename = rows[0].NAME;
|
|
|
- var password = rows[0].PASSWORD;
|
|
|
- var unitcode = rows[0].UNIT;
|
|
|
- var unitname = rows[0].UNIT_NAME;
|
|
|
- var contact = rows[0].CONTACT;
|
|
|
- var sex = rows[0].SEX;
|
|
|
- var telephone = rows[0].TELPHONE;
|
|
|
- var email = rows[0].MAIL;
|
|
|
- var identify = rows[0].IS_IDENTIFY;
|
|
|
- var usertype = rows[0].TYPE;
|
|
|
- var userkeycode = rows[0]["TEMPUSERKEYCODE"];
|
|
|
- var changetime = rows[0]["CHANGE_TIME"];
|
|
|
- //保存用户信息
|
|
|
- const loginUserInfo = {
|
|
|
- gxjh_usercode: usercode,
|
|
|
- gxjh_username: username,
|
|
|
- gxjh_unitcode: unitcode,
|
|
|
- gxjh_unitname: unitname,
|
|
|
- gxjh_contact: contact ? decode(contact) : '',
|
|
|
- gxjh_telephone: telephone ? decode(telephone) : '',
|
|
|
- gxjh_email: email ? decode(email) : '',
|
|
|
- gxjh_identify: identify,
|
|
|
- gxjh_userkeycode: userkeycode,
|
|
|
- gxjh_changetime: changetime,
|
|
|
- }
|
|
|
- localStorage.setItem('exchangeUserInfo', JSON.stringify(loginUserInfo))
|
|
|
- loginKj_log(unitcode, usercode, "浏览系统-登录", "登录系统成功", "系统登录");
|
|
|
- //切换首页
|
|
|
- window.open(url, url)
|
|
|
- // window.location.href = url;
|
|
|
- return;
|
|
|
- }
|
|
|
-
|
|
|
+ let rows = result[0].Rows[0];
|
|
|
+ localStorage.setItem("yyfnzt_user", JSON.stringify(rows))
|
|
|
})
|
|
|
.catch((e) => {
|
|
|
debugger
|