dev_2022-05-11
yujialong 3 years ago
parent ccc3affa99
commit f4f63e54a6
  1. 2
      src/assets/css/main.css
  2. 8
      src/store/index.js
  3. 14
      src/views/course/AddCurriculum.vue
  4. 58
      src/views/customer/AddCustomer.vue
  5. 2
      src/views/customer/Order.vue
  6. 1
      src/views/customer/customer.vue
  7. 14
      src/views/data/Product.vue
  8. 95
      src/views/order/AddOrder.vue
  9. 2
      src/views/parner/pcRole.vue
  10. 37
      src/views/parner/staff.vue
  11. 2
      src/views/system/role.vue
  12. 23
      src/views/system/staff.vue

@ -162,7 +162,7 @@ li {
width: 60%;
}
.orderTable td .normal{
width: auto;
width: 90%;
}
.orderTable .el-select>.el-input{

@ -20,7 +20,8 @@ const store = new Vuex.Store({
lastSystemId: null,
projectFields: {},
btns: [],
routes: []
routes: [],
customerPage: 1
},
actions: {
setSystemId({ state,commit },systemId) {
@ -78,7 +79,10 @@ const store = new Vuex.Store({
},
addRoutes(state,routes) {
state.routes = routes
}
},
SET_C_PAGE: (state, page) => {
state.customerPage = page
},
}
});

@ -62,11 +62,11 @@
<div class="settlement">
<el-radio v-model="form.settlementMethod" label="1">比例分成</el-radio>
<span class="label">商务经理占比</span>
<el-input v-model.trim="form.businessProportion">
<el-input v-model.trim="form.businessProportion" @change="calcProp">
<template slot="append">%</template>
</el-input>
<span class="label">产品厂商占比</span>
<el-input v-model.trim="form.manufacturerProportion">
<el-input v-model.trim="form.manufacturerProportion" @change="calcProp">
<template slot="append">%</template>
</el-input>
</div>
@ -498,6 +498,16 @@ export default {
}).catch(err => {
});
},
//
calcProp() {
const p1 = this.form.businessProportion
const p2 = this.form.manufacturerProportion
if (p1 && p2) {
if(isNaN(p1)) return this.$message.warning('商务经理占比请输入数字')
if(isNaN(p2)) return this.$message.warning('产品厂商占比请输入数字')
if(+p1 + +p2 !== 100) return this.$message.warning('比例分成总和须为100%,请重新修改')
}
},
handleExceed(files, fileList) { //
this.$message.warning("当前限制选择 1 个文件,如需更换,请删除上一个文件再重新选择!");
},

