|
@@ -256,7 +256,7 @@ export default {
|
|
256
|
// 根据角色返回不同的出勤信息数组
|
256
|
// 根据角色返回不同的出勤信息数组
|
|
257
|
attendanceItems() {
|
257
|
attendanceItems() {
|
|
258
|
let res = {};
|
258
|
let res = {};
|
|
259
|
-
|
|
|
|
|
|
259
|
+
|
|
260
|
if (this.role.includes('kezhang') || this.isZhanZhang) {
|
260
|
if (this.role.includes('kezhang') || this.isZhanZhang) {
|
|
261
|
// 班组长选择班组视图
|
261
|
// 班组长选择班组视图
|
|
262
|
if (this.isZhanZhang) {
|
262
|
if (this.isZhanZhang) {
|
|
@@ -265,19 +265,19 @@ export default {
|
|
265
|
if (this.role.includes('kezhang')) {
|
265
|
if (this.role.includes('kezhang')) {
|
|
266
|
res = this.attendanceStats.sectionLeaderStats
|
266
|
res = this.attendanceStats.sectionLeaderStats
|
|
267
|
}
|
267
|
}
|
|
268
|
-
|
|
|
|
|
|
268
|
+
|
|
269
|
// 抽离复杂的判断逻辑
|
269
|
// 抽离复杂的判断逻辑
|
|
270
|
const isZhanZhang = this.isZhanZhang;
|
270
|
const isZhanZhang = this.isZhanZhang;
|
|
271
|
- const firstLabel = isZhanZhang ? '在岗大队' :this.isBrigade? '执勤大队' : '在岗班组';
|
|
|
|
|
|
271
|
+ const firstLabel = isZhanZhang ? '在岗大队' : this.isBrigade ? '执勤大队' : '在岗班组';
|
|
272
|
const firstValue = isZhanZhang ? res?.dutyDeptName : res?.onDutyTeamCount;
|
272
|
const firstValue = isZhanZhang ? res?.dutyDeptName : res?.onDutyTeamCount;
|
|
273
|
-
|
|
|
|
274
|
- const secondLabel = isZhanZhang||this.isBrigade ? '在岗班组' : '在岗人员';
|
|
|
|
|
|
273
|
+
|
|
|
|
274
|
+ const secondLabel = isZhanZhang || this.isBrigade ? '在岗班组' : '在岗人员';
|
|
275
|
const secondValue = isZhanZhang ? res?.onDutyTeamCount : res?.onDutyPersonnelCount;
|
275
|
const secondValue = isZhanZhang ? res?.onDutyTeamCount : res?.onDutyPersonnelCount;
|
|
276
|
-
|
|
|
|
277
|
- const thirdLabel = isZhanZhang||this.isBrigade ? '在岗人员' : '出勤时间';
|
|
|
|
|
|
276
|
+
|
|
|
|
277
|
+ const thirdLabel = isZhanZhang || this.isBrigade ? '在岗人员' : '出勤时间';
|
|
278
|
const thirdValue = isZhanZhang ? res?.onDutyPersonnelCount : (res?.attendanceTime || res?.attendanceTimeTips);
|
278
|
const thirdValue = isZhanZhang ? res?.onDutyPersonnelCount : (res?.attendanceTime || res?.attendanceTimeTips);
|
|
279
|
const thirdLink = isZhanZhang ? '' : (res?.attendanceTime ? '' : '/pages/attendance/index');
|
279
|
const thirdLink = isZhanZhang ? '' : (res?.attendanceTime ? '' : '/pages/attendance/index');
|
|
280
|
-
|
|
|
|
|
|
280
|
+
|
|
281
|
return [
|
281
|
return [
|
|
282
|
{ label: firstLabel, value: firstValue },
|
282
|
{ label: firstLabel, value: firstValue },
|
|
283
|
{ label: secondLabel, value: secondValue },
|
283
|
{ label: secondLabel, value: secondValue },
|
|
@@ -824,7 +824,7 @@ export default {
|
|
824
|
} else if (this.isTeamView) {
|
824
|
} else if (this.isTeamView) {
|
|
825
|
return '班组';
|
825
|
return '班组';
|
|
826
|
} else if (this.role.includes('kezhang')) {
|
826
|
} else if (this.role.includes('kezhang')) {
|
|
827
|
- return '全科';
|
|
|
|
|
|
827
|
+ return '主管';
|
|
828
|
} else if (this.isZhanZhang) {
|
828
|
} else if (this.isZhanZhang) {
|
|
829
|
return '全站';
|
829
|
return '全站';
|
|
830
|
} else {
|
830
|
} else {
|
|
@@ -834,14 +834,14 @@ export default {
|
|
834
|
|
834
|
|
|
835
|
// 根据角色获取巡检数据项数组
|
835
|
// 根据角色获取巡检数据项数组
|
|
836
|
getInspectionDataItems() {
|
836
|
getInspectionDataItems() {
|
|
837
|
- const { personalPassRate, teamPassRate, departmentPassRate, stationPassRate, teamRankingList, departmentRankingList } = this.inspectionData;
|
|
|
|
|
|
837
|
+ const { personalPassRate, teamPassRate, departmentPassRate, stationPassRate, teamRankingList, departmentRankingList,brigadeRankingList,brigadePassRate } = this.inspectionData;
|
|
838
|
if (this.isIndividualView) {
|
838
|
if (this.isIndividualView) {
|
|
839
|
// SecurityCheck角色:本人、班平均、主管平均、站平均
|
839
|
// SecurityCheck角色:本人、班平均、主管平均、站平均
|
|
840
|
return [
|
840
|
return [
|
|
841
|
{ label: '本人', value: ((personalPassRate || 0) * 100).toFixed(2), isImage: false },
|
841
|
{ label: '本人', value: ((personalPassRate || 0) * 100).toFixed(2), isImage: false },
|
|
842
|
{ label: '班平均', value: ((teamPassRate || 0) * 100).toFixed(2), isImage: false, color: teamPassRate < personalPassRate ? '#00AE41' : '#F96060' },
|
842
|
{ label: '班平均', value: ((teamPassRate || 0) * 100).toFixed(2), isImage: false, color: teamPassRate < personalPassRate ? '#00AE41' : '#F96060' },
|
|
843
|
{ label: '主管平均', value: ((departmentPassRate || 0) * 100).toFixed(2), isImage: false, color: departmentPassRate < personalPassRate ? '#00AE41' : '#F96060' },
|
843
|
{ label: '主管平均', value: ((departmentPassRate || 0) * 100).toFixed(2), isImage: false, color: departmentPassRate < personalPassRate ? '#00AE41' : '#F96060' },
|
|
844
|
- { label: '大队平均', value: 0, isImage: false, color: departmentPassRate < personalPassRate ? '#00AE41' : '#F96060' },
|
|
|
|
|
|
844
|
+ { label: '大队平均', value: ((brigadePassRate || 0) * 100).toFixed(2), isImage: false, color: brigadePassRate < personalPassRate ? '#00AE41' : '#F96060' },
|
|
845
|
{ label: '站平均', value: ((stationPassRate || 0) * 100).toFixed(2), isImage: false, color: stationPassRate < personalPassRate ? '#00AE41' : '#F96060' }
|
845
|
{ label: '站平均', value: ((stationPassRate || 0) * 100).toFixed(2), isImage: false, color: stationPassRate < personalPassRate ? '#00AE41' : '#F96060' }
|
|
846
|
];
|
846
|
];
|
|
847
|
} else if (this.isTeamView) {
|
847
|
} else if (this.isTeamView) {
|
|
@@ -852,19 +852,19 @@ export default {
|
|
852
|
{ label: '站平均', value: ((stationPassRate || 0) * 100).toFixed(2), isImage: false, color: stationPassRate < teamPassRate ? '#00AE41' : '#F96060' }
|
852
|
{ label: '站平均', value: ((stationPassRate || 0) * 100).toFixed(2), isImage: false, color: stationPassRate < teamPassRate ? '#00AE41' : '#F96060' }
|
|
853
|
];
|
853
|
];
|
|
854
|
} else if (this.role.includes('kezhang')) {
|
854
|
} else if (this.role.includes('kezhang')) {
|
|
855
|
- // kezhang角色:全科、站平均、前三名班组(isImage: true)
|
|
|
|
|
|
855
|
+ // kezhang角色:主管、站平均、前三名班组(isImage: true)
|
|
856
|
return [
|
856
|
return [
|
|
857
|
- { label: '全科', value: ((departmentPassRate || 0) * 100).toFixed(2), isImage: false },
|
|
|
|
|
|
857
|
+ { label: '主管', value: ((departmentPassRate || 0) * 100).toFixed(2), isImage: false },
|
|
858
|
{ label: '站平均', value: ((stationPassRate || 0) * 100).toFixed(2), isImage: false, color: stationPassRate < departmentPassRate ? '#00AE41' : '#F96060' },
|
858
|
{ label: '站平均', value: ((stationPassRate || 0) * 100).toFixed(2), isImage: false, color: stationPassRate < departmentPassRate ? '#00AE41' : '#F96060' },
|
|
859
|
{ label: this.getObjByRank(teamRankingList, 1).name, value: '/static/images/icon/one.png', isImage: true },
|
859
|
{ label: this.getObjByRank(teamRankingList, 1).name, value: '/static/images/icon/one.png', isImage: true },
|
|
860
|
{ label: this.getObjByRank(teamRankingList, 2).name, value: '/static/images/icon/two.png', isImage: true },
|
860
|
{ label: this.getObjByRank(teamRankingList, 2).name, value: '/static/images/icon/two.png', isImage: true },
|
|
861
|
{ label: this.getObjByRank(teamRankingList, 3).name, value: '/static/images/icon/three.png', isImage: true }
|
861
|
{ label: this.getObjByRank(teamRankingList, 3).name, value: '/static/images/icon/three.png', isImage: true }
|
|
862
|
];
|
862
|
];
|
|
863
|
} else if (this.isBrigade) {
|
863
|
} else if (this.isBrigade) {
|
|
864
|
- // brigade角色:全科、站平均、前三名班组(isImage: true)
|
|
|
|
|
|
864
|
+ // brigade角色:主管、站平均、前三名班组(isImage: true)
|
|
865
|
return [
|
865
|
return [
|
|
866
|
- { label: '全科', value: ((departmentPassRate || 0) * 100).toFixed(2), isImage: false },
|
|
|
|
867
|
- { label: '大队平均', value: ((stationPassRate || 0) * 100).toFixed(2), isImage: false, color: stationPassRate < departmentPassRate ? '#00AE41' : '#F96060' },
|
|
|
|
|
|
866
|
+ { label: '主管', value: ((departmentPassRate || 0) * 100).toFixed(2), isImage: false },
|
|
|
|
867
|
+ { label: '大队平均', value: ((brigadePassRate || 0) * 100).toFixed(2), isImage: false, color: brigadePassRate < departmentPassRate ? '#00AE41' : '#F96060' },
|
|
868
|
{ label: this.getObjByRank(teamRankingList, 1).name, value: '/static/images/icon/one.png', isImage: true },
|
868
|
{ label: this.getObjByRank(teamRankingList, 1).name, value: '/static/images/icon/one.png', isImage: true },
|
|
869
|
{ label: this.getObjByRank(teamRankingList, 2).name, value: '/static/images/icon/two.png', isImage: true },
|
869
|
{ label: this.getObjByRank(teamRankingList, 2).name, value: '/static/images/icon/two.png', isImage: true },
|
|
870
|
{ label: this.getObjByRank(teamRankingList, 3).name, value: '/static/images/icon/three.png', isImage: true }
|
870
|
{ label: this.getObjByRank(teamRankingList, 3).name, value: '/static/images/icon/three.png', isImage: true }
|
|
@@ -905,18 +905,18 @@ export default {
|
|
905
|
{ label: '站平均', value: (siteAvgAccuracy || 0), isImage: false, color: siteAvgAccuracy < teamAvgAccuracy ? '#00AE41' : '#F96060' }
|
905
|
{ label: '站平均', value: (siteAvgAccuracy || 0), isImage: false, color: siteAvgAccuracy < teamAvgAccuracy ? '#00AE41' : '#F96060' }
|
|
906
|
];
|
906
|
];
|
|
907
|
} else if (this.role.includes('kezhang')) {
|
907
|
} else if (this.role.includes('kezhang')) {
|
|
908
|
- // kezhang角色:全科、站平均、前三名班组(isImage: true)
|
|
|
|
|
|
908
|
+ // kezhang角色:主管、站平均、前三名班组(isImage: true)
|
|
909
|
return [
|
909
|
return [
|
|
910
|
- { label: '全科', value: (deptAvgAccuracy || 0), isImage: false, },
|
|
|
|
|
|
910
|
+ { label: '主管', value: (deptAvgAccuracy || 0), isImage: false, },
|
|
911
|
{ label: '站平均', value: (siteAvgAccuracy || 0), isImage: false, color: siteAvgAccuracy < deptAvgAccuracy ? '#00AE41' : '#F96060' },
|
911
|
{ label: '站平均', value: (siteAvgAccuracy || 0), isImage: false, color: siteAvgAccuracy < deptAvgAccuracy ? '#00AE41' : '#F96060' },
|
|
912
|
{ label: this.getObjByRank(topTeamsInDept, 1).teamName, value: '/static/images/icon/one.png', isImage: true },
|
912
|
{ label: this.getObjByRank(topTeamsInDept, 1).teamName, value: '/static/images/icon/one.png', isImage: true },
|
|
913
|
{ label: this.getObjByRank(topTeamsInDept, 2).teamName, value: '/static/images/icon/two.png', isImage: true },
|
913
|
{ label: this.getObjByRank(topTeamsInDept, 2).teamName, value: '/static/images/icon/two.png', isImage: true },
|
|
914
|
{ label: this.getObjByRank(topTeamsInDept, 3).teamName, value: '/static/images/icon/three.png', isImage: true }
|
914
|
{ label: this.getObjByRank(topTeamsInDept, 3).teamName, value: '/static/images/icon/three.png', isImage: true }
|
|
915
|
];
|
915
|
];
|
|
916
|
} else if (this.isBrigade) {
|
916
|
} else if (this.isBrigade) {
|
|
917
|
- // brigade角色:全科、站平均、前三名班组(isImage: true)
|
|
|
|
|
|
917
|
+ // brigade角色:主管、站平均、前三名班组(isImage: true)
|
|
918
|
return [
|
918
|
return [
|
|
919
|
- { label: '全科', value: (deptAvgAccuracy || 0), isImage: false, },
|
|
|
|
|
|
919
|
+ { label: '主管', value: (deptAvgAccuracy || 0), isImage: false, },
|
|
920
|
{ label: '大队平均', value: (siteAvgAccuracy || 0), isImage: false, color: siteAvgAccuracy < deptAvgAccuracy ? '#00AE41' : '#F96060' },
|
920
|
{ label: '大队平均', value: (siteAvgAccuracy || 0), isImage: false, color: siteAvgAccuracy < deptAvgAccuracy ? '#00AE41' : '#F96060' },
|
|
921
|
{ label: this.getObjByRank(topTeamsInDept, 1).teamName, value: '/static/images/icon/one.png', isImage: true },
|
921
|
{ label: this.getObjByRank(topTeamsInDept, 1).teamName, value: '/static/images/icon/one.png', isImage: true },
|
|
922
|
{ label: this.getObjByRank(topTeamsInDept, 2).teamName, value: '/static/images/icon/two.png', isImage: true },
|
922
|
{ label: this.getObjByRank(topTeamsInDept, 2).teamName, value: '/static/images/icon/two.png', isImage: true },
|
|
@@ -945,48 +945,50 @@ export default {
|
|
945
|
if (this.isIndividualView) {
|
945
|
if (this.isIndividualView) {
|
|
946
|
// SecurityCheck角色:从securityCheckerData解构
|
946
|
// SecurityCheck角色:从securityCheckerData解构
|
|
947
|
const { securityCheckerData } = this.seizeData;
|
947
|
const { securityCheckerData } = this.seizeData;
|
|
948
|
- const { selfSeizureCount, teamAverage, departmentAverage, stationAverage } = securityCheckerData || {}
|
|
|
|
|
|
948
|
+ const { selfSeizureCount, teamAverage, departmentAverage, brigadeAverage, stationAverage } = securityCheckerData || {}
|
|
949
|
|
949
|
|
|
950
|
// SecurityCheck角色:本人、班平均、主管平均、站平均
|
950
|
// SecurityCheck角色:本人、班平均、主管平均、站平均
|
|
951
|
return [
|
951
|
return [
|
|
952
|
{ label: '本人', value: selfSeizureCount || 0, isImage: false },
|
952
|
{ label: '本人', value: selfSeizureCount || 0, isImage: false },
|
|
953
|
{ label: '班平均', value: teamAverage || 0, isImage: false, color: teamAverage < selfSeizureCount ? '#00AE41' : '#F96060' },
|
953
|
{ label: '班平均', value: teamAverage || 0, isImage: false, color: teamAverage < selfSeizureCount ? '#00AE41' : '#F96060' },
|
|
954
|
{ label: '主管平均', value: departmentAverage || 0, isImage: false, color: departmentAverage < selfSeizureCount ? '#00AE41' : '#F96060' },
|
954
|
{ label: '主管平均', value: departmentAverage || 0, isImage: false, color: departmentAverage < selfSeizureCount ? '#00AE41' : '#F96060' },
|
|
955
|
- { label: '大队平均', value: 0, isImage: false, color: departmentAverage < selfSeizureCount ? '#00AE41' : '#F96060' },
|
|
|
|
|
|
955
|
+ { label: '大队平均', value: brigadeAverage || 0, isImage: false, color: brigadeAverage < selfSeizureCount ? '#00AE41' : '#F96060' },
|
|
956
|
{ label: '站平均', value: (stationAverage && stationAverage.toFixed(2)) || 0, isImage: false, color: stationAverage < selfSeizureCount ? '#00AE41' : '#F96060' }
|
956
|
{ label: '站平均', value: (stationAverage && stationAverage.toFixed(2)) || 0, isImage: false, color: stationAverage < selfSeizureCount ? '#00AE41' : '#F96060' }
|
|
957
|
];
|
957
|
];
|
|
958
|
} else if (this.isTeamView) {
|
958
|
} else if (this.isTeamView) {
|
|
959
|
// banzuzhang角色:从teamLeaderData解构
|
959
|
// banzuzhang角色:从teamLeaderData解构
|
|
960
|
const { teamLeaderData } = this.seizeData;
|
960
|
const { teamLeaderData } = this.seizeData;
|
|
961
|
- const { departmentAverage, stationAverage, teamAverage } = teamLeaderData || {};
|
|
|
|
|
|
961
|
+ const { departmentAverage, brigadeAverage, stationAverage, teamAverage } = teamLeaderData || {};
|
|
962
|
// banzuzhang角色:班组、主管平均、站平均
|
962
|
// banzuzhang角色:班组、主管平均、站平均
|
|
963
|
return [
|
963
|
return [
|
|
964
|
{ label: '班组', value: teamAverage || 0, isImage: false },
|
964
|
{ label: '班组', value: teamAverage || 0, isImage: false },
|
|
965
|
{ label: '主管平均', value: departmentAverage || 0, isImage: false, color: departmentAverage < teamAverage ? '#00AE41' : '#F96060' },
|
965
|
{ label: '主管平均', value: departmentAverage || 0, isImage: false, color: departmentAverage < teamAverage ? '#00AE41' : '#F96060' },
|
|
966
|
- { label: '大队平均', value: 0, isImage: false, color: departmentAverage < teamAverage ? '#00AE41' : '#F96060' },
|
|
|
|
|
|
966
|
+ { label: '大队平均', value: brigadeAverage || 0, isImage: false, color: brigadeAverage < teamAverage ? '#00AE41' : '#F96060' },
|
|
967
|
{ label: '站平均', value: (stationAverage && stationAverage.toFixed(2)) || 0, isImage: false, color: stationAverage < teamAverage ? '#00AE41' : '#F96060' }
|
967
|
{ label: '站平均', value: (stationAverage && stationAverage.toFixed(2)) || 0, isImage: false, color: stationAverage < teamAverage ? '#00AE41' : '#F96060' }
|
|
968
|
];
|
968
|
];
|
|
969
|
} else if (this.role.includes('kezhang')) {
|
969
|
} else if (this.role.includes('kezhang')) {
|
|
970
|
// kezhang角色:从securityCheckerData解构
|
970
|
// kezhang角色:从securityCheckerData解构
|
|
971
|
const { sectionMasterData } = this.seizeData;
|
971
|
const { sectionMasterData } = this.seizeData;
|
|
972
|
- const { stationAverage, topThreeTeams, departmentAverage } = sectionMasterData || {}
|
|
|
|
|
|
972
|
+ const { teamAverage, brigadeAverage, departmentAverage,stationAverage } = sectionMasterData || {}
|
|
973
|
|
973
|
|
|
974
|
- // kezhang角色:全科、站平均、前三名班组(isImage: true)
|
|
|
|
|
|
974
|
+ // kezhang角色:主管、站平均、前三名班组(isImage: true)
|
|
975
|
return [
|
975
|
return [
|
|
976
|
- { label: '全科', value: departmentAverage || 0, isImage: false },
|
|
|
|
977
|
- { label: '站平均', value: stationAverage?.toFixed(2) || 0, isImage: false, color: stationAverage?.toFixed(2) < departmentAverage ? '#00AE41' : '#F96060' },
|
|
|
|
978
|
- { label: this.getObjByRank(topThreeTeams, 1).teamName, value: '/static/images/icon/one.png', isImage: true },
|
|
|
|
979
|
- { label: this.getObjByRank(topThreeTeams, 2).teamName, value: '/static/images/icon/two.png', isImage: true },
|
|
|
|
980
|
- { label: this.getObjByRank(topThreeTeams, 3).teamName, value: '/static/images/icon/three.png', isImage: true }
|
|
|
|
|
|
976
|
+ { label: '主管', value: departmentAverage || 0, isImage: false },
|
|
|
|
977
|
+ { label: '主管平均', value: departmentAverage || 0, isImage: false, color: departmentAverage < teamAverage ? '#00AE41' : '#F96060' },
|
|
|
|
978
|
+ { label: '大队平均', value: brigadeAverage || 0, isImage: false, color: brigadeAverage < teamAverage ? '#00AE41' : '#F96060' },
|
|
|
|
979
|
+ { label: '站平均', value: (stationAverage && stationAverage.toFixed(2)) || 0, isImage: false, color: stationAverage < teamAverage ? '#00AE41' : '#F96060' }
|
|
|
|
980
|
+ // { label: this.getObjByRank(topThreeTeams, 1).teamName, value: '/static/images/icon/one.png', isImage: true },
|
|
|
|
981
|
+ // { label: this.getObjByRank(topThreeTeams, 2).teamName, value: '/static/images/icon/two.png', isImage: true },
|
|
|
|
982
|
+ // { label: this.getObjByRank(topThreeTeams, 3).teamName, value: '/static/images/icon/three.png', isImage: true }
|
|
981
|
];
|
983
|
];
|
|
982
|
} else if (this.isBrigade) {
|
984
|
} else if (this.isBrigade) {
|
|
983
|
// brigade角色:从securityCheckerData解构
|
985
|
// brigade角色:从securityCheckerData解构
|
|
984
|
const { sectionMasterData } = this.seizeData;
|
986
|
const { sectionMasterData } = this.seizeData;
|
|
985
|
const { stationAverage, topThreeTeams, departmentAverage } = sectionMasterData || {}
|
987
|
const { stationAverage, topThreeTeams, departmentAverage } = sectionMasterData || {}
|
|
986
|
|
988
|
|
|
987
|
- // brigade角色:全科、站平均、前三名班组(isImage: true)
|
|
|
|
|
|
989
|
+ // brigade角色:主管、站平均、前三名班组(isImage: true)
|
|
988
|
return [
|
990
|
return [
|
|
989
|
- { label: '全科', value: departmentAverage || 0, isImage: false },
|
|
|
|
|
|
991
|
+ { label: '主管', value: departmentAverage || 0, isImage: false },
|
|
990
|
{ label: '大队平均', value: stationAverage?.toFixed(2) || 0, isImage: false, color: stationAverage?.toFixed(2) < departmentAverage ? '#00AE41' : '#F96060' },
|
992
|
{ label: '大队平均', value: stationAverage?.toFixed(2) || 0, isImage: false, color: stationAverage?.toFixed(2) < departmentAverage ? '#00AE41' : '#F96060' },
|
|
991
|
{ label: this.getObjByRank(topThreeTeams, 1).teamName, value: '/static/images/icon/one.png', isImage: true },
|
993
|
{ label: this.getObjByRank(topThreeTeams, 1).teamName, value: '/static/images/icon/one.png', isImage: true },
|
|
992
|
{ label: this.getObjByRank(topThreeTeams, 2).teamName, value: '/static/images/icon/two.png', isImage: true },
|
994
|
{ label: this.getObjByRank(topThreeTeams, 2).teamName, value: '/static/images/icon/two.png', isImage: true },
|
|
@@ -1028,14 +1030,14 @@ export default {
|
|
1028
|
|
1030
|
|
|
1029
|
// 根据角色获取巡检排名列表
|
1031
|
// 根据角色获取巡检排名列表
|
|
1030
|
getRankList() {
|
1032
|
getRankList() {
|
|
1031
|
- const { teamRanking, teamTotal, departmentRanking, departmentTotal, stationRanking, stationTotal } = this.inspectionData;
|
|
|
|
|
|
1033
|
+ const { teamRanking, teamTotal, departmentRanking, departmentTotal, stationRanking, stationTotal,brigadeTotal,brigadeRanking } = this.inspectionData;
|
|
1032
|
// 根据角色返回不同的排名数据
|
1034
|
// 根据角色返回不同的排名数据
|
|
1033
|
if (this.isIndividualView) {
|
1035
|
if (this.isIndividualView) {
|
|
1034
|
// 科长、SecurityCheck角色:显示班组、科级和站级排名
|
1036
|
// 科长、SecurityCheck角色:显示班组、科级和站级排名
|
|
1035
|
return [
|
1037
|
return [
|
|
1036
|
{ label: '班组排名', current: teamRanking || 0, total: teamTotal || 0, percentage: teamTotal ? ((teamRanking || 0) / teamTotal) * 100 : 0 },
|
1038
|
{ label: '班组排名', current: teamRanking || 0, total: teamTotal || 0, percentage: teamTotal ? ((teamRanking || 0) / teamTotal) * 100 : 0 },
|
|
1037
|
{ label: '主管排名', current: departmentRanking || 0, total: departmentTotal || 0, percentage: departmentTotal ? ((departmentRanking || 0) / departmentTotal) * 100 : 0 },
|
1039
|
{ label: '主管排名', current: departmentRanking || 0, total: departmentTotal || 0, percentage: departmentTotal ? ((departmentRanking || 0) / departmentTotal) * 100 : 0 },
|
|
1038
|
- { label: '大队排名', current: departmentRanking || 0, total: departmentTotal || 0, percentage: departmentTotal ? ((departmentRanking || 0) / departmentTotal) * 100 : 0 },
|
|
|
|
|
|
1040
|
+ { label: '大队排名', current: brigadeRanking || 0, total: brigadeTotal || 0, percentage: brigadeTotal ? ((brigadeRanking || 0) / brigadeTotal) * 100 : 0 },
|
|
1039
|
{ label: '站级排名', current: stationRanking || 0, total: stationTotal || 0, percentage: stationTotal ? ((stationRanking || 0) / stationTotal) * 100 : 0, type: 'station' }
|
1041
|
{ label: '站级排名', current: stationRanking || 0, total: stationTotal || 0, percentage: stationTotal ? ((stationRanking || 0) / stationTotal) * 100 : 0, type: 'station' }
|
|
1040
|
];
|
1042
|
];
|
|
1041
|
} else if (this.role.includes('kezhang')) {
|
1043
|
} else if (this.role.includes('kezhang')) {
|
|
@@ -1100,20 +1102,20 @@ export default {
|
|
1100
|
// 根据角色返回不同的排名数据
|
1102
|
// 根据角色返回不同的排名数据
|
|
1101
|
if (this.isIndividualView) {
|
1103
|
if (this.isIndividualView) {
|
|
1102
|
const { securityCheckerData } = this.seizeData;
|
1104
|
const { securityCheckerData } = this.seizeData;
|
|
1103
|
- const { teamRanking, departmentRanking, stationRanking } = securityCheckerData || {}
|
|
|
|
|
|
1105
|
+ const { teamRanking, departmentRanking, stationRanking,brigadeRanking } = securityCheckerData || {}
|
|
1104
|
// 科长、SecurityCheck角色:显示班组、科级和站级排名
|
1106
|
// 科长、SecurityCheck角色:显示班组、科级和站级排名
|
|
1105
|
return [
|
1107
|
return [
|
|
1106
|
{ label: '班组排名', current: teamRanking?.currentRank || 0, total: teamRanking?.totalItems || 0, percentage: teamRanking?.totalItems ? ((teamRanking.currentRank || 0) / teamRanking.totalItems) * 100 : 0 },
|
1108
|
{ label: '班组排名', current: teamRanking?.currentRank || 0, total: teamRanking?.totalItems || 0, percentage: teamRanking?.totalItems ? ((teamRanking.currentRank || 0) / teamRanking.totalItems) * 100 : 0 },
|
|
1107
|
{ label: '主管排名', current: departmentRanking?.currentRank || 0, total: departmentRanking?.totalItems || 0, percentage: departmentRanking?.totalItems ? ((departmentRanking.currentRank || 0) / departmentRanking.totalItems) * 100 : 0 },
|
1109
|
{ label: '主管排名', current: departmentRanking?.currentRank || 0, total: departmentRanking?.totalItems || 0, percentage: departmentRanking?.totalItems ? ((departmentRanking.currentRank || 0) / departmentRanking.totalItems) * 100 : 0 },
|
|
1108
|
- { label: '大队排名', current: departmentRanking?.currentRank || 0, total: departmentRanking?.totalItems || 0, percentage: departmentRanking?.totalItems ? ((departmentRanking.currentRank || 0) / departmentRanking.totalItems) * 100 : 0 },
|
|
|
|
|
|
1110
|
+ { label: '大队排名', current: brigadeRanking?.currentRank || 0, total: brigadeRanking?.totalItems || 0, percentage: brigadeRanking?.totalItems ? ((brigadeRanking.currentRank || 0) / brigadeRanking.totalItems) * 100 : 0 },
|
|
1109
|
{ label: '站级排名', current: stationRanking?.currentRank || 0, total: stationRanking?.totalItems || 0, percentage: stationRanking?.totalItems ? ((stationRanking.currentRank || 0) / stationRanking.totalItems) * 100 : 0, type: 'station' }
|
1111
|
{ label: '站级排名', current: stationRanking?.currentRank || 0, total: stationRanking?.totalItems || 0, percentage: stationRanking?.totalItems ? ((stationRanking.currentRank || 0) / stationRanking.totalItems) * 100 : 0, type: 'station' }
|
|
1110
|
];
|
1112
|
];
|
|
1111
|
} else if (this.role.includes('kezhang')) {
|
1113
|
} else if (this.role.includes('kezhang')) {
|
|
1112
|
const { sectionMasterData } = this.seizeData;
|
1114
|
const { sectionMasterData } = this.seizeData;
|
|
1113
|
- const { stationRanking, departmentRanking } = sectionMasterData || {};
|
|
|
|
|
|
1115
|
+ const { stationRanking, departmentRanking,brigadeRanking } = sectionMasterData || {};
|
|
1114
|
// 科长、SecurityCheck角色:显示班组、科级和站级排名
|
1116
|
// 科长、SecurityCheck角色:显示班组、科级和站级排名
|
|
1115
|
return [
|
1117
|
return [
|
|
1116
|
- { label: '大队排名', current: departmentRanking?.currentRank || 0, total: departmentRanking?.totalItems || 0, percentage: departmentRanking?.totalItems ? ((departmentRanking.currentRank || 0) / departmentRanking.totalItems) * 100 : 0 },
|
|
|
|
|
|
1118
|
+ { label: '大队排名', current: brigadeRanking?.currentRank || 0, total: brigadeRanking?.totalItems || 0, percentage: brigadeRanking?.totalItems ? ((brigadeRanking.currentRank || 0) / brigadeRanking.totalItems) * 100 : 0 },
|
|
1117
|
{ label: '站级排名', current: stationRanking?.currentRank || 0, total: stationRanking?.totalItems || 0, percentage: stationRanking?.totalItems ? ((stationRanking.currentRank || 0) / stationRanking.totalItems) * 100 : 0, type: 'station' }
|
1119
|
{ label: '站级排名', current: stationRanking?.currentRank || 0, total: stationRanking?.totalItems || 0, percentage: stationRanking?.totalItems ? ((stationRanking.currentRank || 0) / stationRanking.totalItems) * 100 : 0, type: 'station' }
|
|
1118
|
];
|
1120
|
];
|
|
1119
|
} else if (this.isBrigade) {
|
1121
|
} else if (this.isBrigade) {
|
|
@@ -1126,11 +1128,11 @@ export default {
|
|
1126
|
];
|
1128
|
];
|
|
1127
|
} else if (this.isTeamView) {
|
1129
|
} else if (this.isTeamView) {
|
|
1128
|
const { teamLeaderData } = this.seizeData;
|
1130
|
const { teamLeaderData } = this.seizeData;
|
|
1129
|
- const { departmentRanking, stationRanking } = teamLeaderData || {}
|
|
|
|
|
|
1131
|
+ const { departmentRanking, stationRanking,brigadeRanking } = teamLeaderData || {}
|
|
1130
|
// 班组长角色:显示科级和站级排名
|
1132
|
// 班组长角色:显示科级和站级排名
|
|
1131
|
return [
|
1133
|
return [
|
|
1132
|
{ label: '主管排名', current: departmentRanking?.currentRank || 0, total: departmentRanking?.totalItems || 0, percentage: departmentRanking?.totalItems ? ((departmentRanking.currentRank || 0) / departmentRanking.totalItems) * 100 : 0 },
|
1134
|
{ label: '主管排名', current: departmentRanking?.currentRank || 0, total: departmentRanking?.totalItems || 0, percentage: departmentRanking?.totalItems ? ((departmentRanking.currentRank || 0) / departmentRanking.totalItems) * 100 : 0 },
|
|
1133
|
- { label: '大队排名', current: departmentRanking?.currentRank || 0, total: departmentRanking?.totalItems || 0, percentage: departmentRanking?.totalItems ? ((departmentRanking.currentRank || 0) / departmentRanking.totalItems) * 100 : 0 },
|
|
|
|
|
|
1135
|
+ { label: '大队排名', current: brigadeRanking?.currentRank || 0, total: brigadeRanking?.totalItems || 0, percentage: brigadeRanking?.totalItems ? ((brigadeRanking.currentRank || 0) / brigadeRanking.totalItems) * 100 : 0 },
|
|
1134
|
{ label: '站级排名', current: stationRanking?.currentRank || 0, total: stationRanking?.totalItems || 0, percentage: stationRanking?.totalItems ? ((stationRanking.currentRank || 0) / stationRanking.totalItems) * 100 : 0, type: 'station' }
|
1136
|
{ label: '站级排名', current: stationRanking?.currentRank || 0, total: stationRanking?.totalItems || 0, percentage: stationRanking?.totalItems ? ((stationRanking.currentRank || 0) / stationRanking.totalItems) * 100 : 0, type: 'station' }
|
|
1135
|
];
|
1137
|
];
|
|
1136
|
} else {
|
1138
|
} else {
|