Lijy 6 months ago
parent
commit
236b68fdaa
1 changed files with 5 additions and 5 deletions
  1. 5 5
      fhKeeper/formulahousekeeper/timesheet/src/views/project/cost.vue

+ 5 - 5
fhKeeper/formulahousekeeper/timesheet/src/views/project/cost.vue

@@ -307,9 +307,9 @@ export default {
 
             // 先将数据置空,防止数据残留
             this.echartsEcharData = [{ data: [] }]
-
+            
             // 分页数据
-            if (this.singleChoiceType != '人员') {
+            if (this.singleChoiceType != '人员' && this.departmentPersonnel != 2) {
                 this.pageTotal = this.allListData.costList ? this.allListData.costList.length : 0
                 list = this.allListData.costList && this.allListData.costList.slice(0 + 10 * (this.pageIndex - 1), 49 + 50 * (this.pageIndex - 1))
 
@@ -327,9 +327,9 @@ export default {
                 newBarChartOptions = this.projectClassificationChartData(list, totalMoneyCost, newBarChartOptions)
             } else if (this.singleChoiceType == '设备') {
                 newBarChartOptions = this.equipmentChartData(list, totalMoneyCost, newBarChartOptions)
-            } else if (this.singleChoiceType == '部门') {
+            } else if (this.singleChoiceType == '部门' && this.departmentPersonnel != 2) {
                 newBarChartOptions = this.processDepartmentalChartData(list, totalMoneyCost, newBarChartOptions)
-            } else if (this.singleChoiceType == '人员') {
+            } else if (this.singleChoiceType == '人员' || this.departmentPersonnel == 2) {
                 newBarChartOptions = this.personnelChartData(totalMoneyCost)
             } else if (this.theCustomListFlg) {
                 this.pageTotal = this.allListData.list ? this.allListData.list.length : 0
@@ -653,7 +653,7 @@ export default {
 
             totalHours = this.totalHours.toFixed(1);
             totalMoneyCost = totalMoneyCost.toFixed(2)
-
+            console.log(xList, yList, list, '<==== xList, yList,')
             return { ...this.sameChartProcessing(xList, yList, totalHours, totalMoneyCost, chartData) }
         },
         projectClassificationChartData(list, totalMoneyCost = 0, chartData) { // 处理项目分类图表数据