update code

prv
haha 2024-04-08 01:54:38 +08:00
parent 5a81054d06
commit 1b4bde84fe
5 changed files with 17 additions and 14 deletions

View File

@ -46,7 +46,14 @@
<div class="glr-login-number analyse-login-numbe"> <div class="glr-login-number analyse-login-numbe">
<div><img src="images/text_red_spot.png" />{{ item.name }}</div> <div><img src="images/text_red_spot.png" />{{ item.name }}</div>
<div class="glr-rate-value glr-rate-red-value"> <div class="glr-rate-value glr-rate-red-value">
<span>{{ item.data }}/{{ item.total }}</span> <template v-if="idx==0">
<span style="color: #c0dafb">{{ item.total }}</span>
</template>
<template v-else>
<span>{{ item.data }}</span>/
<span style="color: #c0dafb">{{item.total }}</span>
</template>
</div> </div>
</div> </div>
</div> </div>

View File

@ -495,6 +495,7 @@ export default {
this.elKey++; this.elKey++;
this.onWarningInfoNav(0); this.onWarningInfoNav(0);
this.sumCostOutByDeptId(); this.sumCostOutByDeptId();
this.groupByProjectCategory(this.deptInfo.id);
})); }));
this.$bus.$on("deptChange", debounce(dept => { this.$bus.$on("deptChange", debounce(dept => {
@ -603,12 +604,6 @@ export default {
} else { } else {
postData.id = this.deptInfo.id; postData.id = this.deptInfo.id;
} }
if (this.callSumCostTime) {
if (+new Date() - this.callSumCostTime < 400) {
return;
}
}
this.callSumCostTime = +new Date();
this.$api.costOut.sumByDeptId(postData).then(d => { this.$api.costOut.sumByDeptId(postData).then(d => {
this.sumCost = d; this.sumCost = d;
}); });

View File

@ -889,6 +889,7 @@ export default {
} }
if (this.project.id == 0) { if (this.project.id == 0) {
if (this.prjs.length > 1) { if (this.prjs.length > 1) {
return this.prjs[1]; return this.prjs[1];
} }
return {}; return {};
@ -992,7 +993,7 @@ export default {
this.$api.costOut.selectYearAndMonth({ this.$api.costOut.selectYearAndMonth({
projectId: id, projectId: id,
year: dt.$y, year: dt.$y,
month: dt.$M month: dt.$M+1
}).then(d => { }).then(d => {
d.totalMonth = d.totalMonth.toFixed(2); d.totalMonth = d.totalMonth.toFixed(2);
d.totalYear = d.totalYear.toFixed(2); d.totalYear = d.totalYear.toFixed(2);

View File

@ -38,8 +38,8 @@ module.exports = defineConfig({
}, },
'/jhapi':{ '/jhapi':{
//target: `http://62.234.3.186/jhapi/`, //target: `http://62.234.3.186/jhapi/`,
//target: `http://127.0.0.1:8090/jhapi/`, target: `http://127.0.0.1:8090/jhapi/`,
target: `http://szgc.jhncidg.com/jhapi/`, //target: `http://szgc.jhncidg.com/jhapi/`,
changeOrigin: true, changeOrigin: true,
pathRewrite: { pathRewrite: {
'^/jhapi':'/' '^/jhapi':'/'