From 9cfd18f1e6ebfeb94030e3a907cd5e79e51a0780 Mon Sep 17 00:00:00 2001
From: CeDo <cedoogle@gmail.com>
Date: 星期六, 05 六月 2021 21:40:15 +0800
Subject: [PATCH] bugfixed

---
 springcloud_k8s_panzhihuazhihuishequ/service_grid/src/main/java/com/panzhihua/service_grid/service/impl/EventServiceImpl.java |   26 ++++++++++++++++++++++++--
 1 files changed, 24 insertions(+), 2 deletions(-)

diff --git a/springcloud_k8s_panzhihuazhihuishequ/service_grid/src/main/java/com/panzhihua/service_grid/service/impl/EventServiceImpl.java b/springcloud_k8s_panzhihuazhihuishequ/service_grid/src/main/java/com/panzhihua/service_grid/service/impl/EventServiceImpl.java
index 6cddbb5..d927b3f 100644
--- a/springcloud_k8s_panzhihuazhihuishequ/service_grid/src/main/java/com/panzhihua/service_grid/service/impl/EventServiceImpl.java
+++ b/springcloud_k8s_panzhihuazhihuishequ/service_grid/src/main/java/com/panzhihua/service_grid/service/impl/EventServiceImpl.java
@@ -52,6 +52,8 @@
     private CommunityService communityService;
     @Resource
     private EventGridDataMapper eventGridDataMapper;
+    @Resource
+    private EventGridMemberRelationMapper eventGridMemberRelationMapper;
 
     /**
      * 分页查找事件
@@ -636,7 +638,8 @@
         if(updated!=1){
             return R.fail("更新事件状态失败");
         }
-        addTransferRecord(eventDO.getId(), commonEventVerifyDTO.getUserId(), commonEventVerifyDTO.getUserName(), 1, commonEventVerifyDTO.getProcessResult(), 6);
+        addTransferRecord(eventDO.getId(), commonEventVerifyDTO.getUserId(), commonEventVerifyDTO.getUserName(), 1, commonEventVerifyDTO.getProcessResult(),
+                commonEventVerifyDTO.getUserId(), commonEventVerifyDTO.getUserName(), 6);
         return R.ok();
     }
 
@@ -1443,7 +1446,7 @@
         eventTransferRecordDO.setProcessDate(new Date());
         eventTransferRecordDO.setEventId(eventId);
         eventTransferRecordDO.setProcessResult("发布成功");
-        eventTransferRecordDO.setProcessType(1);//初始状态
+        eventTransferRecordDO.setProcessType(0);//初始状态
         int inserted = eventTransferRecordService.getBaseMapper().insert(eventTransferRecordDO);
         if(inserted!=1){
             throw new ServiceException("事件流转记录添加失败");
@@ -1578,4 +1581,23 @@
         }
         return -1;
     }
+
+    /**
+     * 后台管理-统计模块
+     * @param communityId   社区id
+     * @return  统计信息
+     */
+    @Override
+    public R eventStatistics(Long communityId){
+        return R.ok(this.baseMapper.eventStatistics(communityId));
+    }
+    /**
+     * 后台管理-网格员统计
+     * @param statisticsAdminDTO    请求参数
+     * @return  网格员统计信息
+     */
+    @Override
+    public R gridMemberStatistics(MemberStatisticsAdminDTO statisticsAdminDTO){
+        return R.ok(eventGridMemberRelationMapper.gridMemberStatistics(new Page(statisticsAdminDTO.getPageNum(),statisticsAdminDTO.getPageSize()),statisticsAdminDTO));
+    }
 }

--
Gitblit v1.7.1