|
|
|
@ -54,7 +54,12 @@
|
|
|
|
|
<Option v-for="item in this.shopList" :value="item.id" :key="item.id">{{item.name}}</Option>
|
|
|
|
|
</Select>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div style="margin-top: 40px" v-if="companySelectDisplay">
|
|
|
|
|
<span class="name-font" style="width: 80px;display: inline-block">零售公司</span>
|
|
|
|
|
<Select v-model="modifyFrom.companyId" filterable style="width: 300px;">
|
|
|
|
|
<Option v-for="item in companyList" :value="item.id" :key="item.id">{{ item.name }}</Option>
|
|
|
|
|
</Select>
|
|
|
|
|
</div>
|
|
|
|
|
<!--确认返回-->
|
|
|
|
|
<div style="margin-top: 40px">
|
|
|
|
|
<Button type="primary" style="height: 39px;width: 101px" @click="modifyAccountConfirm()" >完成</Button>
|
|
|
|
@ -66,10 +71,14 @@
|
|
|
|
|
<script>
|
|
|
|
|
import accountManagementModify from '../../services/account/AccountManagementModify'
|
|
|
|
|
import accountManagement from '../../services/account/AccountManagement'
|
|
|
|
|
import IncreaseData from "../../services/generalize/IncreaseData";
|
|
|
|
|
|
|
|
|
|
export default {
|
|
|
|
|
|
|
|
|
|
data() {
|
|
|
|
|
return {
|
|
|
|
|
companyList: [],
|
|
|
|
|
companySelectDisplay:false,
|
|
|
|
|
name: "accountManagementModify",
|
|
|
|
|
modifyFrom: {
|
|
|
|
|
accountId: this.$route.query.accountId,
|
|
|
|
@ -80,7 +89,8 @@
|
|
|
|
|
confirmPassword: this.$route.query.password,
|
|
|
|
|
roleId: this.$route.query.roleId,
|
|
|
|
|
shopId: this.$route.query.shopId,
|
|
|
|
|
type:this.$route.query.type
|
|
|
|
|
type:this.$route.query.type,
|
|
|
|
|
companyId: this.$route.query.companyId,
|
|
|
|
|
},
|
|
|
|
|
passwordCheck:[
|
|
|
|
|
{required:true,message:'密码不能为空',trigger:'blur'},
|
|
|
|
@ -115,14 +125,22 @@
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
mounted: function () {
|
|
|
|
|
debugger
|
|
|
|
|
if(this.$route.query.roleCode === 'DZ-DIANZHANG'){
|
|
|
|
|
this.shopSelectDisplay = true;
|
|
|
|
|
this.modifyFrom.type = 1;
|
|
|
|
|
this.modifyFrom.companyId = null;
|
|
|
|
|
this.listShop();
|
|
|
|
|
} else if(this.$route.query.roleCode === "DG-DAOGOU"){
|
|
|
|
|
this.shopSelectDisplay = true;
|
|
|
|
|
this.modifyFrom.type = 4;
|
|
|
|
|
this.modifyFrom.companyId = null;
|
|
|
|
|
this.listShop();
|
|
|
|
|
}else if(this.$route.query.roleCode === 'DG-YUNYING'){
|
|
|
|
|
this.companySelectDisplay = true;
|
|
|
|
|
this.shopSelectDisplay = false;
|
|
|
|
|
this.modifyFrom.type = 2;
|
|
|
|
|
this.allCompany();
|
|
|
|
|
}
|
|
|
|
|
this.listRole();
|
|
|
|
|
},
|
|
|
|
@ -210,14 +228,24 @@
|
|
|
|
|
if(roleBean.code === 'DZ-DIANZHANG'){
|
|
|
|
|
this.shopSelectDisplay = true;
|
|
|
|
|
this.modifyFrom.type = 1;
|
|
|
|
|
this.companySelectDisplay = false;
|
|
|
|
|
this.modifyFrom.companyId = null;
|
|
|
|
|
this.listShop();
|
|
|
|
|
} else if(roleBean.code === "DG-DAOGOU"){
|
|
|
|
|
this.shopSelectDisplay = true;
|
|
|
|
|
this.modifyFrom.type = 4;
|
|
|
|
|
this.companySelectDisplay = false;
|
|
|
|
|
this.modifyFrom.companyId = null;
|
|
|
|
|
this.listShop();
|
|
|
|
|
}else if(roleBean.code === 'DG-YUNYING'){
|
|
|
|
|
this.companySelectDisplay = true;
|
|
|
|
|
this.shopSelectDisplay = false;
|
|
|
|
|
this.modifyFrom.type = 2;
|
|
|
|
|
this.allCompany();
|
|
|
|
|
} else {
|
|
|
|
|
this.shopSelectDisplay = false;
|
|
|
|
|
this.modifyFrom.shopId = null;
|
|
|
|
|
this.modifyFrom.companyId = null;
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
//所有店铺
|
|
|
|
@ -241,7 +269,26 @@
|
|
|
|
|
check(){
|
|
|
|
|
this.modifyValidate.password = this.passwordCheck;
|
|
|
|
|
this.modifyValidate.confirmPassword = this.confirmPasswordCheck;
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
allCompany(){
|
|
|
|
|
let that = this;
|
|
|
|
|
let request = {
|
|
|
|
|
userId:JSON.parse(sessionStorage.getItem("loginInfo")).userId
|
|
|
|
|
};
|
|
|
|
|
this.companyList = [];
|
|
|
|
|
IncreaseData.listOfRetailCompany(request,function (data) {
|
|
|
|
|
data = data.data;
|
|
|
|
|
if (data.code === '0001') {
|
|
|
|
|
that.$Message.error("查询零售公司出错!");
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
if (data.code === '0000') {
|
|
|
|
|
data.results.forEach(da => {
|
|
|
|
|
that.companyList.push(da);
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|