| | |
| | | }, |
| | | series: [ |
| | | { |
| | | name: '任务数量', |
| | | name: '当日认领数量', |
| | | type: 'bar', |
| | | data: this.claimedData, |
| | | itemStyle:{ |
| | |
| | | } |
| | | }, |
| | | { |
| | | name: '已完成', |
| | | name: '当日完成数量', |
| | | type: 'bar', |
| | | data: this.completedData, |
| | | itemStyle:{ |
| | |
| | | } |
| | | }, |
| | | { |
| | | name: '未完成', |
| | | name: '累计领取未完成数量', |
| | | type: 'bar', |
| | | data: this.uncompletedData, |
| | | itemStyle:{ |
| | |
| | | }, |
| | | methods:{ |
| | | async updateData(val) { |
| | | debugger |
| | | let res = await getInspectTask(val) |
| | | if(res.data.code === '200'){ |
| | | debugger |
| | | this.claimedData = res.data.data.claimed.map(item =>{ |
| | | return item.num |
| | | }) |
| | |
| | | legend: { |
| | | left: 'center', |
| | | top: '5%', |
| | | data:['任务数量','已完成','未完成'] |
| | | data:['当日认领数量','当日完成数量','累计领取未完成数量'] |
| | | }, |
| | | xAxis: { |
| | | type: 'category', |
| | |
| | | { |
| | | data: this.claimedData, |
| | | type: 'bar', |
| | | name:'任务数量', |
| | | name:'当日认领数量', |
| | | showBackground: true, |
| | | backgroundStyle: { |
| | | color: '#91cc75' |
| | |
| | | { |
| | | data: this.completedData, |
| | | type: 'bar', |
| | | name:'已完成', |
| | | name:'当日完成数量', |
| | | showBackground: true, |
| | | backgroundStyle: { |
| | | color: '#fac858' |
| | |
| | | { |
| | | data: this.uncompletedData, |
| | | type: 'bar', |
| | | name:'未完成', |
| | | name:'累计领取未完成数量', |
| | | showBackground: true, |
| | | backgroundStyle: { |
| | | color: '#ee6666' |
| | |
| | | startTime:'', |
| | | endTime:'', |
| | | }, |
| | | taskListQuery:{ |
| | | depId:41, |
| | | startTime:'', |
| | | endTime:'', |
| | | }, |
| | | completeListQuery:{ |
| | | depId:41, |
| | | startTime:'', |
| | | endTime:'', |
| | | status:1, |
| | | }, |
| | | taskListQuery:{ |
| | | depId:41, |
| | | startTime:'', |
| | | endTime:'', |
| | | }, |
| | | stateList:[ |
| | | {id:1,name:'正常'}, |
| | |
| | | this.personListQuery.endTime = this.value1[1] |
| | | this.$refs.inspectionPerson.updateData(this.personListQuery) |
| | | this.value2 = [(newTime.getFullYear()+ '-' + ((newTime.getMonth() + 1) < 10 ? '0' + (newTime.getMonth() + 1) : (newTime.getMonth() + 1)) + '-' + '01').toString() + ' ' + '00:00:00',(newTime.getFullYear()+ '-' + ((newTime.getMonth() + 1) < 10 ? '0' + (newTime.getMonth() + 1) : (newTime.getMonth() + 1)) + '-' + newTime.getDate()).toString() + ' ' + '23:59:59'] |
| | | this.completeListQuery.startTime = this.value1[0] |
| | | this.completeListQuery.endTime = this.value1[1] |
| | | this.completeListQuery.startTime = this.value2[0] |
| | | this.completeListQuery.endTime = this.value2[1] |
| | | this.$refs.inspectionComplete.updateData(this.completeListQuery) |
| | | this.value3 = [(newTime.getFullYear()+ '-' + ((newTime.getMonth() + 1) < 10 ? '0' + (newTime.getMonth() + 1) : (newTime.getMonth() + 1)) + '-' + '01').toString() + ' ' + '00:00:00',(newTime.getFullYear()+ '-' + ((newTime.getMonth() + 1) < 10 ? '0' + (newTime.getMonth() + 1) : (newTime.getMonth() + 1)) + '-' + newTime.getDate()).toString() + ' ' + '23:59:59'] |
| | | this.taskListQuery.startTime = this.value3[0] |
| | |
| | | }, |
| | | changeTimeTask(){ |
| | | if(this.value3 !== null){ |
| | | this.taskListQuery.startTime = this.value1[0] |
| | | this.taskListQuery.endTime = this.value1[1] |
| | | this.taskListQuery.startTime = this.value3[0] |
| | | this.taskListQuery.endTime = this.value3[1] |
| | | } |
| | | this.$refs.todayUnusual.updateData(this.personListQuery) |
| | | this.$refs.todayUnusual.updateData(this.taskListQuery) |
| | | }, |
| | | changeCompleteTimeInspectionPerson() { |
| | | if(this.value2 !== null){ |
| | |
| | | this.$refs.inspectionComplete.updateData(this.completeListQuery) |
| | | }, |
| | | changeInspectionTask() { |
| | | this.$refs.todayUnusual.updateData(this.personListQuery) |
| | | this.$refs.todayUnusual.updateData(this.taskListQuery) |
| | | }, |
| | | changeInspectionPerson() { |
| | | this.$refs.inspectionPerson.updateData(this.personListQuery) |