剧本代码调整

This commit is contained in:
joylink_cuiweidong 2020-05-18 13:32:25 +08:00
parent 3e64c6da02
commit 25b1c09141

View File

@ -213,22 +213,20 @@ export default {
checkDisabled(role) {
if (!this.$route.fullPath.includes('design/displayNew/demon')) {
if (this.$route.query.prdType == '01') {
return role !== 'Attendant' && role !== 'no';
} else if (this.$route.query.prdType == '02') {
return role !== 'Dispatcher' && role !== 'no';
} else if (this.$route.query.prdType == '04') {
return role !== 'Driver' && role !== 'no';
}
const prdType = this.$route.query.prdType;
return this.judgeDisabled(prdType, role);
} else {
const prdType = this.$store.state.training.prdType;
if ( prdType == '01') {
return role !== '行值' && role !== 'no';
} else if (prdType == '02') {
return role !== '行调' && role !== 'no';
} else if (prdType == '04') {
return role !== '司机' && role !== 'no';
}
return this.judgeDisabled(prdType, role);
}
},
judgeDisabled(prdType, role) {
if ( prdType == '01') {
return role !== '行值' && role !== 'no';
} else if (prdType == '02') {
return role !== '行调' && role !== 'no';
} else if (prdType == '04') {
return role !== '司机' && role !== 'no';
}
},