Commit d6d3c22f authored by Marcus's avatar Marcus

Merge remote-tracking branch 'origin/dev' into dev

parents 5f36b447 b62d56ea
...@@ -162,6 +162,7 @@ export default { ...@@ -162,6 +162,7 @@ export default {
if (!!this.customerId) getCustomerContactsListByCustomer({customerId: this.customerId}).then(r => { if (!!this.customerId) getCustomerContactsListByCustomer({customerId: this.customerId}).then(r => {
this.customerContactsList = r.data this.customerContactsList = r.data
this.customerFollow.form.customerId = this.customerId this.customerFollow.form.customerId = this.customerId
this.customerFollow.form.bizId = this.id
}) })
listServiceUser().then(r => { listServiceUser().then(r => {
this.serviceUserList = r.data this.serviceUserList = r.data
......
...@@ -29,7 +29,8 @@ export default { ...@@ -29,7 +29,8 @@ export default {
multiple: Boolean, multiple: Boolean,
clearable: Boolean, clearable: Boolean,
defaultable: Boolean, // 没有值的时候是否选择第一项 defaultable: Boolean, // 没有值的时候是否选择第一项
disabled: Boolean disabled: Boolean,
test: String
}, },
computed:{ computed:{
optionsFormated(){ optionsFormated(){
...@@ -53,9 +54,15 @@ export default { ...@@ -53,9 +54,15 @@ export default {
}, },
optionsFormated(){ optionsFormated(){
this.setDefault() this.setDefault()
},
test(val, old){
console.warn('test变化', val, old)
} }
}, },
created(){ created(){
if(this.test == 'allPriceUnit'){
console.log('allPriceUnit selector', this.value, this.defaultable)
}
this.valueSync = this.value this.valueSync = this.value
this.setDefault() this.setDefault()
}, },
......
...@@ -52,27 +52,43 @@ ...@@ -52,27 +52,43 @@
<!-- 列表 --> <!-- 列表 -->
<el-table v-loading="loading" :data="list"> <el-table v-loading="loading" :data="list">
<el-table-column :label="$t('客货投诉')" align="center" prop="code" >
</el-table-column>
<el-table-column :label="$t('投诉类型')" align="center" prop="type">
<template slot-scope="scope">
<dict-tag :type="DICT_TYPE.CUSTOMER_COMPLAINT_TYPE" :value="scope.row.type" />
</template>
</el-table-column>
<el-table-column :label="$t('客户名称')" align="center" > <el-table-column :label="$t('客户名称')" align="center" >
<template slot-scope="scope"> <template slot-scope="scope">
<div>{{ formatCustomerName(scope.row.customerId) }}</div> <div>{{ formatCustomerName(scope.row.customerId) }}</div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('投诉类型')" align="center" prop="type"> <el-table-column :label="$t('投诉日期')" align="center" width="180">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :type="DICT_TYPE.CUSTOMER_COMPLAINT_TYPE" :value="scope.row.type" /> <span>{{ parseTime(scope.row.createTime)}}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('订单号')" align="center" prop="orderId" /> <el-table-column :label="$t('登记客服')" align="center" prop="adminNickname">
<el-table-column :label="$t('提单号')" align="center" prop="ladingbillId" /> </el-table-column>
<el-table-column :label="$t('投诉内容')" align="center" prop="content" /> <el-table-column :label="$t('状态')" align="center" prop="status">
<el-table-column :label="$t('处理状态')" align="center" prop="status">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :type="DICT_TYPE.CUSTOMER_COMPLAINT_STATUS" :value="scope.row.status" /> <dict-tag :type="DICT_TYPE.CUSTOMER_COMPLAINT_STATUS" :value="scope.row.status" />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('创建时间')" align="center" prop="createTime" width="180"> <el-table-column :label="$t('提单号')" align="center" prop="ladingbillId" />
<el-table-column :label="$t('订单号')" align="center" prop="orderId" />
<el-table-column :label="$t('处理时间')" align="center" prop="handleAt" width="180">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ parseTime(scope.row.createTime) }}</span> <span>{{ parseTime(scope.row.handleAt)}}</span>
</template>
</el-table-column>
<el-table-column :label="$t('赔付金额')" align="center" prop="handleAt" width="180">
<template slot-scope="scope">
{{scope.row.indemnity || '0.00'}}
<dict-tag
:value="scope.row.currencyUnit"
:type="DICT_TYPE.COMMISSION_CURRENCY_TYPE"></dict-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('操作')" align="center" class-name="small-padding fixed-width"> <el-table-column :label="$t('操作')" align="center" class-name="small-padding fixed-width">
...@@ -194,8 +210,7 @@ ...@@ -194,8 +210,7 @@
<el-dialog :title="title" :visible.sync="openCustomer" width="900px" append-to-body> <el-dialog :title="title" :visible.sync="openCustomer" width="900px" append-to-body>
<el-form ref="form" :model="form" label-width="80px"> <el-form ref="form" :inline="true" :model="form" label-width="80px">
<div class="formShow">
<el-form-item :label="$t('客户名称')+':'"> <el-form-item :label="$t('客户名称')+':'">
<div>{{ formatCustomerName(form.customerId) }}</div> <div>{{ formatCustomerName(form.customerId) }}</div>
</el-form-item> </el-form-item>
...@@ -216,7 +231,6 @@ ...@@ -216,7 +231,6 @@
<dict-tag :type="DICT_TYPE.CUSTOMER_COMPLAINT_STATUS" :value="form.status" /> <dict-tag :type="DICT_TYPE.CUSTOMER_COMPLAINT_STATUS" :value="form.status" />
</el-form-item> </el-form-item>
</div> </div>
</div>
<el-form-item :label="$t('投诉内容')+':'" > <el-form-item :label="$t('投诉内容')+':'" >
<div>{{form.content|| $t('无')}}</div> <div>{{form.content|| $t('无')}}</div>
</el-form-item> </el-form-item>
...@@ -536,7 +550,7 @@ export default { ...@@ -536,7 +550,7 @@ export default {
this.exportLoading = true; this.exportLoading = true;
return exportCustomerComplaintExcel(params); return exportCustomerComplaintExcel(params);
}).then(response => { }).then(response => {
this.$download.excel(response, '${table.classComment}.xls'); this.$download.excel(response, '客户投诉列表.xls');
this.exportLoading = false; this.exportLoading = false;
}).catch(() => {}); }).catch(() => {});
}, },
......
...@@ -88,7 +88,7 @@ ...@@ -88,7 +88,7 @@
<!-- </el-descriptions> --> <!-- </el-descriptions> -->
</el-card> </el-card>
<el-card class="card amountCard"> <el-card class="card amountCard">
<div slot="header" class="card-title">{{ $t('订单信息') }}</div> <div slot="header" class="card-title">{{ $t('应收明细') }}</div>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
type="primary" type="primary"
...@@ -1139,21 +1139,22 @@ export default { ...@@ -1139,21 +1139,22 @@ export default {
} }
// params.receiptAccountList.length = params.receiptAccountList.length - 1 // params.receiptAccountList.length = params.receiptAccountList.length - 1
params.receiptAccountList.splice(params.receiptAccountList.length - 1,1)
var saveStatus = true var saveStatus = true
params.receiptAccountList.map(v => { params.receiptAccountList.forEach(v => {
if(!v.platformAccountId){ if(v.type!='total'){
saveStatus = false if(!v.platformAccountId){
} saveStatus = false
var bankname = this.bankData.filter(item=>item.id == v.platformAccountId) }
if(bankname.length>0){ var bankname = this.bankData.filter(item=>item.id == v.platformAccountId)
v.platformAccountName = bankname[0].baAccountName if(bankname.length>0){
v.platformAccountNo = bankname[0].baAccountNum v.platformAccountName = bankname[0].baAccountName
v.platformAccountBlankName = bankname[0].baBankName v.platformAccountNo = bankname[0].baAccountNum
v.platformAccountBlankName = bankname[0].baBankName
}
delete v.discountTotal
v.writeOffRate = Number(v.writeOffRate)
} }
delete v.discountTotal
v.writeOffRate = Number(v.writeOffRate)
return v
}) })
if(!saveStatus){ if(!saveStatus){
this.$modal.msgError(this.$t('请添加收款账户')); this.$modal.msgError(this.$t('请添加收款账户'));
...@@ -1178,10 +1179,11 @@ export default { ...@@ -1178,10 +1179,11 @@ export default {
}); });
if (valid) { if (valid) {
this.saveBtnLoading = true this.saveBtnLoading = true
params.receiptAccountList.splice(params.receiptAccountList.length - 1,1)
if (this.id && this.id != 0) { if (this.id && this.id != 0) {
updateReceipt(params).then(res => { updateReceipt(params).then(res => {
this.$modal.msgSuccess(this.$t('修改成功')); this.$modal.msgSuccess(this.$t('修改成功'));
this.$router.back(); this.$store.dispatch('tagsView/delCurrentView')
}).finally(() => { }).finally(() => {
this.saveBtnLoading = false this.saveBtnLoading = false
}) })
...@@ -1189,7 +1191,7 @@ export default { ...@@ -1189,7 +1191,7 @@ export default {
params.currencyId = this.showCurrencyId params.currencyId = this.showCurrencyId
createReceipt(params).then(res => { createReceipt(params).then(res => {
this.$modal.msgSuccess(this.$t('保存成功')); this.$modal.msgSuccess(this.$t('保存成功'));
this.$router.back(); this.$store.dispatch('tagsView/delCurrentView')
}).finally(() => { }).finally(() => {
this.saveBtnLoading = false this.saveBtnLoading = false
}) })
...@@ -1201,11 +1203,12 @@ export default { ...@@ -1201,11 +1203,12 @@ export default {
this.$refs.form.validate ((valid)=>{ this.$refs.form.validate ((valid)=>{
if (valid) { if (valid) {
this.saveBtnLoading = true this.saveBtnLoading = true
params.receiptAccountList.splice(params.receiptAccountList.length - 1,1)
if (this.id && this.id != 0) { if (this.id && this.id != 0) {
if(params.state==0) params.state = 1 if(params.state==0) params.state = 1
updateReceipt(params).then(res => { updateReceipt(params).then(res => {
this.$modal.msgSuccess(this.$t('修改成功')); this.$modal.msgSuccess(this.$t('修改成功'));
this.$router.back(); this.$store.dispatch('tagsView/delCurrentView')
}).finally(() => { }).finally(() => {
this.saveBtnLoading = false this.saveBtnLoading = false
}) })
...@@ -1213,7 +1216,7 @@ export default { ...@@ -1213,7 +1216,7 @@ export default {
params.currencyId = this.showCurrencyId params.currencyId = this.showCurrencyId
createReceipt(params).then(res => { createReceipt(params).then(res => {
this.$modal.msgSuccess(this.$t('新增成功')); this.$modal.msgSuccess(this.$t('新增成功'));
this.$router.back(); this.$store.dispatch('tagsView/delCurrentView')
}).finally(() => { }).finally(() => {
this.saveBtnLoading = false this.saveBtnLoading = false
}) })
......
...@@ -5,18 +5,18 @@ ...@@ -5,18 +5,18 @@
<div style="text-align: center;font-weight: bold;font-size: 26px;padding: 22px 0;border-top: 1px solid #666;border-left:1px solid #666;border-right: 1px solid #666;">捷道货运收款单</div> <div style="text-align: center;font-weight: bold;font-size: 26px;padding: 22px 0;border-top: 1px solid #666;border-left:1px solid #666;border-right: 1px solid #666;">捷道货运收款单</div>
<table border="1" style="width: 100%;text-align: center;border-collapse: collapse; "> <table border="1" style="width: 100%;text-align: center;border-collapse: collapse; ">
<tr> <tr>
<td style="font-weight: bold;width:12.5%">部门</td> <td style="font-weight: bold;width:12.5%">{{$t('部门')}}</td>
<td style="width:12.5%">{{form?form.departmentName:''}}</td> <td style="width:12.5%">{{form?form.departmentName:$t('')}}</td>
<td style="font-weight: bold;width:12.5%">客户名称</td> <td style="font-weight: bold;width:12.5%">{{$t('客户名称')}}</td>
<td colspan="2" style="width: 25%;">{{form?form.customerName:''}}</td> <td colspan="2" style="width: 25%;">{{form?form.customerName:$t('')}}</td>
<td style="font-weight: bold;width:12.5%">收款日期</td> <td style="font-weight: bold;width:12.5%">{{$t('收款日期')}}</td>
<td colspan="2" style="width: 25%;">{{form?form.payedAt:''}}</td> <td colspan="2" style="width: 25%;">{{parseTime(date)||$t('')}}</td>
</tr> </tr>
<tr> <tr>
<td style="font-weight: bold;width:12.5%">收款单号</td> <td style="font-weight: bold;width:12.5%">{{$t('收款单号')}}</td>
<td style="width:12.5%">{{form?form.receiptNo:''}}</td> <td style="width:12.5%">{{form?form.receiptNo:$t('')}}</td>
<td style="font-weight: bold;width:12.5%">备注</td> <td style="font-weight: bold;width:12.5%">{{$t('备注')}}</td>
<td colspan="4" style="width: 50%;">{{form?form.remark:''}}</td> <td colspan="4" style="width: 50%;">{{form?form.remark:$t('')}}</td>
</tr> </tr>
<tr> <tr>
<td colspan="8">Form/To:{{orderData.logisticsInfoDto?orderData.logisticsInfoDto.startTitleZh:''}}>{{orderData.logisticsInfoDto?orderData.logisticsInfoDto.destAddressZh:''}}</td> <td colspan="8">Form/To:{{orderData.logisticsInfoDto?orderData.logisticsInfoDto.startTitleZh:''}}>{{orderData.logisticsInfoDto?orderData.logisticsInfoDto.destAddressZh:''}}</td>
...@@ -24,14 +24,14 @@ ...@@ -24,14 +24,14 @@
</table> </table>
<table border="1" style="width: 100%;text-align: center;border-collapse: collapse; border-top: 0;"> <table border="1" style="width: 100%;text-align: center;border-collapse: collapse; border-top: 0;">
<tr> <tr>
<th style="width: 12.5%;">序号</th> <th style="width: 12.5%;">{{$t('序号')}}</th>
<th style="width: 12.5%;">提单号</th> <th style="width: 12.5%;">{{$t('提单号')}}</th>
<th style="width: 12.5%;">订单号</th> <th style="width: 12.5%;">{{$t('订单号')}}</th>
<th style="width: 12.5%;">品名</th> <th style="width: 12.5%;">{{$t('品名')}}</th>
<th style="width: 12.5%;">收入类型</th> <th style="width: 12.5%;">{{$t('收入类型')}}</th>
<th style="width: 12.5%;">金额</th> <th style="width: 12.5%;">{{$t('金额')}}</th>
<th style="width: 12.5%;">币种</th> <th style="width: 12.5%;">{{$t('币种')}}</th>
<th style="width: 12.5%;">优惠金额</th> <th style="width: 12.5%;">{{$t('优惠金额')}}</th>
</tr> </tr>
<tr v-for="(item, index) in list" :key="index"> <tr v-for="(item, index) in list" :key="index">
<td>{{ index + 1 }}</td> <td>{{ index + 1 }}</td>
...@@ -44,38 +44,38 @@ ...@@ -44,38 +44,38 @@
<td>{{ item.discountTotal||0 }}</td> <td>{{ item.discountTotal||0 }}</td>
</tr> </tr>
<tr v-for="(items, indexs) in receiptAccountList" :key="indexs"> <tr v-for="(items, indexs) in receiptAccountList" :key="indexs">
<td><dict-tag :type="DICT_TYPE.BOX_SHIPPING_PRICE_UNIT" :value="items.currencyId" />应收合计</td> <td><dict-tag :type="DICT_TYPE.BOX_SHIPPING_PRICE_UNIT" :value="items.currencyId" />{{$t('应收合计')}}</td>
<td ><span v-if="items.discountTotal>0">{{ `${items.receivableAmount - items.discountTotal }(${items.receivableAmount} - ${items.discountTotal})` }}</span> <td ><span v-if="items.discountTotal>0">{{ `${items.receivableAmount - items.discountTotal }(${items.receivableAmount} - ${items.discountTotal})` }}</span>
<span v-else>{{ `${items.receivableAmount - items.discountTotal }` }}</span> <span v-else>{{ `${items.receivableAmount - items.discountTotal }` }}</span>
</td> </td>
<td>汇率</td> <td>{{$t('汇率')}}</td>
<td>{{ items.collectionRate}}</td> <td>{{ items.collectionRate}}</td>
<td>收款金额(<dict-tag :type="DICT_TYPE.BOX_SHIPPING_PRICE_UNIT" :value="items.collectionCurrencyId" />)</td> <td>{{$t('收款金额')}}(<dict-tag :type="DICT_TYPE.BOX_SHIPPING_PRICE_UNIT" :value="items.collectionCurrencyId" />)</td>
<td colspan="3">{{ items.collectionAmount}}</td> <td colspan="3">{{ items.collectionAmount}}</td>
</tr> </tr>
</table> </table>
<div style="text-align: center;border-left:1px solid #666;border-right: 1px solid #666;height: 36px;line-height: 36px;"> <div style="text-align: center;border-left:1px solid #666;border-right: 1px solid #666;height: 36px;line-height: 36px;">
银行信息 {{$t('银行信息')}}
</div> </div>
<div style="display: flex;align-items: center;border-top: 1px solid #666;border-left:1px solid #666;border-right: 1px solid #666;" v-for="(bankTiem,index) in detailed" :key="index"> <div style="display: flex;align-items: center;border-top: 1px solid #666;border-left:1px solid #666;border-right: 1px solid #666;" v-for="(bankTiem,index) in detailed" :key="index">
<div style="padding:6px 0;width: 12.5%;text-align: center;border-right: 1px solid #666;" > <div style="padding:6px 0;width: 12.5%;text-align: center;border-right: 1px solid #666;" >
<p style="margin: 0;word-break: break-all;">户名{{bankTiem.accountName}}</p> <p style="margin: 0;word-break: break-all;">{{$t('户名')}}{{bankTiem.accountName}}</p>
<p style="margin: 0;word-break: break-all;">银行名称{{bankTiem.accountBankName||''}}</p> <p style="margin: 0;word-break: break-all;">{{$t('银行名称')}}{{bankTiem.accountBankName||''}}</p>
<p style="margin: 0;word-break: break-all;">A/C NO{{bankTiem.accountNo}}</p> <p style="margin: 0;word-break: break-all;">A/C NO{{bankTiem.accountNo}}</p>
</div> </div>
<div style="padding:6px 0;width: 87.5%;text-align: center;"> <div style="padding:6px 0;width: 87.5%;text-align: center;">
<p style="margin: 0;">实收<dict-tag :type="DICT_TYPE.BOX_SHIPPING_PRICE_UNIT" :value="bankTiem.currencyId" />{{bankTiem.writeOffAmount}}¥</p> <p style="margin: 0;">{{$t('实收')}}<dict-tag :type="DICT_TYPE.BOX_SHIPPING_PRICE_UNIT" :value="bankTiem.currencyId" />{{bankTiem.amount}}¥</p>
<!-- <p style="margin: 0;">未收:¥{{bankTiem.noReceipt}}</p> --> <!-- <p style="margin: 0;">未收:¥{{bankTiem.noReceipt}}</p> -->
</div> </div>
</div> </div>
<div style="display: flex;align-items: center;border: 1px solid #666;"> <div style="display: flex;align-items: center;border: 1px solid #666;">
<div style="font-weight: bold;width: 12.5%;text-align: center;border-right: 1px solid #666;height: 36px;line-height: 36px;">主管</div> <div style="font-weight: bold;width: 12.5%;text-align: center;border-right: 1px solid #666;height: 36px;line-height: 36px;">{{$t('主管')}}</div>
<div style="width: 12.5%;text-align: center;border-right: 1px solid #666;height: 36px;line-height: 36px;"></div> <div style="width: 12.5%;text-align: center;border-right: 1px solid #666;height: 36px;line-height: 36px;"></div>
<div style="font-weight: bold;width: 12.5%;text-align: center;border-right: 1px solid #666;height: 36px;line-height: 36px;">会计</div> <div style="font-weight: bold;width: 12.5%;text-align: center;border-right: 1px solid #666;height: 36px;line-height: 36px;">{{$t('会计')}}</div>
<div style="width: 12.5%;text-align: center;border-right: 1px solid #666;height: 36px;line-height: 36px;"></div> <div style="width: 12.5%;text-align: center;border-right: 1px solid #666;height: 36px;line-height: 36px;"></div>
<div style="font-weight: bold;width: 12.5%;text-align: center;border-right: 1px solid #666;height: 36px;line-height: 36px;">出纳</div> <div style="font-weight: bold;width: 12.5%;text-align: center;border-right: 1px solid #666;height: 36px;line-height: 36px;">{{$t('出纳')}}</div>
<div style="width: 12.5%;text-align: center;height: 36px;line-height: 36px;border-right: 1px solid #666;"></div> <div style="width: 12.5%;text-align: center;height: 36px;line-height: 36px;border-right: 1px solid #666;"></div>
<div style="font-weight: bold;width: 12.5%;text-align: center;border-right: 1px solid #666;height: 36px;line-height: 36px;">经手人</div> <div style="font-weight: bold;width: 12.5%;text-align: center;border-right: 1px solid #666;height: 36px;line-height: 36px;">{{$t('经手人')}}</div>
<div style="width: 12.5%;text-align: center;height: 36px;line-height: 36px;"></div> <div style="width: 12.5%;text-align: center;height: 36px;line-height: 36px;"></div>
</div> </div>
</div> </div>
...@@ -120,7 +120,8 @@ ...@@ -120,7 +120,8 @@
deptArr:[], deptArr:[],
id:0, id:0,
orderData:{}, orderData:{},
detailed:[] detailed:[],
date:''
} }
}, },
async created() { async created() {
...@@ -206,7 +207,14 @@ ...@@ -206,7 +207,14 @@
getList() { getList() {
getReceivableItem({ id: this.id }).then(res => { getReceivableItem({ id: this.id }).then(res => {
this.detailed = res.data this.detailed = res.data
this.detailed.forEach(item=>{
if(!this.date){
this.date = item.amountDate
}else if(this.date<item.amountDate){
this.date = item.amountDate
}
}) })
})
}, },
getCollectionData(){ getCollectionData(){
let that = this let that = this
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
</el-descriptions> </el-descriptions>
</el-card> </el-card>
<el-card class="card"> <el-card class="card">
<div slot="header" class="card-title">{{ $t('订单信息') }}</div> <div slot="header" class="card-title">{{ $t('应收明细') }}</div>
<el-table :data="list" border> <el-table :data="list" border>
<el-table-column :label="$t('订单号')" align="center" prop="orderNo" /> <el-table-column :label="$t('订单号')" align="center" prop="orderNo" />
<el-table-column :label="$t('唛头')" align="center" prop="marks" /> <el-table-column :label="$t('唛头')" align="center" prop="marks" />
...@@ -108,51 +108,7 @@ ...@@ -108,51 +108,7 @@
</el-descriptions-item> </el-descriptions-item>
</el-descriptions> </el-descriptions>
</el-card> </el-card>
<el-card class="card">
<div slot="header" class="card-title">{{ $t('银行收款明细') }}</div>
<div>
<el-button type="primary" plain size="mini" @click="batchVerification" style="padding: 10px; margin-bottom: 10px">{{ $t('批量核销') }}</el-button>
<el-button type="primary" plain size="mini" @click="handleAddReceiptItem" style="padding: 10px; margin-bottom: 10px">{{ $t('添加收款明细') }}</el-button>
</div>
<el-table ref="multipleTable" :data="detailed" border row-key="id" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="50" :reserve-selection="true"> </el-table-column>
<el-table-column :label="$t('序号')" type="index" align="center" width="50"></el-table-column>
<el-table-column :label="$t('收款账户')" align="center" prop="accountName" />
<el-table-column :label="$t('实收金额')" align="center" prop="amount" />
<el-table-column :label="$t('实收币种')" align="center" prop="marks">
<template slot-scope="scope">
<dict-tag :type="DICT_TYPE.BOX_SHIPPING_PRICE_UNIT" :value="scope.row.currencyId" />
</template>
</el-table-column>
<el-table-column :label="$t('汇率')" align="center" prop="rate" />
<el-table-column :label="$t('核销货币金额')" align="center" prop="writeOffAmount" />
<el-table-column :label="$t('实收日期')" align="center" prop="amountDate">
<!-- <template slot-scope="scope">
<span>{{ parseTime(scope.row.amountDate, '{y}-{m}-{d}') }}</span>
</template> -->
</el-table-column>
<el-table-column :label="$t('水单号')" align="center" prop="billNo" />
<el-table-column :label="$t('水单附件')" align="center" prop="attr">
<template slot-scope="scope" v-if="scope.row.attr">
<div v-for="(v, i) in scope.row.attr" :key="i"><el-link :href="v.url" type="primary" target="_blank">{{ v.name }}</el-link></div>
</template>
</el-table-column>
<el-table-column :label="$t('状态')" align="center" prop="status">
<template slot-scope="scope">
<span>{{ scope.row.status == 0 ? $t('待核销') : $t('已核销') }}</span>
</template>
</el-table-column>
<el-table-column :label="$t('操作')" align="center" width="200">
<template slot-scope="scope">
<el-button v-if="scope.row.status == 0" type="text" @click="deleteClick(scope.row)">{{ $t('删除') }}</el-button>
<el-button type="text" @click="detailClick(scope.row)">{{ $t('详情') }}</el-button>
<el-button v-if="scope.row.status == 0" type="text" @click="verificationClick(scope.row)">{{ $t('核销') }}</el-button>
<el-button v-if="scope.row.status == 1" type="text" @click="verificationCancelClick(scope.row)">{{ $t('反核销') }}</el-button>
<el-button v-if="scope.row.status == 0" type="text" @click="editClick(scope.row)">{{ $t('编辑') }}</el-button>
</template>
</el-table-column>
</el-table>
</el-card>
<el-card class="card"> <el-card class="card">
<div slot="header" class="card-title">{{ $t('收款信息') }}</div> <div slot="header" class="card-title">{{ $t('收款信息') }}</div>
<el-table :data="form.receiptAccountList" border> <el-table :data="form.receiptAccountList" border>
...@@ -241,6 +197,51 @@ ...@@ -241,6 +197,51 @@
</el-descriptions-item> </el-descriptions-item>
</el-descriptions> </el-descriptions>
</el-card> </el-card>
<el-card class="card">
<div slot="header" class="card-title">{{ $t('银行收款明细') }}</div>
<div>
<el-button type="primary" plain size="mini" @click="batchVerification" style="padding: 10px; margin-bottom: 10px">{{ $t('批量核销') }}</el-button>
<el-button type="primary" plain size="mini" @click="handleAddReceiptItem" style="padding: 10px; margin-bottom: 10px">{{ $t('添加收款明细') }}</el-button>
</div>
<el-table ref="multipleTable" :data="detailed" border row-key="id" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="50" :reserve-selection="true"> </el-table-column>
<el-table-column :label="$t('序号')" type="index" align="center" width="50"></el-table-column>
<el-table-column :label="$t('收款账户')" align="center" prop="accountName" />
<el-table-column :label="$t('实收金额')" align="center" prop="amount" />
<el-table-column :label="$t('实收币种')" align="center" prop="marks">
<template slot-scope="scope">
<dict-tag :type="DICT_TYPE.BOX_SHIPPING_PRICE_UNIT" :value="scope.row.currencyId" />
</template>
</el-table-column>
<el-table-column :label="$t('汇率')" align="center" prop="rate" />
<el-table-column :label="$t('核销货币金额')" align="center" prop="writeOffAmount" />
<el-table-column :label="$t('实收日期')" align="center" prop="amountDate">
<!-- <template slot-scope="scope">
<span>{{ parseTime(scope.row.amountDate, '{y}-{m}-{d}') }}</span>
</template> -->
</el-table-column>
<el-table-column :label="$t('水单号')" align="center" prop="billNo" />
<el-table-column :label="$t('水单附件')" align="center" prop="attr">
<template slot-scope="scope" v-if="scope.row.attr">
<div v-for="(v, i) in scope.row.attr" :key="i"><el-link :href="v.url" type="primary" target="_blank">{{ v.name }}</el-link></div>
</template>
</el-table-column>
<el-table-column :label="$t('状态')" align="center" prop="status">
<template slot-scope="scope">
<span>{{ scope.row.status == 0 ? $t('待核销') : $t('已核销') }}</span>
</template>
</el-table-column>
<el-table-column :label="$t('操作')" align="center" width="200">
<template slot-scope="scope">
<el-button v-if="scope.row.status == 0" type="text" @click="deleteClick(scope.row)">{{ $t('删除') }}</el-button>
<el-button type="text" @click="detailClick(scope.row)">{{ $t('详情') }}</el-button>
<el-button v-if="scope.row.status == 0" type="text" @click="verificationClick(scope.row)">{{ $t('核销') }}</el-button>
<el-button v-if="scope.row.status == 1" type="text" @click="verificationCancelClick(scope.row)">{{ $t('反核销') }}</el-button>
<el-button v-if="scope.row.status == 0" type="text" @click="editClick(scope.row)">{{ $t('编辑') }}</el-button>
</template>
</el-table-column>
</el-table>
</el-card>
<el-card class="card hexiaoCard"> <el-card class="card hexiaoCard">
<el-descriptions :column="3" border> <el-descriptions :column="3" border>
<el-descriptions-item :label="$t('已核销总金额')"> <el-descriptions-item :label="$t('已核销总金额')">
...@@ -801,6 +802,10 @@ export default { ...@@ -801,6 +802,10 @@ export default {
.catch(() => {}); .catch(() => {});
}, },
verificationAll() { verificationAll() {
if(!this.detailed||this.detailed.length==0){
this.$modal.msgError(this.$t('当前收款单未添加银行收款明细,无法全部核销,请添加银行收款单明细,并核销所有实收明细后再进行全部核销!'));
return
}
this.$modal this.$modal
.confirm(this.$t('您确认要全部核销吗?')) .confirm(this.$t('您确认要全部核销吗?'))
.then(() => { .then(() => {
......
...@@ -11,12 +11,12 @@ ...@@ -11,12 +11,12 @@
<!-- <el-table-column label="已到箱数/总箱数"> <!-- <el-table-column label="已到箱数/总箱数">
<template slot-scope="{row}">/{{row.sumNum}}/{{row.sumNum}}</template> <template slot-scope="{row}">/{{row.sumNum}}/{{row.sumNum}}</template>
</el-table-column> --> </el-table-column> -->
<el-table-column :label="$t('单统计')"> <el-table-column :label="$t('单统计')">
<template slot-scope="{row}"> <template slot-scope="{row}">
{{row.costVO.totalNum}}{{$t('')}}<br/>{{row.costVO.totalVolume}}<br/>{{row.costVO.totalWeight}}kg {{row.costVO.totalNum}}{{$t('')}}<br/>{{row.costVO.totalVolume}}<br/>{{row.costVO.totalWeight}}kg
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('入仓统计')"> <el-table-column :label="$t('入仓统计')">
<template slot-scope="{row}"> <template slot-scope="{row}">
{{row.sumNum}}{{$t('')}}<br/>{{row.sumVolume}}<br/>{{row.sumWeight}}kg {{row.sumNum}}{{$t('')}}<br/>{{row.sumVolume}}<br/>{{row.sumWeight}}kg
</template> </template>
......
...@@ -75,6 +75,11 @@ ...@@ -75,6 +75,11 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
<el-row>
<el-form-item :label="$t('备注')+':'">
{{orderFee.notes}}
</el-form-item>
</el-row>
</el-form> </el-form>
</div> </div>
</template> </template>
......
...@@ -145,7 +145,7 @@ ...@@ -145,7 +145,7 @@
{{order.inWarehouseState > 1 && row.warehouseInInfoVO ? row.warehouseInInfoVO.weight : row.weight}} {{order.inWarehouseState > 1 && row.warehouseInInfoVO ? row.warehouseInInfoVO.weight : row.weight}}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="quantity" :label="$t('数量') + '(个)'" width="90px"/> <el-table-column prop="warehouseInInfoVO.quantityAll" :label="$t('数量') + '(个)'" width="90px"/>
<el-table-column prop="" :label="$t('费用类型')"> <el-table-column prop="" :label="$t('费用类型')">
<template slot-scope="{row}"> <template slot-scope="{row}">
<dict-tag :type="DICT_TYPE.ECW_PAY_ADVANCE" :value="row.isPayAdvance" /> <dict-tag :type="DICT_TYPE.ECW_PAY_ADVANCE" :value="row.isPayAdvance" />
......
...@@ -270,7 +270,7 @@ ...@@ -270,7 +270,7 @@
</el-form-item> </el-form-item>
<!--代收货款,只有非控货订单、并且线路开通了代收货款后,才显示是否代收货款选项--> <!--代收货款,只有非控货订单、并且线路开通了代收货款后,才显示是否代收货款选项-->
<el-form-item :label="$t('代收货款金额')" v-if="collectionProxy && form.isCollection" prop="collectionProxy" class="ml-20"> <el-form-item :label="$t('代收货款金额')" v-if="collectionProxy && form.isCollection" prop="collectionProxy" class="ml-20">
<el-input v-model="form.collectionProxy" class="w-200 mr-10" :disabled="false"></el-input> <el-input type="number" v-model="form.collectionProxy" class="w-200 mr-10" :disabled="false"></el-input>
<selector v-model="form.collectionProxyCurrency" :options="currencyList" label-field="titleZh" value-field="id" defaultable class="w-100" :disabled="false"/> <selector v-model="form.collectionProxyCurrency" :options="currencyList" label-field="titleZh" value-field="id" defaultable class="w-100" :disabled="false"/>
</el-form-item> </el-form-item>
</div> </div>
......
...@@ -68,12 +68,18 @@ ...@@ -68,12 +68,18 @@
<span v-if="scope.row.orderExceptionDescVO">{{$l(scope.row.orderExceptionDescVO, 'desc')}}</span> <span v-if="scope.row.orderExceptionDescVO">{{$l(scope.row.orderExceptionDescVO, 'desc')}}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('金额')" align="center" scope="orderExceptionAmount" /> <el-table-column :label="$t('金额')" align="center" scope="orderExceptionAmount">
<el-table-column :label="$t('状态')" align="center"> <template slot-scope="{row}">
{{row.orderExceptionAmount}}
{{currencyMap[row.orderExceptionAmountCurrencyId]}}
</template>
</el-table-column>
</el-table-column>
<el-table-column :label="$t('状态')" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :type="DICT_TYPE.ORDER_EXCEPTION_STATUS" :value="scope.row.orderExceptionStatus" /> <dict-tag :type="DICT_TYPE.ORDER_EXCEPTION_STATUS" :value="scope.row.orderExceptionStatus" />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('附件')" align="center"> <el-table-column :label="$t('附件')" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<div class="filelist"> <div class="filelist">
...@@ -81,6 +87,13 @@ ...@@ -81,6 +87,13 @@
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('备注')" align="center">
<template slot-scope="{row}">
<el-tooltip class="item" effect="dark" :content="row.orderExceptionNotes" placement="top-start">
<div class="clamp3">{{row.orderExceptionNotes}}</div>
</el-tooltip>
</template>
</el-table-column>
<el-table-column :label="$t('处理人')" align="center" prop="userName" /> <el-table-column :label="$t('处理人')" align="center" prop="userName" />
<el-table-column :label="$t('处理时间')" align="center"> <el-table-column :label="$t('处理时间')" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
...@@ -103,7 +116,7 @@ ...@@ -103,7 +116,7 @@
<script> <script>
import {getExceptionListByOrderId} from "@/api/ecw/orderException" import {getExceptionListByOrderId} from "@/api/ecw/orderException"
import {DICT_TYPE} from '@/utils/dict' import { getCurrencyList } from '@/api/ecw/currency'
import {getOrder} from '@/api/ecw/order' import {getOrder} from '@/api/ecw/order'
import FilePreview from '@/components/FilePreview' import FilePreview from '@/components/FilePreview'
import {getProduct} from '@/api/ecw/product' import {getProduct} from '@/api/ecw/product'
...@@ -125,9 +138,20 @@ export default { ...@@ -125,9 +138,20 @@ export default {
timers:"", //时间戳 timers:"", //时间戳
FilePreAll:[], // 预览数组 FilePreAll:[], // 预览数组
TragetPic:{}, TragetPic:{},
currencyList:[]
}; };
}, },
computed:{
currencyMap(){
let map = {}
this.currencyList.forEach(item => {
map[item.id] = this.$l(item, 'title')
})
return map
},
},
created() { created() {
getCurrencyList().then(res => this.currencyList = res.data)
if(this.$route.query.id){ if(this.$route.query.id){
this.orderId = this.$route.query.id this.orderId = this.$route.query.id
this.getList() this.getList()
...@@ -253,4 +277,10 @@ export default { ...@@ -253,4 +277,10 @@ export default {
.card{ .card{
margin-top: 20px; margin-top: 20px;
} }
.clamp3{
overflow: hidden;
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 3;
}
</style> </style>
...@@ -32,14 +32,19 @@ ...@@ -32,14 +32,19 @@
<!-- 单证异常,发货人异常,其他异常 不显示这部分内容 --> <!-- 单证异常,发货人异常,其他异常 不显示这部分内容 -->
<div v-if="['order_doc_exception','order_consignor_exception', 'order_other_exception'].indexOf(orderExceptionData.orderExceptionType) == -1"> <div v-if="['order_doc_exception','order_consignor_exception', 'order_other_exception'].indexOf(orderExceptionData.orderExceptionType) == -1">
<!-- 预付异常,提货异常是针对整个订单的 --> <!-- 预付异常,提货异常,代收货款是针对整个订单的 -->
<template v-if="['order_pay_exception','order_pick_up_exception'].indexOf(orderExceptionData.orderExceptionType) > -1"> <template v-if="['order_pay_exception','order_pick_up_exception', 'order_cod_exception'].indexOf(orderExceptionData.orderExceptionType) > -1">
<el-row> <el-row>
<el-form-item :label="$t('填单参数')+':'"> <el-form-item :label="$t('填单参数')+':'">
<template v-if="orderData && orderData.costVO"> <template v-if="orderData && orderData.costVO">
{{(orderData.costVO.totalNum||0)+$t('')+(orderData.costVO.totalVolume||0)+''+(orderData.costVO.totalWeight||0)+'kg '+(orderData.costVO.totalQuantity||0)+$t('')}} {{(orderData.costVO.totalNum||0)+$t('')+(orderData.costVO.totalVolume||0)+''+(orderData.costVO.totalWeight||0)+'kg '+(orderData.costVO.totalQuantity||0)+$t('')}}
</template> </template>
</el-form-item> </el-form-item>
<el-form-item :label="$t('代收金额')+':'" v-if="orderExceptionData.orderExceptionType == 'order_cod_exception'">
<template v-if="orderData && orderData.costVO">
{{orderExceptionData.orderExceptionAmount}} {{currencyMap[orderExceptionData.orderExceptionAmountCurrencyId]}}
</template>
</el-form-item>
</el-row> </el-row>
<el-row> <el-row>
<el-form-item :label="$t('入仓参数')+':'"> <el-form-item :label="$t('入仓参数')+':'">
...@@ -128,8 +133,10 @@ ...@@ -128,8 +133,10 @@
</el-table-column> </el-table-column>
<el-table-column :label="$t('付款人')"> <el-table-column :label="$t('付款人')">
<template slot-scope="scope"> <template slot-scope="{row}">
<span>{{scope.row.consigneeName}}({{$t('收货人')}})</span> <span>
<dict-tag :type="DICT_TYPE.DRAWEE" :value="row.paymentUser"></dict-tag>
</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('付款状态')" prop="worth"> <el-table-column :label="$t('付款状态')" prop="worth">
...@@ -254,8 +261,22 @@ ...@@ -254,8 +261,22 @@
<el-option :disabled="dict.value=='pending'" :key="dict.value" :label="$l(dict, 'label')" :value="dict.value"/> <el-option :disabled="dict.value=='pending'" :key="dict.value" :label="$l(dict, 'label')" :value="dict.value"/>
</template> </template>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-row> </el-row>
<!-- 代收货款 时需要填写代收金额 -->
<el-row v-if="handlerParams.orderExceptionHandlerResult == 'cod'" >
<el-form-item :label="$t('代收金额')+':'" size="medium" required>
<el-input class="w-100" type="text" v-model="handlerParams.amount" />
<!-- <el-select v-model="handlerParams.currency" clearable>
<el-option v-for="dict in getDictDatas('shipping_price_unit') "
:key="dict.value" :label="dict.label" :value="dict.value"/>
</el-select> -->
<dict-tag type="shipping_price_unit" v-model="handlerParams.currency" class="w-100 ml-10" />
</el-form-item>
</el-row>
<el-row :span="8" v-if="orderExceptionData.orderExceptionType=='order_pick_up_exception'&&handlerParams.orderExceptionHandlerResult=='cost_required'"> <el-row :span="8" v-if="orderExceptionData.orderExceptionType=='order_pick_up_exception'&&handlerParams.orderExceptionHandlerResult=='cost_required'">
<el-form-item :label="$t('送货费用')+':'" size="medium"> <el-form-item :label="$t('送货费用')+':'" size="medium">
<el-input style="width: 100px;" type="text" v-model="handlerParams.amount" /> <el-input style="width: 100px;" type="text" v-model="handlerParams.amount" />
...@@ -386,6 +407,11 @@ ...@@ -386,6 +407,11 @@
if(val == 'no_pay'){ if(val == 'no_pay'){
this.showWorkFlow = true this.showWorkFlow = true
}else this.showWorkFlow = false }else this.showWorkFlow = false
// 如果是代收货款,则给默认单位
if(val == 'cod' && this.orderExceptionData.orderExceptionAmountCurrencyId){
this.$set(this.handlerParams, 'currency', this.orderExceptionData.orderExceptionAmountCurrencyId)
}
} }
}, },
computed: { computed: {
...@@ -476,7 +502,9 @@ ...@@ -476,7 +502,9 @@
this.$modal.msgError(this.$t('请上传报关资料')); this.$modal.msgError(this.$t('请上传报关资料'));
return return
} }
this.handlerParams.files = Array.isArray(this.handlerParams.fileList) ? this.handlerParams.fileList.join(',') : this.handlerParams.fileList
} }
handlerExceptionByExceptionId(this.handlerParams).then(res=>{ handlerExceptionByExceptionId(this.handlerParams).then(res=>{
this.$modal.msgSuccess(this.$t('提交成功')); this.$modal.msgSuccess(this.$t('提交成功'));
this.$redirect('/order/pending?id=' + this.orderData.orderId) this.$redirect('/order/pending?id=' + this.orderData.orderId)
......
...@@ -93,9 +93,9 @@ ...@@ -93,9 +93,9 @@
prop="address" prop="address"
:label="$t('操作')"> :label="$t('操作')">
<template v-slot="{row}"> <template v-slot="{row}">
<el-button size="mini" type="text" v-hasPermi="['ecw:order:update']" @click="showDiscountItem=row">{{$t('优惠申请')}}</el-button> <el-button v-if="row.originalSeaFreight" size="mini" type="text" v-hasPermi="['ecw:order:update']" @click="showDiscountItem=row">{{$t('优惠申请')}}</el-button>
<el-button size="mini" type="text" v-hasPermi="['ecw:order:update']" @click="showCommissionItem=row">{{$t('佣金规则')}}</el-button> <el-button v-if="row.originalSeaFreight" size="mini" type="text" v-hasPermi="['ecw:order:update']" @click="showCommissionItem=row">{{$t('佣金规则')}}</el-button>
<el-button size="mini" type="text" v-hasPermi="['ecw:order:update']" @click="showAllowanceItem=row">{{$t('管理折扣')}}</el-button> <el-button v-if="row.originalSeaFreight" size="mini" type="text" v-hasPermi="['ecw:order:update']" @click="showAllowanceItem=row">{{$t('管理折扣')}}</el-button>
</template> </template>
</el-table-column> </el-table-column>
......
...@@ -20,10 +20,10 @@ ...@@ -20,10 +20,10 @@
<dict-tag :type="DICT_TYPE.ECW_TRANSPORT_TYPE" :value="orderData.transportId" /> <dict-tag :type="DICT_TYPE.ECW_TRANSPORT_TYPE" :value="orderData.transportId" />
</el-descriptions-item> </el-descriptions-item>
<el-descriptions-item :label="$t('始发地')" :span="2"> <el-descriptions-item :label="$t('始发地')" :span="2">
{{orderData.logisticsInfoDto?orderData.logisticsInfoDto.startAddressZh:$t('')}} {{orderData.logisticsInfoDto?orderData.logisticsInfoDto.startTitleZh:$t('')}}
</el-descriptions-item> </el-descriptions-item>
<el-descriptions-item :label="$t('目的地')"> <el-descriptions-item :label="$t('目的地')">
{{orderData.logisticsInfoDto?orderData.logisticsInfoDto.destAddressZh:$t('')}} {{orderData.logisticsInfoDto?orderData.logisticsInfoDto.destTitleZh:$t('')}}
</el-descriptions-item> </el-descriptions-item>
</el-descriptions> </el-descriptions>
<el-descriptions :column="4"> <el-descriptions :column="4">
...@@ -76,7 +76,7 @@ ...@@ -76,7 +76,7 @@
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{$t('箱规')}}{{scope.row.warehouseInInfoVO?scope.row.warehouseInInfoVO.boxGauge:0}}</span> <span>{{$t('箱规')}}{{scope.row.warehouseInInfoVO?scope.row.warehouseInInfoVO.boxGauge:0}}</span>
<p> <p>
<span>{{$t('品牌')}}{{getBrand(scope.row.brand)}}&nbsp;&nbsp;</span> <span>{{$t('品牌')}}<dict-tag :type="DICT_TYPE.ECW_IS_BRAND" :value="scope.row.brandType" /></span>
<span>{{$t('箱数')}}{{scope.row.warehouseInInfoVO?scope.row.warehouseInInfoVO.cartonsNum:0}}&nbsp;&nbsp;</span> <span>{{$t('箱数')}}{{scope.row.warehouseInInfoVO?scope.row.warehouseInInfoVO.cartonsNum:0}}&nbsp;&nbsp;</span>
<span>{{$t('体积')}}{{scope.row.warehouseInInfoVO?scope.row.warehouseInInfoVO.volume:0}}CBM&nbsp;&nbsp;</span> <span>{{$t('体积')}}{{scope.row.warehouseInInfoVO?scope.row.warehouseInInfoVO.volume:0}}CBM&nbsp;&nbsp;</span>
<span>{{$t('重量')}}{{scope.row.warehouseInInfoVO?scope.row.warehouseInInfoVO.weight:0}}KG</span> <span>{{$t('重量')}}{{scope.row.warehouseInInfoVO?scope.row.warehouseInInfoVO.weight:0}}KG</span>
......
...@@ -439,15 +439,17 @@ export default { ...@@ -439,15 +439,17 @@ export default {
this.reset(); this.reset();
const id = row.id; const id = row.id;
getProduct(id).then(response => { getProduct(id).then(response => {
this.form = response.data; this.form = {...response.data};
let attrArray = this.form.attrId.split(','); let attrArray = this.form.attrId.split(',');
for (let index in attrArray) { for (let index in attrArray) {
let value = attrArray[index]; let value = attrArray[index];
attrArray[index] = parseInt(value); attrArray[index] = parseInt(value);
} }
this.form.attrArray = attrArray; this.$nextTick(() =>{
this.form.attrArray = attrArray
})
this.open = true; this.open = true;
this.title = this.$t("修改商品"); this.title = this.$t("修改商品1");
}); });
}, },
......
...@@ -74,7 +74,7 @@ ...@@ -74,7 +74,7 @@
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
<el-form-item :label="$t('单价模式')" prop="priceType"> <el-form-item :label="$t('单价模式')" prop="priceType">
<dict-selector :type="DICT_TYPE.ECW_PRICE_TYPE" v-model="form.priceType" form-type="radio" formatter="number" defaultable /> <dict-selector :type="DICT_TYPE.ECW_PRICE_TYPE" v-model="form.priceType" form-type="radio" formatter="number" defaultable2 />
</el-form-item> </el-form-item>
<!--阶梯定价--> <!--阶梯定价-->
<template v-if="form.stepPrice==1" > <template v-if="form.stepPrice==1" >
...@@ -92,45 +92,46 @@ ...@@ -92,45 +92,46 @@
- -
<el-input v-model="item.endNum" type="number" placeholder="" class="w-100"></el-input> <el-input v-model="item.endNum" type="number" placeholder="" class="w-100"></el-input>
/ /
<selector v-model="form.weightUnit" :options="unitList" :label-field="$l(null, 'title')" value-field="id" defaultable class="w-100" /> <selector v-model="form.weightUnit" :options="unitList" :label-field="$l(null, 'title')" value-field="id" defaultable2 class="w-100" />
</el-form-item> </el-form-item>
<el-form-item :label="$t('默认运费')" v-if="form.priceType != 1"> <el-form-item :label="$t('默认运费')" v-if="form.priceType != 1">
<inputor default="0" v-model.number="item.transportPrice" type="number" :placeholder="$t('整数或者两位小数')" class="w-100 mr-10" /> <inputor default2="0" v-model.number="item.transportPrice" type="number" :placeholder="$t('整数或者两位小数')" class="w-100 mr-10" />
<selector v-model="item.transportPriceUnit" :options="currencyList" :label-field="$l(null, 'title')" value-field="id" defaultable class="w-100" /> <selector v-model="item.transportPriceUnit" :options="currencyList" :label-field="$l(null, 'title')" value-field="id" defaultable2 class="w-100" />
/ <selector v-model="item.transportVolumeUnit" :options="unitList" :label-field="$l(null, 'title')" value-field="id" defaultable class="w-100" /> / <selector v-model="item.transportVolumeUnit" :options="unitList" :label-field="$l(null, 'title')" value-field="id" defaultable2 class="w-100" />
</el-form-item> </el-form-item>
<el-form-item :label="$t('默认清关费')" v-if="form.priceType != 1"> <el-form-item :label="$t('默认清关费')" v-if="form.priceType != 1">
<inputor default="0" v-model.number="item.clearancePrice" type="number" :placeholder="$t('整数或者两位小数')" class="w-100 mr-10" /> <inputor default2="0" v-model.number="item.clearancePrice" type="number" :placeholder="$t('整数或者两位小数')" class="w-100 mr-10" />
<selector v-model="item.clearancePriceUnit" :options="currencyList" :label-field="$l(null, 'title')" value-field="id" defaultable class="w-100" /> <selector v-model="item.clearancePriceUnit" :options="currencyList" :label-field="$l(null, 'title')" value-field="id" defaultable2 class="w-100" />
/ <selector v-model="item.clearanceVolumeUnit" :options="unitList" :label-field="$l(null, 'title')" value-field="id" defaultable class="w-100" /> / <selector v-model="item.clearanceVolumeUnit" :options="unitList" :label-field="$l(null, 'title')" value-field="id" defaultable2 class="w-100" />
</el-form-item> </el-form-item>
<el-form-item :label="$t('默认全包价')" v-if="form.priceType == 1"> <el-form-item :label="$t('默认全包价')" v-if="form.priceType == 1">
<selector v-model="item.allPriceUnit" :options="currencyList" :label-field="$l(null, 'title')" value-field="id" defaultable class="w-100" /> <selector v-model="item.allPriceUnit" :options="currencyList" :label-field="$l(null, 'title')" value-field="id" defaultable2 class="w-100" />
<inputor default="0" v-model.number="item.allPrice" type="number" :placeholder="$t('整数或者两位小数')" class="w-100 mr-10" /> <inputor default2="0" v-model.number="item.allPrice" type="number" :placeholder="$t('整数或者两位小数')" class="w-100 mr-10" />
/ <selector v-model="item.allVolumeUnit" :options="unitList" :label-field="$l(null, 'title')" value-field="id" defaultable class="w-100" /> / <selector v-model="item.allVolumeUnit" :options="unitList" :label-field="$l(null, 'title')" value-field="id" defaultable2 class="w-100" />
</el-form-item> </el-form-item>
</div> </div>
</template> </template>
<template v-else> <template v-else>
<el-form-item :label="$t('默认全包价')" v-if="form.priceType == 1"> <el-form-item :label="$t('默认全包价')" v-if="form.priceType == 1">
<selector v-model="form.allPriceUnit" :options="currencyList" :label-field="$l('title')" value-field="id" defaultable class="w-100 mr-10" /> <selector test="allPriceUnit" v-model="form.allPriceUnit" :options="currencyList" :label-field="$l('title')" value-field="id" defaultable2 class="w-100 mr-10 aaa" />
<inputor default="0" v-model.number="form.allPrice" type="number" :placeholder="$t('整数或者两位小数')" class="w100 mr10" /> <inputor default2="0" v-model.number="form.allPrice" type="number" :placeholder="$t('整数或者两位小数')" class="w-100 mr10" />
/ <selector v-model="form.allVolumeUnit" :options="unitList" :label-field="$l('title')" value-field="id" defaultable class="w-100" /> <span class="mr-10">/</span>
<selector v-model="form.allVolumeUnit" :options="unitList" :label-field="$l('title')" value-field="id" defaultable2 class="w-100" />
</el-form-item> </el-form-item>
<template v-else> <template v-else>
<el-form-item :label="$t('默认运费')" prop="transportPrice"> <el-form-item :label="$t('默认运费')" prop="transportPrice">
<selector v-model="form.transportPriceUnit" :options="currencyList" :label-field="$l('title')" value-field="id" defaultable class="w-100 mr-10" /> <selector v-model="form.transportPriceUnit" :options="currencyList" :label-field="$l('title')" value-field="id" defaultable2 class="w-100 mr-10" />
<inputor default="0" v-model.number="form.transportPrice" type="number" :placeholder="$t('整数或者两位小数')" class="w-100 mr-10" /> <inputor default2="0" v-model.number="form.transportPrice" type="number" :placeholder="$t('整数或者两位小数')" class="w-100 mr-10" />
<span class="mr-10">/</span> <span class="mr-10">/</span>
<selector v-model="form.transportVolumeUnit" :options="unitList" :label-field="$l('title')" value-field="id" defaultable class="w-100" /> <selector v-model="form.transportVolumeUnit" :options="unitList" :label-field="$l('title')" value-field="id" defaultable2 class="w-100" />
</el-form-item> </el-form-item>
<el-form-item :label="$t('默认清关费')" prop="clearancePrice"> <el-form-item :label="$t('默认清关费')" prop="clearancePrice">
<selector v-model="form.clearancePriceUnit" :options="currencyList" :label-field="$l('title')" value-field="id" defaultable class="w-100 mr-10" /> <selector v-model="form.clearancePriceUnit" :options="currencyList" :label-field="$l('title')" value-field="id" defaultable2 class="w-100 mr-10" />
<inputor default="0" v-model.number="form.clearancePrice" type="number" :placeholder="$t('整数或者两位小数')" class="w-100 mr-10" /> <inputor default2="0" v-model.number="form.clearancePrice" type="number" :placeholder="$t('整数或者两位小数')" class="w-100 mr-10" />
<span class="mr-10">/</span> <span class="mr-10">/</span>
<selector v-model="form.clearanceVolumeUnit" :options="unitList" :label-field="$l('title')" value-field="id" defaultable class="w-100" /> <selector v-model="form.clearanceVolumeUnit" :options="unitList" :label-field="$l('title')" value-field="id" defaultable2 class="w-100" />
</el-form-item> </el-form-item>
</template> </template>
...@@ -141,28 +142,28 @@ ...@@ -141,28 +142,28 @@
v-for="(special, specialIndex) in this.specialProducts" v-for="(special, specialIndex) in this.specialProducts"
:label="getDictDataLabel(DICT_TYPE.ECW_SPECIAL_REQ_FOR_LINE_PRODUCTS, special.specialDictType) + $t('全包价')" :label="getDictDataLabel(DICT_TYPE.ECW_SPECIAL_REQ_FOR_LINE_PRODUCTS, special.specialDictType) + $t('全包价')"
:key="specialIndex + 'transport'"> :key="specialIndex + 'transport'">
<selector v-model="special.allPriceUnit" :options="currencyList" :label-field="$l(null, 'title')" value-field="id" defaultable class="w-100 mr-10" /> <selector v-model="special.allPriceUnit" :options="currencyList" :label-field="$l(null, 'title')" value-field="id" defaultable2 class="w-100 mr-10" />
<inputor default="0" v-model.number="special.allPrice" type="number" :placeholder="$t('整数或者两位小数')" class="w-100 mr-10" /> <inputor default2="0" v-model.number="special.allPrice" type="number" :placeholder="$t('整数或者两位小数')" class="w-100 mr-10" />
<span class="mr-10">/</span> <span class="mr-10">/</span>
<selector v-model="special.allVolumeUnit" :options="unitList" :label-field="$l(null, 'title')" value-field="id" defaultable class="w-100" /> <selector v-model="special.allVolumeUnit" :options="unitList" :label-field="$l(null, 'title')" value-field="id" defaultable2 class="w-100" />
</el-form-item> </el-form-item>
</template> </template>
<template v-else v-for="(special, specialIndex) in this.specialProducts"> <template v-else v-for="(special, specialIndex) in this.specialProducts">
<el-form-item <el-form-item
:label="getDictDataLabel(DICT_TYPE.ECW_SPECIAL_REQ_FOR_LINE_PRODUCTS, special.specialDictType) + $t('运费')" :label="getDictDataLabel(DICT_TYPE.ECW_SPECIAL_REQ_FOR_LINE_PRODUCTS, special.specialDictType) + $t('运费')"
:key="specialIndex + 'transport'"> :key="specialIndex + 'transport'">
<selector v-model="special.transportPriceUnit" :options="currencyList" :label-field="$l(null, 'title')" value-field="id" defaultable class="w-100 mr-10" /> <selector v-model="special.transportPriceUnit" :options="currencyList" :label-field="$l(null, 'title')" value-field="id" defaultable2 class="w-100 mr-10" />
<inputor default="0" v-model.number="special.transportPrice" type="number" :placeholder="$t('整数或者两位小数')" class="w-100 mr-10" /> <inputor default2="0" v-model.number="special.transportPrice" type="number" :placeholder="$t('整数或者两位小数')" class="w-100 mr-10" />
<span class="mr-10">/</span> <span class="mr-10">/</span>
<selector v-model="special.transportVolumeUnit" :options="unitList" :label-field="$l(null, 'title')" value-field="id" defaultable class="w-100" /> <selector v-model="special.transportVolumeUnit" :options="unitList" :label-field="$l(null, 'title')" value-field="id" defaultable2 class="w-100" />
</el-form-item> </el-form-item>
<el-form-item <el-form-item
:label="getDictDataLabel(DICT_TYPE.ECW_SPECIAL_REQ_FOR_LINE_PRODUCTS, special.specialDictType) + $t('清关费')" :label="getDictDataLabel(DICT_TYPE.ECW_SPECIAL_REQ_FOR_LINE_PRODUCTS, special.specialDictType) + $t('清关费')"
:key="specialIndex + 'clearance'"> :key="specialIndex + 'clearance'">
<selector v-model="special.clearancePriceUnit" :options="currencyList" :label-field="$l(null, 'title')" value-field="id" defaultable class="w-100 mr-10" /> <selector v-model="special.clearancePriceUnit" :options="currencyList" :label-field="$l(null, 'title')" value-field="id" defaultable2 class="w-100 mr-10" />
<inputor default="0" v-model.number="special.clearancePrice" type="number" :placeholder="$t('整数或者两位小数')" class="w-100 mr-10" /> <inputor default2="0" v-model.number="special.clearancePrice" type="number" :placeholder="$t('整数或者两位小数')" class="w-100 mr-10" />
<span class="mr-10">/</span> <span class="mr-10">/</span>
<selector v-model="special.clearanceVolumeUnit" :options="unitList" :label-field="$l(null, 'title')" value-field="id" defaultable class="w-100" /> <selector v-model="special.clearanceVolumeUnit" :options="unitList" :label-field="$l(null, 'title')" value-field="id" defaultable2 class="w-100" />
</el-form-item> </el-form-item>
</template> </template>
</template> </template>
...@@ -222,14 +223,7 @@ export default { ...@@ -222,14 +223,7 @@ export default {
return { return {
checkList: [], checkList: [],
selectedRoutes: [], // 勾选的路线渠道 selectedRoutes: [], // 勾选的路线渠道
form: { form: {},
stepPrice: 0,
advanceStatus: 0,
needBook: 0,
dayLimit: 10000,
validateEndDate: undefined,
validateStartDate: undefined
},
needPay: false, // 是否需要预付 needPay: false, // 是否需要预付
stepPrice: false, // 是否阶梯订单 stepPrice: false, // 是否阶梯订单
specialProducts: [], specialProducts: [],
...@@ -269,10 +263,13 @@ export default { ...@@ -269,10 +263,13 @@ export default {
/* getProductType(this.product.typeId).then(res => { /* getProductType(this.product.typeId).then(res => {
this.productType = res.data this.productType = res.data
}) */ }) */
this.$set(this.form, 'needBook', this.product.needBook) // 只有新建才需要把参数带过来
this.$set(this.form, 'square', this.product.square) if(!this.$route.query.action){
this.$set(this.form, 'dayLimit', this.product.dayLimit) this.$set(this.form, 'needBook', this.product.needBook)
this.$set(this.form, 'containerLocation', this.product.containerLocation) this.$set(this.form, 'square', this.product.square)
this.$set(this.form, 'dayLimit', this.product.dayLimit)
this.$set(this.form, 'containerLocation', this.product.containerLocation)
}
}, },
form(val) { form(val) {
...@@ -296,6 +293,12 @@ export default { ...@@ -296,6 +293,12 @@ export default {
}) */ }) */
} }
}, },
'form.priceType'(priceType){
// 切换全包价的时候给默认货币单位
if(priceType == 1){
this.$set(this.form, 'allPriceUnit', 1)
}
},
'form.transportVolumeUnit'(val){ 'form.transportVolumeUnit'(val){
this.specialProducts.forEach(item => { this.specialProducts.forEach(item => {
item.transportVolumeUnit = val item.transportVolumeUnit = val
...@@ -370,10 +373,6 @@ export default { ...@@ -370,10 +373,6 @@ export default {
if(res.data.validateEndDate){ if(res.data.validateEndDate){
this.form.validateEndDate = parseTime(res.data.validateEndDate) this.form.validateEndDate = parseTime(res.data.validateEndDate)
} }
// 特需价格更新
this.lineList = [res.data] this.lineList = [res.data]
}) })
} }
...@@ -402,22 +401,34 @@ export default { ...@@ -402,22 +401,34 @@ export default {
// 获取类型列表 // 获取类型列表
getProductTypeList().then(res => this.productTypeList = res.data) getProductTypeList().then(res => this.productTypeList = res.data)
if (this.$route.query.product_type) {
this.$set(this.form, 'productType', +this.$route.query.product_type)
}
if (this.$route.query.product_id) {
this.$set(this.form, 'productId', +this.$route.query.product_id)
}
// 修改单条路线不回显单位
if(this.$route.query.action !== 'update'){
this.setDefaultVolumeUnit(7)
}
// 没有操作标识的就是新建,给有效期默认值 // 没有操作标识的就是新建,给有效期默认值
if(!this.$route.query.action){ if(!this.$route.query.action){
this.form = {
priceType: 0,
stepPrice: 0,
advanceStatus: 0,
needBook: 0,
// dayLimit: 10000,
validateEndDate: undefined,
validateStartDate: undefined,
clearancePrice: 0,
transportPrice: 0
}
// 默认体积单位(立方米)
this.setDefaultVolumeUnit(7)
// 默认货币单位(美元)
this.setDefaultPriceUnit(1)
this.form.validateStartDate = parseTime(Date.now()) this.form.validateStartDate = parseTime(Date.now())
this.form.validateEndDate = parseTime(Date.now() + 86400*365*2*1000) this.form.validateEndDate = parseTime(Date.now() + 86400*365*2*1000)
}
if (this.$route.query.product_type) {
this.$set(this.form, 'productType', +this.$route.query.product_type)
}
if (this.$route.query.product_id) {
this.$set(this.form, 'productId', +this.$route.query.product_id)
} }
getCurrencyList().then(res => this.currencyList = res.data) getCurrencyList().then(res => this.currencyList = res.data)
...@@ -425,11 +436,11 @@ export default { ...@@ -425,11 +436,11 @@ export default {
this.getDictDatas(this.DICT_TYPE.ECW_SPECIAL_REQ_FOR_LINE_PRODUCTS).forEach(item => { this.getDictDatas(this.DICT_TYPE.ECW_SPECIAL_REQ_FOR_LINE_PRODUCTS).forEach(item => {
this.specialProducts.push({ this.specialProducts.push({
"clearancePrice": null, "clearancePrice": !this.$route.query.action ? 0 : null, // 新建默认给0,否则默认是null
"clearancePriceUnit": null, "clearancePriceUnit": null,
"clearanceVolumeUnit": null, "clearanceVolumeUnit": null,
"specialDictType": item.value, "specialDictType": item.value,
"transportPrice": null, "transportPrice": !this.$route.query.action ? 0 : null, // 新建默认给0,否则默认是null
"transportPriceUnit": null, "transportPriceUnit": null,
"transportVolumeUnit": null, "transportVolumeUnit": null,
}) })
...@@ -441,6 +452,11 @@ export default { ...@@ -441,6 +452,11 @@ export default {
this.$set(this.form, 'clearanceVolumeUnit', unit) this.$set(this.form, 'clearanceVolumeUnit', unit)
this.$set(this.form, 'allVolumeUnit', unit) this.$set(this.form, 'allVolumeUnit', unit)
}, },
setDefaultPriceUnit(priceUnit){
this.$set(this.form, 'transportPriceUnit', priceUnit)
this.$set(this.form, 'clearancePriceUnit', priceUnit)
this.$set(this.form, 'allPriceUnit', priceUnit)
},
submitForm() { submitForm() {
this.$refs["form"].validate(valid => { this.$refs["form"].validate(valid => {
if (!valid) { if (!valid) {
...@@ -529,7 +545,7 @@ export default { ...@@ -529,7 +545,7 @@ export default {
} }
</script> </script>
<style scoped> <style scoped>
.w100{ .w-100{
width: 100px; width: 100px;
} }
.mr10{ .mr10{
......
...@@ -156,7 +156,7 @@ ...@@ -156,7 +156,7 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12" v-if="hasCustomerServicePost">
<el-form-item label="跟单客服"> <el-form-item label="跟单客服">
<el-select v-model="form.customerServiceId" placeholder="请选择"> <el-select v-model="form.customerServiceId" placeholder="请选择">
<el-option v-for="dict in followUpList" :key="parseInt(dict.id)" :label="dict.nickname" :value="parseInt(dict.id)"/> <el-option v-for="dict in followUpList" :key="parseInt(dict.id)" :label="dict.nickname" :value="parseInt(dict.id)"/>
...@@ -383,6 +383,18 @@ export default { ...@@ -383,6 +383,18 @@ export default {
} }
} }
}, },
computed:{
hasCustomerServicePost(){
if(!this.form.postIds) return false
let has = false
this.postOptions.forEach(item => {
if(this.form.postIds.indexOf(item.id) > -1 && item.code == 'customer service'){
has = true
}
})
return has
}
},
created() { created() {
this.getList(); this.getList();
this.getTreeselect(); this.getTreeselect();
...@@ -444,6 +456,7 @@ export default { ...@@ -444,6 +456,7 @@ export default {
}, },
// 节点单击事件 // 节点单击事件
handleNodeClick(data) { handleNodeClick(data) {
this.queryParams.pageNo = 1
this.queryParams.deptId = data.id; this.queryParams.deptId = data.id;
this.getList(); this.getList();
}, },
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment