From 58d7fbd7f0c3e801f88ab5fa2b6779c371e4b9f3 Mon Sep 17 00:00:00 2001 From: qiezi <15576055375@163.com> Date: Thu, 27 Mar 2025 13:48:02 +0800 Subject: [PATCH] 2025-03-27 --- .../project/projectInfo/projectInfo.vue | 5 +- .../project/projectPart/projectPartQuote.vue | 170 +++++++++------ .../modules/quote/detail/quoteDetail.vue | 200 +++++++++++++++++- .../modules/quote/detail/quoteGroupDetail.vue | 200 +++++++++++++++++- src/views/modules/quote/index.vue | 1 - 5 files changed, 505 insertions(+), 71 deletions(-) diff --git a/src/views/modules/project/projectInfo/projectInfo.vue b/src/views/modules/project/projectInfo/projectInfo.vue index 99694cd..fd6669c 100644 --- a/src/views/modules/project/projectInfo/projectInfo.vue +++ b/src/views/modules/project/projectInfo/projectInfo.vue @@ -245,7 +245,8 @@ - + + @@ -411,9 +412,11 @@ import CustomerInfo from "../../quotation/sellForQuotation/customerInfo.vue"; import Quote from "../../quote/index.vue"; import ProjectQuotation from "./com_project_puotation.vue"; + import ProjectPartQuote from "../projectPart/projectPartQuote.vue"; /*組件*/ export default { components: { + ProjectPartQuote, ProjectQuotation, Quote, CustomerInfo, diff --git a/src/views/modules/project/projectPart/projectPartQuote.vue b/src/views/modules/project/projectPart/projectPartQuote.vue index ca2c896..536926b 100644 --- a/src/views/modules/project/projectPart/projectPartQuote.vue +++ b/src/views/modules/project/projectPart/projectPartQuote.vue @@ -11,11 +11,19 @@ export default { height:{ type: [String,Number], default: '26vh' + }, + isExport:{ + type: Boolean, + default: false } }, data(){ return{ dataList:[], + exportData: [], + exportName: '项目报价'+this.dayjs().format('YYYYMMDDHHmmss'), + exportHeader: ["项目报价"], + exportFooter: [], queryLoading:false, columns:[ { @@ -110,130 +118,129 @@ export default { }, { userId: this.$store.state.user.name, - functionId: 101002002, - serialNumber: '101002002Table2AdjustPartCost', - tableId: '101002002Table2', + functionId: 102001, + serialNumber: '102001Table2Qty', + tableId: '102001Table2', tableName: '报价详情信息表', - columnProp: 'adjustPartCost', + columnProp: 'unitPrice', headerAlign: 'center', align: 'right', - columnLabel: '材料成本', + columnLabel: '未税单价', columnHidden: false, columnImage: false, columnSortable: false, sortLv: 0, status: true, fixed: '', - columnWidth: 130 + columnWidth: 100 }, { userId: this.$store.state.user.name, - functionId: 101002002, - serialNumber: '101002002Table2AdjustLabourCost', - tableId: '101002002Table2', + functionId: 102001, + serialNumber: '102001Table2Qty', + tableId: '102001Table2', tableName: '报价详情信息表', - columnProp: 'adjustLabourCost', + columnProp: 'taxRate', headerAlign: 'center', align: 'right', - columnLabel: '人工成本', + columnLabel: '税率', columnHidden: false, columnImage: false, columnSortable: false, sortLv: 0, status: true, fixed: '', - columnWidth: 120 + columnWidth: 100 }, { userId: this.$store.state.user.name, - functionId: 101002002, - serialNumber: '101002002Table2AdjustMachineCost', - tableId: '101002002Table2', + functionId: 102001, + serialNumber: '102001Table2Qty', + tableId: '102001Table2', tableName: '报价详情信息表', - columnProp: 'adjustMachineCost', + columnProp: 'exchangeRate1', headerAlign: 'center', align: 'right', - columnLabel: '机器成本', + columnLabel: '其他税率', columnHidden: false, columnImage: false, columnSortable: false, sortLv: 0, status: true, fixed: '', - columnWidth: 120 + columnWidth: 100 }, { userId: this.$store.state.user.name, - functionId: 101002002, - serialNumber: '101002002Table2AdjustToolCost', - tableId: '101002002Table2', + functionId: 102001, + serialNumber: '102001Table2Qty', + tableId: '102001Table2', tableName: '报价详情信息表', - columnProp: 'adjustToolCost', + columnProp: 'taxUnitPrice', headerAlign: 'center', align: 'right', - columnLabel: '工具成本', + columnLabel: '含税单价(CNY)', columnHidden: false, columnImage: false, columnSortable: false, sortLv: 0, status: true, fixed: '', - columnWidth: 120 + columnWidth: 100 }, - { userId: this.$store.state.user.name, - functionId: 101002002, - serialNumber: '101002002Table2AdjustTestCost', - tableId: '101002002Table2', + functionId: 102001, + serialNumber: '102001Table2Qty', + tableId: '102001Table2', tableName: '报价详情信息表', - columnProp: 'adjustTestCost', + columnProp: 'currencyDesc2', headerAlign: 'center', align: 'right', - columnLabel: '测试成本', + columnLabel: '币种', columnHidden: false, columnImage: false, columnSortable: false, sortLv: 0, status: true, fixed: '', - columnWidth: 120 + columnWidth: 100 }, { userId: this.$store.state.user.name, - functionId: 101002002, - serialNumber: '101002002Table2AdjustElseCost', - tableId: '101002002Table2', + functionId: 102001, + serialNumber: '102001Table2Qty', + tableId: '102001Table2', tableName: '报价详情信息表', - columnProp: 'adjustElseCost', + columnProp: 'exchangeRate2', headerAlign: 'center', align: 'right', - columnLabel: '其他成本', + columnLabel: '汇率', columnHidden: false, columnImage: false, columnSortable: false, sortLv: 0, status: true, fixed: '', - columnWidth: 120 + columnWidth: 100 }, { userId: this.$store.state.user.name, - functionId: 101002002, - serialNumber: '101002002Table2TotalCost', - tableId: '101002002Table2', + functionId: 102001, + serialNumber: '102001Table2Qty', + tableId: '102001Table2', tableName: '报价详情信息表', - columnProp: 'totalCost', + columnProp: 'currencyTotalCost2', headerAlign: 'center', align: 'right', - columnLabel: '总成本', + columnLabel: '含税单价', columnHidden: false, columnImage: false, columnSortable: false, sortLv: 0, status: true, fixed: '', - columnWidth: 140 + columnWidth: 100 }, { userId: this.$store.state.user.name, @@ -307,7 +314,22 @@ export default { }, }) } - } + }, + fields() { + let json = "{" + this.columns.forEach((item, index) => { + if (index === this.columns.length - 1) { + json += "\"" + item.columnLabel + "\"" + ":" + "\"" + item.columnProp + "\"" + } else { + json += "\"" + item.columnLabel + "\"" + ":" + "\"" + item.columnProp + "\"" + "," + } + }) + json += "}" + return eval("(" + json + ")") + }, + createExportData() { + return this.dataList; + }, }, watch:{ part(newVal,oldVal){ @@ -322,29 +344,43 @@ export default {