|
|
|
@ -70,7 +70,7 @@
|
|
|
|
|
</el-col>
|
|
|
|
|
<el-col :span="8" v-if="judgeShow('customerStarRating')">
|
|
|
|
|
<jnpf-form-tip-item label="客户星级" v-if="judgeShow('customerStarRating')" prop="customerStarRating">
|
|
|
|
|
<JnpfSelect v-model="dataForm.customerStarRating" @change="changeData('customerStarRating', -1)"
|
|
|
|
|
<JnpfSelect v-model="dataForm.customerStarRating" @change="customerStarRatingChangeData"
|
|
|
|
|
placeholder="请选择" :disabled="judgeWrite('customerStarRating')" clearable :style='{ "width": "100%" }'
|
|
|
|
|
:options="customerStarRatingOptions" :props="customerStarRatingProps">
|
|
|
|
|
</JnpfSelect>
|
|
|
|
@ -560,7 +560,7 @@
|
|
|
|
|
</el-col>
|
|
|
|
|
<el-col :span="8" v-if="judgeShow('settlementMethod')">
|
|
|
|
|
<jnpf-form-tip-item label="结算方式" v-if="judgeShow('settlementMethod')" prop="settlementMethod">
|
|
|
|
|
<JnpfRadio v-model="dataForm.settlementMethod" @change="changeData('settlementMethod', -1)"
|
|
|
|
|
<JnpfRadio v-model="dataForm.settlementMethod" @change="settlementMethodChangeData"
|
|
|
|
|
:disabled="judgeWrite('settlementMethod')" optionType="default" direction="horizontal"
|
|
|
|
|
:style='{ "width": "100%" }' size="default" :options="settlementMethodOptions"
|
|
|
|
|
:props="settlementMethodProps">
|
|
|
|
@ -2159,6 +2159,40 @@ export default {
|
|
|
|
|
},
|
|
|
|
|
mounted() { },
|
|
|
|
|
methods: {
|
|
|
|
|
customerStarRatingChangeData(){
|
|
|
|
|
let settlementMethodName = this.settlementMethodOptions.filter((item)=>{
|
|
|
|
|
if(this.dataForm.settlementMethod==item.id){
|
|
|
|
|
return item.fullName
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
let customerStarRatingName = this.customerStarRatingOptions.filter((item)=>{
|
|
|
|
|
if(this.dataForm.customerStarRating==item.id){
|
|
|
|
|
return item.fullName
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
this.defaultAccountPeriodRules.forEach(item => {
|
|
|
|
|
if (customerStarRatingName[0].fullName == item.creditRating && item.settlementType == settlementMethodName[0].fullName) {
|
|
|
|
|
this.defaultAccountPeriod = item;
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
settlementMethodChangeData(){
|
|
|
|
|
let settlementMethodName = this.settlementMethodOptions.filter((item)=>{
|
|
|
|
|
if(this.dataForm.settlementMethod==item.id){
|
|
|
|
|
return item.fullName
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
let customerStarRatingName = this.customerStarRatingOptions.filter((item)=>{
|
|
|
|
|
if(this.dataForm.customerStarRating==item.id){
|
|
|
|
|
return item.fullName
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
this.defaultAccountPeriodRules.forEach(item => {
|
|
|
|
|
if (customerStarRatingName[0].fullName == item.creditRating && item.settlementType == settlementMethodName[0].fullName) {
|
|
|
|
|
this.defaultAccountPeriod = item;
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
changeData(model, index) {
|
|
|
|
|
this.isEdit = false
|
|
|
|
|
this.childIndex = index
|
|
|
|
@ -2553,18 +2587,21 @@ export default {
|
|
|
|
|
queryDefaultAccountPeriodRules('1').then(res => {
|
|
|
|
|
if (res.data.tableField102) {
|
|
|
|
|
this.defaultAccountPeriodRules = res.data.tableField102
|
|
|
|
|
var customerStarRating = this.dataForm.customerStarRating
|
|
|
|
|
if (this.dataForm.customerStarRating == '517682428312028165') {
|
|
|
|
|
this.defaultAccountPeriod = res.data.tableField102[0]
|
|
|
|
|
} else if (this.dataForm.customerStarRating == '517682463938446341') {
|
|
|
|
|
this.defaultAccountPeriod = res.data.tableField102[1]
|
|
|
|
|
} else if (this.dataForm.customerStarRating == '517682488533844997') {
|
|
|
|
|
this.defaultAccountPeriod = res.data.tableField102[2]
|
|
|
|
|
} else if (this.dataForm.customerStarRating == '517682518925771781') {
|
|
|
|
|
this.defaultAccountPeriod = res.data.tableField102[3]
|
|
|
|
|
} else if (this.dataForm.customerStarRating == '517682574965867525') {
|
|
|
|
|
this.defaultAccountPeriod = res.data.tableField102[4]
|
|
|
|
|
}
|
|
|
|
|
let settlementMethodName = this.settlementMethodOptions.filter((item)=>{
|
|
|
|
|
if(this.dataForm.settlementMethod==item.id){
|
|
|
|
|
return item.fullName
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
let customerStarRatingName = this.customerStarRatingOptions.filter((item)=>{
|
|
|
|
|
if(this.dataForm.customerStarRating==item.id){
|
|
|
|
|
return item.fullName
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
this.defaultAccountPeriodRules.forEach(item => {
|
|
|
|
|
if (customerStarRatingName[0].fullName == item.creditRating && item.settlementType == settlementMethodName[0].fullName) {
|
|
|
|
|
this.defaultAccountPeriod = item;
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
} else {
|
|
|
|
|
this.$confirm('请先配置账期规则', '提示', {
|
|
|
|
|
showCancelButton: false, //是否显示取消按钮
|
|
|
|
|