4.7新增付款申请和付款需求

product
17602169347 2 years ago
parent 8369c7620e
commit 188bca2a77

@ -158,6 +158,16 @@ public class PaymentController {
public ActionResult confirmPrice(@RequestBody PaymentListVO paymentListVO) {
PaymentEntity paymentEntity = paymentService.getById(paymentListVO.getId());
paymentEntity.setStatus("2");
if(paymentListVO.getAccountingPeriod() != null && paymentListVO.getAccountingPeriod() > 0){
paymentEntity.setAccountingPeriod(paymentListVO.getAccountingPeriod());
Calendar mon = Calendar.getInstance();
mon.setTime(paymentEntity.getBusinessdate());
mon.add(Calendar.DATE,paymentListVO.getAccountingPeriod());
paymentEntity.setPaymentDate(mon.getTime());
}else{
paymentEntity.setAccountingPeriod(0);
paymentEntity.setPaymentDate(paymentEntity.getBusinessdate());
}
paymentService.updateById(paymentEntity);
List<Payment_item0Entity> Payment_item0List = paymentService.GetPayment_item0List(paymentEntity.getId());
for (Payment_item0Entity payment_item0Entity: Payment_item0List) {

@ -117,4 +117,13 @@ public class PaymentEntity {
private String voucher;
@TableField("supplier_id")
private String supplierId;
@TableField("accounting_period")
private Integer accountingPeriod;
@TableField("payment_date")
private Date paymentDate;
@TableField("advance_amount")
private BigDecimal advanceAmount;
@TableField("overdue_interest")
private BigDecimal overdueInterest;
}

@ -97,5 +97,13 @@ public class PaymentCrForm {
@JsonProperty("payment_item0List")
private List<Payment_item0Model> payment_item0List;
@JsonProperty("accountingPeriod")
private Integer accountingPeriod;
@JsonProperty("paymentDate")
private Long paymentDate;
@JsonProperty("advanceAmount")
private String advanceAmount;
@JsonProperty("overdueInterest")
private String overdueInterest;
}

@ -99,4 +99,13 @@ public class PaymentInfoVO{
/** 子表数据 **/
@JsonProperty("payment_item0List")
private List<Payment_item0Model> payment_item0List;
@JsonProperty("accountingPeriod")
private Integer accountingPeriod;
@JsonProperty("paymentDate")
private Long paymentDate;
@JsonProperty("advanceAmount")
private String advanceAmount;
@JsonProperty("overdueInterest")
private String overdueInterest;
}

@ -112,4 +112,14 @@ public class PaymentListVO{
private String supplierId;
@JsonProperty("supplierName")
private String supplierName;
@JsonProperty("accountingPeriod")
private Integer accountingPeriod;
@JsonFormat(pattern = "yyyy-MM-dd",timezone = "GMT+8")
@JsonProperty("paymentDate")
private Date paymentDate;
@JsonProperty("advanceAmount")
private String advanceAmount;
@JsonProperty("overdueInterest")
private String overdueInterest;
}

@ -115,4 +115,12 @@ public class PaymentUpForm{
@JsonProperty("payment_item0List")
private List<Payment_item0Model> payment_item0List;
@JsonProperty("accountingPeriod")
private Integer accountingPeriod;
@JsonProperty("paymentDate")
private Date paymentDate;
@JsonProperty("advanceAmount")
private String advanceAmount;
@JsonProperty("overdueInterest")
private String overdueInterest;
}

@ -142,4 +142,9 @@ public class PaymentdocEntity {
@TableField(exist = false)
private List<PoundlistEntity> poundlistEntityList;
@TableField("customer_name")
private String customerName;
@TableField("num")
private BigDecimal num;
}

@ -127,5 +127,10 @@ public class PaymentdocCrForm {
@JsonProperty("paymentdocitem2List")
private List<PaymentdocItem2Model> paymentdocitem2List;
@JsonProperty("customerName")
private String customerName;
@JsonProperty("num")
private BigDecimal num;
@JsonProperty("creatorUserName")
private String creatorUserName;
}

@ -117,4 +117,11 @@ public class PaymentdocInfoVO{
/** 子表数据 **/
@JsonProperty("paymentEntityList")
private List<PaymentEntity> paymentEntityList;
@JsonProperty("customerName")
private String customerName;
@JsonProperty("num")
private BigDecimal num;
@JsonProperty("creatorUserName")
private String creatorUserName;
}

@ -151,4 +151,11 @@ public class PaymentdocListVO{
@JsonProperty("poundlistEntityList")
private List<PoundlistEntity> poundlistEntityList;
@JsonProperty("customerName")
private String customerName;
@JsonProperty("num")
private BigDecimal num;
@JsonProperty("creatorUserName")
private String creatorUserName;
}

@ -117,4 +117,10 @@ public class PaymentdocUpForm{
@JsonProperty("paymentdocitem2List")
private List<PaymentdocItem2Model> paymentdocitem2List;
@JsonProperty("customerName")
private String customerName;
@JsonProperty("num")
private BigDecimal num;
@JsonProperty("creatorUserName")
private String creatorUserName;
}

@ -987,4 +987,47 @@ public class PurchaseorderController {
}
return ActionResult.success("删除成功");
}
/**
*
*
* @param id
* @return
*/
@DeleteMapping("/removePound/{id}")
@Transactional
public ActionResult removePound(@PathVariable("id") String id) {
PurchaseorderitemEntity entity = purchaseorderitemService.getInfo(id);
if (!entity.getStatus().equals("0")) {
return ActionResult.fail("该状态下不允许删除!");
}
if (entity != null) {
purchaseorderitemService.delete(entity);
QueryWrapper<Purchaseorder_item0Entity> queryWrapper = new QueryWrapper<>();
queryWrapper.lambda().eq(Purchaseorder_item0Entity::getPurchaseorderId, entity.getId());
queryWrapper.lambda().select(Purchaseorder_item0Entity::getPoundlistId);
List<String> poundlistIdList = purchaseorder_item0Service.listObjs(queryWrapper).stream().map(o -> (String) o).collect(Collectors.toList());
List<PoundlistEntity> poundlistList = poundlistService.listByIds(poundlistIdList);
for (PoundlistEntity poundlistEntity : poundlistList) {
poundlistService.delete(poundlistEntity);
}
QueryWrapper<Purchaseorder_item0Entity> queryWrapperPurchaseorder_item0 = new QueryWrapper<>();
queryWrapperPurchaseorder_item0.lambda().eq(Purchaseorder_item0Entity::getPurchaseorderId, entity.getId());
purchaseorder_item0Service.remove(queryWrapperPurchaseorder_item0);
QueryWrapper<Invoices_item0itemEntity> queryWrapperInvoices_item0item = new QueryWrapper<>();
queryWrapperInvoices_item0item.lambda().eq(Invoices_item0itemEntity::getPurchaseorderId, entity.getId());
invoices_item0itemService.remove(queryWrapperInvoices_item0item);
QueryWrapper<PaymentitemEntity> queryWrapperPaymentitem = new QueryWrapper<>();
queryWrapperPaymentitem.lambda().eq(PaymentitemEntity::getDocumentno, entity.getDocumentNo());
paymentitemService.remove(queryWrapperPaymentitem);
QueryWrapper<PurchasebackitemEntity> queryWrapperPurchasebackitem = new QueryWrapper<>();
queryWrapperPurchasebackitem.lambda().eq(PurchasebackitemEntity::getPurchaseOrderId, entity.getId());
purchasebackitemService.remove(queryWrapperPurchasebackitem);
QueryWrapper<CollectionpoEntity> queryWrapperCollectionitem = new QueryWrapper<>();
queryWrapperCollectionitem.lambda().eq(CollectionpoEntity::getSalesOrderNo, entity.getDocumentNo());
collectionpoService.remove(queryWrapperCollectionitem);
}
return ActionResult.success("删除成功");
}
}

@ -100,7 +100,22 @@
</el-input-number>
</el-form-item>
</el-col>
<el-col :span="6" v-if="judgeShow('num')">
<el-form-item label="结算重量" prop="num">
<el-input-number :disabled="true" v-model="dataForm.num"
:style='{"width":"100%"}' placeholder="数字文本" :step="1" :precision="6">
</el-input-number>
</el-form-item>
</el-col>
<el-col :span="6" v-if="judgeShow('customerName')">
<el-form-item label="客户名称" prop="customerName">
<el-input v-model="dataForm.customerName" placeholder="请输入"
clearable :style='{"width":"100%"}' readonly>
</el-input>
</el-form-item>
</el-col>
<el-col :span="6" v-if="judgeShow('collectionAccount')">
<el-form-item label="收款账户" prop="collectionAccount">
<el-input v-model="dataForm.collectionAccount"
@ -159,7 +174,6 @@
</el-input>
</el-form-item>
</el-col>
<!-- <el-col :span="8" v-if="judgeShow('departmentId')">
<el-form-item label="部门id" prop="departmentId">
<el-input :disabled="judgeWrite('departmentId')" v-model="dataForm.departmentId"
@ -956,9 +970,12 @@
var paymentAmount = 0;
var paymentAmountHistory = 0;
var unpaymentAmount = 0;
var num = 0;
var paymentdocitem1List = [];
var customerNameArr = [];
this.dataForm.paymentEntityList = [];
data.purchaseorder.forEach((item, index) => {
num = this.jnpf.floatAdd(num, item.num);
item.allAmount = item.amount;
item.amount = item.allAmount - item.payPrice;
item.purchaseorderId = item.id;
@ -969,12 +986,20 @@
paymentAmountHistory = paymentAmountHistory + item.payPrice; //
unpaymentAmount = unpaymentAmount + (item.allAmount - item.payPrice); //
item.poundlistEntityList.forEach((item2, index2) => {
customerNameArr.push(item2.customerName);
item2.poundlistId = item2.id;
item2.purchaseorderId = item.purchaseorderId;
item2.id = '';
paymentdocitem1List.push(item2);
});
});
if(customerNameArr.length > 0){
var newCustomerNameArr = [...new Set(customerNameArr)]; //Set
this.dataForm.customerName = newCustomerNameArr.join(",");
}else{
this.dataForm.customerName = '';
}
this.dataForm.num = num;
this.dataForm.paymentdocitem1List = paymentdocitem1List;
this.dataForm.ramount = ramount;
this.dataForm.paymentAmount = paymentAmount;

@ -69,6 +69,14 @@
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="垫资金额" prop="advanceAmount">
<el-input v-model="dataForm.advanceAmount" placeholder="请输入" clearable :style='{"width":"100%"}'
:disabled="true">
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="应付日期" prop="duedate">
<el-date-picker v-model="dataForm.duedate" placeholder="请选择" clearable :style='{"width":"100%"}'
@ -110,6 +118,13 @@
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="付款凭证" prop="voucher">
<JNPF-UploadFz v-model="dataForm.voucher" :fileSize="15" :showTip="true" sizeUnit="MB" :limit="9"
buttonText="点击上传">
</JNPF-UploadFz>
</el-form-item>
</el-col>
<el-col :span="16">
<el-form-item label="备注" prop="remark">
<el-input v-model="dataForm.remark" placeholder="请输入" clearable :style='{"width":"100%"}'>
@ -126,13 +141,6 @@
</el-select>
</el-form-item>
</el-col> -->
<el-col :span="8">
<el-form-item label="付款凭证" prop="voucher">
<JNPF-UploadFz v-model="dataForm.voucher" :fileSize="15" :showTip="true" sizeUnit="MB" :limit="9"
buttonText="点击上传">
</JNPF-UploadFz>
</el-form-item>
</el-col>
<el-col :span="24">
<el-tabs v-model="activeivpzpd" tab-position="top" class="mb-20">
<el-tab-pane label="申请明细">

@ -77,6 +77,14 @@
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="垫资金额" prop="advanceAmount">
<el-input v-model="dataForm.advanceAmount" placeholder="请输入" clearable :style='{"width":"100%"}'
:disabled="true">
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="实付日期" prop="businessdate">
<el-date-picker v-model="dataForm.businessdate" placeholder="请选择" clearable :style='{"width":"100%"}'
@ -117,7 +125,14 @@
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-col :span="8">
<el-form-item label="付款凭证" prop="voucher">
<JNPF-UploadFz v-model="dataForm.voucher" :fileSize="15" :showTip="true" sizeUnit="MB" :limit="9"
buttonText="点击上传">
</JNPF-UploadFz>
</el-form-item>
</el-col>
<el-col :span="16">
<el-form-item label="备注" prop="remark">
<el-input v-model="dataForm.remark" placeholder="请输入" clearable :style='{"width":"100%"}'>
@ -133,13 +148,6 @@
</el-select>
</el-form-item>
</el-col> -->
<el-col :span="8">
<el-form-item label="付款凭证" prop="voucher">
<JNPF-UploadFz v-model="dataForm.voucher" :fileSize="15" :showTip="true" sizeUnit="MB" :limit="9"
buttonText="点击上传">
</JNPF-UploadFz>
</el-form-item>
</el-col>
<el-col :span="24">
<el-tabs v-model="activeivpzpd" tab-position="top" class="mb-20">
<el-tab-pane label="申请明细">

@ -0,0 +1,297 @@
<template>
<el-dialog :title="!dataForm.id ? '新建' : isDetail ? '详情':'认款'" :close-on-click-modal="false" append-to-body
:visible.sync="visible" class="JNPF-dialog JNPF-dialog_center" lock-scroll width="500px">
<el-row :gutter="15" class="">
<el-form ref="elForm" :model="dataForm" :rules="rules" size="small" label-width="100px" label-position="right">
<template v-if="!loading">
<el-col :span="16">
<el-form-item label="账期(日)" prop="accountingPeriod">
<el-input-number v-model="dataForm.accountingPeriod" :min="0" @change="toInteger"></el-input-number>
</el-input>
</el-form-item>
</el-col>
</template>
</el-form>
</el-row>
<span slot="footer" class="dialog-footer">
<el-button @click="visible = false"> </el-button>
<el-button type="primary" @click="dataFormSubmit()" v-if="!isDetail" :disabled="submitDisabled"> </el-button>
</span>
</el-dialog>
</template>
<script>
import request from '@/utils/request'
import {
getDataInterfaceRes
} from '@/api/systemData/dataInterface'
import {
getDictionaryDataSelector
} from '@/api/systemData/dictionary'
export default {
components: {},
props: [],
data() {
return {
submitDisabled: false,
excludeFields: [],
visible: false,
loading: false,
isDetail: false,
dataForm: {
documentno: '',
suppliername: '',
paymenttype: "0",
paymentaccount: '',
paymentbank: '',
paymentamount: '',
collectionaccount: '',
collectionbank: '',
requestedamount: '',
accountingPeriod: 0,
duedate: '',
businessdate: '',
currency: "0",
settlementtype: "0",
paymentno: '',
remark: '',
status: "0",
payment_item0List: [],
voucher : [],
},
activeivpzpd: '0',
rules: {
suppliername: [],
paymentaccount: [],
paymentamount: [{
required: true,
message: '请输入付款金额',
trigger: 'blur'
},
],
businessdate: [{
required: true,
message: '请选择实付日期',
trigger: 'blur'
}
],
},
paymenttypeOptions: [{
"fullName": "货款",
"id": "0"
}, {
"fullName": "运费",
"id": "1"
}, {
"fullName": "仓储",
"id": "2"
}],
currencyOptions: [{
"fullName": "人民币",
"id": "0"
}, {
"fullName": "美元",
"id": "1"
}, {
"fullName": "英镑",
"id": "2"
}],
settlementtypeOptions: [{
"fullName": "现金",
"id": "0"
}, {
"fullName": "赊购",
"id": "1"
}, {
"fullName": "网银",
"id": "2"
}, {
"fullName": "银企直连",
"id": "3"
}, {
"fullName": "银票",
"id": "4"
}, {
"fullName": "商票",
"id": "5"
}],
statusOptions: [{
"fullName": "已保存",
"id": "0"
}, {
"fullName": "审批中",
"id": "1"
}, {
"fullName": "已审批",
"id": "2"
}, {
"fullName": "已付款",
"id": "3"
}],
}
},
computed: {},
watch: {
dataForm: {
deep: true,
handler: function() {
this.popupSelect()
}
}
},
created() {},
mounted() {},
methods: {
toInteger() {
let reg = /^[0-9]+$/
if(!reg.test(this.dataForm.accountingPeriod)){
this.$message.warning("只能输入整数")
// domdom
this.$nextTick(() => {
this.dataForm.accountingPeriod = parseInt(this.dataForm.accountingPeriod)
})
}
},
getSummaries(param) {
const { columns, data } = param;
const sums = [];
columns.forEach((column, index) => {
if (index === 0) {
sums[index] = '合计';
return;
}
const values = data.map(item => Number(item[column.property]));
if (!values.every(value => isNaN(value)) && (index === 1 || index === 2 || index === 3 || index === 4|| index === 5|| index === 8|| index === 9|| index === 10|| index === 11 )) {
sums[index] = values.reduce((prev, curr) => {
const value = Number(curr);
if (!isNaN(value)) {
return this.jnpf.floatAdd(prev,curr);
} else {
return prev;
}
}, 0);
} else {
sums[index] = '';
}
});
return sums;
},
popupSelect() {
let amount = 0
for (let i = 0; i < this.dataForm.payment_item0List.length; i++) {
amount = amount + parseFloat(this.dataForm.payment_item0List[i].amount);
}
parseFloat(this.dataForm.paymentamount = amount)
},
payment_item0Exist() {
let isOk = true;
for (let i = 0; i < this.dataForm.payment_item0List.length; i++) {
const e = this.dataForm.payment_item0List[i];
}
return isOk;
},
clearData(data) {
for (let key in data) {
if (data[key] instanceof Array) {
data[key] = [];
} else if (data[key] instanceof Object) {
this.clearData(data[key]);
} else {
data[key] = "";
}
}
},
init(id, isDetail) {
this.dataForm.id = id || 0;
this.visible = true;
this.isDetail = isDetail || false;
this.$nextTick(() => {
this.$refs['elForm'].resetFields();
if (this.dataForm.id) {
this.loading = true
request({
url: '/api/payment/Payment/' + this.dataForm.id,
method: 'get'
}).then(res => {
this.dataInfo(res.data)
this.loading = false
});
} else {
this.clearData(this.dataForm)
}
});
this.$store.commit('generator/UPDATE_RELATION_DATA', {})
},
//
dataFormSubmit() {
this.$refs['elForm'].validate((valid) => {
if (valid) {
if (!this.payment_item0Exist()) return
this.request()
}
})
},
request() {
this.submitDisabled = true;
var _data = this.dataList()
request({
url: `/api/payment/Payment/confirmprice`,
method: 'POST',
data: _data
}).then(res => {
this.$message({
message: res.msg,
type: 'success',
duration: 1000,
onClose: () => {
this.submitDisabled = false;
this.visible = false
this.$emit('refresh', true)
}
})
}).catch(() => {
this.submitDisabled = false
})
},
addpayment_item0List() {
let item = {
amount: undefined,
creatorUserId: undefined,
creatorUserName: undefined,
lastModifyUserId: undefined,
lastModifyUserName: undefined,
lastModifyTime: undefined,
deleteUserId: undefined,
deleteTime: undefined,
orgnizeId: undefined,
departmentId: undefined,
creatorTime: undefined,
}
this.dataForm.payment_item0List.push(item)
},
delpayment_item0List(index) {
this.dataForm.payment_item0List.splice(index, 1);
},
dataList() {
var _data = JSON.parse(JSON.stringify(this.dataForm));
_data.voucher = JSON.stringify(_data.voucher)
for (let i = 0; i < _data.payment_item0List.length; i++) {
var _list = _data.payment_item0List[i];
}
return _data;
},
dataInfo(dataAll) {
let _dataAll = dataAll
_dataAll.voucher = JSON.parse( _dataAll.voucher)
for (let i = 0; i < _dataAll.payment_item0List.length; i++) {
var _list = _dataAll.payment_item0List[i];
}
this.dataForm = _dataAll
},
},
}
</script>

@ -91,6 +91,10 @@
{{ scope.row.settlementtype | dynamicText(settlementtypeOptions) }}
</template>
</el-table-column>
<el-table-column prop="accountingPeriod" label="账期(日)" sortable width="150" align="center" />
<el-table-column prop="paymentDate" label="应回日期" sortable width="150" align="center" />
<el-table-column prop="advanceAmount" label="垫资金额" sortable width="150" align="center" />
<el-table-column prop="overdueInterest" label="逾期利息" sortable width="150" align="center" />
<el-table-column label="操作" fixed="right" width="150" align="center" >
<template slot-scope="scope">
<el-button v-if="scope.row.status == 0" type="text" @click="addOrUpdateHandle(scope.row.id)" v-has="'btn_edit'">
@ -107,6 +111,7 @@
</div>
</div>
<JNPF-Form v-if="formVisible" ref="JNPFForm" @refresh="refresh" />
<RenkuanForm v-if="formVisible2" ref="JNPFForm2" @refresh="refresh2" />
<ExportBox v-if="exportBoxVisible" ref="ExportBox" @download="download" />
<Detail v-if="detailVisible" ref="Detail" @refresh="detailVisible=false" />
</div>
@ -118,6 +123,7 @@
getDictionaryDataSelector
} from '@/api/systemData/dictionary'
import JNPFForm from './Form'
import RenkuanForm from './RenkuanForm'
import ExportBox from './ExportBox'
import {
getDataInterfaceRes
@ -127,6 +133,7 @@
export default {
components: {
JNPFForm,
RenkuanForm,
ExportBox,
Detail
},
@ -153,6 +160,7 @@
sidx: "businessdate",
},
formVisible: false,
formVisible2: false,
exportBoxVisible: false,
columnList: [{
prop: 'paymentno',
@ -453,21 +461,28 @@
})
return
}
let param = {};
param.id= this.multipleSelectionItem[0].id;
request({
url: `/api/payment/Payment/confirmprice`,
method: 'POST',
data: param
}).then(res => {
this.$message({
type: 'success',
message: res.msg,
onClose: () => {
this.initData()
}
});
})
this.formVisible2 = true
if(this.multipleSelectionItem[0].advanceAmount > 0){
this.$nextTick(() => {
this.$refs.JNPFForm2.init(this.multipleSelectionItem[0].id)
})
}else{
let param = {};
param.id= this.multipleSelectionItem[0].id;
request({
url: `/api/payment/Payment/confirmprice`,
method: 'POST',
data: param
}).then(res => {
this.$message({
type: 'success',
message: res.msg,
onClose: () => {
this.initData()
}
});
})
}
},
addOrUpdateHandle(id, isDetail) {
this.formVisible = true
@ -512,6 +527,10 @@
this.formVisible = false
if (isrRefresh) this.reset()
},
refresh2(isrRefresh) {
this.formVisible2 = false
if (isrRefresh) this.reset()
},
reset() {
// for (let key in this.query) {
// this.query[key] = undefined

@ -152,6 +152,13 @@
align="center"
sortable="custom"
/>
<el-table-column
prop="customerName"
label="客户名"
width="200"
align="center"
sortable="custom"
/>
<el-table-column
prop="ramount"
label="申请金额"
@ -159,6 +166,13 @@
align="center"
sortable="custom"
/>
<el-table-column
prop="num"
label="结算重量"
width="150"
align="center"
sortable="custom"
/>
<el-table-column
prop="paymentAmount"
label="已付款金额"
@ -194,6 +208,13 @@
align="center"
sortable="custom"
/>
<el-table-column
prop="creatorUserName"
label="创建人"
width="150"
align="center"
sortable="custom"
/>
<el-table-column
prop="remark"
label="备注"

@ -73,6 +73,14 @@
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="垫资金额" prop="advanceAmount">
<el-input v-model="dataForm.advanceAmount" placeholder="请输入" clearable :style='{"width":"100%"}'
:disabled="true">
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="应付日期" prop="duedate">
<el-date-picker v-model="dataForm.duedate" placeholder="请选择" clearable :style='{"width":"100%"}'
@ -115,6 +123,13 @@
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="付款凭证" prop="voucher">
<JNPF-UploadFz v-model="dataForm.voucher" :fileSize="15" :showTip="true" sizeUnit="MB" :limit="9"
buttonText="点击上传">
</JNPF-UploadFz>
</el-form-item>
</el-col>
<el-col :span="16">
<el-form-item label="备注" prop="remark">
<el-input v-model="dataForm.remark" placeholder="请输入" clearable :style='{"width":"100%"}'>
@ -132,13 +147,6 @@
</el-select>
</el-form-item>
</el-col> -->
<el-col :span="8">
<el-form-item label="付款凭证" prop="voucher">
<JNPF-UploadFz v-model="dataForm.voucher" :fileSize="15" :showTip="true" sizeUnit="MB" :limit="9"
buttonText="点击上传">
</JNPF-UploadFz>
</el-form-item>
</el-col>
<el-col :span="24">
<el-tabs v-model="activeivpzpd" tab-position="top" class="mb-20">
<el-tab-pane label="申请明细">
@ -285,6 +293,7 @@
collectionaccount: '',
collectionbank: '',
requestedamount: '',
advanceAmount: '',
duedate: '',
businessdate: '',
currency: "0",
@ -451,14 +460,17 @@
this.dataForm.settlementtype = paymentdoc.settlementType
this.dataForm.paymentno = paymentdoc.documentNo
var requestedamount = 0;
var advanceAmount = 0;
paymentdoc.paymentdocitem0List.forEach((item, index) => {
//item.requestAmount = item.amount;
requestedamount = this.jnpf.floatAdd(requestedamount, item.requestAmount);
advanceAmount = this.jnpf.floatAdd(advanceAmount, item.advanceAmount);
//item.amount = item.requestAmount;
item.paymentdocitemId = item.id;
item.id = '';
});
this.dataForm.requestedamount = requestedamount
this.dataForm.advanceAmount = advanceAmount
this.dataForm.payment_item0List = paymentdoc.paymentdocitem0List
let param = {
param : 'payment'

@ -122,7 +122,7 @@
<!-- <el-table-column prop="contractNo" label="对方合同号" width="0" align="center" />
<el-table-column prop="notAmount" label="不含税金额" width="0" align="center" />
<el-table-column prop="remark" label="备注信息" width="0" align="center" /> -->
<el-table-column label="操作" fixed="right" width="200" align="center" >
<el-table-column label="操作" fixed="right" width="250" align="center" >
<template slot-scope="scope">
<el-button type="text" @click="addOrUpdateHandle(scope.row)" v-has="'btn_edit'">
</el-button>
@ -130,6 +130,8 @@
</el-button>
<el-button type="text" class="JNPF-table-delBtn" @click="handleDel(scope.row)" v-has="'btn_remove'">
</el-button>
<el-button type="text" class="JNPF-table-delBtn" @click="handleDel2(scope.row)" v-has="'btn_remove'">
</el-button>
<el-button type="text" class="JNPF-table-delBtn" @click="handleTuihuo(scope.row)" v-has="'btn_handleTuihuo'">退
</el-button>
</template>
@ -455,6 +457,48 @@
});
}
},
handleDel2(row) {
if(row.status != '0'){
var msg = '';
if(row.status == '1'){
msg = '开票';
}else if(row.status == '2'){
msg = '入库';
}else if(row.status == '3'){
msg = '归档';
}
this.$message({
type: 'error',
message: '已' + msg +'无法删除',
duration: 2500
});
return
}
if (row.isPayment == '1' || row.isTransfer == '1'){
this.$message({
type: 'error',
message: '已转销售或已提交付款申请无法删除',
duration: 2500
});
return
}
this.$confirm('此操作将永久删除该数据, 是否继续?', '提示', {
type: 'warning'
}).then(() => {
request({
url: `/api/purchaseorder/Purchaseorder/removePound/${row.id}`,
method: 'DELETE'
}).then(res => {
this.$message({
type: 'success',
message: res.msg,
onClose: () => {
this.initData()
}
});
})
}).catch(() => {});
},
handleDel(row) {
if(row.status != '0'){
var msg = '';

Loading…
Cancel
Save