发票
This commit is contained in:
@@ -48,14 +48,14 @@ export function addInvoice(...params) {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
// 发票编辑
|
// 发票编辑
|
||||||
export function editInvoice(num1, num2, num3, time1, money, send, receive, remark) {
|
export function editInvoice(...params) {
|
||||||
return request({
|
return request({
|
||||||
url: '',
|
url: '',
|
||||||
method: 'post',
|
method: 'post',
|
||||||
data: {
|
data: {
|
||||||
type: '2',
|
type: '2',
|
||||||
name: '采购管理_发票_修改数据',
|
name: '采购管理_采购发票_修改数据',
|
||||||
param: '发票流水号=' + num1 + '&采购合同流水号=' + num2 + '&发票号=' + num3 + '&开票时间=' + time1 + '&开票金额=' + money + '&传送人=' + send + '&接收人=' + receive + '&备注=' + remark
|
param: `发票交接流水号=${params[0]}&发票号=${params[1]}&开户行=${params[2]}&开票时间=${params[3]}&接收人流水号=${params[4]}`
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -287,8 +287,8 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped>
|
<style scoped>
|
||||||
|
|||||||
@@ -100,7 +100,7 @@
|
|||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column align="center" label="开票时间" min-width="100px">
|
<el-table-column align="center" label="开票时间" min-width="100px">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
{{ scope.row.开票时间 ? scope.row.开票时间 : '—' }}
|
{{ scope.row.开票时间 ? scope.row.开票时间.split(' ')[0] : '—' }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column align="center" label="合同总额" min-width="100px">
|
<el-table-column align="center" label="合同总额" min-width="100px">
|
||||||
@@ -189,7 +189,7 @@
|
|||||||
</el-dialog>
|
</el-dialog>
|
||||||
|
|
||||||
<el-dialog :title="title1" :visible.sync="dialogVisible2" center style="min-height: 300px" width="1200px">
|
<el-dialog :title="title1" :visible.sync="dialogVisible2" center style="min-height: 300px" width="1200px">
|
||||||
<el-form ref="form1" :model="form1" :rules="rules1" label-position="left" label-width="70px">
|
<el-form ref="form1" :model="form1" :rules="rules1" label-position="right" label-width="80px">
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="6">
|
<el-col :span="6">
|
||||||
<el-form-item label="合同编号">
|
<el-form-item label="合同编号">
|
||||||
@@ -233,6 +233,29 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="6">
|
||||||
|
<el-form-item label="发票号" prop="invoiceNum">
|
||||||
|
<el-input v-model="form1.invoiceNum" size="small" placeholder="发票号"/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="6">
|
||||||
|
<el-form-item label="开户行" prop="bank">
|
||||||
|
<el-input v-model="form1.bank" size="small" placeholder="开户行"/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="6">
|
||||||
|
<el-form-item label="开票时间" prop="invoiceTime">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="form1.invoiceTime"
|
||||||
|
size="small"
|
||||||
|
type="date"
|
||||||
|
value-format="yyyy-MM-dd"
|
||||||
|
format="yyyy-MM-dd"
|
||||||
|
placeholder="开票时间"/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-form-item label="扫描件">
|
<el-form-item label="扫描件">
|
||||||
<img :src="scanSrc" alt="发票扫描件" width="1000px">
|
<img :src="scanSrc" alt="发票扫描件" width="1000px">
|
||||||
@@ -257,7 +280,7 @@ export default {
|
|||||||
name: '', // 采购发票交接
|
name: '', // 采购发票交接
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
office: true,
|
office: false,
|
||||||
scanSrc: '',
|
scanSrc: '',
|
||||||
upload: `http://localhost:8411/submit/uploadInvoiceScan.ashx`,
|
upload: `http://localhost:8411/submit/uploadInvoiceScan.ashx`,
|
||||||
limit: 1,
|
limit: 1,
|
||||||
@@ -274,10 +297,14 @@ export default {
|
|||||||
dialogVisible2: false, // 办公室
|
dialogVisible2: false, // 办公室
|
||||||
title1: '',
|
title1: '',
|
||||||
form1: {
|
form1: {
|
||||||
|
invoiceDeliveryNum: '',
|
||||||
contractNumValue: '',
|
contractNumValue: '',
|
||||||
money: '',
|
money: '',
|
||||||
sendPersonValue: '',
|
sendPersonValue: '',
|
||||||
receivePersonValue: ''
|
receivePersonValue: '',
|
||||||
|
invoiceNum: '',
|
||||||
|
bank: '',
|
||||||
|
invoiceTime: ''
|
||||||
},
|
},
|
||||||
rules1: {
|
rules1: {
|
||||||
contractNumValue: [
|
contractNumValue: [
|
||||||
@@ -285,6 +312,15 @@ export default {
|
|||||||
],
|
],
|
||||||
money: [
|
money: [
|
||||||
{ required: true, message: '请填写金额' }
|
{ required: true, message: '请填写金额' }
|
||||||
|
],
|
||||||
|
invoiceNum: [
|
||||||
|
{ required: true, message: '请填写发票号' }
|
||||||
|
],
|
||||||
|
bank: [
|
||||||
|
{ required: true, message: '请填写开户行' }
|
||||||
|
],
|
||||||
|
invoiceTime: [
|
||||||
|
{ required: true, message: '请填写开票时间' }
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -399,19 +435,22 @@ export default {
|
|||||||
}
|
}
|
||||||
this.title1 = '编辑'
|
this.title1 = '编辑'
|
||||||
this.dialogVisible2 = true
|
this.dialogVisible2 = true
|
||||||
|
this.form1.invoiceDeliveryNum = row.发票交接流水号
|
||||||
this.form1.contractNumValue = parseInt(row.采购合同流水号)
|
this.form1.contractNumValue = parseInt(row.采购合同流水号)
|
||||||
this.form1.invoiceTime = row.开票时间
|
|
||||||
this.form1.money = row.开票金额
|
this.form1.money = row.开票金额
|
||||||
this.form1.sendPersonValue = parseInt(row.传送人流水号)
|
this.form1.sendPersonValue = parseInt(row.传送人流水号)
|
||||||
this.form1.receivePersonValue = Number(this.id)
|
this.form1.receivePersonValue = Number(this.id)
|
||||||
|
this.form1.invoiceNum = row.发票号
|
||||||
|
this.form1.bank = row.开户行
|
||||||
|
this.form1.invoiceTime = row.开票时间
|
||||||
},
|
},
|
||||||
submitEdit(formName) {
|
submitEdit(formName) {
|
||||||
this.$refs[formName].validate((valid) => {
|
this.$refs[formName].validate((valid) => {
|
||||||
if (valid) {
|
if (valid) {
|
||||||
editInvoice(this.form1.invoiceNumValue, this.form1.contractNum, this.form1.invoiceNum, this.form1.invoiceTime, this.form1.money, this.form1.sendPersonValue, this.form1.receivePersonValue, this.form1.remark).then(response => {
|
editInvoice(this.form1.invoiceDeliveryNum, this.form1.invoiceNum, this.form1.bank, this.form1.invoiceTime, this.form1.receivePersonValue).then(response => {
|
||||||
if (response.data[0].result === '1') {
|
if (response.data[0].result === '1') {
|
||||||
this.$message.success('编辑成功')
|
this.$message.success('编辑成功')
|
||||||
this.dialogVisible1 = false
|
this.dialogVisible2 = false
|
||||||
this.searchTable1()
|
this.searchTable1()
|
||||||
} else { this.$message.error('编辑失败') }
|
} else { this.$message.error('编辑失败') }
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user