优化:商户登录 区分商户类别 禁止跨类别登录

This commit is contained in:
wuhui_zzw 2024-07-12 15:09:14 +08:00
parent 151ce626ce
commit 2b1531a213
1 changed files with 19 additions and 1 deletions

View File

@ -73,7 +73,8 @@ export default {
login_bg: '',
loginInfo:{
account: '',
password: ''
password: '',
merchant_type: '',
},
//
intervalId: '',
@ -85,6 +86,17 @@ export default {
},
onLoad: function(options) {
this.is_sys = options.is_sys;
// merchant_type0=1=2=3=4=5=6=7=
// is_sys0=1=2=3=4=5=6=7=
switch (Number(this.is_sys)) {
case 0:this.loginInfo.merchant_type = 0;break;//
case 2:this.loginInfo.merchant_type = 1;break;//
case 3:this.loginInfo.merchant_type = 3;break;//
case 4:this.loginInfo.merchant_type = 4;break;//
case 5:this.loginInfo.merchant_type = 5;break;//
case 6:this.loginInfo.merchant_type = 6;break;//
case 7:this.loginInfo.merchant_type = 7;break;//
}
//
this.pageTitle = this.$util.getIsSysText(this.is_sys);
uni.setNavigationBarTitle({
@ -173,6 +185,12 @@ export default {
// -
loginPopupClose(){
this.$refs.loginPopup.close();
//
if(Object.values(this.loginHistory).length <= 0){
uni.switchTab({
url: '/pages/user/index',
});
}
},