|
|
@@ -38,7 +38,7 @@ export default {
|
|
|
return {
|
|
|
navTitle1: ' > 数据管理',
|
|
|
navTitle2: '',
|
|
|
- isManufacturer: 'manufacturer', // distributor 经销商 manufacturer 厂商
|
|
|
+ isManufacturer: 'distributor', // distributor 经销商 manufacturer 厂商
|
|
|
userAccount: ''
|
|
|
}
|
|
|
},
|
|
|
@@ -69,14 +69,14 @@ export default {
|
|
|
data:token
|
|
|
}).then((res) => {
|
|
|
console.log(res);
|
|
|
- if(res.data && res.data.code === 200) {
|
|
|
+ if(res.data.code === 200) {
|
|
|
let userInfo = res.data.data;
|
|
|
if (!userInfo.agentId) {
|
|
|
this.isManufacturer = 'manufacturer';
|
|
|
console.log(this.$route.path,222)
|
|
|
- // if (this.$route.path !== '/uploadInfor') {
|
|
|
- // this.$router.replace({ path: "/uploadInfor" });
|
|
|
- // }
|
|
|
+ if (this.$route.path !== '/uploadInfor') {
|
|
|
+ this.$router.replace({ path: "/uploadInfor" });
|
|
|
+ }
|
|
|
return
|
|
|
} else {
|
|
|
if (userInfo.userRole == '1' || userInfo.userRole == '2') {
|
|
|
@@ -84,6 +84,9 @@ export default {
|
|
|
localStorage.setItem("userId", userInfo.agentId);
|
|
|
} else {
|
|
|
this.isManufacturer = 'manufacturer';
|
|
|
+ if (this.$route.path !== '/uploadInfor') {
|
|
|
+ this.$router.replace({ path: "/uploadInfor" });
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
this.userAccount = userInfo.userCode;
|