|
@@ -61,8 +61,39 @@
|
|
|
<el-table-column label="序号" type="index" align="left" width="100" show-overflow-tooltip></el-table-column>
|
|
|
<el-table-column align="left" label="经销商编码" prop="customerNumber" min-width="160" show-overflow-tooltip>
|
|
|
<template slot-scope="scope">
|
|
|
- <div v-if="scope.$index == 0">{{ searchForm.customerNumber }}</div>
|
|
|
- <div v-if="scope.$index == 1">{{ scope.row.customerNumber }}</div>
|
|
|
+ <div v-if="scope.$index == 0">
|
|
|
+ <div v-if="isCustomer">{{ searchForm.customerNumber }}</div>
|
|
|
+ <div v-else>
|
|
|
+ <el-select
|
|
|
+ size="mini"
|
|
|
+ class="dateStyle"
|
|
|
+ @change="changeCustomerNumber($event,0)"
|
|
|
+ filterable
|
|
|
+ v-model="scope.row.customerNumber"
|
|
|
+ placeholder="请选择"
|
|
|
+ >
|
|
|
+ <el-option v-for="item in customerData" :key="item.id" :label="item.number" :value="item.number"> </el-option>
|
|
|
+ </el-select>
|
|
|
+
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div v-if="scope.$index == 1">
|
|
|
+ <div v-if="isCustomer">{{ scope.row.customerNumber }}</div>
|
|
|
+ <div v-else>
|
|
|
+ <el-select
|
|
|
+ size="mini"
|
|
|
+ class="dateStyle"
|
|
|
+ @change="changeCustomerNumber($event,1)"
|
|
|
+
|
|
|
+ filterable
|
|
|
+ v-model="scope.row.customerNumber"
|
|
|
+ placeholder="请选择"
|
|
|
+ >
|
|
|
+ <el-option v-for="item in customerData" :key="item.id" :label="item.number" :value="item.number"> </el-option>
|
|
|
+ </el-select>
|
|
|
+
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
<el-table-column align="left" label="经销商名称" prop="customerName" min-width="260" show-overflow-tooltip>
|
|
@@ -174,7 +205,7 @@ export default {
|
|
|
customerNumber: ''
|
|
|
},
|
|
|
customerData: [], //经销商数据
|
|
|
- typeList: [] //返利类型数据
|
|
|
+ typeList: [], //返利类型数据
|
|
|
// rules: {
|
|
|
// theTime: [
|
|
|
// {
|
|
@@ -184,6 +215,7 @@ export default {
|
|
|
// },
|
|
|
// ],
|
|
|
// },
|
|
|
+ isCustomer: JSON.parse(localStorage.getItem('supply_user')).isCustomer
|
|
|
}
|
|
|
},
|
|
|
computed: {
|
|
@@ -225,7 +257,9 @@ export default {
|
|
|
// }
|
|
|
// return null;
|
|
|
// },
|
|
|
-
|
|
|
+ changeCustomerNumber(e,index){
|
|
|
+ this.$set(this.dataList[index],'customerNumber',e)
|
|
|
+ },
|
|
|
resetFn() {
|
|
|
this.searchForm.theTime = null
|
|
|
this.dataList.forEach(v => {
|