diff --git a/src/views/home/components/CostsBottomBar.vue b/src/views/home/components/CostsBottomBar.vue index 1f7d15da..eec9f2a5 100644 --- a/src/views/home/components/CostsBottomBar.vue +++ b/src/views/home/components/CostsBottomBar.vue @@ -130,6 +130,7 @@ export default { display: flex; flex-direction: column; padding: 12px; + margin: 7px 0; .barTop { display: flex; diff --git a/src/views/home/components/heatBarChart.vue b/src/views/home/components/heatBarChart.vue index 5e533e73..a58bfdd9 100644 --- a/src/views/home/components/heatBarChart.vue +++ b/src/views/home/components/heatBarChart.vue @@ -1,5 +1,5 @@ + + diff --git a/src/views/home/productionCostAnalysisComponents/dataTrendBarSingleFuelF.vue b/src/views/home/productionCostAnalysisComponents/dataTrendBarSingleFuelF.vue new file mode 100644 index 00000000..59ec2b52 --- /dev/null +++ b/src/views/home/productionCostAnalysisComponents/dataTrendBarSingleFuelF.vue @@ -0,0 +1,475 @@ + + + + + diff --git a/src/views/home/productionCostAnalysisComponents/dataTrendBarSingleFuelYL.vue b/src/views/home/productionCostAnalysisComponents/dataTrendBarSingleFuelYL.vue new file mode 100644 index 00000000..3ae8d2fb --- /dev/null +++ b/src/views/home/productionCostAnalysisComponents/dataTrendBarSingleFuelYL.vue @@ -0,0 +1,476 @@ + + + + + diff --git a/src/views/home/productionCostAnalysisComponents/dataTrendSingleCombustible.vue b/src/views/home/productionCostAnalysisComponents/dataTrendSingleCombustible.vue index b31294c2..e5b3c316 100644 --- a/src/views/home/productionCostAnalysisComponents/dataTrendSingleCombustible.vue +++ b/src/views/home/productionCostAnalysisComponents/dataTrendSingleCombustible.vue @@ -9,7 +9,7 @@ background-color: rgba(249, 252, 255, 1); "> - + @@ -28,6 +28,10 @@ export default { type: Array, default: () => [], }, + fuelName: { + type: String, + default: () => "", + } }, data() { return { diff --git a/src/views/home/productionCostAnalysisComponents/dataTrendSingleFuel.vue b/src/views/home/productionCostAnalysisComponents/dataTrendSingleFuel.vue index 48ac3ad9..1d53b9d1 100644 --- a/src/views/home/productionCostAnalysisComponents/dataTrendSingleFuel.vue +++ b/src/views/home/productionCostAnalysisComponents/dataTrendSingleFuel.vue @@ -18,7 +18,7 @@ + + + + diff --git a/src/views/home/productionCostAnalysisComponents/dataTrendSingleFuelF.vue b/src/views/home/productionCostAnalysisComponents/dataTrendSingleFuelF.vue new file mode 100644 index 00000000..dcdb2403 --- /dev/null +++ b/src/views/home/productionCostAnalysisComponents/dataTrendSingleFuelF.vue @@ -0,0 +1,250 @@ + + + + + + + diff --git a/src/views/home/productionCostAnalysisComponents/dataTrendSingleFuelYL.vue b/src/views/home/productionCostAnalysisComponents/dataTrendSingleFuelYL.vue new file mode 100644 index 00000000..4a9e6672 --- /dev/null +++ b/src/views/home/productionCostAnalysisComponents/dataTrendSingleFuelYL.vue @@ -0,0 +1,250 @@ + + + + + + + diff --git a/src/views/home/productionCostAnalysisComponents/monthlyRelatedMetricsProcessingFuel.vue b/src/views/home/productionCostAnalysisComponents/monthlyRelatedMetricsProcessingFuel.vue index 4ba6396b..89f4c0b5 100644 --- a/src/views/home/productionCostAnalysisComponents/monthlyRelatedMetricsProcessingFuel.vue +++ b/src/views/home/productionCostAnalysisComponents/monthlyRelatedMetricsProcessingFuel.vue @@ -7,7 +7,7 @@
- 电·万元 + 电·元/㎡
完成率:{{dianData.proportion}}% diff --git a/src/views/home/productionCostAnalysisComponents/monthlyThreeRelatedMetrics.vue b/src/views/home/productionCostAnalysisComponents/monthlyThreeRelatedMetrics.vue deleted file mode 100644 index 1a60e8ee..00000000 --- a/src/views/home/productionCostAnalysisComponents/monthlyThreeRelatedMetrics.vue +++ /dev/null @@ -1,240 +0,0 @@ - - - - - - diff --git a/src/views/home/productionCostAnalysisComponents/monthlyThreeRelatedMetricsCCA.vue b/src/views/home/productionCostAnalysisComponents/monthlyThreeRelatedMetricsCCA.vue index 74a46732..2f5007e9 100644 --- a/src/views/home/productionCostAnalysisComponents/monthlyThreeRelatedMetricsCCA.vue +++ b/src/views/home/productionCostAnalysisComponents/monthlyThreeRelatedMetricsCCA.vue @@ -7,7 +7,7 @@ v-for="item in sortedIndicators" :key="item.key" class="dashboard" - @click="handleDashboardClick(item.name)" + @click="item.route && handleDashboardClick(item.name,item.route)" >
{{ item.name }}·{{ item.unit }} @@ -62,9 +62,9 @@ export default { computed: { indicatorDefs() { return [ - { key: 'mx', name: '芒硝', unit: '元/㎡'}, - { key: 'xsn', name: '硝酸钠', unit: '元/㎡'}, - { key: 'jtsn', name: '焦锑酸钠', unit: '元/㎡'}, + { key: 'mx', name: '芒硝', unit: '元/㎡', route: 'SIMFRMCostAnalysis'}, + { key: 'xsn', name: '硝酸钠', unit: '元/㎡', route: 'SIMFRMCostAnalysis'}, + { key: 'jtsn', name: '焦锑酸钠', unit: '元/㎡', route: 'SIMFRMCostAnalysis'}, ] }, indicators() { @@ -112,16 +112,17 @@ export default { console.log('组件挂载时的相关数据:', this.relatedData); }, methods: { - handleDashboardClick(name) { + handleDashboardClick(material, path) { this.$router.push({ - path: 'singleProcMfgOverheadCost', + path: path, query: { - name, - factory: this.$route.query.factory ? this.$route.query.factory : this.factory, + name: material, + month: this.month, + factory: this.$route.query.factory ? this.$route.query.factory :5, dateData: this.dateData } - }) - } + }); + }, } } diff --git a/src/views/home/productionCostAnalysisComponents/operatingLineBarSale.vue b/src/views/home/productionCostAnalysisComponents/operatingLineBarSale.vue index 72a6c4b6..1f0c00ad 100644 --- a/src/views/home/productionCostAnalysisComponents/operatingLineBarSale.vue +++ b/src/views/home/productionCostAnalysisComponents/operatingLineBarSale.vue @@ -134,7 +134,7 @@ export default { return; // 实例未初始化则返回 } - const { allPlaceNames, series } = this.chartData || {}; + const { allPlaceNames,unit, series } = this.chartData || {}; const xData = allPlaceNames || []; const chartSeries = series || []; @@ -152,7 +152,7 @@ export default { top: 30, bottom: 5, right: 20, - left: 35, + left: 55, containLabel: true }, xAxis: [ @@ -181,7 +181,7 @@ export default { yAxis: [ { type: 'value', - name: '元/m²', + name: unit, nameTextStyle: { color: 'rgba(0, 0, 0, 0.45)', fontSize: 12, diff --git a/src/views/home/productionCostAnalysisComponents/relateCombustibleCostAnalysis.vue b/src/views/home/productionCostAnalysisComponents/relateCombustibleCostAnalysis.vue index 47073a7d..35fe3056 100644 --- a/src/views/home/productionCostAnalysisComponents/relateCombustibleCostAnalysis.vue +++ b/src/views/home/productionCostAnalysisComponents/relateCombustibleCostAnalysis.vue @@ -67,10 +67,10 @@ export default { computed: { indicatorDefs() { return [ - { key: 'naturalGas', name: '天然气', unit: '元/吨',route:'singleCombustible'}, - { key: 'lng', name: 'LNG液化天然气', unit: '元/吨',route:'singleCombustible'}, - { key: 'heavyOil', name: '重油', unit: '元/吨',route:'singleCombustible'}, - { key: 'water', name: '水', unit: '元/吨',route:'singleCombustible'} + { key: 'naturalGas', name: '天然气', unit: '元/㎡',route:'singleCombustible'}, + { key: 'lng', name: 'LNG液化天然气', unit: '元/㎡',route:'singleCombustible'}, + { key: 'heavyOil', name: '重油', unit: '元/㎡',route:'singleCombustible'}, + { key: 'water', name: '水', unit: '元/m³',route:'singleCombustible'} ] }, indicators() { @@ -87,7 +87,7 @@ export default { }) }, sortedIndicators() { - const unitOrder = ['元/吨'] + const unitOrder = ['元/㎡', '元/m³'] const unitRank = (u) => { const idx = unitOrder.indexOf(u) return idx === -1 ? 999 : idx diff --git a/src/views/home/productionCostAnalysisComponents/relateFactoryBurdenCostAnalysis.vue b/src/views/home/productionCostAnalysisComponents/relateFactoryBurdenCostAnalysis.vue index 5c931a20..c9ccb423 100644 --- a/src/views/home/productionCostAnalysisComponents/relateFactoryBurdenCostAnalysis.vue +++ b/src/views/home/productionCostAnalysisComponents/relateFactoryBurdenCostAnalysis.vue @@ -76,10 +76,10 @@ export default { computed: { indicatorDefs() { return [ - { key: 'packaging', name: '包材', unit: '元/吨'}, - { key: 'spareParts', name: '备件、机物料', unit: '元/吨'}, - { key: 'depreciation', name: '折旧', unit: '元/吨'}, - { key: 'other', name: '其他', unit: '元/吨'}, + { key: 'packaging', name: '包材', unit: '元/㎡'}, + { key: 'spareParts', name: '备件、机物料', unit: '元/㎡'}, + { key: 'depreciation', name: '折旧', unit: '元/㎡'}, + { key: 'other', name: '其他', unit: '元/㎡'}, ] }, indicators() { @@ -96,7 +96,7 @@ export default { }) }, sortedIndicators() { - const unitOrder = ['元/吨'] + const unitOrder = ['元/㎡'] const unitRank = (u) => { const idx = unitOrder.indexOf(u) return idx === -1 ? 999 : idx diff --git a/src/views/home/productionCostAnalysisComponents/relateFuCostAnalysis.vue b/src/views/home/productionCostAnalysisComponents/relateFuCostAnalysis.vue new file mode 100644 index 00000000..1fa00faf --- /dev/null +++ b/src/views/home/productionCostAnalysisComponents/relateFuCostAnalysis.vue @@ -0,0 +1,230 @@ + + + + + diff --git a/src/views/home/productionCostAnalysisComponents/relateFuelCostAnalysis.vue b/src/views/home/productionCostAnalysisComponents/relateFuelCostAnalysis.vue index 5a058093..f5d4c0e9 100644 --- a/src/views/home/productionCostAnalysisComponents/relateFuelCostAnalysis.vue +++ b/src/views/home/productionCostAnalysisComponents/relateFuelCostAnalysis.vue @@ -65,14 +65,13 @@ export default { indicatorDefs() { return [ { key: 'silicaSand', name: '硅砂', unit: '元/㎡', route: 'SIMFRMCostAnalysis'}, - // { key: 'seaSand', name: '海砂', unit: '元/㎡', route: 'SIMFRMCostAnalysis'}, { key: 'sodaAsh', name: '纯碱', unit: '元/㎡', route: 'SIMFRMCostAnalysis'}, { key: 'dolomite', name: '白云石', unit: '元/㎡', route: 'SIMFRMCostAnalysis'}, { key: 'limestone', name: '石灰石', unit: '元/㎡', route: 'SIMFRMCostAnalysis'}, { key: 'compoundClarifyingAgent', name: '复合澄清剂', unit: '元/㎡', route: 'compositeClarifyingAgentCostAnalysis'}, - { key: 'ATH', name: '氢氧化铝', unit: '元/㎡', route: null}, - { key: 'cosolvent', name: '助溶剂', unit: '元/㎡', route: null}, - { key: 'brokenGlass', name: '碎玻璃', unit: '元/㎡', route: null}, + { key: 'ATH', name: '氢氧化铝', unit: '元/㎡', route: 'SIMFRMCostAnalysis'}, + { key: 'cosolvent', name: '助熔剂', unit: '元/㎡', route: 'SIMFRMCostAnalysis'}, + { key: 'brokenGlass', name: '碎玻璃', unit: '元/㎡', route: 'SIMFRMCostAnalysis'}, ] }, indicators() { diff --git a/src/views/home/productionCostAnalysisComponents/relateSingleCombustible.vue b/src/views/home/productionCostAnalysisComponents/relateSingleCombustible.vue index 5c49d484..afabd709 100644 --- a/src/views/home/productionCostAnalysisComponents/relateSingleCombustible.vue +++ b/src/views/home/productionCostAnalysisComponents/relateSingleCombustible.vue @@ -50,6 +50,10 @@ export default { type: String, default: '' // 默认空字符串,保持原有配置 }, + fuelName: { // 接收父组件传递的设备数据数组 + type: String, + default: '' // 默认空字符串,保持原有配置 + } }, data() { return { @@ -77,13 +81,23 @@ export default { }, computed: { indicatorDefs() { - return [ - { key: 'unitPrice', name: '采购单价', unit: '元/m³'}, - { key: 'product', name: '产量', unit: '吨'}, - { key: 'unitHao', name: '单耗', unit: '吨/m³'}, - { key: 'haoNum', name: '消耗量', unit: 'm³'}, - { key: 'heatConsumption', name: '热耗', unit: 'kcal/kg'}, + if (this.fuelName === '重油') { + return [ + { key: 'unitPrice', name: '采购单价', unit: '元/吨'}, + { key: 'product', name: '产量', unit: '㎡'}, + { key: 'unitHao', name: '单耗', unit: '千克/㎡'}, + { key: 'haoNum', name: '消耗量', unit: '吨'}, + { key: 'heatConsumption', name: '热耗', unit: '千卡/千克'}, ] + }else{ + return [ + { key: 'unitPrice', name: '采购单价', unit: '元/m³'}, + { key: 'product', name: '产量', unit: '㎡'}, + { key: 'unitHao', name: '单耗', unit: 'm³/㎡'}, + { key: 'haoNum', name: '消耗量', unit: 'm³'}, + { key: 'heatConsumption', name: '热耗', unit: '千卡/千克'}, + ] + } }, indicators() { const fallback = { targetValue: 0, value: 0, completed: 0, diffValue: 0 } @@ -99,7 +113,7 @@ export default { }) }, sortedIndicators() { - const unitOrder = ['元/㎡','吨','吨/m³','m³','kcal/kg'] + const unitOrder = ['元/m³','㎡','m³/㎡','m³','千卡/千克'] const unitRank = (u) => { const idx = unitOrder.indexOf(u) return idx === -1 ? 999 : idx diff --git a/src/views/home/productionCostAnalysisComponents/relateSingleFuelCostAnalysis.vue b/src/views/home/productionCostAnalysisComponents/relateSingleFuelCostAnalysis.vue index c4ea9cab..cc1859b7 100644 --- a/src/views/home/productionCostAnalysisComponents/relateSingleFuelCostAnalysis.vue +++ b/src/views/home/productionCostAnalysisComponents/relateSingleFuelCostAnalysis.vue @@ -53,7 +53,7 @@ export default { month: { type: String, default: '' - }, + } }, data() { return { @@ -66,8 +66,8 @@ export default { indicatorDefs() { return [ { key: 'rawMaterialCost', name: '采购单价', unit: '元/吨'}, - { key: 'fuelCost', name: '产量', unit: '吨'}, - { key: 'electricityCost', name: '单耗', unit: '吨'}, + { key: 'fuelCost', name: '产量', unit: '㎡'}, + { key: 'electricityCost', name: '单耗', unit: '千克/㎡'}, { key: 'laborCost', name: '消耗量', unit: '吨'}, { key: 'laborCostDay', name: '日均消耗量', unit: '吨'} ] @@ -86,7 +86,7 @@ export default { }) }, sortedIndicators() { - const unitOrder = ['元/吨', '吨'] + const unitOrder = ['元/吨','㎡','千克/㎡', '吨'] const unitRank = (u) => { const idx = unitOrder.indexOf(u) return idx === -1 ? 999 : idx diff --git a/src/views/home/productionCostAnalysisComponents/relateSingleFuelCostAnalysisDian.vue b/src/views/home/productionCostAnalysisComponents/relateSingleFuelCostAnalysisDian.vue index 71ee35b5..8a43de03 100644 --- a/src/views/home/productionCostAnalysisComponents/relateSingleFuelCostAnalysisDian.vue +++ b/src/views/home/productionCostAnalysisComponents/relateSingleFuelCostAnalysisDian.vue @@ -8,7 +8,7 @@
- 采购单价·元/度 + 采购单价·{{unitList[0]}}
完成率:{{unitPriceData.proportion}}% @@ -20,7 +20,7 @@
- 产量·吨 + 产量.{{unitList[1]}}
完成率:{{productData.proportion}}% @@ -32,7 +32,7 @@
- 单耗·度/吨 + 单耗·{{unitList[2]}}
完成率:{{unitHaoData.proportion}}% @@ -44,7 +44,7 @@
- 消耗量·度 + 消耗量·{{unitList[3]}}
完成率:{{haoNumData.proportion}}% @@ -90,6 +90,10 @@ export default { type: String, default: '' }, + fuelName:{ + type: String, + default: '' + }, }, data() { return { @@ -101,6 +105,13 @@ export default { }, // 对齐第二个组件:添加计算属性,精准筛选各物料数据 computed: { + unitList() { + if (this.fuelName === '电') { + return ['元/度','㎡','度/㎡','度'] + }else{ + return ['元/m³','㎡','m³/㎡','m³'] + } + }, // 1. 硅砂数据:从激活数据集中筛选,兜底值与第二个组件统一 unitPriceData() { return this.activeData.find(item => (item.name || '').includes('采购单价')) || { diff --git a/src/views/home/productionCostAnalysisComponents/relateSingleFuelCostAnalysisFu.vue b/src/views/home/productionCostAnalysisComponents/relateSingleFuelCostAnalysisFu.vue index d9b4a7ce..f5c44c2a 100644 --- a/src/views/home/productionCostAnalysisComponents/relateSingleFuelCostAnalysisFu.vue +++ b/src/views/home/productionCostAnalysisComponents/relateSingleFuelCostAnalysisFu.vue @@ -65,10 +65,10 @@ export default { computed: { indicatorDefs() { return [ - { key: 'unitPrice', name: '采购单价', unit: 'kg/㎡'}, - { key: 'product', name: '产量', unit: '万㎡'}, - { key: 'unitHao', name: '单耗', unit: 'kg/m²'}, - { key: 'haoNum', name: '消耗量', unit: 'kg'}, + { key: 'unitPrice', name: '采购单价', unit: '元/千克'}, + { key: 'product', name: '产量', unit: '㎡'}, + { key: 'unitHao', name: '单耗', unit: '千克/㎡'}, + { key: 'haoNum', name: '消耗量', unit: '千克'}, ] }, indicators() { diff --git a/src/views/home/productionCostAnalysisComponents/yearRelatedMetricsFuel.vue b/src/views/home/productionCostAnalysisComponents/yearRelatedMetricsFuel.vue index 4ba6396b..89f4c0b5 100644 --- a/src/views/home/productionCostAnalysisComponents/yearRelatedMetricsFuel.vue +++ b/src/views/home/productionCostAnalysisComponents/yearRelatedMetricsFuel.vue @@ -7,7 +7,7 @@
- 电·万元 + 电·元/㎡
完成率:{{dianData.proportion}}% diff --git a/src/views/home/productionCostAnalysisComponents/yearThreeRelatedMetrics.vue b/src/views/home/productionCostAnalysisComponents/yearThreeRelatedMetrics.vue deleted file mode 100644 index 1a60e8ee..00000000 --- a/src/views/home/productionCostAnalysisComponents/yearThreeRelatedMetrics.vue +++ /dev/null @@ -1,240 +0,0 @@ - - - - - - diff --git a/src/views/home/productionCostAnalysisComponents/yearThreeRelatedMetricsCCA.vue b/src/views/home/productionCostAnalysisComponents/yearThreeRelatedMetricsCCA.vue index 74a46732..8fe885df 100644 --- a/src/views/home/productionCostAnalysisComponents/yearThreeRelatedMetricsCCA.vue +++ b/src/views/home/productionCostAnalysisComponents/yearThreeRelatedMetricsCCA.vue @@ -7,7 +7,7 @@ v-for="item in sortedIndicators" :key="item.key" class="dashboard" - @click="handleDashboardClick(item.name)" + @click="item.route && handleDashboardClick(item.name,item.route)" >
{{ item.name }}·{{ item.unit }} @@ -112,16 +112,17 @@ export default { console.log('组件挂载时的相关数据:', this.relatedData); }, methods: { - handleDashboardClick(name) { + handleDashboardClick(material, path) { this.$router.push({ - path: 'singleProcMfgOverheadCost', + path: path, query: { - name, - factory: this.$route.query.factory ? this.$route.query.factory : this.factory, + name: material, + month: this.month, + factory: this.$route.query.factory ? this.$route.query.factory :5, dateData: this.dateData } - }) - } + }); + }, } } diff --git a/src/views/home/salesVolumeAnalysis/productionSalesBase.vue b/src/views/home/salesVolumeAnalysis/productionSalesBase.vue index 8c587aaf..562ad321 100644 --- a/src/views/home/salesVolumeAnalysis/productionSalesBase.vue +++ b/src/views/home/salesVolumeAnalysis/productionSalesBase.vue @@ -181,7 +181,7 @@ export default { // index: this.index, // sort: 1, paramName: '产销率', - paramList: ['产量(深加工)', '销量'], + paramList: ['加工产量', '销量'], baseId: this.factory, // baseId: Number(this.factory), }; diff --git a/src/views/home/salesVolumeAnalysisComponents/dataTrendBarProduct.vue b/src/views/home/salesVolumeAnalysisComponents/dataTrendBarProduct.vue index 97eea35c..d8e77cf4 100644 --- a/src/views/home/salesVolumeAnalysisComponents/dataTrendBarProduct.vue +++ b/src/views/home/salesVolumeAnalysisComponents/dataTrendBarProduct.vue @@ -67,7 +67,7 @@ export default { profitOptions:[ {name:'产销率',unit:'%'}, {name:'销量',unit:'万㎡'}, - {name:'产量(深加工)',unit:'㎡'}, + {name:'加工产量',unit:'㎡'}, ], unit:'%', };