Commit eadba73c authored by dragondean@qq.com's avatar dragondean@qq.com
parents 4c0e44ce 7db8d452
......@@ -119,7 +119,7 @@
{{$t('操作')}}<i class="el-icon-arrow-down el-icon--right"></i>
</el-button>
<el-dropdown-menu slot="dropdown">
<!-- <el-dropdown-item :disabled="scope.row.ldStatus>=46" command="edit">{{$t('编辑')}}</el-dropdown-item> -->
<el-dropdown-item :disabled="scope.row.ldStatus>=46" command="edit" v-hasPermi="['shipment:box:update']">{{$t('编辑')}}</el-dropdown-item>
<el-dropdown-item command="sea" v-hasPermi="['shipment:box:action:sea']">{{$t('操作-海运')}}</el-dropdown-item>
<el-dropdown-item command="error" v-hasPermi="['shipment:box:action:error']">{{$t('异常登记')}}</el-dropdown-item>
<el-dropdown-item command="cost" v-hasPermi="['shipment:box:action:cost']">{{$t('费用登记')}}</el-dropdown-item>
......
......@@ -147,7 +147,7 @@
<!-- 修改柜信息 -->
<template v-if="dialogConfig.type === 'modifyCabinet' && dialogConfig.dialogVisible">
<el-form ref="modifyForm" :rules="rules" :model="modifyCabinetObj" label-width="80px">
<el-form-item :label="$t('起运仓库')" prop="startWarehouseId">
<el-form-item v-if="false" :label="$t('起运仓库')" prop="startWarehouseId">
<el-select v-model="modifyCabinetObj.startWarehouseId" :placeholder="$t('请选择仓库')" filterable>
<el-option v-for="warehouse in $attrs.warehouseList" :key="warehouse.id" :label="$l(warehouse, 'title')" :value="warehouse.id"></el-option>
</el-select>
......
......@@ -23,11 +23,11 @@
<ladingSelect v-model="subMaterialObj.shipperId" :placeholder="$t('请选择托运人')" :allUsers="this.$attrs.allLading" />
</el-form-item>
<el-form-item :label="$t('收货人')">
<el-input v-model="subMaterialObj.consigneeName"></el-input>
<el-input v-model="subMaterialObj.consigneeName" readonly></el-input>
<!-- <userSelect v-model="subMaterialObj.consigneeId" :placeholder="$t('请选择收货人')" :allUsers="this.$attrs.allUsers" /> -->
</el-form-item>
<el-form-item :label="$t('通知方')">
<el-input v-model="subMaterialObj.notifyingName"></el-input>
<el-input v-model="subMaterialObj.notifyingName" readonly></el-input>
<!-- <userSelect v-model="subMaterialObj.notifyingId" :placeholder="$t('请选择通知方')" :allUsers="this.$attrs.allUsers" /> -->
</el-form-item>
<el-form-item label="Mark & No.">
......@@ -150,7 +150,7 @@ export default {
this.$set(this.subMaterialObj,'notifyingName',response.data.externalBackVO?.notifyCompanyName||'/')
this.$set(this.subMaterialObj,'packageNum',response.data.externalBackVO?.packNum)
this.$set(this.subMaterialObj,'packageUnit',response.data.externalBackVO?.packUnit)
this.$set(this.subMaterialObj,'goodsDesc',response.data.externalBackVO?.goodName+response.data.externalBackVO?.fromNo+response.data.externalBackVO?.baNo)
this.$set(this.subMaterialObj,'goodsDesc',response.data.externalBackVO?.goodName||''+response.data.externalBackVO?.fromNo||''+response.data.externalBackVO?.baNo||'')
if(this.subMaterialObj.goodsDesc == null){
this.$set(this.subMaterialObj,'goodsDesc','/')
}
......@@ -180,8 +180,8 @@ export default {
},
download() {
getBoxLadingBillPdf({shipmentId: this.shipmentObj.id}).then(res=>{
let blob = new Blob([res], {type: "application/pdf"})
FileSaver.saveAs(blob, this.$t('提单确认件'));
let blob = new Blob([res], {type: "application/vnd.ms-excel"})
FileSaver.saveAs(blob, this.$t('提单确认件.xlsx'));
})
}
},
......
......@@ -164,7 +164,7 @@ export default {
list.push({
...oItem,
warehouseInInfo,
multiSpecification: item.multiSpecification,
// multiSpecification: item.multiSpecification,
positionNo: oItem.positionNo,
tallyStatus: item.tallyStatus,
tallyTime: item.tallyTime,
......
......@@ -799,6 +799,9 @@ export default {
return
}
// 重货标准和泡货标准,未打开就不传,提交前清空一下
if(!this.showZhong) this.form.weightUnit = ''
if(!this.showPao) this.form.lightUnit = ''
const form = {...this.form, type: this.form.type?.join(','), transportType: (this.form.transportType || [])?.join(','), taxRate: Number(this.form.taxRate)}
// 检查路线是否启用了但是没选择目的仓
......
......@@ -109,13 +109,13 @@
<el-button type="text" size="mini" v-has-permi="['ecw:commission-Payment:delete']" @click="deleteFn(row)" v-if="[0,2].includes(row.state)" > {{$t('删除')}}</el-button>
<el-button type="text" size="mini" v-has-permi="['ecw:commission-Payment:details']" v-if="[7,3,1,5].includes(row.state)" @click="$router.push({path:'/bpm/process-instance/detail',query:{id:row.bmpId}})" >{{$t('审核详情')}}</el-button>
<el-button type="text" size="mini" v-has-permi="['ecw:commission-Payment:Unapprove']" v-if="[1].includes(row.state)" @click="bridgeFn('取消审核',7, row, '取消审核' )" >{{$t('取消审核')}}</el-button>
<el-button type="text" size="mini" v-has-permi="['ecw:commission-Payment:De-approval']" v-if="[4,].includes(row.state)" @click="bridgeFn('付款单反审核', 1, row, '提交反审核',)" >{{$t('反审核')}}</el-button>
<el-button type="text" size="mini" v-has-permi="['ecw:commission-Payment:Write-off']" v-if="[4,].includes(row.state)" @click="bridgeFn('付款单核销申请', 2, row, '提交核销')" >{{$t('核销')}}</el-button>
<el-button type="text" size="mini" v-has-permi="['ecw:commission-Payment:De-approval']" v-if="[4,].includes(row.state)" @click="bridgeFn('佣金付款单反审核', 1, row, '提交反审核',)" >{{$t('反审核')}}</el-button>
<el-button type="text" size="mini" v-has-permi="['ecw:commission-Payment:Write-off']" v-if="[4,].includes(row.state)" @click="bridgeFn('佣金付款单核销申请', 2, row, '提交核销')" >{{$t('核销')}}</el-button>
<el-button type="text" size="mini" v-has-permi="['ecw:commission-Payment:print']" v-if="[4,6].includes(row.state)" @click="$router.push({path:'/financial/printPaymentVoucherCommission',query:{id:row.id}})" >{{$t('打印')}}</el-button>
<el-button type="text" size="mini" v-has-permi="['ecw:commission-Payment:CancelWrite-off']" v-if="[6,].includes(row.state)" @click="bridgeFn('付款单反核销申请', 3, row, '提交方核销')" >{{$t('反核销')}}</el-button>
<el-button type="text" size="mini" v-has-permi="['ecw:commission-Payment:CancelDe-approval']" v-if="[3].includes(row.state)" @click="bridgeFn('取消反审核',4, row, '提交取消反审核' )" >{{$t('取消反审核')}}</el-button>
<el-button type="text" size="mini" v-has-permi="['ecw:commission-Payment:CancelWrite-off']" v-if="[5].includes(row.state)" @click="bridgeFn('取消付款单核销',5, row, '取消付款单核销' )" > {{$t('取消核销')}} </el-button>
<el-button type="text" size="mini" v-has-permi="['ecw:commission-Payment:CancelCancellingWrite-off']" v-if="[7].includes(row.state)" @click="bridgeFn('取消付款单反核销',6, row, '取消付款单反核销' )" > {{$t('取消反核销')}} </el-button>
<el-button type="text" size="mini" v-has-permi="['ecw:commission-Payment:CancelWrite-off']" v-if="[6,].includes(row.state)" @click="bridgeFn('佣金付款单反核销申请', 3, row, '提交反核销')" >{{$t('反核销')}}</el-button>
<el-button type="text" size="mini" v-has-permi="['ecw:commission-Payment:CancelDe-approval']" v-if="[3].includes(row.state)" @click="bridgeFn('取消佣金付款单反审核',4, row, '提交取消反审核' )" >{{$t('取消反审核')}}</el-button>
<el-button type="text" size="mini" v-has-permi="['ecw:commission-Payment:CancelWrite-off']" v-if="[5].includes(row.state)" @click="bridgeFn('取消佣金付款单核销',5, row, '取消付款单核销' )" > {{$t('取消核销')}} </el-button>
<el-button type="text" size="mini" v-has-permi="['ecw:commission-Payment:CancelCancellingWrite-off']" v-if="[7].includes(row.state)" @click="bridgeFn('取消佣金付款单反核销',6, row, '取消付款单反核销' )" > {{$t('取消反核销')}} </el-button>
</template>
</el-table-column>
</el-table>
......@@ -130,7 +130,7 @@
<el-dialog @close="paymentValue = ''" width="30%" :title="paymentTitle" :visible.sync="paymentShow">
<div class="cancel_content">
<span>{{ $t('申请理由') }}</span>
<el-input type="textarea" :rows="6" v-model="paymentValue" :placeholder="$t('请输入取消理由')"></el-input>
<el-input type="textarea" :rows="6" v-model="paymentValue" :placeholder="[1,2,3].includes(paymentIndex) ? $t('请输入申请理由') : $t('请输入取消理由')"></el-input>
</div>
<span slot="footer" class="dialog-footers">
<el-button type="primary" @click="cancelWriteOffClick()">{{ $t(butTitle) }}</el-button>
......
......@@ -88,8 +88,12 @@
</el-card>
<el-table border :data="list" style="margin-top: 30px">
<el-table-column align="center" :label="$t('订单编号')" prop="orderNo" ></el-table-column>
<el-table-column align="center" :label="$t('品名')">
<template v-slot="{row}">
{{row.titleZh}}/{{row.titleEn}}
</template>
</el-table-column>
<el-table-column align="center" :label="$t('客户名称')" prop="customerName" ></el-table-column>
<el-table-column align="center" :label="$t('订单编号')" prop="payableNo" ></el-table-column>
<el-table-column align="center" :label="$t('佣金类型')">
<template v-slot="{row}">
<dict-tag
......
......@@ -68,7 +68,7 @@
:rules="{required:true,message:$t('业务员不能为空')}"
:error="$t('业务员不能为空')"
>
<el-select v-model="form.salesmanName" :placeholder="$t('请选择业务员')">
<el-select filterable v-model="form.salesmanName" :placeholder="$t('请选择业务员')">
<el-option
v-for="item in creatorData"
:key="item.id"
......@@ -98,11 +98,12 @@
</el-form-item>
</el-descriptions-item>
<el-descriptions-item :label="$t('客户的账户名称')" >
<el-form-item label-width="0" prop="customerBankAccountName">
<el-select v-model="form.customerBankAccount" >
<el-option @click.native="getBankInfo(item)" v-for="(item) in bankAccountList" :value="item.bankAccount" :label="item.bankAccount + (item.bankName)" ></el-option>
<el-form-item v-if="(form.customerId && bankAccountList.length) || !form.customerId" label-width="0" prop="customerBankAccountName">
<el-select v-model="form.customerBankAccountName" >
<el-option @click.native="getBankInfo(item)" v-for="(item) in bankAccountList" :value="item.accountName" :label="item.accountName" ></el-option>
</el-select>
</el-form-item>
<span v-else >{{$t('客户档案未设置银行账户。')}}</span>
</el-descriptions-item>
<el-descriptions-item :label="$t('账户名称')" >
<el-form-item label-width="0" :rules="{message:$t('账户名称不能为空'),required:true,}" prop="customerBankAccountName">
......@@ -403,8 +404,12 @@
>
<el-table-column type="selection" width="55" :reserve-selection="true"></el-table-column>
<el-table-column :label="$t('订单编号')" prop="orderNo"></el-table-column>
<el-table-column align="center" :label="$t('品名')">
<template v-slot="{row}">
{{row.titleZh}}/{{row.titleEn}}
</template>
</el-table-column>
<el-table-column :label="$t('客户名称')" prop="customerName"></el-table-column>
<el-table-column :label="$t('订单编号')" prop="payableNo"></el-table-column>
<el-table-column :label="$t('佣金类型')">
<template v-slot="{row}">
<dict-tag
......@@ -466,10 +471,12 @@ import NP from 'number-precision'
import {getWarehouseList} from '@/api/ecw/warehouse'
import WorkFlow from '@/components/WorkFlow/'
import {getCustomer, getCustomerPage} from "@/api/ecw/customer";
import Template from "@/views/cms/template/index.vue";
export default {
name: "commission-requestFunds",
components: {
Template,
CustomerSelector, WorkFlow
},
data() {
......@@ -533,7 +540,7 @@ export default {
applicationAt: this.parseTime(res.data.applicationAt, '{y}-{m}-{d} {h}:{i}:{s}'),
invoiceStatus: String(res.data.invoiceStatus),
}
this.$set(this.form, 'customerBankAccount', res.data.customerBankAccount)
this.$set(this.form, 'customerBankAccountName', accountName)
this.list = [...res.data.payableBackVOList]
this.defaultList = [...res.data.payableBackVOList]
});
......@@ -865,6 +872,15 @@ export default {
watch:{
'form.customerId'(val){
this.selectChange(val)
if(!val){
// 清空银行卡信息
this.form.customerAccountType = ''; //账户类型
this.form.customerBank = ''; //客户银行
this.form.customerBankAccount = ''; // 客户银行账号
this.form.customerBankAccountName = ''; //客户银行账户名
this.form.customerBankAddress = ''; // 银行地址
this.form.customerBankCode = ''; // 银行代码
}
}
}
......@@ -872,6 +888,9 @@ export default {
</script>
<style scoped>
.el-form-item{
margin-bottom: 0;
}
.card {
margin-top: 20px;
}
......
......@@ -152,6 +152,7 @@ export default {
currencyList:[],
list:[],
detailed: [],
detatilData:[],
showCurrencyId:0,
surplusData:[],
openAddDialog:false,
......@@ -159,7 +160,8 @@ export default {
addForm:{},
receiptId:0,
receiptItemId:0,
reason:''
reason:'',
receiptAccountList:[]
}
},
watch:{
......@@ -197,18 +199,19 @@ export default {
},
getList() {
getReceivableItem({ id: this.receiptId }).then(res => {
res.data = res.data.map(v => ({
this.detatilData = res.data.map(v => ({
...v,
amountDate: this.parseTime(v.amountDate, '{y}-{m}-{d}'),
accountNo: +v.accountNo,
rate:parseFloat(v.rate).toFixed(6),
attr: v.attr ? v.attr.split(',').map(t => ({ name: t.slice(t.lastIndexOf('/') + 1), url: t })) : []
}))
this.addForm = res.data.find(v=>v.id==this.receiptItemId)
this.addForm = this.detatilData.find(v=>v.id==this.receiptItemId)
this.detailed = []
this.detailed.push(this.addForm)
this.getCollectionData()
})
},
getReceiptInfo(){
getReceiptInfoByIds({ id: this.receiptId }).then(res => {
......@@ -274,7 +277,7 @@ export default {
handleAddReceiptItem() {
// 已收
let recepted = []
this.detailed.forEach(item => {
this.detatilData.forEach(item => {
if(!recepted[item.currencyId]){
recepted[item.currencyId] = item.amount
}else recepted[item.currencyId] = NP.plus(recepted[item.currencyId], item.amount)
......@@ -282,9 +285,9 @@ export default {
// 应收
let collom = []
// 从期望收费金额中提取应收币种和金额
this.collectionAmount.forEach(item => {
collom[item.currencyId] = item.amount
})
this.collectionAmount.forEach(item => {
collom[item.currencyId] = item.amount
})
console.log(recepted)
recepted.forEach((amount,currency)=>{
if(amount){
......
......@@ -7,40 +7,23 @@
:model="queryParams"
ref="queryForm"
size="small"
:inline="true"
label-width="100px"
class="card"
>
<el-row :span="24">
<el-form-item :label="$t('柜号')">
<el-row :gutter="10">
<el-col :span="4"> <el-form-item :label="$t('付款单号')">
<el-input
style="max-width: 188px"
v-model="queryParams.receiptNo"
:placeholder="$t('请输入收款单号')"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item :label="$t('自编号')">
<el-input
style="max-width: 188px"
v-model="queryParams.receiptNo"
:placeholder="$t('请输入收款单号')"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item :label="$t('付款单号')">
<el-input
style="max-width: 188px"
v-model="queryParams.receiptNo"
v-model="queryParams.paymentNo"
:placeholder="$t('请输入付款单号')"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item :label="$t('供应商')">
</el-form-item></el-col>
<el-col :span="4"><el-form-item :label="$t('供应商')">
<el-select
clearable
v-model="queryParams.supplierId"
:placeholder="$t('请选择供应商')"
>
......@@ -51,13 +34,8 @@
:value="supplier.id"
></el-option>
</el-select>
</el-form-item>
<el-form-item :label="$t('状态')">
<dict-selector :type="DICT_TYPE.PAYMENT_STATE" v-model="queryParams.state"/>
</el-form-item>
</el-row>
<el-row :span="24">
<el-form-item :label="$t('业务员')">
</el-form-item></el-col>
<el-col :span="4"><el-form-item :label="$t('业务员')">
<!-- <el-select v-model="form.salesmanId" :placeholder="$t('请选择业务员')">
<el-option
v-for="item in creatorData"
......@@ -66,7 +44,8 @@
:value="item.id"
/>
</el-select> -->
<el-select v-model="form.salesmanId" filterable :placeholder="$t('请选择业务员')"
<el-select v-model="queryParams.salesmanId" filterable :placeholder="$t('请选择业务员')"
clearable
@change="v => form.salesmanName = creatorData.find(t => t.id === v).nickname">
<el-option
v-for="item in creatorData"
......@@ -75,8 +54,8 @@
:value="item.id"
/>
</el-select>
</el-form-item>
<el-form-item :label="$t('创建时间')">
</el-form-item> </el-col>
<el-col :span="6"><el-form-item :label="$t('创建时间')">
<el-date-picker
v-model="queryParams.beginCreateTime"
type="datetimerange"
......@@ -85,17 +64,25 @@
:start-placeholder="$t('请选择日期')"
:end-placeholder="$t('请选择日期')">
</el-date-picker>
</el-form-item>
<el-form-item :label="$t('发票状态')">
</el-form-item></el-col>
</el-row>
<el-row :gutter="10">
<el-col :span="4">
<el-form-item :label="$t('状态')">
<dict-selector clearable :type="DICT_TYPE.ECW_PAYMENT_STATE" v-model="queryParams.state"/>
</el-form-item>
</el-col>
<el-col :span="4"><el-form-item :label="$t('发票状态')">
<el-select
clearable
v-model="queryParams.invoiceStatus"
:placeholder="$t('请选择是否开票')"
>
<el-option :label="$t('未开票')" value="0"/>
<el-option :label="$t('已开票')" value="1"/>
</el-select>
</el-form-item>
<el-form-item>
</el-form-item></el-col>
<el-col :span="6"><el-form-item>
<el-button type="primary" @click="handleQuery">{{ $t('查找') }}</el-button>
<el-button
style="margin-left: 10px"
......@@ -104,7 +91,7 @@
@click="handleAdd(0)"
>{{ $t('新增请款单') }}</el-button
>
</el-form-item>
</el-form-item></el-col>
</el-row>
</el-form>
</el-card>
......@@ -154,12 +141,12 @@
v-hasPermi="['ecw:paymentVoucher:edit']" type="text">{{ $t('编辑') }}
</el-button>
<!-- <el-button v-if="[1,3].includes(row.state)" size="mini" v-hasPermi="['ecw:paymentVoucher:process']" type="text" @click="examineClick(scope.row.id)">{{ $t('审核') }}</el-button>-->
<el-button size="mini" v-has-permi="['ecw:paymentVoucher:Unapprove']" type="text" v-if="[1].includes(row.state)" @click="bridgeFn(1, '取消审核',row)">
<el-button size="mini" type="text" v-show="[1].includes(row.state)" v-hasPermi="['ecw:paymentVoucher:Unapprove']" @click="bridgeFn(1, '取消审核',row)">
{{ $t('取消审核') }}
</el-button>
<el-button size="mini" type="text" v-has-permi="['ecw:paymentVoucher:details']" v-if="[7,3,1,5].includes(row.state)" @click="$router.push({path:'/bpm/process-instance/detail',query:{id:row.bmpId}})" >{{ $t('审核详情') }}</el-button>
<el-button size="mini" type="text" v-has-permi="['ecw:paymentVoucher:Cancel-De-approval']" v-if="[3].includes(row.state)" @click="bridgeFn(2, '取消付款单反审核',row)" >{{ $t('取消反审核') }}</el-button>
<el-button size="mini" v-has-permi="['ecw:paymentVoucher:Cancel-Write-off']" type="text" v-if="[5].includes(row.state)" @click="bridgeFn(3, '取消付款单核销',row)" >{{ $t('取消核销') }}</el-button>
<el-button size="mini" type="text" v-show="[7,3,1,5].includes(row.state)" v-hasPermi="['ecw:paymentVoucher:details']" @click="$router.push({path:'/bpm/process-instance/detail',query:{id:row.bmpId}})" >{{ $t('审核详情') }}</el-button>
<el-button size="mini" type="text" v-if="[3].includes(row.state)" v-hasPermi="['ecw:paymentVoucher:Cancel-De-approval']" @click="bridgeFn(2, '取消付款单反审核',row)" >{{ $t('取消反审核') }}</el-button>
<el-button size="mini" type="text" v-if="[5].includes(row.state)" v-hasPermi="['ecw:paymentVoucher:Cancel-Write-off']" @click="bridgeFn(3, '取消付款单核销',row)" >{{ $t('取消核销') }}</el-button>
<el-button v-if="[4].includes(row.state)" size="mini" type="text" v-hasPermi="['ecw:paymentVoucher:De-approval']"
@click="bridgeFn(4, '反审核',row)">{{ $t('反审核') }}
......@@ -172,7 +159,7 @@
v-hasPermi="['ecw:paymentVoucher:cancelWriteOff']" @click="bridgeFn(6, '反核销',row)">
{{ $t('反核销') }}
</el-button>
<el-button v-hasPermi="['ecw:paymentVoucher:Cancel-Cancelling-Write-off']" v-if="[7].includes(row.state)" size="mini" type="text" @click="bridgeFn(7, '取消付款单反核销',row)" > {{ $t('取消反核销') }}</el-button>
<el-button v-if="[7].includes(row.state)" v-hasPermi="['ecw:paymentVoucher:Cancel-Cancelling-Write-off']" size="mini" type="text" @click="bridgeFn(7, '取消付款单反核销',row)" > {{ $t('取消反核销') }}</el-button>
<!-- <el-button v-if="scope.row.state == 3" size="mini" type="text">{{ $t('开票') }}</el-button> -->
<el-button v-if="[6,4].includes(row.state)" size="mini" type="text" @click="toprint(row.id)"
......
......@@ -33,7 +33,7 @@
<table border="1" style="margin-top: 20px;width: 100%;text-align: center;border-collapse: collapse;line-height: 2 ">
<tr>
<th style="width: 6%;">{{ $t('序号') }}</th>
<th style="width: 11%;">{{ $t('编号') }}</th>
<th style="width: 11%;">{{ $t('订单编号') }}</th>
<th style="width: 15%;">{{ $t('佣金类型') }}</th>
<th style="width: 10%;">{{ $t('币种') }}</th>
<th style="width: 10%;">{{ $t('汇率') }}</th>
......@@ -44,7 +44,7 @@
</tr>
<tr v-for="(item, index) in list" :key="index">
<td>{{ index + 1 }}</td>
<td>{{ item.payableNo }}</td>
<td>{{ item.orderNo }}</td>
<td>
<dict-tag
:type="DICT_TYPE.COMMISSION_TYPE"
......
......@@ -218,7 +218,7 @@
<el-card class="card">
<div slot="header" class="card-title">{{ $t('银行收款明细') }}</div>
<div>
<el-button type="primary" v-if="form.state!=7&&form.state!=0" plain size="mini" @click="batchVerification" v-hasPermi="['ecw:payment:detail:batchWriteOff']" style="padding: 10px; margin-bottom: 10px">{{ $t('批量核销') }}</el-button>
<!-- <el-button type="primary" v-if="form.state!=7&&form.state!=0" plain size="mini" @click="batchVerification" v-hasPermi="['ecw:payment:detail:batchWriteOff']" style="padding: 10px; margin-bottom: 10px">{{ $t('批量核销') }}</el-button> -->
<el-button type="primary" v-if="form.state!=7&&form.state!=0" plain size="mini" @click="handleAddReceiptItem" v-hasPermi="['ecw:payment:detail:addBank']" style="padding: 10px; margin-bottom: 10px">{{ $t('添加收款明细') }}</el-button>
</div>
<el-table ref="multipleTable" :data="detailed" border row-key="id" @selection-change="handleSelectionChange">
......@@ -312,8 +312,8 @@
</el-descriptions>
</el-card>
<div slot="footer" style="margin: 20px 0">
<el-button v-if="form.state!=7&&form.state!=9&&form.state!=10&&form.state!=11" type="primary" @click="toEdit" v-hasPermi="['ecw:payment:detail:edit']">{{ $t('编辑') }}</el-button>
<el-button v-if="form.state!=7&&form.state!=9&&form.state!=10&&form.state!=11" type="primary" @click="verificationAll" v-hasPermi="['ecw:payment:detail:allWriteOff']">{{ $t('全部核销') }}</el-button>
<el-button v-if="form.state!=7&&form.state!=9&&form.state!=10&&form.state!=11&&form.state != 4&&form.state != 5 && form.state != 6" type="primary" @click="toEdit" v-hasPermi="['ecw:payment:detail:edit']">{{ $t('编辑') }}</el-button>
<el-button v-if="form.state!=7&&form.state!=9&&form.state!=10&&form.state!=11&&form.state != 4&&form.state != 5 && form.state != 6" type="primary" @click="verificationAll" v-hasPermi="['ecw:payment:detail:allWriteOff']">{{ $t('全部核销') }}</el-button>
<el-button
type="primary"
v-if="form.state == 11"
......@@ -342,6 +342,13 @@
@click="detailClickCancel(2)"
>{{ $t('取消全部核销审核') }}</el-button
>
<el-button
v-if="form.state == 4 || form.state == 5 || form.state == 6"
type="primary"
v-hasPermi="['ecw:voucher:cancelWriteOff']"
@click="writeOffShow()"
>{{ $t('提交收款单反核销') }}</el-button
>
<el-button plain type="primary" @click="$store.dispatch('tagsView/delCurrentView')">{{$t('返回')}}</el-button>
</div>
......@@ -358,6 +365,19 @@
<el-button @click="detailShow = false">{{$t('取消')}}</el-button>
</span>
</el-dialog>
<el-dialog
:title="$t('收款单反核销')"
:visible.sync="wiffShow"
width="30%">
<div class="cancel_content">
<span>{{$t('申请理由')}}</span>
<el-input type="textarea" :rows ="6" v-model="wiffRemark" :placeholder="$t('请输入理由')"></el-input>
</div>
<span slot="footer" class="dialog-footers">
<el-button type="primary" @click="writeOffClick()">{{$t('提交反核销')}}</el-button>
<el-button @click="wiffShow = false">{{$t('取消')}}</el-button>
</span>
</el-dialog>
<el-dialog v-if="openAddDialog" :visible.sync="openAddDialog" :title="dialogTitle" width="50%" append-to-body>
<div style="padding: 0 24px">
<el-form ref="addForm" :model="addForm" label-width="250px">
......@@ -539,7 +559,8 @@ import {
cancelFinanceReceiptItemWriteOff,
cancelFinanceReceiptItemWriteOffNo,
cancelFinanceReceiptWriteOffNo,
cancelFinanceReceiptWriteOff
cancelFinanceReceiptWriteOff,
financeReceiptWriteOffNo
} from "@/api/ecw/financial";
import { getCurrencyPage } from "@/api/ecw/currency";
import NP from 'number-precision'
......@@ -594,7 +615,9 @@ export default {
detailReason:'',
detailTitle:'',
detailShow:false,
detailIndex:1
detailIndex:1,
wiffShow:false,
wiffRemark:''
}
},
computed: {
......@@ -640,6 +663,11 @@ export default {
})
return total.toFixed(2)
},
//显示反审核反核销弹窗
writeOffShow(){
this.wiffRemark = ''
this.wiffShow = true
},
WriteOffProportion(){
let total = 0
if(!this.form.receiptAccountList) return 0
......@@ -778,6 +806,18 @@ export default {
this.form.receiptAccountList[index] = {...row}
},
setWriteOffAmount() {
var pointArr = []
var regs=/^[0-9]+\d*(\.\d*)?$|^0?\.\d*[0-9]\d*$/;
if(this.addForm.amount&&!regs.test(this.addForm.amount)){
this.addForm.amount = ''
this.$modal.msgError(this.$t('输入金额不对'));
}else{
pointArr = this.addForm.amount.split('.')
if(pointArr.length>1&&pointArr[1]){
this.addForm.amount =Math.round(this.addForm.amount*100)/100
}
}
this.$set(this.addForm, 'writeOffAmount', NP.times(this.addForm.rate || 0, this.addForm.amount || 0))
},
getCurrencyLabel(id){
......@@ -785,6 +825,43 @@ export default {
if(label.length>0) return this.$i18n.locale=='zh_CN'?label[0].titleZh:label[0].titleEn
return ''
},
getsurplusData() {
// 已收
this.surplusData = []
let recepted = []
this.detailed.forEach(item => {
if(!recepted[item.currencyId]){
recepted[item.currencyId] = item.amount
}else recepted[item.currencyId] = NP.plus(recepted[item.currencyId], item.amount)
})
// 应收
let collom = []
// 从期望收费金额中提取应收币种和金额
this.form.receiptAccountList.find(item => item.type == 'total').collectionAmount.forEach(item => {
collom[item.currencyId] = item.amount
})
recepted.forEach((amount,currency)=>{
if(amount){
if(collom[currency]){
if((collom[currency]-amount)!=0) this.surplusData[currency] = +parseFloat((collom[currency]-amount).toPrecision(12))
}else{
this.surplusData[currency] = -amount
}
}
})
collom.forEach((amount,currency)=>{
if(amount){
if(!this.surplusData[currency]){
if(recepted[currency]){
if((amount-recepted[currency])!=0) this.surplusData[currency] = +parseFloat((amount-recepted[currency]).toPrecision(12))
}else{
this.surplusData[currency] = amount
}
}
}
})
},
calculation() {
// this.currencyList.forEach((item,index)=>{
// var verificationList = this.detailed.filter(v => v.status === 1)
......@@ -889,6 +966,24 @@ export default {
this.reason = ''
this.dialogVisible = true
},
writeOffClick(){
if(!this.wiffRemark){
this.$modal.msgError(this.$t('请输入申请理由'));
return
}
this.$modal
.confirm(this.$t('您确认要反核销吗')+'?')
.then(()=>{
financeReceiptWriteOffNo({receiptId:this.id,receiptNo:this.form.receiptNo,remark:this.wiffRemark}).then(res=>{
this.getReceiptInfoData();
this.$message.success(this.$t("提交成功"));
this.wiffShow = false
// this.$store.dispatch('tagsView/delCurrentView')
});
})
.catch(() => {this.wiffShow = false});
},
//显示取消审核弹窗
detailClickCancel(type){
this.detailIndex = type
......@@ -916,20 +1011,33 @@ export default {
if(this.detailIndex ==1){
cancelFinanceReceiptWriteOffNo({receiptId:this.id,remark:this.detailReason}).then(res=>{
this.detailShow = false
this.getList();
this.getReceiptInfoData();
this.$message.success(this.$t("提交成功"));
});
}else{
cancelFinanceReceiptWriteOff({receiptId:this.id,remark:this.detailReason}).then(res=>{
this.detailShow = false
this.getList();
this.getReceiptInfoData();
this.$message.success(this.$t("提交成功"));
});
}
},
getReceiptInfoData(){
getReceiptInfoByIds({ id: this.id }).then(res => {
this.form = res.data
getCustomer(this.form.customerId).then(res => {
this.form.customerName = res?.data?.name
})
var dept = this.deptData.filter((itt) => itt.id == res.data.departmentId);
// console.log(dept)
if(dept.length>0){
this.form.departmentName = dept[0].name
}
})
},
//取消审核
cancelWriteOffClick(){
if(!this.cancelReason){
......@@ -1011,6 +1119,7 @@ export default {
return this.$router.push("creatCollection?id=" + this.id);
},
detailClick(row) {
this.getsurplusData()
this.openAddDialog = true
this.dialogTitle = this.$t('银行实收明细详情')
this.isView = true
......@@ -1112,59 +1221,7 @@ export default {
this.openAddDialog = false
},
handleAddReceiptItem() {
this.surplusData = []
// 已收
let recepted = []
this.detailed.forEach(item => {
if(!recepted[item.currencyId]){
recepted[item.currencyId] = item.amount
}else recepted[item.currencyId] = NP.plus(recepted[item.currencyId], item.amount)
})
console.log('rece',recepted)
// 应收
let collom = []
/* this.form.receiptAccountList.forEach(item => {
if(item.type!='total'){
if(!collom[item.currencyId]){
collom[item.currencyId] = item.receivableAmount-item.discountTotal
}else collom[item.currencyId] = NP.plus(collom[item.currencyId], item.receivableAmount)
}
}) */
// 从期望收费金额中提取应收币种和金额
this.form.receiptAccountList.find(item => item.type == 'total').collectionAmount.forEach(item => {
collom[item.currencyId] = item.amount
})
console.log(this.form.receiptAccountList)
console.log('collom',collom)
// if(recepted.length>collom.length){
recepted.forEach((amount,currency)=>{
if(amount){
if(collom[currency]){
if((collom[currency]-amount)!=0) this.surplusData[currency] = +parseFloat((collom[currency]-amount).toPrecision(12))
}else{
this.surplusData[currency] = -amount
}
}
})
// }else{
collom.forEach((amount,currency)=>{
if(amount){
if(!this.surplusData[currency]){
if(recepted[currency]){
if((amount-recepted[currency])!=0) this.surplusData[currency] = +parseFloat((amount-recepted[currency]).toPrecision(12))
}else{
this.surplusData[currency] = amount
}
}
}
})
// }
console.log(this.surplusData)
this.getsurplusData()
this.addForm = {}
this.openAddDialog = true
this.isView = false
......
......@@ -316,6 +316,7 @@ export default {
dateType: [],
loading: "",
params: {
},
// 查询参数
queryParams: {
......@@ -361,6 +362,13 @@ export default {
/** 查询列表 */
getList() {
this.loading = true;
this.params = {}
for(var key in this.queryParams){
if(this.queryParams[key]){
this.params[key] = this.queryParams[key]
}
}
console.log(this.params)
// 处理查询参数
let params = { ...this.params };
this.addBeginAndEndTime(params, this.dateRangeCreateTime, "createTime");
......@@ -451,7 +459,7 @@ export default {
this.cancelShow = false
this.getList();
this.$message.success(this.$t("提交成功"));
});
}
......@@ -500,7 +508,6 @@ export default {
},
/** 搜索按钮操作 */
handleQuery() {
this.params = {}
if(this.dateFilter&&this.dateFilter.length>0){
this.queryParams.beginCreateTime = this.dateFilter[0]
this.queryParams.endCreateTime = this.dateFilter[1]
......@@ -509,12 +516,7 @@ export default {
this.queryParams.endCreateTime = ''
}
this.queryParams.pageNo = 1;
for(var key in this.queryParams){
if(this.queryParams[key]){
this.params[key] = this.queryParams[key]
}
}
this.queryParams.page = 1;
this.getList();
},
/** 新增按钮操作 */
......
......@@ -2,7 +2,7 @@
<el-dialog :title="title" visible :before-close="closeDialog" :close-on-click-modal="false" v-loading="loading">
<el-timeline v-if="list.length">
<el-timeline-item v-for="item in list" :timestamp="item.pickTime|parseTime" placement="top" :key="item.id">
<div> {{item.deleted ? $t('已撤销') : $t('已提货')}} <el-button v-if="!item.deleted" size="mini" @click="deletePickup(item.id)" class="ml-10">{{$t('撤销')}}</el-button></div>
<div> {{item.deleted ? $t('已撤销') : $t('已提货')}} <el-button v-if="!item.deleted" :disabled="loading" size="mini" @click="deletePickup(item.id)" class="ml-10">{{$t('撤销')}}</el-button></div>
<div>{{$t('提货箱数')}}{{item.pickNum}}</div>
<div>{{$t('操作人')}}{{item.creator}}</div>
<div v-if="item.deleted">{{$t('撤销人')}}{{item.updater}}</div>
......@@ -50,6 +50,7 @@ export default {
}).then(res => {
this.$message.success('操作成功')
this.$emit('delete', id)
this.getList()
})
},
closeDialog(){
......@@ -58,4 +59,4 @@ export default {
}
}
}
</script>
\ No newline at end of file
</script>
......@@ -192,7 +192,7 @@ export default {
channelList:[],
processInstanceID:undefined,
list:[],
currencyList:[],
prodName: ''
}
},
......
......@@ -55,7 +55,8 @@
</el-table-column>
<el-table-column :label="$t('操作')">
<template v-slot:default = 'scope'>
<el-button type="text" v-if="scope.row.status !== 0">{{STATUS[scope.row.status]}}</el-button>
<el-button type="text" v-if="scope.row.status !== 0&&scope.row.status !== 1">{{STATUS[scope.row.status]}}</el-button>
<el-button type="text" v-if="scope.row.status == 1" @click="examineFn">{{$t('审核中')}}</el-button>
<el-button type="text" v-if="scope.row.status === 2" @click="modify(scope.row)">{{$t('修改')}}</el-button>
</template>
</el-table-column>
......@@ -185,6 +186,7 @@ export default {
},
examineFn(){
let item = this.list.find(e => e.status === 1);
console.log(item)
this.$router.push({path:'/bpm/process-instance/detail',query:{id:item.bpmProcessId}})
},
cancel(){
......
......@@ -503,10 +503,10 @@ export default {
watch: {
visible(val){
if (val) {
this.init()
this.getProductBrandPage(this.warehousing.brandName)
this.getProductBrandPage1()
this.handleBrandChange(parseInt(this.form.brand))
this.init()
} else {
this.$emit('close')
}
......@@ -723,6 +723,7 @@ export default {
orderId: this.warehousing.orderId,
orderItemId: this.warehousing.orderItemId,
orderNo: this.warehousing.orderNo,
isAppend: this.isAdd ? true : undefined,
orderWarehouseInItemDoList: this.form.table.map(e => {
return {
...e,
......
......@@ -89,7 +89,7 @@
<el-table-column :label="$t('序号')" width="80px">
<template slot-scope="scope">{{scope.$index + 1}}</template>
</el-table-column>
<el-table-column :label="$t('部门')" prop="priceAdvantage">
<el-table-column :label="$t('部门')" prop="department">
</el-table-column>
<el-table-column :label="$t('职位')" prop="position">
</el-table-column>
......@@ -470,6 +470,7 @@ export default {
this.formData = response.data
this.$set(this.formData, 'companyTypeArr', this.strToArray(response.data.companyType))
this.$set(this.formData, 'priceAdvantage', response.data.priceAdvantage==0?'':response.data.priceAdvantage)
this.$set(this.formData, 'settlementPeriod', response.data.settlementPeriod==0?null:response.data.settlementPeriod)
this.formData.bankList.forEach(item => {
item.currency = +item.currency
......
......@@ -20,7 +20,7 @@
<el-input v-model="queryParams.keyword" :placeholder="$t('名称/代码')" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item :label="$t('供应商区域')" prop="areaType">
<el-form-item :label="$t('境内外')" prop="areaType">
<el-select v-model="queryParams.areaType" placeholder="请选择" clearable="true">
<el-option
v-for="item in areaTypes"
......@@ -64,6 +64,11 @@
</template>
</template>
</el-table-column>
<el-table-column :label="$t('境内外')" align="center" prop="areaType">
<template slot-scope="scope">
<span>{{ areaData[scope.row.areaType] }}</span>
</template>
</el-table-column>
<el-table-column :label="$t('合作类型')" align="center" prop="cooperationType">
<template slot-scope="{row}">
<dict-tag type="cooperation_type" :value="row.cooperationType" />
......@@ -120,9 +125,10 @@ export default {
dateRangeCreateTime: [],
areaTypes:[
{value:0, label:"国内供应商"},
{value:1, label:"国外供应商"}
{value:0, label:"境内"},
{value:1, label:"境外"}
],
areaData: ["境内", "境外"],
// 查询参数
queryParams: {
......
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