feat: 登录默认密码提示改密并可取消,版本升至1.1.19

This commit is contained in:
2026-11-03 16:01:56 +08:00
parent fdacdfbda0
commit 59e699b4f6
3 changed files with 65 additions and 16 deletions
+30 -10
View File
@@ -364,12 +364,6 @@ export default {
console.log('自动匹配扫码设置失败', scanError);
}
setTimeout(() => {
uni.reLaunch({
url: '/pages/sys/workbench/index'
});
}, 500);
var that = this
if (that.remember == true) {
if ((this.login.username.length > 0) && (this.login.password.length > 0)) {
@@ -381,14 +375,40 @@ export default {
}
uni.showToast({
icon: 'none',
title: '登录成功!'
});
this.$store.dispatch('initNotification');
setTimeout(function () {
uni.hideLoading();
}, 1000);
const goWorkbench = () => {
uni.reLaunch({
url: '/pages/sys/workbench/index'
});
};
if (aLoginUserData.is_default_password) {
uni.showModal({
title: '提示',
content: '检测到当前为默认密码,建议修改后再使用',
confirmText: '去修改',
cancelText: '取消',
success: (modalRes) => {
if (modalRes.confirm) {
uni.reLaunch({
url: '/pages/sys/user/pwd?from=login'
});
} else {
goWorkbench();
}
}
});
} else {
uni.showToast({
icon: 'none',
title: '登录成功!'
});
setTimeout(goWorkbench, 500);
}
}).catch((error) => {
console.log('login error', error)
uni.showToast({