{"remainingRequest":"D:\\jenkins\\workspace\\reform-fvue\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\jenkins\\workspace\\reform-fvue\\src\\views\\BigScreen\\components\\subComponents\\projectTable2.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\reform-fvue\\src\\views\\BigScreen\\components\\subComponents\\projectTable2.vue","mtime":1702263619964},{"path":"D:\\jenkins\\workspace\\reform-fvue\\node_modules\\babel-loader\\lib\\index.js","mtime":315532800000},{"path":"D:\\jenkins\\workspace\\reform-fvue\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\reform-fvue\\node_modules\\vue-loader\\lib\\index.js","mtime":499162500000}],"contextDependencies":[],"result":["//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n\r\nimport apiList from '@/api/bigScreen/majorView.js'\r\nexport default {\r\n props: {\r\n tableOptions: {\r\n type: Object,\r\n default: () => {\r\n return {}\r\n },\r\n },\r\n },\r\n data() {\r\n return {\r\n loading: false,\r\n loadingColor: 'rgba(6, 46, 106, 0.4)',\r\n tableData: [],\r\n sum1: 0,\r\n sum2: 0,\r\n sum3: '',\r\n sum4: 0,\r\n sum5: 0,\r\n sum6: '',\r\n sum7: 0,\r\n sum8: 0,\r\n }\r\n },\r\n beforeDestroy() {\r\n this.$bus.$off('changeDate')\r\n },\r\n mounted() {\r\n this.getData()\r\n this.$bus.$on('changeDate', (searchDate) => {\r\n this.getData()\r\n })\r\n },\r\n created() {\r\n this.$emit('searchDateChange')\r\n },\r\n methods: {\r\n getSummaries(param) {\r\n const {columns, data} = param\r\n const sums = []\r\n columns.forEach((column, index) => {\r\n if (index === 1 || index === 0 || index === 7) {\r\n sums[index] = index === 1 ? '总计' : ''\r\n return\r\n }\r\n const values = data.map((item) => Number(item[column.property]))\r\n if (!values.every((value) => isNaN(value))) {\r\n sums[index] = values.reduce((prev, curr) => {\r\n const value = Number(curr)\r\n if (!isNaN(value)) {\r\n return prev + curr\r\n } else {\r\n return prev\r\n }\r\n }, 0)\r\n }\r\n if (index === 6) {\r\n sums[index] = ((sums[3] / sums[2]) * 100).toFixed(2) + '%'\r\n }\r\n })\r\n\r\n return sums\r\n },\r\n // 跳转成果榜\r\n handleDetail(comp, title, id) {\r\n this.$router.push({\r\n path: '/DetailComponent',\r\n name: 'DetailComponent',\r\n query: {\r\n comp,\r\n // type,\r\n title,\r\n projectId: id,\r\n },\r\n })\r\n },\r\n getData() {\r\n this.loading = true\r\n let data = JSON.parse(sessionStorage.getItem('searchDate'))\r\n console.log(data)\r\n // 综合\r\n apiList.getProjectStatistics(data, (res) => {\r\n this.tableData = res.value\r\n this.sum1 = 0\r\n this.sum2 = 0\r\n this.sum3 = ''\r\n this.sum4 = 0\r\n this.sum5 = 0\r\n this.sum6 = ''\r\n this.sum7 = 0\r\n this.sum8 = 0\r\n res.value.forEach((item) => {\r\n this.sum1 += item.currentMonthTotalNum\r\n this.sum2 += item.currentMonthFinishNum\r\n this.sum4 += item.upToMonthTotalNum\r\n this.sum5 += item.upToMonthFinishNum\r\n this.sum7 += item.totalYearNum\r\n // this.sum8 += item.totalYearRate\r\n })\r\n this.sum3 = ((this.sum2 / this.sum1) * 100).toFixed(2) + '%'\r\n this.sum6 = ((this.sum5 / this.sum4) * 100).toFixed(2) + '%'\r\n this.sum8 = ((this.sum5 / this.sum7) * 100).toFixed(2) + '%'\r\n this.loading = false\r\n })\r\n },\r\n },\r\n}\r\n",null]}