This commit is contained in:
2026-07-03 09:23:16 +08:00
parent ca32aa87e7
commit bbd4eb6499
6 changed files with 14 additions and 0 deletions

View File

@@ -177,8 +177,10 @@ export const FIELD_MAPPINGS = {
'不含税金额(元)大': 'bu_han_shui_jin_e_yuan_da',
'含税总金额(元)大': 'han_shui_zong_jin_e_yuan_da',
'不含税金额(元)(大+独)': 'bu_han_shui_jin_e_yuan_da_du',
'不含税金额(元)大+独': 'bu_han_shui_jin_e_yuan_da_du',
'不含税金额(元)(大+独)(大写)': 'bu_han_shui_jin_e_yuan_da_du_da_xie',
'含税总金额(元)(大+独)': 'han_shui_zong_jin_e_yuan_da_du',
'含税总金额(元)大+独': 'han_shui_zong_jin_e_yuan_da_du',
'含税总金额(元)(大+独)(大写)': 'han_shui_zong_jin_e_yuan_da_du_da_xie',
"不含税金额(元)多家": 'bu_han_shui_jin_e_yuan_duo',//不含税金额(元)多项改为多家
"含税金额(元)多家": 'han_shui_jin_e_yuan_duo',//含税金额(元)多项改为多家

View File

@@ -124,6 +124,7 @@ export function processInvoiceDataItem(item: any): any {
zhang_qi: zhang_qi, // 使用计算后的账期值
invoice_type_enum: item.invoice_type_enum,
// 透传新增字段
contractNumber: item.contractNumber || item.salesContractNumber || '',
tong_yi_she_hui_xin_yong_dai_ma: item.tong_yi_she_hui_xin_yong_dai_ma || null,
bankName: item.bankName || null,
bankAccount: item.bankAccount || null,

View File

@@ -12,6 +12,7 @@ import { AGREEMENT_CODE_TO_NAME, AGREEMENT_TYPE_CODE, AGREEMENT_TYPES, XIANGMU_Z
const COLUMN_WIDTHS = {
"数据ID": 20,
"项目编号": 15,
"合同编号": 25,
"单位": 25,
"票号": 15,
"不含税金额": 15,
@@ -78,6 +79,7 @@ export default async function handler(
where: { dataId: { in: ids } },
orderBy: { invoiceJobNumber: 'asc' },
select: {
salesContractNumber: true,
dataId: true,
invoiceJobNumber: true,
projectNumber: true,
@@ -132,6 +134,7 @@ export default async function handler(
where: whereForAll,
orderBy: { invoiceJobNumber: 'asc' },
select: {
salesContractNumber: true,
dataId: true,
invoiceJobNumber: true,
projectNumber: true,
@@ -253,6 +256,7 @@ export default async function handler(
"开票作业序号": item.invoiceJobNumber || '',
"数据ID": item.dataId,
"项目编号": item.projectNumber || '',
"合同编号": item.salesContractNumber || '',
"单位": processed.customerCompanyName || '',
// 移除"集团内外"
"票号": item.piao_hao || '',
@@ -280,6 +284,7 @@ export default async function handler(
"开票作业序号",
"数据ID",
"项目编号",
"合同编号",
"单位",
// 移除"集团内外"
"票号",

View File

@@ -25,6 +25,7 @@ const COLUMN_WIDTHS = {
"开票作业序号": 15,
"数据ID": 20,
"项目编号": 15,
"合同编号": 25,
"单位": 25,
// 移除“集团内外”
"票号": 15,
@@ -208,6 +209,7 @@ export default async function handler(
"开票作业序号": item.invoiceJobNumber || '',
"数据ID": item.dataId,
"项目编号": item.projectNumber || '',
"合同编号": item.salesContractNumber || '',
"单位": processed.customerCompanyName || '',
"票号": item.piao_hao || '',
"不含税金额": buHanShuiAmount,
@@ -254,6 +256,7 @@ export default async function handler(
"开票作业序号",
"数据ID",
"项目编号",
"合同编号",
"单位",
// "集团内外" 已移除
"票号",

View File

@@ -39,8 +39,10 @@ export const ExcelToMySQLFieldMapping: {
'不含税金额(元)大': 'bu_han_shui_jin_e_yuan_da',
'含税总金额(元)大': 'han_shui_zong_jin_e_yuan_da',
'不含税金额(元)(大+独)': 'bu_han_shui_jin_e_yuan_da_du',
'不含税金额(元)大+独': 'bu_han_shui_jin_e_yuan_da_du',
'不含税金额(元)(大+独)(大写)': 'bu_han_shui_jin_e_yuan_da_du_da_xie',
'含税总金额(元)(大+独)': 'han_shui_zong_jin_e_yuan_da_du',
'含税总金额(元)大+独': 'han_shui_zong_jin_e_yuan_da_du',
'含税总金额(元)(大+独)(大写)': 'han_shui_zong_jin_e_yuan_da_du_da_xie',
'审批编号': 'approvalNumber',
'创建时间': 'creationTime',

View File

@@ -221,6 +221,7 @@ export interface ProcessedInvoiceDataItemFromFunction {
hui_kuan_jin_e: string | null;
business_content: string;
zhang_qi: string | null;
contractNumber?: string;
// 新增:透传给前端使用
tong_yi_she_hui_xin_yong_dai_ma?: string | null;
bankName?: string | null;