This commit is contained in:
‘937886381’
2025-12-30 09:04:48 +08:00
parent 80deffbb42
commit 7b3873f9ea
232 changed files with 13127 additions and 17011 deletions

View File

@@ -17,7 +17,7 @@
gap: 12px;
grid-template-columns: 1624px;
">
<changeBase @selectChange="selectChange" />
<changeBase :factory="factory" @baseChange="selectChange" />
</div>
</div>
<div class="top" style="display: flex; gap: 16px;margin-top: -20px;">
@@ -26,8 +26,8 @@
gap: 12px;
grid-template-columns: 804px 804px;
">
<monthlyOverview :month="month" :itemData="renderList" :title="'月度概览'" />
<totalOverview :itemData="renderList" :title="'累计概览'" />
<monthlyOverview :month="month" :monData="monData" :title="'月度概览'" />
<totalOverview :totalData="totalData" :title="'累计概览'" />
</div>
</div>
@@ -35,10 +35,10 @@
<div class="left-three" style="
display: grid;
gap: 12px;
grid-template-columns: 804px 804px;
grid-template-columns: 804px 804px;
">
<monthlyRelatedMetrics :itemData="renderList" :title="'月度·相关指标分析'" />
<yearRelatedMetrics :month="month" :itemData="renderList" :title="'累计·相关指标分析'" />
<monthlyRelatedMetrics :relatedMon="relatedMon" :title="'月度·相关指标分析'" />
<yearRelatedMetrics :relatedTotal="relatedTotal" :title="'累计·相关指标分析'" />
</div>
</div>
@@ -48,7 +48,7 @@
gap: 12px;
grid-template-columns: 1624px;
">
<dataTrend :itemData="renderList" :title="'数据趋势'" />
<dataTrend :trendData="trend" :title="'数据趋势'" />
</div>
</div>
</div>
@@ -73,10 +73,8 @@ import totalOverview from "../salesVolumeAnalysisComponents/totalOverview.vue";
import monthlyRelatedMetrics from "../salesVolumeAnalysisComponents/monthlyThreeRelatedMetrics.vue";
import yearRelatedMetrics from "../salesVolumeAnalysisComponents/yearThreeRelatedMetrics.vue";
import dataTrend from "../salesVolumeAnalysisComponents/dataTrendDouble.vue";
import profitLineChart from "../costComponents/profitLineChart.vue";
import { mapState } from "vuex";
import { getCostAnalysisXXCostList } from '@/api/cockpit'
import { getUnitPriceAnalysisBaseData } from '@/api/cockpit'
// import PSDO from "./components/PSDO.vue";
// import psiLineChart from "./components/psiLineChart.vue";
@@ -91,13 +89,12 @@ export default {
components: {
ReportHeader,
changeBase,
profitLineChart,
monthlyOverview,
Sidebar,
totalOverview,
dataTrend,
monthlyRelatedMetrics,
yearRelatedMetrics,
dataTrend
yearRelatedMetrics
// psiLineChart
},
data() {
@@ -105,16 +102,15 @@ export default {
isFullScreen: false,
timer: null,
beilv: 1,
month:'',
month: '',
value: 100,
dateData:{},
levelId:undefined,
itemData: [],
trendData: [],
parentItemList: [
{ name: "燃料成本", target: 0, value: 0, proportion: 0, flag: 1 },
{ name: "天然气", target: 0, value: 0, proportion: 0, flag: 1 }
],
factory: 5,
dateData: {},
monData: {},
totalData: {},
trend: [],
relatedData: {},
// cusProData: {},
};
},
@@ -131,12 +127,6 @@ export default {
needTagsView: (state) => state.settings.tagsView,
fixedHeader: (state) => state.settings.fixedHeader,
}),
renderList() {
if (this.itemData && this.itemData.length > 0) {
return this.itemData;
}
return this.parentItemList;
},
classObj() {
return {
hideSidebar: !this.sidebar.opened,
@@ -186,28 +176,46 @@ export default {
this.beilv = _this.clientWidth / 1920;
})();
};
this.factory = this.$route.query.factory ? Number(this.$route.query.factory) : this.factory
},
methods: {
handleChange(value) {
this.index = value
this.getData()
},
getData() {
const requestParams = {
// startTime: this.startTime,
// endTime: this.endTime,
// mode: this.mode,
startTime: this.dateData.startTime,
endTime: this.dateData.endTime,
mode: this.dateData.mode,
trendName: "燃料成本",
levelId: this.levelId ? this.levelId :1
// index: this.index,
// sort: 1,
paramName: '双镀销量',
paramList: ['双镀成本', '双镀均价','双镀毛利'],
baseId: this.factory,
// baseId: Number(this.factory),
};
// 调用接口
getCostAnalysisXXCostList(requestParams).then((res) => {
this.itemData = res.data[0].map((item) => {
return {
...item,
route: 'singleFuelAnalysis'
}
})
this.trendData= res.data[1]
getUnitPriceAnalysisBaseData(requestParams).then((res) => {
this.monData = res.data.monData
this.totalData = res.data.totalData
// this.relatedMon = res.data.relatedMon
this.relatedData = {
relatedTotal: res.data.relatedTotal,
relatedMon: res.data.relatedMon,
}
this.trend = res.data.trend
// this.relatedTotal = res.data.relatedTotal
// this.cusProData = {
// customerPriceMon: res.data.customerPriceMon,
// customerPriceTotal: res.data.customerPriceTotal,
// customerSaleMon: res.data.customerSaleMon,
// customerSaleTotal: res.data.customerSaleTotal,
// productMonSale: res.data.productMonSale,
// productPriceMon: res.data.productPriceMon,
// productPriceTotal: res.data.productPriceTotal,
// productTotalSale: res.data.productTotalSale,
// }
});
},
@@ -216,14 +224,14 @@ export default {
this.dateData = {
startTime: obj.startTime,
endTime: obj.endTime,
mode: obj.mode,
// mode: obj.mode,
}
this.getData()
},
selectChange(data) {
console.log('选中的数据:', data);
this.levelId = data
this.factory = data
if (this.dateData.startTime && this.dateData.endTime) {
this.getData();
}
@@ -308,12 +316,14 @@ export default {
<style scoped lang="scss">
@import "~@/assets/styles/mixin.scss";
@import "~@/assets/styles/variables.scss";
.dayReport {
width: 1920px;
height: 1080px;
background: url("../../../assets/img/backp.png") no-repeat;
background-size: cover;
}
.hideSidebar .fixed-header {
width: calc(100% - 54px);
}

View File

@@ -17,7 +17,7 @@
gap: 12px;
grid-template-columns: 1624px;
">
<changeBase @selectChange="selectChange" />
<changeBase :factory="factory" @baseChange="selectChange" />
</div>
</div>
<div class="top" style="display: flex; gap: 16px;margin-top: -20px;">
@@ -26,8 +26,8 @@
gap: 12px;
grid-template-columns: 804px 804px;
">
<monthlyOverview :month="month" :itemData="renderList" :title="'月度概览'" />
<totalOverview :itemData="renderList" :title="'累计概览'" />
<monthlyOverview :month="month" :monData="monData" :title="'月度概览'" />
<totalOverview :totalData="totalData" :title="'累计概览'" />
</div>
</div>
@@ -35,10 +35,10 @@
<div class="left-three" style="
display: grid;
gap: 12px;
grid-template-columns: 804px 804px;
grid-template-columns: 804px 804px;
">
<monthlyRelatedMetrics :itemData="renderList" :title="'月度·相关指标分析'" />
<yearRelatedMetrics :month="month" :itemData="renderList" :title="'累计·相关指标分析'" />
<monthlyRelatedMetrics :relatedMon="relatedMon" :title="'月度·相关指标分析'" />
<yearRelatedMetrics :relatedTotal="relatedTotal" :title="'累计·相关指标分析'" />
</div>
</div>
@@ -48,7 +48,7 @@
gap: 12px;
grid-template-columns: 1624px;
">
<dataTrend :itemData="renderList" :title="'数据趋势'" />
<dataTrend :trendData="trend" :title="'数据趋势'" />
</div>
</div>
</div>
@@ -72,11 +72,9 @@ import totalOverview from "../salesVolumeAnalysisComponents/totalOverview.vue";
// import totalOverview from "../operatingComponents/totalOverview.vue";
import monthlyRelatedMetrics from "../salesVolumeAnalysisComponents/monthlyRelatedMetrics.vue";
import yearRelatedMetrics from "../salesVolumeAnalysisComponents/yearRelatedMetrics.vue";
import dataTrend from "../salesVolumeAnalysisComponents/dataTrend.vue";
import profitLineChart from "../costComponents/profitLineChart.vue";
import dataTrend from "../salesVolumeAnalysisComponents/dataTrendProduct.vue";
import { mapState } from "vuex";
import { getCostAnalysisXXCostList } from '@/api/cockpit'
import { getUnitPriceAnalysisBaseData } from '@/api/cockpit'
// import PSDO from "./components/PSDO.vue";
// import psiLineChart from "./components/psiLineChart.vue";
@@ -91,13 +89,12 @@ export default {
components: {
ReportHeader,
changeBase,
profitLineChart,
monthlyOverview,
Sidebar,
totalOverview,
dataTrend,
monthlyRelatedMetrics,
yearRelatedMetrics,
dataTrend
yearRelatedMetrics
// psiLineChart
},
data() {
@@ -105,16 +102,15 @@ export default {
isFullScreen: false,
timer: null,
beilv: 1,
month:'',
month: '',
value: 100,
dateData:{},
levelId:undefined,
itemData: [],
trendData: [],
parentItemList: [
{ name: "燃料成本", target: 0, value: 0, proportion: 0, flag: 1 },
{ name: "天然气", target: 0, value: 0, proportion: 0, flag: 1 }
],
factory: 5,
dateData: {},
monData: {},
totalData: {},
trend: [],
relatedData: {},
// cusProData: {},
};
},
@@ -131,12 +127,6 @@ export default {
needTagsView: (state) => state.settings.tagsView,
fixedHeader: (state) => state.settings.fixedHeader,
}),
renderList() {
if (this.itemData && this.itemData.length > 0) {
return this.itemData;
}
return this.parentItemList;
},
classObj() {
return {
hideSidebar: !this.sidebar.opened,
@@ -186,28 +176,46 @@ export default {
this.beilv = _this.clientWidth / 1920;
})();
};
this.factory = this.$route.query.factory ? Number(this.$route.query.factory) : this.factory
},
methods: {
handleChange(value) {
this.index = value
this.getData()
},
getData() {
const requestParams = {
// startTime: this.startTime,
// endTime: this.endTime,
// mode: this.mode,
startTime: this.dateData.startTime,
endTime: this.dateData.endTime,
mode: this.dateData.mode,
trendName: "燃料成本",
levelId: this.levelId ? this.levelId :1
// index: this.index,
// sort: 1,
paramName: '产销率',
paramList: ['产量', '销量'],
baseId: this.factory,
// baseId: Number(this.factory),
};
// 调用接口
getCostAnalysisXXCostList(requestParams).then((res) => {
this.itemData = res.data[0].map((item) => {
return {
...item,
route: 'singleFuelAnalysis'
}
})
this.trendData= res.data[1]
getUnitPriceAnalysisBaseData(requestParams).then((res) => {
this.monData = res.data.monData
this.totalData = res.data.totalData
// this.relatedMon = res.data.relatedMon
this.relatedData = {
relatedTotal: res.data.relatedTotal,
relatedMon: res.data.relatedMon,
}
this.trend = res.data.trend
// this.relatedTotal = res.data.relatedTotal
// this.cusProData = {
// customerPriceMon: res.data.customerPriceMon,
// customerPriceTotal: res.data.customerPriceTotal,
// customerSaleMon: res.data.customerSaleMon,
// customerSaleTotal: res.data.customerSaleTotal,
// productMonSale: res.data.productMonSale,
// productPriceMon: res.data.productPriceMon,
// productPriceTotal: res.data.productPriceTotal,
// productTotalSale: res.data.productTotalSale,
// }
});
},
@@ -216,14 +224,14 @@ export default {
this.dateData = {
startTime: obj.startTime,
endTime: obj.endTime,
mode: obj.mode,
// mode: obj.mode,
}
this.getData()
},
selectChange(data) {
console.log('选中的数据:', data);
this.levelId = data
this.factory = data
if (this.dateData.startTime && this.dateData.endTime) {
this.getData();
}
@@ -308,12 +316,14 @@ export default {
<style scoped lang="scss">
@import "~@/assets/styles/mixin.scss";
@import "~@/assets/styles/variables.scss";
.dayReport {
width: 1920px;
height: 1080px;
background: url("../../../assets/img/backp.png") no-repeat;
background-size: cover;
}
.hideSidebar .fixed-header {
width: calc(100% - 54px);
}

View File

@@ -16,7 +16,7 @@
gap: 12px;
grid-template-columns:1624px;
">
<operatingLineChart :salesTrendMap="salesTrendMap" :grossMarginTrendMap="grossMarginTrendMap" />
<operatingLineChart :thisMonData="thisMonData" />
</div>
</div>
<div class="top" style="display: flex; gap: 16px;margin-top: 6px;">
@@ -25,7 +25,7 @@
gap: 12px;
grid-template-columns: 1624px;
">
<operatingLineChartCumulative :salesTrendMap="salesTrendMap" :grossMarginTrendMap="grossMarginTrendMap" />
<operatingLineChartCumulative :totalData="totalData" />
<!-- <keyWork /> -->
</div>
</div>
@@ -50,7 +50,7 @@ import { mapState } from "vuex";
import operatingLineChart from "../salesVolumeAnalysisComponents/operatingLineChart";
import operatingLineChartCumulative from "../salesVolumeAnalysisComponents/operatingLineChartCumulative.vue";
import { getSalesRevenueData } from '@/api/cockpit'
import { getUnitPriceAnalysisGroupData } from '@/api/cockpit'
import moment from "moment";
export default {
name: "DayReport",
@@ -68,11 +68,9 @@ export default {
timer: null,
beilv: 1,
value: 100,
saleData: {},
premiumProduct: {},
salesTrendMap: {},
grossMarginTrendMap: {},
salesProportion:{},
selectDate: {},
thisMonData: {},
totalData: {},
};
},
@@ -141,22 +139,27 @@ export default {
},
methods: {
getData(obj) {
getSalesRevenueData({
startTime: obj.startTime,
endTime: obj.endTime,
timeDim: obj.mode
getUnitPriceAnalysisGroupData({
startTime: this.selectDate.startTime,
endTime: this.selectDate.endTime,
paramName: '销量'
// timeDim: this.selectDate.mode
}).then((res) => {
console.log(res);
this.saleData = res.data.SaleData
this.premiumProduct = res.data.premiumProduct
this.salesTrendMap = res.data.salesTrendMap
this.grossMarginTrendMap = res.data.grossMarginTrendMap
this.salesProportion = res.data.salesProportion ? res.data.salesProportion : {}
this.thisMonData = res.data.thisMonData
this.totalData = res.data.totalData
// this.saleData = res.data.SaleData
// this.premiumProduct = res.data.premiumProduct
// this.salesTrendMap = res.data.salesTrendMap
// this.grossMarginTrendMap = res.data.grossMarginTrendMap
// this.salesProportion = res.data.salesProportion ? res.data.salesProportion : {}
})
},
handleTimeChange(obj) {
console.log(obj, 'obj');
this.getData(obj)
// console.log(obj, 'obj');
this.selectDate = obj
this.getData()
},
handleClickOutside() {
this.$store.dispatch("app/closeSideBar", { withoutAnimation: false });
@@ -228,12 +231,14 @@ export default {
<style scoped lang="scss">
@import "~@/assets/styles/mixin.scss";
@import "~@/assets/styles/variables.scss";
.dayReport {
width: 1920px;
height: 1080px;
background: url("../../../assets/img/backp.png") no-repeat;
background-size: cover;
}
.hideSidebar .fixed-header {
width: calc(100% - 54px);
}

View File

@@ -17,7 +17,7 @@
gap: 12px;
grid-template-columns: 1624px;
">
<changeBase @selectChange="selectChange" />
<changeBase :factory="factory" @baseChange="selectChange" />
</div>
</div>
<div class="top" style="display: flex; gap: 16px;margin-top: -20px;">
@@ -26,8 +26,8 @@
gap: 12px;
grid-template-columns: 804px 804px;
">
<monthlyOverview :month="month" :itemData="renderList" :title="'月度概览'" />
<totalOverview :itemData="renderList" :title="'累计概览'" />
<monthlyOverview :month="month" :monData="monData" :title="'月度概览'" />
<totalOverview :totalData="totalData" :title="'累计概览'" />
</div>
</div>
@@ -37,7 +37,8 @@
gap: 12px;
grid-template-columns: 1624px;
">
<relatedIndicatorsAnalysis :itemData="renderList" :title="'相关指标分析/万元'" />
<relatedIndicatorsAnalysis :relatedData="relatedData" :title="'相关指标分析·单位/万元'" />
</div>
</div>
<div class="bottom" style="display: flex; gap: 16px;margin-top: 6px;">
@@ -46,7 +47,7 @@
gap: 12px;
grid-template-columns: 1624px;
">
<dataTrend :itemData="renderList" :title="'数据趋势'" />
<dataTrend :trendData="trend" :title="'数据趋势'" />
</div>
</div>
</div>
@@ -68,15 +69,10 @@ import changeBase from "../components/changeBase.vue";
import monthlyOverview from "../salesVolumeAnalysisComponents/monthlyOverview.vue";
import totalOverview from "../salesVolumeAnalysisComponents/totalOverview.vue";
// import totalOverview from "../operatingComponents/totalOverview.vue";
// import monthlyRelatedMetrics from "../salesVolumeAnalysisComponents/monthlyRelatedMetrics.vue";
// import yearRelatedMetrics from "../salesVolumeAnalysisComponents/yearRelatedMetrics.vue";
import relatedIndicatorsAnalysis from "../salesVolumeAnalysisComponents/relatedIndicatorsAnalysis";
import relatedIndicatorsAnalysis from "../salesVolumeAnalysisComponents/relatedIndicatorsAnalysis";
import dataTrend from "../salesVolumeAnalysisComponents/dataTrend.vue";
import profitLineChart from "../costComponents/profitLineChart.vue";
import { mapState } from "vuex";
import { getCostAnalysisXXCostList } from '@/api/cockpit'
import { getUnitPriceAnalysisBaseData } from '@/api/cockpit'
// import PSDO from "./components/PSDO.vue";
// import psiLineChart from "./components/psiLineChart.vue";
@@ -91,12 +87,11 @@ export default {
components: {
ReportHeader,
changeBase,
profitLineChart,
monthlyOverview,
Sidebar,
totalOverview,
relatedIndicatorsAnalysis,
dataTrend
dataTrend,
relatedIndicatorsAnalysis
// psiLineChart
},
data() {
@@ -104,16 +99,15 @@ export default {
isFullScreen: false,
timer: null,
beilv: 1,
month:'',
month: '',
value: 100,
dateData:{},
levelId:undefined,
itemData: [],
trendData: [],
parentItemList: [
{ name: "燃料成本", target: 0, value: 0, proportion: 0, flag: 1 },
{ name: "天然气", target: 0, value: 0, proportion: 0, flag: 1 }
],
factory: 5,
dateData: {},
monData: {},
totalData: {},
trend: [],
relatedData:{},
// cusProData: {},
};
},
@@ -130,12 +124,6 @@ export default {
needTagsView: (state) => state.settings.tagsView,
fixedHeader: (state) => state.settings.fixedHeader,
}),
renderList() {
if (this.itemData && this.itemData.length > 0) {
return this.itemData;
}
return this.parentItemList;
},
classObj() {
return {
hideSidebar: !this.sidebar.opened,
@@ -185,28 +173,46 @@ export default {
this.beilv = _this.clientWidth / 1920;
})();
};
this.factory = this.$route.query.factory ? Number(this.$route.query.factory) : this.factory
},
methods: {
handleChange(value) {
this.index = value
this.getData()
},
getData() {
const requestParams = {
// startTime: this.startTime,
// endTime: this.endTime,
// mode: this.mode,
startTime: this.dateData.startTime,
endTime: this.dateData.endTime,
mode: this.dateData.mode,
trendName: "燃料成本",
levelId: this.levelId ? this.levelId :1
// index: this.index,
// sort: 1,
paramName: '销量',
paramList: ['净价', '单价', '产销率', '双镀销量', '双镀占比', '溢价产品销量', '溢价产品毛利'],
baseId: 2,
// baseId: Number(this.factory),
};
// 调用接口
getCostAnalysisXXCostList(requestParams).then((res) => {
this.itemData = res.data[0].map((item) => {
return {
...item,
route: 'singleFuelAnalysis'
}
})
this.trendData= res.data[1]
getUnitPriceAnalysisBaseData(requestParams).then((res) => {
this.monData = res.data.monData
this.totalData = res.data.totalData
// this.relatedMon = res.data.relatedMon
this.relatedData = {
relatedTotal: res.data.relatedTotal,
relatedMon: res.data.relatedMon,
}
this.trend = res.data.trend
// this.relatedTotal = res.data.relatedTotal
// this.cusProData = {
// customerPriceMon: res.data.customerPriceMon,
// customerPriceTotal: res.data.customerPriceTotal,
// customerSaleMon: res.data.customerSaleMon,
// customerSaleTotal: res.data.customerSaleTotal,
// productMonSale: res.data.productMonSale,
// productPriceMon: res.data.productPriceMon,
// productPriceTotal: res.data.productPriceTotal,
// productTotalSale: res.data.productTotalSale,
// }
});
},
@@ -215,14 +221,14 @@ export default {
this.dateData = {
startTime: obj.startTime,
endTime: obj.endTime,
mode: obj.mode,
// mode: obj.mode,
}
this.getData()
},
selectChange(data) {
console.log('选中的数据:', data);
this.levelId = data
this.factory = data
if (this.dateData.startTime && this.dateData.endTime) {
this.getData();
}
@@ -307,12 +313,14 @@ export default {
<style scoped lang="scss">
@import "~@/assets/styles/mixin.scss";
@import "~@/assets/styles/variables.scss";
.dayReport {
width: 1920px;
height: 1080px;
background: url("../../../assets/img/backp.png") no-repeat;
background-size: cover;
}
.hideSidebar .fixed-header {
width: calc(100% - 54px);
}