@ -10,12 +10,12 @@
</div>
</el-card>
<el-card shadow="hover" :class="customerId ? 'mgb20' : 'card'">
<el-card shadow="hover" class="card">
<div class="tabs" v-if="customerId">
<a class="item" v-for="(item, i) in tabs" :key="i" :class="{active: i == curTab}" @click="tabChange(i)">{{ item }}</a>
</div>
<div v-show="curTab === 'tab1'">
<el-form style="margin-top: 20px" :model="form" :rules="rules" ref="form" label-width="120px" class="flex-start-around" :disabled="isDetail">
<el-form :model="form" :rules="rules" ref="form" label-width="120px" class="flex-start-around info" :disabled="isDetail">
<el-col :span="6" style="margin-right: 60px;">
<el-form-item prop="countries" label="国家">
<el-select v-model="form.countries" clearable placeholder="请选择国家">
@ -76,8 +76,9 @@
</el-form-item>
</el-col>
</el-form>
<div style="text-align: center">
<el-button v-if="!isDetail" type="primary" v-preventReClick @click="saveAdd('form')">确定</el-button>
<div v-if="!isDetail" style="margin-top: 20px;text-align: center">
<el-button type="primary" v-preventReClick @click="saveAdd('form')">确定</el-button>
<el-button v-preventReClick @click="$router.back()">取消</el-button>
</div>
</div>
@ -104,7 +105,7 @@
<el-button type="primary" @click="exportList">导出列表</el-button>
</div>
</div>
<el-table :data="products" class="orderTable" stripe header-align="center" @selection-change="handleSelectionChange" row-key="customerId">
<el-table :data="products" class="orderTable" stripe header-align="center" @selection-change="handleSelectionChange" row-key="dataOrCourseId">
<el-table-column type="selection" width="55" align="center" :reserve-selection="true"></el-table-column>
<el-table-column type="index" width="100" label="序号" align="center">
</el-table-column>
@ -158,7 +159,7 @@
<el-input style="width: 250px;" placeholder="请输入订单编号、内容" prefix-icon="el-icon-search" clearable v-model="form3.keyword"></el-input>
</div>
</div>
<el-table :data="orders" class="orderTable" stripe header-align="center" @selection-change="handleSelectionChange" row-key="customerId">
<el-table :data="orders" class="orderTable" stripe header-align="center" @selection-change="handleSelectionChange" row-key="orderId">
<el-table-column type="selection" width="55" align="center" :reserve-selection="true"></el-table-column>
<el-table-column type="index" width="100" label="序号" align="center">
</el-table-column>
@ -277,7 +278,7 @@ export default {
token: sessionStorage.getItem('token'),
customerId : this.$route.query.id,
isDetail : Boolean(this.$route.query.show),
curTab: 'tab1',
curTab: this.$route.query.type || 'tab1',
tabs: {
tab1: '基本信息',
tab2: '已订阅产品',
@ -414,7 +415,7 @@ export default {
],
products: [],
productAll: [],
pageProduct: 1,
pageProduct: this.$route.query.type === 'tab2' ? (+this.$route.query.page || 1) : 1,
pageSizeProduct: 10,
totalProduct: 0,
@ -449,7 +450,7 @@ export default {
name: '待发货'
}
],
pageOrder: 1,
pageOrder: this.$route.query.type === 'tab3' ? (+this.$route.query.page || 1) : 1,
pageSizeOrder: 10,
totalOrder: 0,
orders: [],
@ -457,7 +458,7 @@ export default {
bmsKeyword: '',
bms: [],
pageBm: 1,
pageBm: this.$route.query.type === 'tab5' ? (+this.$route.query.page || 1) : 1,
pageSizeBm: 10,
totalBm: 0,
@ -487,9 +488,10 @@ export default {
},500)
},
'form3.keyword': function(val) {
this.pageOrder = 1
clearTimeout(this.searchTimer)
this.searchTimer = setTimeout(() => {
this.filterOrder()
this.handlePageOrder()
},500)
},
bmsKeyword: function(val) {
@ -562,6 +564,15 @@ export default {
e.endTime = connect ? list[list.length - 1].endTime : list[0].endTime
e.status = '未生效'
e.orderEnable = list[0].isEnable
//
if (!connect && list[1]) {
const notActive = list.slice(1) //
e.other = ''
notActive.map(j => {
e.other += `<br>${j.startTime} ~ ${j.endTime}`
})
}
} else if (now > new Date(list[list.length - 1].endTime).getTime()) {
e.status = '已过期'
} else {
@ -609,7 +620,7 @@ export default {
e.startAndEndTime = e.status === '已过期' ? '' : e.startTime + ' ~ ' + e.endTime
e.productTypeName = productTypeList.find(n => n.id === e.productType).name
// 1 0
e.isEnable = (e.status === '已过期' || !e.orderEnable) ?
e.isEnable = (e.status === '未生效' || e.status === '已过期' || !e.orderEnable) ?
0 :
1
}
@ -621,7 +632,7 @@ export default {
},
//
getRemain(startTime, endTime) {
return parseInt(((new Date(endTime).getTime() - new Date(startTime).getTime()) / 86400000)) + 1
return parseInt(((new Date(endTime).getTime() - new Date(startTime).getTime()) / 86400000))
},
//
handlePage() {
@ -630,6 +641,7 @@ export default {
handleCurrentChangeProduct(val) {
this.pageProduct = val
this.handlePage()
this.$router.push(`addcustomer?id=${this.customerId}&type=tab2&page=${val}`)
},
//
filterForm2() {
@ -670,7 +682,7 @@ export default {
customerName: this.form.customerName,
orderStatus,
orderType,
pageNo: this.pageOrder,
pageNo: 1,
pageSize: 10000,
provinceId: ''
}).then(({ orderPage }) => {
@ -688,7 +700,7 @@ export default {
filterOrder() {
const { keyword } = this.form3
const { orders } = this
this.orders = keyword ? orders.filter(e => e.orderNumber.includes(keyword) || e.orderContent.includes(keyword)) : this.orderAll
this.orders = keyword ? this.orderAll.filter(e => e.orderNumber.includes(keyword) || e.orderContent.includes(keyword)) : orders
},
//
handlePageOrder() {
@ -698,6 +710,7 @@ export default {
handleCurrentChangeOrder(val) {
this.pageOrder = val
this.handlePageOrder()
this.$router.push(`addcustomer?id=${this.customerId}&type=tab3&page=${val}`)
},
//
toOrderDetail(row) {
@ -719,6 +732,7 @@ export default {
handleCurrentChangeBm(val) {
this.pageBm = val
this.getBm()
this.$router.push(`addcustomer?id=${this.customerId}&type=tab5&page=${val}`)
},
//
toOrder(row) {
@ -727,6 +741,11 @@ export default {
tabChange(index) {
this.curTab = index
this.$router.push(`addcustomer?id=${this.customerId}&type=${index}`)
this.pageProduct = 1
this.pageOrder = 1
this.pageBm = 1
index === 'tab3' && this.handlePageOrder()
},
//
getCityData(){
@ -938,7 +957,7 @@ export default {
},
goback(){
this.$router.back()
this.$router.push(`customer?page=${this.$store.state.customerPage}`)
}
}
};
@ -950,6 +969,7 @@ export default {
}
.card {
min-height: calc(100vh - 260px);
margin-bottom: 20px;
}
.addhr_tag{
background-color: #666;
@ -976,4 +996,10 @@ export default {
line-clamp: 2;
-webkit-box-orient: vertical;
}
.info {
margin-top: 20px;
.el-select {
width: 100%;
}
}
</style>

@ -5,7 +5,7 @@
<div class="per_title" v-preventReClick @click="back">
<i class="el-icon-arrow-left"></i>
<span class="per_back">返回</span>
<span class="per_school">{{ $route.query.userName }}</span>
<span class="per_school">{{ $route.query.userName }}的订单</span>
</div>
</div>
</el-card>

@ -236,6 +236,7 @@ export default {
},
handleCurrentChange(val) {
this.page = val
this.$store.commit('SET_C_PAGE', val)
this.$router.push(`customer?page=${val}`)
this.getData()
},

@ -76,13 +76,13 @@
<div class="settle-item">
<div style="margin-bottom: 10px">
<span class="label">商务经理占比</span>
<el-input v-model.trim="businessProportion">
<el-input v-model.trim="businessProportion" @change="calcProp">
<template slot="append">%</template>
</el-input>
</div>
<div>
<span class="label">产品厂商占比</span>
<el-input v-model.trim="manufacturerProportion">
<el-input v-model.trim="manufacturerProportion" @change="calcProp">
<template slot="append">%</template>
</el-input>
</div>
@ -491,6 +491,16 @@ export default {
this.page = val
this.getData()
},
//
calcProp() {
const p1 = this.businessProportion
const p2 = this.manufacturerProportion
if (p1 && p2) {
if(isNaN(p1)) return this.$message.warning('商务经理占比请输入数字')
if(isNaN(p2)) return this.$message.warning('产品厂商占比请输入数字')
if(+p1 + +p2 !== 100) return this.$message.warning('比例分成总和须为100%,请重新修改')
}
},
//
closeProduct(){
this.productName = ''

@ -174,12 +174,11 @@
<el-table-column label="市场价" align="center" min-width="170">
<template slot-scope="scope">
<div class="small">
<el-input class="normal" disabled v-model="scope.row.marketValue" placeholder=""
type="text"></el-input>
<el-input class="normal" disabled v-model="scope.row.marketValue" type="text"></el-input>
</div>
</template>
</el-table-column>
<el-table-column label="折扣率 " align="center" min-width="100">
<el-table-column label="折扣率 " align="center" min-width="110">
<template slot-scope="scope">
<el-input class="normal" disabled v-model="scope.row.discountRate" placeholder=""
type="text" size="small" style="width: 100%"></el-input>
@ -193,7 +192,7 @@
@input="scope.row.finalPrice = scope.row.finalPrice.replace(/^\D*(\d*(?:\.\d{0,2})?).*$/g, '$1')"
@change="[allAmount($event,scope.row),calculateDiscountCourse($event,scope.row)]"
v-model="scope.row.finalPrice"
type="text"></el-input>
type="text"></el-input>
</div>
</template>
</el-table-column>
@ -204,7 +203,7 @@
:disabled="viewDisabled"
@input="scope.row.settlementPrice = scope.row.settlementPrice.replace(/^\D*(\d*(?:\.\d{0,2})?).*$/g, '$1')"
v-model="scope.row.settlementPrice"
type="text"></el-input>
type="text"></el-input>
</div>
</template>
</el-table-column>
@ -222,18 +221,25 @@
@click="delCourseForm(scope.$index)"
style="margin-right:10px;"
>删除</el-button>
<!-- 1: 未生效2生效中3已过期 -->
<!--
1查看时不可操作
2发货和启用不要同时出现生效前只会显示发货不发货按钮生效后只显示禁启用按钮
3处理中的订单显示发货不显示禁用
-->
<el-switch
v-if="scope.row.status === 1 || dispose || isAdd"
style="margin-right:10px;"
v-if='dispose || (!editDisabled&&!viewDisabled)'
v-model="scope.row.ship"
:active-value="1"
:inactive-value="0"
:active-text="scope.row.ship ? '已发货' : '未发货'"
:disabled="viewDisabled"
@change="handleDeliver($event,scope.row)">
</el-switch>
<el-switch
v-show="scope.row.ship && editDisabled && !dispose"
:disabled="viewDisabled"
v-if="!dispose && (scope.row.status === 2 || scope.row.status === 3)"
:disabled="viewDisabled || scope.row.status === 3"
v-model="scope.row.isEnable"
:active-value="1"
:inactive-value="0"
@ -362,26 +368,26 @@
</template>
</el-table-column>
<!-- 金额自动计算计算方式账号数*成交价且可以手动修改保留两位小数 -->
<el-table-column label="成交价" align="center" min-width="180">
<el-table-column label="成交价" align="center" min-width="160">
<template slot-scope="scope">
<div class="small">
<el-input :class="['normal', scope.row.finalPrice === '' && whetherSubmit?'red':'']"
<el-input style="width: 80%" :class="['normal', scope.row.finalPrice === '' && whetherSubmit?'red':'']"
:disabled="viewDisabled||editDisabled"
@blur="[allAmount($event,scope.row),dealFinalValue($event,scope.row)]"
@input="scope.row.finalPrice = scope.row.finalPrice.replace(/^\D*(\d*(?:\.\d{0,2})?).*$/g, '$1')"
v-model="scope.row.finalPrice"
type="text"></el-input>
type="text"></el-input>
</div>
</template>
</el-table-column>
<el-table-column label="结算价" align="center" min-width="130">
<el-table-column label="结算价" align="center" min-width="160">
<template slot-scope="scope">
<div class="small">
<el-input :class="['normal', scope.row.settlementPrice === '' && whetherSubmit?'red':'']"
<el-input style="width: 80%" :class="['normal', scope.row.settlementPrice === '' && whetherSubmit?'red':'']"
:disabled="viewDisabled"
@input="scope.row.settlementPrice = scope.row.settlementPrice.replace(/^\D*(\d*(?:\.\d{0,2})?).*$/g, '$1')"
v-model="scope.row.settlementPrice"
type="text"></el-input>
type="text"></el-input>
</div>
</template>
</el-table-column>
@ -395,8 +401,8 @@
style="margin-right:10px;"
>删除</el-button>
<el-switch
v-if="scope.row.status === 1 || dispose || isAdd"
style="margin-right:10px;"
v-if='dispose || (!editDisabled&&!viewDisabled)'
v-model="scope.row.ship"
:active-value="1"
:inactive-value="0"
@ -404,7 +410,7 @@
@change="handleDeliver($event,scope.row)">
</el-switch>
<el-switch
v-show="scope.row.ship && editDisabled && !dispose"
v-if="!dispose && (scope.row.status === 2 || scope.row.status === 3)"
:disabled="viewDisabled"
v-model="scope.row.isEnable"
:active-value="1"
@ -883,6 +889,7 @@ export default {
const promises = []
const { customerId } = form
const list = []
//
if (orderOther.find(e => e.authority)) {
promises.push(new Promise((resolve, reject) => {
this.$post(this.api.renew, {
@ -913,14 +920,13 @@ export default {
});
},
setStartDate(renewList, orderOther) {
console.log(555)
let list = orderOther.map(e => {
const now = Date.now()
const item = renewList.find(n => n.dataOrCourseId === e.dataOrCourseId && n.authority === e.authority) // renew
if (item) {
//
if (this.renewDisabled) {
let end = Date.parse(item.endTime);
let now = +new Date();
if (now < end) {
let time = new Date(item.endTime.split(" ")[0])
time = new Date(time.setDate(time.getDate() + 1))
@ -936,6 +942,15 @@ export default {
e.endTime = item.endTime.split(" ")[0];
}
}
const startTime = new Date(e.startTime)
const endTime = new Date(e.endTime)
// 1: 23
e.status = now < startTime ?
1 :
now > startTime && now < endTime ?
2 :
3
if (e.status === 3) e.isEnable = 0 //
return e;
});//
@ -1126,7 +1141,7 @@ export default {
ship: 0,// 01
authority: 1, // 01
options: 1,
settlementPrice: '', //
settlementPrice: orderType === 2 ? 0 : '', //
settlementMethod: e.settlementMethod, // 01
settlementPriceUnit: e.settlementPrice, //
businessProportion: e.businessProportion, //
@ -1234,10 +1249,10 @@ export default {
startTime: new Date(),//
endTime: "", //
remainingPeriod: "",//
marketValue: e.market, //
marketValue: e.market, //
finalPrice: '',//
finalValue: '', //
marketValue: '', //
marketPrice: e.market, //
finalPrice: orderType === 2 ? 0 : '',//
finalValue: orderType === 2 ? 0 : '', //
discountRate: "",//
accountNum: "",//
totalAmount: orderType === 2 ? 0 : '',//
@ -1245,7 +1260,7 @@ export default {
ship: 0,// 01
authority: 0,//
options:1,
settlementPrice: '', //
settlementPrice: orderType === 2 ? 0 : '', //
settlementMethod: e.settlementMethod, // 01
settlementPriceUnit: e.settlementPrice, //
businessProportion: e.businessProportion, //
@ -1357,18 +1372,16 @@ export default {
options === 1 ?
12 :
1)).toFixed(2)
this.calculateDiscount(val, row)
}
},
// **//
dealComputers(e, row) {
const { finalValue, accountNum, periodOfUse, options } = row
if (finalValue && accountNum) {
row.finalPrice = ((!options ?
finalValue / 365 * periodOfUse :
options === 1 ?
finalValue / 12 * periodOfUse :
finalValue * periodOfUse) * accountNum).toFixed(2)
row.finalPrice = Math.round(finalValue * periodOfUse * accountNum)
}
this.dealSettlePrice(row)
this.allAmount(e, row)
},
//
@ -1376,7 +1389,7 @@ export default {
const unit = row.options // 使
const useUnit = row.periodOfUse // 使
let sPrice = ''
if (row.settlementMethod === '0') {
if (row.settlementMethod == 0) {
// **/**(1)
const priceUnit = row.settlementPriceUnit
sPrice = ((!unit ?
@ -1388,7 +1401,7 @@ export default {
row.accountNum)).toFixed(2)
} else {
// *
sPrice = row.finalPrice * row.businessProportion / 100
sPrice = (row.finalPrice * row.businessProportion / 100).toFixed(2)
}
row.settlementPrice = this.handleNaN(sPrice)
},
@ -1417,17 +1430,15 @@ export default {
row.remainingPeriod = endYears
const unit = row.options // 使
const useUnit = row.periodOfUse // 使
//
if (row.authority) {
const price = row.marketPrice //
// //365,/12)
row.marketValue = ((!unit ?
price / 365 * useUnit :
unit === 1 ?
price / 12 * useUnit :
price * useUnit)).toFixed(2)
}
this.dealSettlePrice(row)
let price = row.marketPrice //
// //365,/12)
row.marketValue = ((!unit ?
price / 365 * useUnit :
unit === 1 ?
price / 12 * useUnit :
price * useUnit)).toFixed(2)
this.dealComputers(e, row)
// +1
if (isDate) {
const cId = row.dataOrCourseId

@ -109,7 +109,7 @@ export default {
methods: {
getData() {
// platformId 4setting.js
this.$get(`${this.api.roleList}?page=${this.page}&size=${this.pageSize}&name=${this.keyword}&platformId=${this.platformId}`).then(res => {
this.$get(`${this.api.roleList}?page=${this.page}&size=${this.pageSize}&name=${this.keyword}&platformId=${this.platformId}&port=0`).then(res => {
this.listData = res.rolePage.records;
this.total = res.rolePage.total;
}).catch(res => {});

@ -4,7 +4,7 @@
<div class="side">
<div>
<div class="flex-between">
<h6 class="p-title" style="margin-bottom: 0">或然城市合伙人</h6>
<h6 class="p-title" style="margin-bottom: 0;cursor: pointer" @click="getAll">或然城市合伙人</h6>
<el-button type="text" @click="addOrg">添加分类</el-button>
</div>
@ -232,13 +232,14 @@ export default {
qrcode: '',
expireTime: '',
curTeamId: '',
submiting: false //
submiting: false, //
setKey: ''
};
},
watch: {
keyWord: function(val) {
clearTimeout(this.searchTimer);
this.searchTimer = setTimeout(this.getList, 500);
this.searchTimer = setTimeout(this.initData, 500);
}
},
mounted() {
@ -250,10 +251,11 @@ export default {
const res = await this.$post(this.api.listParner)
const list = res.treeList
// children
const handleLeaf = list => {
const handleLeaf = (list, ids) => {
list.map(e => {
e.ids = ids ? [...ids, e.id] : [e.id]
if (e.children.length) {
handleLeaf(e.children)
handleLeaf(e.children, e.ids)
} else {
delete e.children
}
@ -261,6 +263,10 @@ export default {
}
handleLeaf(list)
this.orgList = list
//
this.setKey && this.$nextTick(() => {
this.$refs.orgTree.setCurrentKey(this.setKey)
})
this.getList()
},
//
@ -284,7 +290,7 @@ export default {
partnerClassificationName: data.partnerClassificationName
}
this.orgVisible = true
const ids = data.ids
const { ids } = data
ids.splice(ids.length - 1, 1)
this.cascaderValue = ids
},
@ -332,6 +338,7 @@ export default {
//
this.$post(this.api.updateParner, form).then(res => {
util.successMsg("编辑成功!")
this.setKey = form.id
this.closeOrg()
}).catch(err => {})
}
@ -342,7 +349,7 @@ export default {
getTeamId(list) {
for (const i in list) {
const e = list[i]
if (e.isTeam) {
if (e.isTeam && !this.curTeamId) {
this.curTeamId = e.id
break
} else {
@ -352,16 +359,15 @@ export default {
},
//
handleNodeClick(data) {
this.curTeamId = data.id
this.curTeamId = ''
if (data.isTeam) {
this.curTeamId = data.id
} else {
this.getTeamId(data.children)
}
if (this.curTeamId) {
this.$refs.orgTree.setCurrentKey(this.curTeamId)
this.getList()
}
if (!this.curTeamId) this.curTeamId = data.id
this.$refs.orgTree.setCurrentKey(this.curTeamId)
this.initData()
this.$refs.table.clearSelection()
},
//
@ -370,6 +376,11 @@ export default {
this.cascaderValue = []
this.getOrg()
},
//
getAll() {
this.curTeamId = ''
this.getList()
},
//
getList() {
this.$post(this.api.partnerAccountList, {
@ -454,7 +465,7 @@ export default {
border-right: 1px solid rgba(0, 0, 0, 0.06);
}
.right {
width: calc(100% - 374px);
flex: 1;
padding: 24px 0;
}
}

@ -107,7 +107,7 @@ export default {
},
methods: {
getData() {
this.$get(`${this.api.roleList}?page=${this.page}&size=${this.pageSize}&name=${this.keyword}&platformId=${Setting.platformId}`).then(res => {
this.$get(`${this.api.roleList}?page=${this.page}&size=${this.pageSize}&name=${this.keyword}&platformId=${Setting.platformId}&port=0`).then(res => {
this.listData = res.rolePage.records;
this.total = res.rolePage.total;
}).catch(res => {});

@ -555,7 +555,25 @@ export default {
this.$get(`${this.api.staffDetail}?accountId=${row.accountId}`).then(res => {
const { data } = res
const { staffArchitectureId, roleId } = data
if (roleId) data.roleList = roleId.split(',').map(e => Number(e))
if (roleId) {
const roleList = roleId.split(',').map(e => Number(e))
const list = this.roleList
if (roleList.length) {
let has = false //
for (const i in roleList) {
if (list.find(n => n.id === roleList[i])) {
has = true
break
}
}
if (!has) {
util.warningMsg('角色被删请重新选择')
data.roleList = []
} else {
data.roleList = roleList
}
}
}
if (staffArchitectureId) {
handleArchId(this.orgList, staffArchitectureId.split(',').map(e => Number(e)))
data.staffArchitectureId = archId
@ -563,12 +581,11 @@ export default {
this.form = data
this.originAccount = data.account
this.originWorkNumber = data.workNumber
console.log(333, this.orgList)
}).catch(res => {})
},
//
getRole() {
this.$get(`${this.api.roleList}?page=1&size=1000&name=&platformId=${Setting.platformId}`).then(res => {
this.$get(`${this.api.roleList}?page=1&size=1000&name=&platformId=${Setting.platformId}&port=0`).then(res => {
this.roleList = res.rolePage.records
}).catch(res => {})
},

Loading…
Cancel
Save