|
@@ -200,7 +200,7 @@
|
|
<el-button style="width: 150px;" @click="() => { $refs.dialog.show = false }">取消</el-button>
|
|
<el-button style="width: 150px;" @click="() => { $refs.dialog.show = false }">取消</el-button>
|
|
</div>
|
|
</div>
|
|
</cy-dialog>
|
|
</cy-dialog>
|
|
- <cy-info-title style="margin-bottom:20px">
|
|
|
|
|
|
+ <!-- <cy-info-title style="margin-bottom:20px">
|
|
<span>
|
|
<span>
|
|
采购发票
|
|
采购发票
|
|
<span class="statistics">数量合计: <span>{{ fourMoney(nvoiceNumTotal) }}</span></span>
|
|
<span class="statistics">数量合计: <span>{{ fourMoney(nvoiceNumTotal) }}</span></span>
|
|
@@ -212,8 +212,8 @@
|
|
<span style="color: #FE7D0B; margin-right: 20px; cursor: pointer" @click="addInfo">添加</span>
|
|
<span style="color: #FE7D0B; margin-right: 20px; cursor: pointer" @click="addInfo">添加</span>
|
|
<span style="color: #FE7D0B; margin-right: 20px; cursor: pointer" @click="view">示例</span>
|
|
<span style="color: #FE7D0B; margin-right: 20px; cursor: pointer" @click="view">示例</span>
|
|
</template>
|
|
</template>
|
|
- </cy-info-title>
|
|
|
|
- <div class="table-box" style="width: 100%">
|
|
|
|
|
|
+ </cy-info-title> -->
|
|
|
|
+ <!-- <div class="table-box" style="width: 100%">
|
|
<el-table :data="procureList">
|
|
<el-table :data="procureList">
|
|
<el-table-column type="index" label="序号" width="50" />
|
|
<el-table-column type="index" label="序号" width="50" />
|
|
<el-table-column prop="nvoiceNumber" label="发票号码" label-class-name="rule-required">
|
|
<el-table-column prop="nvoiceNumber" label="发票号码" label-class-name="rule-required">
|
|
@@ -276,12 +276,22 @@
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
</el-table>
|
|
</el-table>
|
|
- </div>
|
|
|
|
- <el-form-item label="商品大类信息" prop="productBroadInfo">
|
|
|
|
- <el-input
|
|
|
|
|
|
+ </div> -->
|
|
|
|
+ <el-form-item label="开票明细表(含税收分类编码)" prop="invoiceDetailFiles" class="form-required">
|
|
|
|
+ <!-- <el-input
|
|
v-model="ruleForm.productBroadInfo"
|
|
v-model="ruleForm.productBroadInfo"
|
|
placeholder="请输入商品大类信息"
|
|
placeholder="请输入商品大类信息"
|
|
:disabled="disabled"
|
|
:disabled="disabled"
|
|
|
|
+ /> -->
|
|
|
|
+ <cy-upload
|
|
|
|
+ ref="invoiceDetailFiles"
|
|
|
|
+ :upload-params="{
|
|
|
|
+ fileType: 'invoiceDetailFile'
|
|
|
|
+ }"
|
|
|
|
+ :file-data="ruleForm.invoiceDetailFiles"
|
|
|
|
+ :upload-from-orange-status="true"
|
|
|
|
+ placeholder="请上传开票明细表附件"
|
|
|
|
+ :disabled="disabled"
|
|
/>
|
|
/>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
<el-form-item
|
|
<el-form-item
|
|
@@ -336,7 +346,7 @@ export default {
|
|
openAmountTotal: 0,
|
|
openAmountTotal: 0,
|
|
openQuantityTotal: 0,
|
|
openQuantityTotal: 0,
|
|
settlementLoading: false,
|
|
settlementLoading: false,
|
|
- procureList: [],
|
|
|
|
|
|
+ // procureList: [],
|
|
basicDisabled: false,
|
|
basicDisabled: false,
|
|
ruleForm: {
|
|
ruleForm: {
|
|
accountBankName: '',
|
|
accountBankName: '',
|
|
@@ -345,8 +355,9 @@ export default {
|
|
amountKind: 'amount_kind_payment',
|
|
amountKind: 'amount_kind_payment',
|
|
openAmount: '',
|
|
openAmount: '',
|
|
remark: '',
|
|
remark: '',
|
|
- productBroadInfo: '',
|
|
|
|
|
|
+ // productBroadInfo: '',
|
|
invoicePurchaseFile: [],
|
|
invoicePurchaseFile: [],
|
|
|
|
+ invoiceDetailFiles: [], // 发票明细
|
|
enterpriseName: '',
|
|
enterpriseName: '',
|
|
socialCreditCode: '',
|
|
socialCreditCode: '',
|
|
phoneNumber: '',
|
|
phoneNumber: '',
|
|
@@ -359,8 +370,8 @@ export default {
|
|
accountNumber: [{ required: true, message: '请输入开户账号', trigger: 'blur' }],
|
|
accountNumber: [{ required: true, message: '请输入开户账号', trigger: 'blur' }],
|
|
invoiceType: [{ required: true, message: '请选择发票类型', trigger: 'change' }],
|
|
invoiceType: [{ required: true, message: '请选择发票类型', trigger: 'change' }],
|
|
amountKind: [{ required: true, message: '请选择金额种类', trigger: 'change' }],
|
|
amountKind: [{ required: true, message: '请选择金额种类', trigger: 'change' }],
|
|
- remark: [{ required: true, message: '请输入备注信息', trigger: 'blur' }],
|
|
|
|
- productBroadInfo: [{ required: true, message: '请输入商品大类信息', trigger: 'blur' }]
|
|
|
|
|
|
+ remark: [{ required: true, message: '请输入备注信息', trigger: 'blur' }]
|
|
|
|
+ // productBroadInfo: [{ required: true, message: '请输入商品大类信息', trigger: 'blur' }]
|
|
},
|
|
},
|
|
findByParentCode: [],
|
|
findByParentCode: [],
|
|
basicInformation: {},
|
|
basicInformation: {},
|
|
@@ -431,41 +442,43 @@ export default {
|
|
return (val) => {
|
|
return (val) => {
|
|
return formatMoney(Number(val.openQuantity) * Number(val.salesPrice))
|
|
return formatMoney(Number(val.openQuantity) * Number(val.salesPrice))
|
|
}
|
|
}
|
|
- },
|
|
|
|
- nvoiceNumTotal() {
|
|
|
|
- let sum = 0
|
|
|
|
- this.procureList.forEach(item => {
|
|
|
|
- sum += Number(item.nvoiceNum)
|
|
|
|
- })
|
|
|
|
- return sum
|
|
|
|
- },
|
|
|
|
- amountTotal() {
|
|
|
|
- let sum = 0
|
|
|
|
- this.procureList.forEach(item => {
|
|
|
|
- sum += Number(item.amount)
|
|
|
|
- })
|
|
|
|
- return sum
|
|
|
|
- },
|
|
|
|
- taxAmountTotal() {
|
|
|
|
- let sum = 0
|
|
|
|
- this.procureList.forEach(item => {
|
|
|
|
- sum += Number(item.taxAmount)
|
|
|
|
- })
|
|
|
|
- return sum
|
|
|
|
- },
|
|
|
|
- priceTaxTotalTotal() {
|
|
|
|
- let sum = 0
|
|
|
|
- this.procureList.forEach(item => {
|
|
|
|
- sum += Number(item.priceTaxTotal)
|
|
|
|
- })
|
|
|
|
- return sum
|
|
|
|
}
|
|
}
|
|
|
|
+ // #region 贸理通4.0版本优化 发票管理
|
|
|
|
+ // nvoiceNumTotal() {
|
|
|
|
+ // let sum = 0
|
|
|
|
+ // this.procureList.forEach(item => {
|
|
|
|
+ // sum += Number(item.nvoiceNum)
|
|
|
|
+ // })
|
|
|
|
+ // return sum
|
|
|
|
+ // },
|
|
|
|
+ // amountTotal() {
|
|
|
|
+ // let sum = 0
|
|
|
|
+ // this.procureList.forEach(item => {
|
|
|
|
+ // sum += Number(item.amount)
|
|
|
|
+ // })
|
|
|
|
+ // return sum
|
|
|
|
+ // },
|
|
|
|
+ // taxAmountTotal() {
|
|
|
|
+ // let sum = 0
|
|
|
|
+ // this.procureList.forEach(item => {
|
|
|
|
+ // sum += Number(item.taxAmount)
|
|
|
|
+ // })
|
|
|
|
+ // return sum
|
|
|
|
+ // },
|
|
|
|
+ // priceTaxTotalTotal() {
|
|
|
|
+ // let sum = 0
|
|
|
|
+ // this.procureList.forEach(item => {
|
|
|
|
+ // sum += Number(item.priceTaxTotal)
|
|
|
|
+ // })
|
|
|
|
+ // return sum
|
|
|
|
+ // }
|
|
|
|
+ // #endregion
|
|
},
|
|
},
|
|
watch: {
|
|
watch: {
|
|
deatilsInfo: {
|
|
deatilsInfo: {
|
|
handler(newV) {
|
|
handler(newV) {
|
|
if (this.deatilsInfo && Object.keys(newV).length) {
|
|
if (this.deatilsInfo && Object.keys(newV).length) {
|
|
- const { purchContractCompletedVo, enterpriseCustomerInfoId, tradingPlatformId, companyName, taxIdentifyNumber, phone, address, accountBankName, accountNumber, invoiceType, openAmount, remark, files, productBroadInfo, invoiceGoodsInfos, purchaseInvoiceInfos } = JSON.parse(JSON.stringify(newV))
|
|
|
|
|
|
+ const { purchContractCompletedVo, enterpriseCustomerInfoId, tradingPlatformId, companyName, taxIdentifyNumber, phone, address, accountBankName, accountNumber, invoiceType, openAmount, remark, files, invoiceGoodsInfos, invoiceDetailList } = JSON.parse(JSON.stringify(newV))
|
|
this.basicInformation = {
|
|
this.basicInformation = {
|
|
...purchContractCompletedVo,
|
|
...purchContractCompletedVo,
|
|
enterpriseCustomerInfoId,
|
|
enterpriseCustomerInfoId,
|
|
@@ -482,11 +495,12 @@ export default {
|
|
amountKind: 'amount_kind_payment',
|
|
amountKind: 'amount_kind_payment',
|
|
openAmount,
|
|
openAmount,
|
|
remark,
|
|
remark,
|
|
- productBroadInfo,
|
|
|
|
- invoicePurchaseFile: files || []
|
|
|
|
|
|
+ // productBroadInfo,
|
|
|
|
+ invoicePurchaseFile: files || [],
|
|
|
|
+ invoiceDetailFiles: invoiceDetailList || []
|
|
}
|
|
}
|
|
this.goodsInfoList = invoiceGoodsInfos || []
|
|
this.goodsInfoList = invoiceGoodsInfos || []
|
|
- this.procureList = purchaseInvoiceInfos || []
|
|
|
|
|
|
+ // this.procureList = purchaseInvoiceInfos || []
|
|
this.totalOpenQuantity()
|
|
this.totalOpenQuantity()
|
|
}
|
|
}
|
|
},
|
|
},
|
|
@@ -510,7 +524,10 @@ export default {
|
|
phoneNumber: val.phoneNumber,
|
|
phoneNumber: val.phoneNumber,
|
|
address: val.address,
|
|
address: val.address,
|
|
invoiceType: '',
|
|
invoiceType: '',
|
|
- amountKind: 'amount_kind_payment'
|
|
|
|
|
|
+ amountKind: 'amount_kind_payment',
|
|
|
|
+ accountBankName: val.accountBankName || '',
|
|
|
|
+ accountNumber: val.accountNumber || '',
|
|
|
|
+ remark: val.remark || ''
|
|
}
|
|
}
|
|
this.businessNumber = businessNumber
|
|
this.businessNumber = businessNumber
|
|
},
|
|
},
|
|
@@ -588,19 +605,21 @@ export default {
|
|
this.openAmountTotal = amount
|
|
this.openAmountTotal = amount
|
|
this.ruleForm.openAmount = formatMoney(amount)
|
|
this.ruleForm.openAmount = formatMoney(amount)
|
|
},
|
|
},
|
|
- addInfo() {
|
|
|
|
- this.procureList.push({
|
|
|
|
- nvoiceNumber: '',
|
|
|
|
- nvoiceNum: '',
|
|
|
|
- amount: '',
|
|
|
|
- taxAmount: '',
|
|
|
|
- priceTaxTotal: '',
|
|
|
|
- sellerName: ''
|
|
|
|
- })
|
|
|
|
- },
|
|
|
|
- view() {
|
|
|
|
|
|
+ // #region comment by lx 贸理通4.0版本优化发票管理
|
|
|
|
+ // addInfo() {
|
|
|
|
+ // this.procureList.push({
|
|
|
|
+ // nvoiceNumber: '',
|
|
|
|
+ // nvoiceNum: '',
|
|
|
|
+ // amount: '',
|
|
|
|
+ // taxAmount: '',
|
|
|
|
+ // priceTaxTotal: '',
|
|
|
|
+ // sellerName: ''
|
|
|
|
+ // })
|
|
|
|
+ // },
|
|
|
|
+ // view() {
|
|
|
|
|
|
- },
|
|
|
|
|
|
+ // },
|
|
|
|
+ // #endregion
|
|
getParams() {
|
|
getParams() {
|
|
return new Promise((resolve, reject) => {
|
|
return new Promise((resolve, reject) => {
|
|
// if (!this.goodsInfoList.length) {
|
|
// if (!this.goodsInfoList.length) {
|
|
@@ -640,8 +659,9 @@ export default {
|
|
// }
|
|
// }
|
|
// }
|
|
// }
|
|
// }
|
|
// }
|
|
- const { enterpriseName, socialCreditCode, address, phoneNumber, invoiceType, amountKind, openAmount, remark, productBroadInfo, accountBankName, accountNumber } = this.ruleForm
|
|
|
|
|
|
+ const { enterpriseName, socialCreditCode, address, phoneNumber, invoiceType, amountKind, openAmount, remark, accountBankName, accountNumber } = this.ruleForm
|
|
const invoicePurchaseFileList = this.$refs.invoicePurchaseFile.getFileLists
|
|
const invoicePurchaseFileList = this.$refs.invoicePurchaseFile.getFileLists
|
|
|
|
+ const invoiceDetailFileList = this.$refs.invoiceDetailFiles.getFileLists
|
|
const { id, taskId } = this.$route.query
|
|
const { id, taskId } = this.$route.query
|
|
this.$refs.basicInformation.getParams().then(item => {
|
|
this.$refs.basicInformation.getParams().then(item => {
|
|
const params = {
|
|
const params = {
|
|
@@ -658,9 +678,10 @@ export default {
|
|
amountKind,
|
|
amountKind,
|
|
openAmount,
|
|
openAmount,
|
|
remark,
|
|
remark,
|
|
- productBroadInfo,
|
|
|
|
- purchaseInvoiceInfos: this.procureList,
|
|
|
|
|
|
+ // productBroadInfo,
|
|
|
|
+ // purchaseInvoiceInfos: this.procureList,
|
|
purchaseInvoiceFiles: invoicePurchaseFileList.map(item => item.id),
|
|
purchaseInvoiceFiles: invoicePurchaseFileList.map(item => item.id),
|
|
|
|
+ invoiceDetailFiles: invoiceDetailFileList.map(item => item.id),
|
|
invoiceGoodsInfos: this.goodsInfoList
|
|
invoiceGoodsInfos: this.goodsInfoList
|
|
}
|
|
}
|
|
resolve(params)
|
|
resolve(params)
|