产量和效率

This commit is contained in:
‘937886381’
2024-05-29 17:05:55 +08:00
83 changed files with 17006 additions and 10610 deletions

View File

@@ -1,29 +1,30 @@
<!--
filename: index.vue
author: liubin
date: 2024-04-16 14:40:15
description: 产量驾驶舱
* @Author: zhp
* @Date: 2024-05-10 11:10:54
* @LastEditTime: 2024-05-28 13:36:07
* @LastEditors: zhp
* @Description:
-->
<template>
<div class="yield-copilot">
<section class="top flex">
<db-container class="std-yield" title="标准组件产出" icon="std">
<std-output :period="period" />
<std-output v-if="show" :period="period" :than="than" />
</db-container>
<db-container class="chip-yield" title="芯片产出" icon="chip2">
<chip-output :period="period" />
<chip-output v-if="show" :period="period" :than="than" />
</db-container>
<db-container class="bipv-yield" title="BIPV产出" icon="bipv">
<bipv-output :period="period" />
<bipv-output v-if="show" :period="period" :than="than" />
</db-container>
</section>
<section class="bottom flex">
<db-container class="fto-involve" title="FTO投入">
<fto-invest :period="period" />
<fto-invest :period="period" :than="than" />
</db-container>
<db-container class="chip-involve" title="芯片投入" icon="chip">
<chip-invest :period="period" />
<chip-invest :period="period" :than="than" />
</db-container>
</section>
</div>
@@ -52,22 +53,40 @@ export default {
type: String,
default: "日",
},
than: {
type: String,
default: "同比",
},
},
data() {
return {};
return {
show:false,
};
},
watch: {
period: {
handler(val) {
val && this.fetchData(val);
val && this.fetchData(val,this.than);
},
immediate: true,
},
than: {
handler(val) {
console.log(val)
val && this.fetchData(this.period,val);
},
immediate: true,
},
},
methods: {
fetchData(period = "日") {
fetchData(period = "日", than) {
// this.$store.commit('copilot/clearState')
console.log(`产量驾驶舱,获取${period}数据`);
this.$store.dispatch("copilot/initCopilot", { period, source: "yield" });
this.$store.dispatch("copilot/initCopilot", { period, source: "yield", than }).then(() => {
this.$nextTick(() => {
this.show = true
})
})
},
},
};