Browse Source

完善单车返利管理

zhanglei
yunuo970428 3 months ago
parent
commit
bed3fe7e91
  1. 30
      anrui-scm/anrui-scm-ui/src/views/bikerebate/bikerebatemanagement/bicyclerebatemanagementEdit.vue

30
anrui-scm/anrui-scm-ui/src/views/bikerebate/bikerebatemanagement/bicyclerebatemanagementEdit.vue

@ -122,10 +122,16 @@ export default {
calculationStandard: '',
sid: '',
vinNo: '',
brandName: '',
purchaseSystemName: '',
manufactorSettlementPrice: '',
freight: '',
topAmount: '',
estimateRebate: '',
remarks: ''
remarks: '',
expectTreatCost: '',
expectSuppCost: '',
expectSuppRemark: ''
},
rules: {
rebateTypeValue: [{ required: true, message: '返利类型不能为空', trigger: 'change' }],
@ -140,9 +146,15 @@ export default {
computed: {
estimateRebateSum() {
let estimateRebate = '0'
//
if (this.formobj.calculationModeKey === '001') {
// = - * / 100
estimateRebate = Math.round(((parseFloat(this.formobj.manufactorSettlementPrice !== '' ? this.formobj.manufactorSettlementPrice : 0) - parseFloat(this.formobj.freight !== '' ? this.formobj.freight : 0)) * (parseFloat(this.formobj.calculationStandard) / 100)) * 100) / 100
if (this.formobj.brandName === '陕汽') {
// = - - * / 100
estimateRebate = Math.round(((parseFloat(this.formobj.manufactorSettlementPrice !== '' ? this.formobj.manufactorSettlementPrice : 0) - parseFloat(this.formobj.freight !== '' ? this.formobj.freight : 0) - parseFloat(this.formobj.topAmount !== '' ? this.formobj.topAmount : 0)) * (parseFloat(this.formobj.calculationStandard) / 100)) * 100) / 100
} else {
// = - * / 100
estimateRebate = Math.round(((parseFloat(this.formobj.manufactorSettlementPrice !== '' ? this.formobj.manufactorSettlementPrice : 0) - parseFloat(this.formobj.freight !== '' ? this.formobj.freight : 0)) * (parseFloat(this.formobj.calculationStandard) / 100)) * 100) / 100
}
} else if (this.formobj.calculationModeKey === '002') {
// =
estimateRebate = this.formobj.calculationStandard
@ -243,15 +255,17 @@ export default {
calculationModeValue: '',
calculationStandard: '',
sid: '',
createOrgSid: '',
createOrgName: '',
useOrgSid: '',
useOrgName: '',
vinNo: '',
brandName: '',
purchaseSystemName: '',
manufactorSettlementPrice: '',
freight: '',
topAmount: '',
estimateRebate: '',
remarks: ''
remarks: '',
expectTreatCost: '',
expectSuppCost: '',
expectSuppRemark: ''
}
this.$refs['form_obj'].resetFields()
this.$emit('doback')

Loading…
Cancel
Save