mirror of
https://gitee.com/elegant_wings/dbd-meeting.git
synced 2025-06-21 17:09:36 +08:00
增加管理员工单提醒数量统计
This commit is contained in:
parent
0bacded2eb
commit
57c14a7fa6
@ -76,7 +76,8 @@ public class RepairStatsController extends BaseController {
|
||||
@RequiresPermissions(value = {"repair:manage:operator"})
|
||||
@RequestMapping("repairAdminStats")
|
||||
public R repairAdminStats() {
|
||||
RepairAdminStatsVo repairAdminStatsVo = repairWorkerStatsService.repairAdminStats();
|
||||
Long userId = getLoginStaffId();
|
||||
RepairAdminStatsVo repairAdminStatsVo = repairWorkerStatsService.repairAdminStats(userId);
|
||||
return R.ok().put("repairAdminStats", repairAdminStatsVo);
|
||||
}
|
||||
|
||||
|
@ -40,7 +40,7 @@ public interface RepairStatsMapper {
|
||||
* 第一行 管理员 工单与 通知统计
|
||||
* @return
|
||||
*/
|
||||
List<RepairAdminStatsVo> repairAdminStats();
|
||||
List<RepairAdminStatsVo> repairAdminStats(Long userId);
|
||||
|
||||
/**
|
||||
* 第二、三行 工单统计、工单完成情况、评价情况
|
||||
|
@ -38,7 +38,7 @@ public interface IRepairStatsService {
|
||||
/**
|
||||
* 第一行 管理员 工单与 通知统计
|
||||
*/
|
||||
RepairAdminStatsVo repairAdminStats();
|
||||
RepairAdminStatsVo repairAdminStats(Long userId);
|
||||
|
||||
/**
|
||||
* 第二、三行 工单统计、工单完成情况、评价情况
|
||||
|
@ -55,8 +55,8 @@ public class RepairStatsServiceImpl implements IRepairStatsService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public RepairAdminStatsVo repairAdminStats() {
|
||||
List<RepairAdminStatsVo> list = repairStatsMapper.repairAdminStats();
|
||||
public RepairAdminStatsVo repairAdminStats(Long userId) {
|
||||
List<RepairAdminStatsVo> list = repairStatsMapper.repairAdminStats(userId);
|
||||
if (list != null && list.size() > 0) return list.get(0);
|
||||
return null;
|
||||
}
|
||||
|
@ -33,9 +33,11 @@
|
||||
<!-- 第一行 管理员 工单与 通知统计 -->
|
||||
<select id="repairAdminStats" resultType="com.ics.admin.vo.RepairAdminStatsVo">
|
||||
<![CDATA[
|
||||
SELECT `wait`,`anew`,0 as newnotice,0 as oldnotice FROM
|
||||
SELECT `wait`,`anew`,newnotice,oldnotice FROM
|
||||
(SELECT count(id) as `wait` FROM ics_repair where delete_flag=0 and status=3) as A,
|
||||
(SELECT count(DISTINCT repair_id) as `anew` FROM ics_repair_log where delete_flag=0 and node_form=3) as B
|
||||
(SELECT count(DISTINCT repair_id) as `anew` FROM ics_repair_log where delete_flag=0 and node_form=3) as B,
|
||||
(select count(id) as newnotice from ics_repair_remind where `read`=0 and user_id= #{userId}) C,
|
||||
(select count(id) as oldnotice from ics_repair_remind where `read`=1 and user_id= #{userId}) D
|
||||
]]>
|
||||
</select>
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user