diff --git a/src/assets/images/kaichu.png b/src/assets/images/kaichu.png new file mode 100644 index 00000000..262703aa Binary files /dev/null and b/src/assets/images/kaichu.png differ diff --git a/src/assets/images/weikaichu.png b/src/assets/images/weikaichu.png new file mode 100644 index 00000000..3dcd1007 Binary files /dev/null and b/src/assets/images/weikaichu.png differ diff --git a/src/views/finance/feeSettlement/detail/index.vue b/src/views/finance/feeSettlement/detail/index.vue index d758d4e6..a0ca5903 100644 --- a/src/views/finance/feeSettlement/detail/index.vue +++ b/src/views/finance/feeSettlement/detail/index.vue @@ -263,8 +263,8 @@ function ClickLast(type) { let indexQuery = 0 let list = [] PaymentSettlementGetList(data).then(res => { - list = res.data.list - res.data.list.forEach((item, index) => { + list = res.data + res.data.forEach((item, index) => { if (item.id == route.query.id) { indexQuery = index } diff --git a/src/views/operation/invoiceApply/detail/feeTable.vue b/src/views/operation/invoiceApply/detail/feeTable.vue index bdad316d..331e0413 100644 --- a/src/views/operation/invoiceApply/detail/feeTable.vue +++ b/src/views/operation/invoiceApply/detail/feeTable.vue @@ -7,10 +7,10 @@ 引用发票明细 - + @@ -185,11 +185,11 @@ const loading = ref(false) const row = { selected: false, name: '', - taxAmount: '', - taxRate: '', - amount: '', - unitPrice: '', - taxUnitPrice: '', + taxAmount: null, + taxRate: null, + amount: null, + unitPrice: null, + taxUnitPrice: null, quantity: 1, unit: '票', specification: '', diff --git a/src/views/operation/invoiceApply/detail/index.vue b/src/views/operation/invoiceApply/detail/index.vue index 8f573b11..35f45c9a 100644 --- a/src/views/operation/invoiceApply/detail/index.vue +++ b/src/views/operation/invoiceApply/detail/index.vue @@ -160,7 +160,7 @@ {{ item.name - }} + }} @@ -328,6 +328,7 @@ const bankForm = [ componentProps: ({ formModel }) => { return { options: bankList.value, + showSearch: true, fieldNames: { label: 'name', value: 'name', @@ -352,6 +353,9 @@ const bankForm = [ }) } }, + filterOption: (input: string, option: any) => { + return option.name.toLowerCase().indexOf(input.toLowerCase()) >= 0 + }, } }, }, @@ -374,6 +378,10 @@ const bankForm = [ label: 'name', value: 'name', }, + showSearch: true, + filterOption: (input: string, option: any) => { + return option.name.toLowerCase().indexOf(input.toLowerCase()) >= 0 + }, onChange: (e, obj) => { if (obj) { formModel.usdCustomerBankId = obj.id diff --git a/src/views/operation/invoiceIssue/columns.tsx b/src/views/operation/invoiceIssue/columns.tsx index 749d0516..deccf059 100644 --- a/src/views/operation/invoiceIssue/columns.tsx +++ b/src/views/operation/invoiceIssue/columns.tsx @@ -236,7 +236,7 @@ export const columns: BasicColumn[] = [ }, { title: '开票类型', - dataIndex: 'invoiceNO1', + dataIndex: 'invoiceNO3', width: 100, align: 'left', }, @@ -266,7 +266,7 @@ export const columns: BasicColumn[] = [ }, { title: '录入人', - dataIndex: 'createByName', + dataIndex: 'createByName1', width: 100, align: 'left', }, diff --git a/src/views/operation/invoiceIssue/detail/index.vue b/src/views/operation/invoiceIssue/detail/index.vue index 81798219..1786c0be 100644 --- a/src/views/operation/invoiceIssue/detail/index.vue +++ b/src/views/operation/invoiceIssue/detail/index.vue @@ -36,34 +36,13 @@ - - -
开票 - + 冲红 开票有误 销货退回 服务中止 @@ -392,9 +369,9 @@ 购方 - + @@ -436,7 +413,8 @@ defineComponent({ }) registerAllModules() const redForm = ref({ - lrfsf: '0' + lrfsf: '0', + chyyDm: '01' }) as any const detailForm = [ { @@ -588,13 +566,13 @@ const detailForm = [ dynamicDisabled: true, colProps: { span: 12 }, }, - { - field: 'redCode', - label: '被冲红发票代码', - component: 'Input', - dynamicDisabled: true, - colProps: { span: 12 }, - }, + // { + // field: 'redCode', + // label: '被冲红发票代码', + // component: 'Input', + // dynamicDisabled: true, + // colProps: { span: 12 }, + // }, { field: 'divider-selects5', component: 'Divider', @@ -674,7 +652,8 @@ function openRed() { function handleSelectAccount(val) { accountList.value.forEach(item => { if (item.bankName == val) { - form.value.customerAddressTel = '' + form.value.customerAccount = item.bankAccountNo + // form.value.customerAddressTel = item.invoiceAddress + ' ' + item.invoiceTel invoiceHeadersList.value = item.invoiceHeaders } }) @@ -777,11 +756,13 @@ function getDetail() { loading.value = true GeneralInvoiceGet({ id: route.query.id }).then(res => { if (res.succeeded) { - res.data.invoiceDetails.forEach(item => { - item.unit = '票' - }) - list.value = res.data.invoiceDetails ? res.data.invoiceDetails : [] - hotTb.value.hotInstance.loadData(res.data.invoiceDetails ? res.data.invoiceDetails : []) + if (res.data.invoiceDetails) { + res.data.invoiceDetails.forEach(item => { + item.unit = '票' + }) + list.value = res.data.invoiceDetails ? res.data.invoiceDetails : [] + hotTb.value.hotInstance.loadData(res.data.invoiceDetails ? res.data.invoiceDetails : []) + } if (res.data.isSettled) { res.data.isSettledName = '是' } else { @@ -792,26 +773,29 @@ function getDetail() { } else { res.data.isLockedName = '否' } - if (res.data.isSetRed) { - res.data.isSetRedName = '是' - res.data.invoiceType = '红票' - } else { - res.data.isSetRedName = '否' - res.data.invoiceType = '正票' - } if (res.data.invoiceNO) { res.data.status = '已开票' } else { res.data.status = '未开票' } + if (res.data.type == 2) { + res.data.invoiceType = '红票' + res.data.isSetRedName = '是' + } + if (res.data.type == 1) { + res.data.invoiceType = '正票' + res.data.isSetRedName = '否' + } res.data.emailFlag = false res.data.cellPhoneNOFlag = false - res.data.applyAmount = numberThousandFormat(res.data.applyAmount, 2, false) - res.data.otherInvoiceAmount = numberThousandFormat(res.data.otherInvoiceAmount, 2, false) - res.data.invoiceAmount = numberThousandFormat(res.data.invoiceAmount, 2, false) - res.data.applications.forEach(item => { - item.applyAmount = numberThousandFormat(item.applyAmount, 2, false) - }) + res.data.applyAmount = numberThousandFormat(res.data.applyAmount ? res.data.applyAmount : 0, 2, false) + res.data.otherInvoiceAmount = numberThousandFormat(res.data.otherInvoiceAmount ? res.data.otherInvoiceAmount : 0, 2, false) + res.data.invoiceAmount = numberThousandFormat(res.data.invoiceAmount ? res.data.invoiceAmount : 0, 2, false) + if (res.data.applications) { + res.data.applications.forEach(item => { + item.applyAmount = numberThousandFormat(item.applyAmount ? res.data.applyAmount : 0, 2, false) + }) + } form.value = res.data getCustomerInfo(res.data.customerId) setTableData(res.data.applications) @@ -829,7 +813,7 @@ function openHand() { function lookInvoice() { loading.value = true let id = 0 - if(form.value.isSetRed){ + if (form.value.isSetRed) { id = form.value.redId } else { id = route.query.id @@ -1289,7 +1273,7 @@ const columns = [ ] -function numberToChineseUpper(num) { +function numberToChineseUpper(num: number): string { // 定义数字对应的中文大写 const chineseNums = ["零", "壹", "贰", "叁", "肆", "伍", "陆", "柒", "捌", "玖"]; // 定义单位 @@ -1297,6 +1281,10 @@ function numberToChineseUpper(num) { // 处理小数点 const decimalUnits = ["角", "分"]; + // 检查是否为负数 + let isNegative = num < 0; + num = Math.abs(num); + // 转换为字符串,并分割成整数部分和小数部分 let parts = num.toString().split('.'); let integerPart = parts[0]; @@ -1314,7 +1302,7 @@ function numberToChineseUpper(num) { for (let i = integerPart.length - 1; i >= 0; i--) { let digit = integerPart[i]; - let digitStr = chineseNums[digit]; + let digitStr = chineseNums[parseInt(digit)]; if (digitStr === "零") { if (hasZero) continue; // 已经有一个零了,跳过当前循环 @@ -1339,13 +1327,18 @@ function numberToChineseUpper(num) { if (decimalPart.length > 0) { for (let i = 0; i < decimalPart.length; i++) { let digit = decimalPart[i]; - result += chineseNums[digit] + decimalUnits[i]; + result += chineseNums[parseInt(digit)] + decimalUnits[i]; } } else { // 如果没有小数部分,添加整 result += '整'; } + // 如果是负数,添加“负”字 + if (isNegative) { + result = '负' + result; + } + return result; } @@ -1570,6 +1563,12 @@ watchEffect(() => { border-bottom: 1px solid rgba(158, 83, 9, 1); padding: 5px 0; } + +.img-in { + height: 33px; + transform: rotate(2deg); + width: 90px; +}