diff --git a/src/views/screenAdaptation/pages/adminCenter/moduleCom/oa/summaryRecord/deptLargeSummary.vue b/src/views/screenAdaptation/pages/adminCenter/moduleCom/oa/summaryRecord/deptLargeSummary.vue index 2445f85..3c05ad9 100644 --- a/src/views/screenAdaptation/pages/adminCenter/moduleCom/oa/summaryRecord/deptLargeSummary.vue +++ b/src/views/screenAdaptation/pages/adminCenter/moduleCom/oa/summaryRecord/deptLargeSummary.vue @@ -47,60 +47,85 @@ import {Spin,} from 'ant-design-vue'; import interConfig from './interConfig'; import moment from 'moment'; - export default{ + + export default { props: { - tabIndexNum: Boolean + tabIndexNum: Boolean, + selectTabIndex: Number, }, - data(){ + data() { return { begin_date: "", end_date: "", searchTime: "", totalRecordJson: {}, spinning: true, + selectTabIndexChild: 1, + } + }, + watch: { + selectTabIndex(xin, jiu) { + this.selectTabIndexChild = xin + this.getNowTime() } }, mounted() { this.getNowTime() }, methods: { - getRecordData () { + getRecordData() { let timeStr = this.searchTime; if (timeStr !== "") { let startDate = timeStr.split("|")[0]; let endDate = timeStr.split("|")[1]; - let url = ""; let param = { begin_date: moment(parseInt(startDate)).format("YYYY-MM-DD"), end_date: moment(parseInt(endDate)).format("YYYY-MM-DD"), org_id: this.BaseConfig.person_info_my.bureau_id, + dept_id: this.BaseConfig.person_info_my.dep_id, }; - let method = ""; - let isTestLogin = ""; - url = interConfig.workSummaryPersonStatistics.url; - param.person_id = this.BaseConfig.userInfo.person_id; - method = interConfig.workSummaryPersonStatistics.method; - isTestLogin = interConfig.workSummaryPersonStatistics.isTestLogin; this.InterfaceConfig.callInterface([{ - url: url, + url: interConfig.workSummaryDeptStatistics.url, params: param, - method: method, - isTestLogin: isTestLogin, + method: interConfig.workSummaryDeptStatistics.method, + isTestLogin: interConfig.workSummaryDeptStatistics.isTestLogin, }], (result) => { - this.showLoading = false; - let resData = result[0].data; - console.log('resData', resData) - if (result[0].status === 200) { - if (resData.code === 2000) { - this.spinning = false; - this.totalRecordJson = resData.data; - this.spinning = false + this.spinning = false; + // console.log('大模块部门总结-总结概览', resData) + if (result[0].data.code === 2000) { + let resData = result[0].data.data; + this.totalRecordJson = {} + if (this.selectTabIndexChild === 1) { + this.totalRecordJson.delay_day_summary = resData.delay_day_summary + this.totalRecordJson.empty_day_summary = resData.empty_day_summary + this.totalRecordJson.total_day_summary = resData.total_day_summary + this.totalRecordJson.total_day_summary = resData.total_day_summary + } else if (this.selectTabIndexChild === 2) { + this.totalRecordJson.delay_day_summary = resData.delay_week_summary + this.totalRecordJson.empty_day_summary = resData.empty_week_summary + this.totalRecordJson.total_day_summary = resData.total_week_summary + this.totalRecordJson.total_day_summary = resData.total_week_summary + } else if (this.selectTabIndexChild === 3) { + this.totalRecordJson.delay_day_summary = resData.delay_month_summary + this.totalRecordJson.empty_day_summary = resData.empty_month_summary + this.totalRecordJson.total_day_summary = resData.total_month_summary + this.totalRecordJson.total_day_summary = resData.total_month_summary + } else if (this.selectTabIndexChild === 4) { + this.totalRecordJson.delay_day_summary = resData.delay_term_summary + this.totalRecordJson.empty_day_summary = resData.empty_term_summary + this.totalRecordJson.total_day_summary = resData.total_term_summary + this.totalRecordJson.total_day_summary = resData.total_term_summary + } else if (this.selectTabIndexChild === 5) { + this.totalRecordJson.delay_day_summary = resData.delay_year_summary + this.totalRecordJson.empty_day_summary = resData.empty_year_summary + this.totalRecordJson.total_day_summary = resData.total_year_summary + this.totalRecordJson.total_day_summary = resData.total_year_summary } } }) } }, - getNowTime () { + getNowTime() { this.InterfaceConfig.callInterface([{ url: interConfig.getNowTime.url, params: {}, diff --git a/src/views/screenAdaptation/pages/adminCenter/moduleCom/oa/summaryRecord/interConfig.js b/src/views/screenAdaptation/pages/adminCenter/moduleCom/oa/summaryRecord/interConfig.js index e211895..eca8d7e 100644 --- a/src/views/screenAdaptation/pages/adminCenter/moduleCom/oa/summaryRecord/interConfig.js +++ b/src/views/screenAdaptation/pages/adminCenter/moduleCom/oa/summaryRecord/interConfig.js @@ -2,42 +2,42 @@ export default { /* * 获取服务器端系统时间 * */ - "getNowTime":{ - url:'/intellioa/common/getNowTime', - method:'get', - isTestLogin:true + "getNowTime": { + url: '/intellioa/common/getNowTime', + method: 'get', + isTestLogin: true }, /* * 个人工作总结统计 * */ - "workSummaryPersonStatistics":{ - url:'/intellioa/workSummary/workSummaryPersonStatistics', - method:'get', - isTestLogin:true + "workSummaryPersonStatistics": { + url: '/intellioa/workSummary/workSummaryPersonStatistics', + method: 'get', + isTestLogin: true }, /* * 部门工作总结统计 * */ - "workSummaryDeptStatistics":{ - url:'/intellioa/workSummary/workSummaryDeptStatistics', - method:'get', - isTestLogin:true + "workSummaryDeptStatistics": { + url: '/intellioa/workSummary/workSummaryDeptStatistics', + method: 'get', + isTestLogin: true }, /* * 机构工作总结统计 * */ - "workSummaryOrgStatistics":{ - url:'/intellioa/workSummary/workSummaryOrgStatistics', - method:'get', - isTestLogin:true + "workSummaryOrgStatistics": { + url: '/intellioa/workSummary/workSummaryOrgStatistics', + method: 'get', + isTestLogin: true }, /* * 《总结-个人》工作总结概览详情 * */ - "workSummaryInfoPersonOverview":{ - url:'/intellioa/workSummary/workSummaryInfoPersonOverview', - method:'get', - isTestLogin:true + "workSummaryInfoPersonOverview": { + url: '/intellioa/workSummary/workSummaryInfoPersonOverview', + method: 'get', + isTestLogin: true }, /* @@ -47,10 +47,10 @@ export default { * person_id: 22933 * org_id: 400195 * */ - "getWorkSummaryPersonCycleStatistics":{ - url:'/intellioa/workSummary/workSummaryPersonCycleStatistics', - method:'get', - isTestLogin:true + "getWorkSummaryPersonCycleStatistics": { + url: '/intellioa/workSummary/workSummaryPersonCycleStatistics', + method: 'get', + isTestLogin: true }, /* @@ -60,10 +60,10 @@ export default { dept_id: 400316 org_id: 400195 * */ - "getWorkSummaryDeptPersonOverview":{ - url:'/intellioa/workSummary/workSummaryDeptPersonOverview', - method:'get', - isTestLogin:true + "getWorkSummaryDeptPersonOverview": { + url: '/intellioa/workSummary/workSummaryDeptPersonOverview', + method: 'get', + isTestLogin: true }, /* @@ -72,18 +72,18 @@ export default { end_date: 2022-03-29 org_id: 400195 * */ - "getWorkSummaryOrgDeptOverview":{ - url:'/intellioa/workSummary/workSummaryOrgDeptOverview', - method:'get', - isTestLogin:true + "getWorkSummaryOrgDeptOverview": { + url: '/intellioa/workSummary/workSummaryOrgDeptOverview', + method: 'get', + isTestLogin: true }, /* * 个人工作总结概览 * */ - "listSuperfusionPersonalWorkSummaryReport":{ - url:'/intellioa/workPlan/listSuperfusionPersonalWorkSummaryReport', - method:'get', - isTestLogin:true + "listSuperfusionPersonalWorkSummaryReport": { + url: '/intellioa/workPlan/listSuperfusionPersonalWorkSummaryReport', + method: 'get', + isTestLogin: true }, } diff --git a/src/views/screenAdaptation/pages/adminCenter/moduleCom/oa/summaryRecord/largeSummaryTable.vue b/src/views/screenAdaptation/pages/adminCenter/moduleCom/oa/summaryRecord/largeSummaryTable.vue index a3fb8e0..ba3512e 100644 --- a/src/views/screenAdaptation/pages/adminCenter/moduleCom/oa/summaryRecord/largeSummaryTable.vue +++ b/src/views/screenAdaptation/pages/adminCenter/moduleCom/oa/summaryRecord/largeSummaryTable.vue @@ -1,22 +1,22 @@