+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see .
+ */
+
+package com.elink.esua.epdc.dto;
+
+import java.io.Serializable;
+import java.util.Date;
+import lombok.Data;
+
+
+/**
+ * 角色菜单关系
+ *
+ * @author elink elink@elink-cn.com
+ * @since v1.0.0 2020-03-25
+ */
+@Data
+public class SysAnalysisRoleMenuDTO implements Serializable {
+
+ private static final long serialVersionUID = 1L;
+
+ /**
+ * id
+ */
+ private Long id;
+
+ /**
+ * 角色ID
+ */
+ private Long roleId;
+
+ /**
+ * 菜单ID
+ */
+ private Long menuId;
+
+ /**
+ * 创建者
+ */
+ private Long creator;
+
+ /**
+ * 创建时间
+ */
+ private Date createDate;
+
+}
\ No newline at end of file
diff --git a/esua-epdc/epdc-admin/epdc-admin-client/src/main/java/com/elink/esua/epdc/dto/SysRoleDTO.java b/esua-epdc/epdc-admin/epdc-admin-client/src/main/java/com/elink/esua/epdc/dto/SysRoleDTO.java
index 2f234a40..c73087fc 100644
--- a/esua-epdc/epdc-admin/epdc-admin-client/src/main/java/com/elink/esua/epdc/dto/SysRoleDTO.java
+++ b/esua-epdc/epdc-admin/epdc-admin-client/src/main/java/com/elink/esua/epdc/dto/SysRoleDTO.java
@@ -77,6 +77,10 @@ public class SysRoleDTO implements Serializable {
* 项目处理类型授权id列表
*/
private List categoryIdList;
+ /**
+ * 数据端菜单ID列表
+ */
+ private List analysisMenuIdList;
/**
* 吹哨部门id列表
diff --git a/esua-epdc/epdc-admin/epdc-admin-client/src/main/java/com/elink/esua/epdc/enums/MenuTableEnum.java b/esua-epdc/epdc-admin/epdc-admin-client/src/main/java/com/elink/esua/epdc/enums/MenuTableEnum.java
index 6a1b5304..5874ba30 100644
--- a/esua-epdc/epdc-admin/epdc-admin-client/src/main/java/com/elink/esua/epdc/enums/MenuTableEnum.java
+++ b/esua-epdc/epdc-admin/epdc-admin-client/src/main/java/com/elink/esua/epdc/enums/MenuTableEnum.java
@@ -22,7 +22,11 @@ public enum MenuTableEnum {
/**
* 非菜单资源
*/
- APP("sys_app_menu");
+ APP("sys_app_menu"),
+ /**
+ * 领导端资源
+ */
+ ANALYSIS("sys_analysis_menu");
private String value;
diff --git a/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/controller/AppMenuController.java b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/controller/AppMenuController.java
index 12a19cac..5bc38d2a 100644
--- a/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/controller/AppMenuController.java
+++ b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/controller/AppMenuController.java
@@ -27,6 +27,7 @@ import com.elink.esua.epdc.commons.tools.validator.group.AddGroup;
import com.elink.esua.epdc.commons.tools.validator.group.DefaultGroup;
import com.elink.esua.epdc.commons.tools.validator.group.UpdateGroup;
import com.elink.esua.epdc.dto.AppMenuDTO;
+import com.elink.esua.epdc.dto.epdc.result.EpdcAppChildNavResultDTO;
import com.elink.esua.epdc.dto.epdc.result.EpdcAppIndexPanelResultDTO;
import com.elink.esua.epdc.excel.AppMenuExcel;
import com.elink.esua.epdc.service.AppMenuService;
@@ -126,4 +127,15 @@ public class AppMenuController {
public Result> indexPanel(@PathVariable("mobile") String mobile) {
return appMenuService.indexPanel(mobile);
}
+ /**
+ * @param userId
+ * @return com.elink.esua.epdc.commons.tools.utils.Result>
+ * @Author lpf
+ * @Description 首页面板 获取数据端APP菜单
+ * @Date 2020/03/18 10:42
+ **/
+ @GetMapping("/analysisIndexPanel/{userId}")
+ public Result> analysisIndexPanel(@PathVariable("userId") String userId) {
+ return appMenuService.getAnalysisIndexPanel(userId);
+ }
}
diff --git a/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/controller/SysAnalysisMenuController.java b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/controller/SysAnalysisMenuController.java
new file mode 100644
index 00000000..04ee8c90
--- /dev/null
+++ b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/controller/SysAnalysisMenuController.java
@@ -0,0 +1,132 @@
+/**
+ * Copyright 2018 人人开源 https://www.renren.io
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see .
+ */
+
+package com.elink.esua.epdc.controller;
+
+import com.elink.esua.epdc.commons.tools.exception.ErrorCode;
+import com.elink.esua.epdc.commons.tools.page.PageData;
+import com.elink.esua.epdc.commons.tools.security.user.UserDetail;
+import com.elink.esua.epdc.commons.tools.utils.ExcelUtils;
+import com.elink.esua.epdc.commons.tools.utils.Result;
+import com.elink.esua.epdc.commons.tools.validator.AssertUtils;
+import com.elink.esua.epdc.commons.tools.validator.ValidatorUtils;
+import com.elink.esua.epdc.commons.tools.validator.group.AddGroup;
+import com.elink.esua.epdc.commons.tools.validator.group.UpdateGroup;
+import com.elink.esua.epdc.commons.tools.validator.group.DefaultGroup;
+import com.elink.esua.epdc.dto.*;
+import com.elink.esua.epdc.dto.epdc.result.EpdcAppChildNavResultDTO;
+import com.elink.esua.epdc.excel.*;
+import com.elink.esua.epdc.service.SysAnalysisMenuService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+
+import javax.servlet.http.HttpServletResponse;
+import java.util.List;
+import java.util.Map;
+
+
+/**
+ * 菜单管理
+ *
+ * @author elink elink@elink-cn.com
+ * @since v1.0.0 2020-03-25
+ */
+@RestController
+@RequestMapping("analysismenu")
+public class SysAnalysisMenuController {
+
+ @Autowired
+ private SysAnalysisMenuService sysAnalysisMenuService;
+
+ /**
+ * 获取APP菜单列表
+ *
+ * @param type 菜单类型 0:菜单 1:按钮 null:全部
+ * @return com.elink.esua.epdc.commons.tools.utils.Result>
+ * @author work@yujt.net.cn
+ * @date 2019/11/19 13:26
+ */
+ @GetMapping("list")
+ public Result> list(Integer type) {
+ List list = sysAnalysisMenuService.getAnalysisMenuList(type);
+ return new Result>().ok(list);
+ }
+
+ @GetMapping("page")
+ public Result> page(@RequestParam Map params){
+ PageData page = sysAnalysisMenuService.page(params);
+ return new Result>().ok(page);
+ }
+
+ @GetMapping("{id}")
+ public Result get(@PathVariable("id") String id){
+ SysAnalysisMenuDTO data = sysAnalysisMenuService.get(id);
+ return new Result().ok(data);
+ }
+
+ @PostMapping
+ public Result save(@RequestBody SysAnalysisMenuDTO dto){
+ //效验数据
+ ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class);
+ sysAnalysisMenuService.save(dto);
+ return new Result();
+ }
+ @GetMapping("select")
+ public Result> select(UserDetail userDetail) {
+ List list = sysAnalysisMenuService.getUserMenuList(userDetail, null);
+
+ return new Result>().ok(list);
+ }
+
+ @PutMapping
+ public Result update(@RequestBody SysAnalysisMenuDTO dto){
+ //效验数据
+ ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class);
+ sysAnalysisMenuService.update(dto);
+ return new Result();
+ }
+
+ @DeleteMapping("{id}")
+ public Result delete(@PathVariable("id") Long id){
+ //效验数据
+ AssertUtils.isNull(id, "id");
+ //判断是否有子菜单或按钮
+ if(sysAnalysisMenuService.hasChileMenu(id)){
+ return new Result().error(ErrorCode.SUB_MENU_EXIST);
+ }
+ sysAnalysisMenuService.delete(id);
+ return new Result();
+ }
+
+ @GetMapping("export")
+ public void export(@RequestParam Map params, HttpServletResponse response) throws Exception {
+ List list = sysAnalysisMenuService.list(params);
+ ExcelUtils.exportExcelToTarget(response, null, list, SysAnalysisMenuExcel.class);
+ }
+ /**
+ * @param userId
+ * @return com.elink.esua.epdc.commons.tools.utils.Result>
+ * @Author lpf
+ * @Description 首页面板 获取数据端APP菜单
+ * @Date 2020/03/18 10:42
+ **/
+ @GetMapping("/analysisIndexPanel/{userId}")
+ public Result> analysisIndexPanel(@PathVariable("userId") String userId) {
+ return sysAnalysisMenuService.getAnalysisIndexPanel(userId);
+ }
+
+}
\ No newline at end of file
diff --git a/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/controller/SysAnalysisRoleMenuController.java b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/controller/SysAnalysisRoleMenuController.java
new file mode 100644
index 00000000..65deebc6
--- /dev/null
+++ b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/controller/SysAnalysisRoleMenuController.java
@@ -0,0 +1,94 @@
+/**
+ * Copyright 2018 人人开源 https://www.renren.io
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see .
+ */
+
+package com.elink.esua.epdc.controller;
+
+import com.elink.esua.epdc.commons.tools.page.PageData;
+import com.elink.esua.epdc.commons.tools.utils.ExcelUtils;
+import com.elink.esua.epdc.commons.tools.utils.Result;
+import com.elink.esua.epdc.commons.tools.validator.AssertUtils;
+import com.elink.esua.epdc.commons.tools.validator.ValidatorUtils;
+import com.elink.esua.epdc.commons.tools.validator.group.AddGroup;
+import com.elink.esua.epdc.commons.tools.validator.group.UpdateGroup;
+import com.elink.esua.epdc.commons.tools.validator.group.DefaultGroup;
+import com.elink.esua.epdc.dto.*;
+import com.elink.esua.epdc.excel.*;
+import com.elink.esua.epdc.service.SysAnalysisRoleMenuService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+
+import javax.servlet.http.HttpServletResponse;
+import java.util.List;
+import java.util.Map;
+
+
+/**
+ * 角色菜单关系
+ *
+ * @author elink elink@elink-cn.com
+ * @since v1.0.0 2020-03-25
+ */
+@RestController
+@RequestMapping("analysisrolemenu")
+public class SysAnalysisRoleMenuController {
+
+ @Autowired
+ private SysAnalysisRoleMenuService sysAnalysisRoleMenuService;
+
+ @GetMapping("page")
+ public Result> page(@RequestParam Map params){
+ PageData page = sysAnalysisRoleMenuService.page(params);
+ return new Result>().ok(page);
+ }
+
+ @GetMapping("{id}")
+ public Result get(@PathVariable("id") String id){
+ SysAnalysisRoleMenuDTO data = sysAnalysisRoleMenuService.get(id);
+ return new Result().ok(data);
+ }
+
+ @PostMapping
+ public Result save(@RequestBody SysAnalysisRoleMenuDTO dto){
+ //效验数据
+ ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class);
+ sysAnalysisRoleMenuService.save(dto);
+ return new Result();
+ }
+
+ @PutMapping
+ public Result update(@RequestBody SysAnalysisRoleMenuDTO dto){
+ //效验数据
+ ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class);
+ sysAnalysisRoleMenuService.update(dto);
+ return new Result();
+ }
+
+ @DeleteMapping
+ public Result delete(@RequestBody String[] ids){
+ //效验数据
+ AssertUtils.isArrayEmpty(ids, "id");
+ sysAnalysisRoleMenuService.delete(ids);
+ return new Result();
+ }
+
+ @GetMapping("export")
+ public void export(@RequestParam Map params, HttpServletResponse response) throws Exception {
+ List list = sysAnalysisRoleMenuService.list(params);
+ ExcelUtils.exportExcelToTarget(response, null, list, SysAnalysisRoleMenuExcel.class);
+ }
+
+}
\ No newline at end of file
diff --git a/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/controller/SysRoleController.java b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/controller/SysRoleController.java
index 3845c6a8..7898ee1f 100644
--- a/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/controller/SysRoleController.java
+++ b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/controller/SysRoleController.java
@@ -52,6 +52,8 @@ public class SysRoleController {
private SysRoleDataScopeService sysRoleDataScopeService;
@Autowired
private AppRoleMenuService appRoleMenuService;
+ @Autowired
+ private SysAnalysisRoleMenuService sysAnalysisRoleMenuService;
@GetMapping("page")
@ApiOperation("分页")
@@ -93,6 +95,10 @@ public class SysRoleController {
List appMenuIdList = appRoleMenuService.getAppMenuIdList(id);
data.setAppMenuIdList(appMenuIdList);
+ //查询角色对应数据端菜单权限
+ List analysisMenuIdList = sysAnalysisRoleMenuService.getAnalysisMenuIdList(id);
+ data.setAnalysisMenuIdList(analysisMenuIdList);
+
//查询角色对应的项目处理类型权限
List categoryIdList = sysRoleService.getCategoryIdList(id);
data.setCategoryIdList(categoryIdList);
diff --git a/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/dao/AppMenuDao.java b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/dao/AppMenuDao.java
index 8154f25e..4a748f12 100644
--- a/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/dao/AppMenuDao.java
+++ b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/dao/AppMenuDao.java
@@ -19,6 +19,7 @@ package com.elink.esua.epdc.dao;
import com.elink.esua.epdc.commons.mybatis.dao.BaseDao;
import com.elink.esua.epdc.dto.AppMenuDTO;
+import com.elink.esua.epdc.dto.epdc.result.EpdcAppChildNavResultDTO;
import com.elink.esua.epdc.dto.epdc.result.EpdcAppIndexPanelResultDTO;
import com.elink.esua.epdc.entity.AppMenuEntity;
import org.apache.ibatis.annotations.Mapper;
@@ -78,4 +79,13 @@ public interface AppMenuDao extends BaseDao {
* @Date 2019/11/20 11:10
**/
List indexPanelByMobile(String mobile);
+
+ /**
+ * @param userId
+ * @return com.elink.esua.epdc.commons.tools.utils.Result>
+ * @Author lpf
+ * @Description 首页面板 获取数据端APP菜单
+ * @Date 2020/03/18 10:42
+ **/
+ List getAnalysisIndexPanel(String userId);
}
diff --git a/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/dao/SysAnalysisMenuDao.java b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/dao/SysAnalysisMenuDao.java
new file mode 100644
index 00000000..e0c83b87
--- /dev/null
+++ b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/dao/SysAnalysisMenuDao.java
@@ -0,0 +1,84 @@
+/**
+ * Copyright 2018 人人开源 https://www.renren.io
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see .
+ */
+
+package com.elink.esua.epdc.dao;
+
+import com.elink.esua.epdc.commons.mybatis.dao.BaseDao;
+import com.elink.esua.epdc.dto.AppMenuDTO;
+import com.elink.esua.epdc.dto.SysAnalysisMenuDTO;
+import com.elink.esua.epdc.dto.epdc.result.EpdcAppChildNavResultDTO;
+import com.elink.esua.epdc.entity.AppMenuEntity;
+import com.elink.esua.epdc.entity.SysAnalysisMenuEntity;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
+
+/**
+ * 菜单管理
+ *
+ * @author elink elink@elink-cn.com
+ * @since v1.0.0 2020-03-25
+ */
+@Mapper
+public interface SysAnalysisMenuDao extends BaseDao {
+
+ /**
+ * @param userId
+ * @return com.elink.esua.epdc.commons.tools.utils.Result>
+ * @Author lpf
+ * @Description 首页面板 获取数据端APP菜单
+ * @Date 2020/03/18 10:42
+ **/
+ List getAnalysisIndexPanel(String userId);
+
+ /**
+ * 获取菜单详细信息
+ * @param id
+ * @return
+ */
+ SysAnalysisMenuDTO selectByIdDIY(@Param("id") String id, @Param("language") String language);
+
+ /**
+ * 查询所有菜单列表
+ *
+ * @param type 菜单类型
+ * @param language 语言
+ */
+ List getMenuList(@Param("type") Integer type, @Param("language") String language);
+
+ /**
+ * 查询用户菜单列表
+ *
+ * @param userId 用户ID
+ * @param type 菜单类型
+ * @param language 语言
+ */
+ List getUserMenuList(@Param("userId") Long userId, @Param("type") Integer type, @Param("language") String language);
+
+ /**
+ * 获取app菜单列表
+ *
+ * @param type 菜单类型
+ * @param language 语言
+ * @return java.util.List
+ * @author work@yujt.net.cn
+ * @date 2019/11/19 13:43
+ */
+ List selectListAppMenu(@Param("type") Integer type, @Param("language") String language);
+
+}
\ No newline at end of file
diff --git a/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/dao/SysAnalysisRoleMenuDao.java b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/dao/SysAnalysisRoleMenuDao.java
new file mode 100644
index 00000000..e817fc77
--- /dev/null
+++ b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/dao/SysAnalysisRoleMenuDao.java
@@ -0,0 +1,50 @@
+/**
+ * Copyright 2018 人人开源 https://www.renren.io
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see .
+ */
+
+package com.elink.esua.epdc.dao;
+
+import com.elink.esua.epdc.commons.mybatis.dao.BaseDao;
+import com.elink.esua.epdc.entity.SysAnalysisRoleMenuEntity;
+import org.apache.ibatis.annotations.Mapper;
+
+import java.util.List;
+
+/**
+ * 角色菜单关系
+ *
+ * @author elink elink@elink-cn.com
+ * @since v1.0.0 2020-03-25
+ */
+@Mapper
+public interface SysAnalysisRoleMenuDao extends BaseDao {
+
+ /**
+ * 根据角色id,删除角色数据权限关系
+ *
+ * @param roleId 角色id
+ */
+ void deleteByRoleId(Long roleId);
+
+ /**
+ * 根据角色ID,获取菜单ID列表
+ *
+ * @param id
+ * @return
+ */
+ List getAnalysisMenuIdList(Long id);
+
+}
\ No newline at end of file
diff --git a/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/entity/SysAnalysisMenuEntity.java b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/entity/SysAnalysisMenuEntity.java
new file mode 100644
index 00000000..ac45ced4
--- /dev/null
+++ b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/entity/SysAnalysisMenuEntity.java
@@ -0,0 +1,120 @@
+/**
+ * Copyright 2018 人人开源 https://www.renren.io
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see .
+ */
+
+package com.elink.esua.epdc.entity;
+
+import com.baomidou.mybatisplus.annotation.TableName;
+
+import com.elink.esua.epdc.commons.mybatis.entity.BaseEntity;
+import com.elink.esua.epdc.commons.mybatis.entity.BaseEpdcEntity;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+import java.util.Date;
+
+/**
+ * 角色菜单关系
+ *
+ * @author elink elink@elink-cn.com
+ * @since v1.0.0 2020-03-25
+ */
+@Data
+@EqualsAndHashCode(callSuper=false)
+@TableName("sys_analysis_role_menu")
+public class SysAnalysisRoleMenuEntity extends BaseEntity {
+
+ private static final long serialVersionUID = 1L;
+
+
+ /**
+ * 角色ID
+ */
+ private Long roleId;
+
+ /**
+ * 菜单ID
+ */
+ private Long menuId;
+
+ /**
+ * 创建者
+ */
+ private Long creator;
+
+ /**
+ * 创建时间
+ */
+ private Date createDate;
+
+}
\ No newline at end of file
diff --git a/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/excel/SysAnalysisMenuExcel.java b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/excel/SysAnalysisMenuExcel.java
new file mode 100644
index 00000000..9e2c7baa
--- /dev/null
+++ b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/excel/SysAnalysisMenuExcel.java
@@ -0,0 +1,83 @@
+/**
+ * Copyright 2018 人人开源 https://www.renren.io
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see .
+ */
+
+package com.elink.esua.epdc.excel;
+
+import cn.afterturn.easypoi.excel.annotation.Excel;
+import lombok.Data;
+
+import java.util.Date;
+
+/**
+ * 菜单管理
+ *
+ * @author elink elink@elink-cn.com
+ * @since v1.0.0 2020-03-25
+ */
+@Data
+public class SysAnalysisMenuExcel {
+
+ @Excel(name = "id")
+ private Long id;
+
+ @Excel(name = "上级ID,一级菜单为0")
+ private Long pid;
+
+ @Excel(name = "类型 0:菜单 1:按钮")
+ private Integer type;
+
+ @Excel(name = "模块名称")
+ private String modelname;
+
+ @Excel(name = "菜单图标")
+ private String icon;
+
+ @Excel(name = "样式名称")
+ private String className;
+
+ @Excel(name = "菜单编码(议题管理-待回应:10001,议题管理-待处理:10002,项目管理-待处理:10003,用户管理-待认证居民:10004,消息:10005)")
+ private String menuCode;
+
+ @Excel(name = "模板ID")
+ private String templateId;
+
+ @Excel(name = "是否显示数字 0否 1是")
+ private String numFlag;
+
+ @Excel(name = "排序")
+ private Integer sort;
+
+ @Excel(name = "备注")
+ private String remark;
+
+ @Excel(name = "删除标识 0:未删除 1:删除")
+ private Integer delFlag;
+
+ @Excel(name = "创建者")
+ private Long creator;
+
+ @Excel(name = "创建时间")
+ private Date createDate;
+
+ @Excel(name = "更新者")
+ private Long updater;
+
+ @Excel(name = "更新时间")
+ private Date updateDate;
+
+
+}
\ No newline at end of file
diff --git a/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/excel/SysAnalysisRoleMenuExcel.java b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/excel/SysAnalysisRoleMenuExcel.java
new file mode 100644
index 00000000..629ac017
--- /dev/null
+++ b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/excel/SysAnalysisRoleMenuExcel.java
@@ -0,0 +1,50 @@
+/**
+ * Copyright 2018 人人开源 https://www.renren.io
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see .
+ */
+
+package com.elink.esua.epdc.excel;
+
+import cn.afterturn.easypoi.excel.annotation.Excel;
+import lombok.Data;
+
+import java.util.Date;
+
+/**
+ * 角色菜单关系
+ *
+ * @author elink elink@elink-cn.com
+ * @since v1.0.0 2020-03-25
+ */
+@Data
+public class SysAnalysisRoleMenuExcel {
+
+ @Excel(name = "id")
+ private Long id;
+
+ @Excel(name = "角色ID")
+ private Long roleId;
+
+ @Excel(name = "菜单ID")
+ private Long menuId;
+
+ @Excel(name = "创建者")
+ private Long creator;
+
+ @Excel(name = "创建时间")
+ private Date createDate;
+
+
+}
\ No newline at end of file
diff --git a/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/redis/SysAnalysisMenuRedis.java b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/redis/SysAnalysisMenuRedis.java
new file mode 100644
index 00000000..3349f7c1
--- /dev/null
+++ b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/redis/SysAnalysisMenuRedis.java
@@ -0,0 +1,47 @@
+/**
+ * Copyright 2018 人人开源 https://www.renren.io
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see .
+ */
+
+package com.elink.esua.epdc.redis;
+
+import com.elink.esua.epdc.commons.tools.redis.RedisUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Component;
+
+/**
+ * 菜单管理
+ *
+ * @author elink elink@elink-cn.com
+ * @since v1.0.0 2020-03-25
+ */
+@Component
+public class SysAnalysisMenuRedis {
+ @Autowired
+ private RedisUtils redisUtils;
+
+ public void delete(Object[] ids) {
+
+ }
+
+ public void set(){
+
+ }
+
+ public String get(String id){
+ return null;
+ }
+
+}
\ No newline at end of file
diff --git a/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/redis/SysAnalysisRoleMenuRedis.java b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/redis/SysAnalysisRoleMenuRedis.java
new file mode 100644
index 00000000..f660239d
--- /dev/null
+++ b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/redis/SysAnalysisRoleMenuRedis.java
@@ -0,0 +1,47 @@
+/**
+ * Copyright 2018 人人开源 https://www.renren.io
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see .
+ */
+
+package com.elink.esua.epdc.redis;
+
+import com.elink.esua.epdc.commons.tools.redis.RedisUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Component;
+
+/**
+ * 角色菜单关系
+ *
+ * @author elink elink@elink-cn.com
+ * @since v1.0.0 2020-03-25
+ */
+@Component
+public class SysAnalysisRoleMenuRedis {
+ @Autowired
+ private RedisUtils redisUtils;
+
+ public void delete(Object[] ids) {
+
+ }
+
+ public void set(){
+
+ }
+
+ public String get(String id){
+ return null;
+ }
+
+}
\ No newline at end of file
diff --git a/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/service/AppMenuService.java b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/service/AppMenuService.java
index b16bd65b..401d3fcd 100644
--- a/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/service/AppMenuService.java
+++ b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/service/AppMenuService.java
@@ -22,6 +22,7 @@ import com.elink.esua.epdc.commons.tools.page.PageData;
import com.elink.esua.epdc.commons.tools.security.user.UserDetail;
import com.elink.esua.epdc.commons.tools.utils.Result;
import com.elink.esua.epdc.dto.AppMenuDTO;
+import com.elink.esua.epdc.dto.epdc.result.EpdcAppChildNavResultDTO;
import com.elink.esua.epdc.dto.epdc.result.EpdcAppIndexPanelResultDTO;
import com.elink.esua.epdc.entity.AppMenuEntity;
@@ -143,4 +144,12 @@ public interface AppMenuService extends BaseService {
* @Date 2019/11/20 10:42
**/
Result> indexPanel(String mobile);
+ /**
+ * @param userId
+ * @return com.elink.esua.epdc.commons.tools.utils.Result>
+ * @Author lpf
+ * @Description 首页面板 获取数据端APP菜单
+ * @Date 2020/03/18 10:42
+ **/
+ Result> getAnalysisIndexPanel(String userId);
}
diff --git a/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/service/SysAnalysisMenuService.java b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/service/SysAnalysisMenuService.java
new file mode 100644
index 00000000..a59c4e77
--- /dev/null
+++ b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/service/SysAnalysisMenuService.java
@@ -0,0 +1,125 @@
+/**
+ * Copyright 2018 人人开源 https://www.renren.io
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see .
+ */
+
+package com.elink.esua.epdc.service.impl;
+
+import cn.hutool.core.collection.CollUtil;
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.elink.esua.epdc.commons.mybatis.service.impl.BaseServiceImpl;
+import com.elink.esua.epdc.commons.tools.page.PageData;
+import com.elink.esua.epdc.commons.tools.utils.ConvertUtils;
+import com.elink.esua.epdc.commons.tools.constant.FieldConstant;
+import com.elink.esua.epdc.dao.SysAnalysisRoleMenuDao;
+import com.elink.esua.epdc.dto.*;
+import com.elink.esua.epdc.entity.SysAnalysisRoleMenuEntity;
+import com.elink.esua.epdc.redis.SysAnalysisRoleMenuRedis;
+import com.elink.esua.epdc.service.SysAnalysisRoleMenuService;
+import org.apache.commons.lang3.StringUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+
+import java.util.Arrays;
+import java.util.List;
+import java.util.Map;
+
+/**
+ * 角色菜单关系
+ *
+ * @author elink elink@elink-cn.com
+ * @since v1.0.0 2020-03-25
+ */
+@Service
+public class SysAnalysisRoleMenuServiceImpl extends BaseServiceImpl implements SysAnalysisRoleMenuService {
+
+ @Autowired
+ private SysAnalysisRoleMenuRedis sysAnalysisRoleMenuRedis;
+
+ @Override
+ public PageData page(Map params) {
+ IPage page = baseDao.selectPage(
+ getPage(params, FieldConstant.CREATED_TIME, false),
+ getWrapper(params)
+ );
+ return getPageData(page, SysAnalysisRoleMenuDTO.class);
+ }
+
+ @Override
+ public List list(Map params) {
+ List entityList = baseDao.selectList(getWrapper(params));
+
+ return ConvertUtils.sourceToTarget(entityList, SysAnalysisRoleMenuDTO.class);
+ }
+
+ private QueryWrapper getWrapper(Map params){
+ String id = (String)params.get(FieldConstant.ID_HUMP);
+
+ QueryWrapper wrapper = new QueryWrapper<>();
+ wrapper.eq(StringUtils.isNotBlank(id), FieldConstant.ID, id);
+
+ return wrapper;
+ }
+ /**
+ * 保存或修改
+ *
+ * @param roleId 角色ID
+ * @param appMenuIdList 菜单ID列表
+ */
+ @Override
+ public void saveOrUpdate(Long roleId, List analysisMenuIdList) {
+ //先删除角色菜单权限关系
+ deleteByRoleId(roleId);
+
+ //角色没有一个菜单权限的情况
+ if (CollUtil.isEmpty(analysisMenuIdList)) {
+ return;
+ }
+
+ //保存角色菜单权限关系
+ for (Long menuId : analysisMenuIdList) {
+ SysAnalysisRoleMenuEntity appRoleMenuEntity = new SysAnalysisRoleMenuEntity();
+ appRoleMenuEntity.setMenuId(menuId);
+ appRoleMenuEntity.setRoleId(roleId);
+
+ //保存
+ insert(appRoleMenuEntity);
+ }
+ }
+ /**
+ * 根据角色id,删除角色数据权限关系
+ *
+ * @param roleId 角色id
+ */
+ @Override
+ public void deleteByRoleId(Long roleId) {
+ baseDao.deleteByRoleId(roleId);
+ }
+
+ @Override
+ public SysAnalysisRoleMenuDTO get(String id) {
+ SysAnalysisRoleMenuEntity entity = baseDao.selectById(id);
+ return ConvertUtils.sourceToTarget(entity, SysAnalysisRoleMenuDTO.class);
+ }
+
+ @Override
+ @Transactional(rollbackFor = Exception.class)
+ public void save(SysAnalysisRoleMenuDTO dto) {
+ SysAnalysisRoleMenuEntity entity = ConvertUtils.sourceToTarget(dto, SysAnalysisRoleMenuEntity.class);
+ insert(entity);
+ }
+
+ @Override
+ @Transactional(rollbackFor = Exception.class)
+ public void update(SysAnalysisRoleMenuDTO dto) {
+ SysAnalysisRoleMenuEntity entity = ConvertUtils.sourceToTarget(dto, SysAnalysisRoleMenuEntity.class);
+ updateById(entity);
+ }
+
+ @Override
+ @Transactional(rollbackFor = Exception.class)
+ public void delete(String[] ids) {
+ // 逻辑删除(@TableLogic 注解)
+ baseDao.deleteBatchIds(Arrays.asList(ids));
+ }
+ /**
+ * 根据角色ID,获取菜单ID列表
+ *
+ * @param id
+ * @return
+ */
+ @Override
+ public List getAnalysisMenuIdList(Long id) {
+ return baseDao.getAnalysisMenuIdList(id);
+ }
+
+}
\ No newline at end of file
diff --git a/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/service/impl/SysRoleServiceImpl.java b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/service/impl/SysRoleServiceImpl.java
index fbc289f2..c57da68f 100644
--- a/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/service/impl/SysRoleServiceImpl.java
+++ b/esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/service/impl/SysRoleServiceImpl.java
@@ -54,6 +54,8 @@ public class SysRoleServiceImpl extends BaseServiceImpl
+
+
+
+
+
+
+
+
+
diff --git a/esua-epdc/epdc-admin/epdc-admin-server/src/main/resources/mapper/SysAnalysisMenuDao.xml b/esua-epdc/epdc-admin/epdc-admin-server/src/main/resources/mapper/SysAnalysisMenuDao.xml
new file mode 100644
index 00000000..649e12cd
--- /dev/null
+++ b/esua-epdc/epdc-admin/epdc-admin-server/src/main/resources/mapper/SysAnalysisMenuDao.xml
@@ -0,0 +1,132 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/esua-epdc/epdc-admin/epdc-admin-server/src/main/resources/mapper/SysAnalysisRoleMenuDao.xml b/esua-epdc/epdc-admin/epdc-admin-server/src/main/resources/mapper/SysAnalysisRoleMenuDao.xml
new file mode 100644
index 00000000..e06a1bea
--- /dev/null
+++ b/esua-epdc/epdc-admin/epdc-admin-server/src/main/resources/mapper/SysAnalysisRoleMenuDao.xml
@@ -0,0 +1,21 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+ delete from sys_analysis_role_menu where role_id = #{value}
+
+
+
+
+
\ No newline at end of file
diff --git a/esua-epdc/epdc-module/epdc-events/epdc-events-client/src/main/java/com/elink/esua/epdc/dto/issue/IssueContentDetailDTO.java b/esua-epdc/epdc-module/epdc-events/epdc-events-client/src/main/java/com/elink/esua/epdc/dto/issue/IssueContentDetailDTO.java
index fc5a1a2c..40b5718b 100644
--- a/esua-epdc/epdc-module/epdc-events/epdc-events-client/src/main/java/com/elink/esua/epdc/dto/issue/IssueContentDetailDTO.java
+++ b/esua-epdc/epdc-module/epdc-events/epdc-events-client/src/main/java/com/elink/esua/epdc/dto/issue/IssueContentDetailDTO.java
@@ -28,6 +28,15 @@ public class IssueContentDetailDTO implements Serializable {
* 手机号
*/
private String mobile;
+
+ /**
+ * 网格ID
+ */
+ private Long gridId;
+ /**
+ * 用户头像
+ */
+ private String userFace;
/**
* 议题内容
*/
@@ -44,6 +53,11 @@ public class IssueContentDetailDTO implements Serializable {
* 评论数
*/
private Integer commentNum;
+
+ /**
+ * 评论数
+ */
+ private Integer participantsNum;
/**
* 图片
*/
diff --git a/esua-epdc/epdc-module/epdc-events/epdc-events-client/src/main/java/com/elink/esua/epdc/dto/issue/IssueWaitHandleOrClosedDTO.java b/esua-epdc/epdc-module/epdc-events/epdc-events-client/src/main/java/com/elink/esua/epdc/dto/issue/IssueWaitHandleOrClosedDTO.java
index f9eff189..a5293816 100644
--- a/esua-epdc/epdc-module/epdc-events/epdc-events-client/src/main/java/com/elink/esua/epdc/dto/issue/IssueWaitHandleOrClosedDTO.java
+++ b/esua-epdc/epdc-module/epdc-events/epdc-events-client/src/main/java/com/elink/esua/epdc/dto/issue/IssueWaitHandleOrClosedDTO.java
@@ -34,6 +34,8 @@ public class IssueWaitHandleOrClosedDTO implements Serializable {
* 参与人数
*/
private Integer participateNum;
+
+ private Integer participantsNum;
/**
* 支持人数
*/
diff --git a/esua-epdc/epdc-module/epdc-events/epdc-events-client/src/main/java/com/elink/esua/epdc/dto/item/result/ItemDetailForPCEndResultDTO.java b/esua-epdc/epdc-module/epdc-events/epdc-events-client/src/main/java/com/elink/esua/epdc/dto/item/result/ItemDetailForPCEndResultDTO.java
index a228b389..ff0453eb 100644
--- a/esua-epdc/epdc-module/epdc-events/epdc-events-client/src/main/java/com/elink/esua/epdc/dto/item/result/ItemDetailForPCEndResultDTO.java
+++ b/esua-epdc/epdc-module/epdc-events/epdc-events-client/src/main/java/com/elink/esua/epdc/dto/item/result/ItemDetailForPCEndResultDTO.java
@@ -81,6 +81,16 @@ public class ItemDetailForPCEndResultDTO implements Serializable {
*/
private String categoryName;
+ /**
+ * 用户头像
+ */
+ private String userFace;
+
+ /**
+ * 网格ID
+ */
+ private Long gridId;
+
/**
* 支持数
*/
@@ -93,6 +103,10 @@ public class ItemDetailForPCEndResultDTO implements Serializable {
* 评论数
*/
private Integer commentNum;
+ /**
+ * 评论数
+ */
+ private Integer participantsNum;
/**
* 友邻社群
diff --git a/esua-epdc/epdc-module/epdc-events/epdc-events-server/src/main/resources/mapper/issue/IssueDao.xml b/esua-epdc/epdc-module/epdc-events/epdc-events-server/src/main/resources/mapper/issue/IssueDao.xml
index 357f7597..f6bc3bff 100644
--- a/esua-epdc/epdc-module/epdc-events/epdc-events-server/src/main/resources/mapper/issue/IssueDao.xml
+++ b/esua-epdc/epdc-module/epdc-events/epdc-events-server/src/main/resources/mapper/issue/IssueDao.xml
@@ -13,6 +13,7 @@
e.BROWSE_NUM AS browseNum,
e.COMMENT_NUM AS commentNum,
( e.APPROVE_NUM + e.OPPOSE_NUM + e.BROWSE_NUM + e.COMMENT_NUM ) AS participateNum,
+ ( e.APPROVE_NUM + e.OPPOSE_NUM + e.BROWSE_NUM + e.COMMENT_NUM ) AS participantsNum,
issue.ISSUE_CODE
FROM
epdc_issue issue
@@ -35,6 +36,9 @@
AND (find_in_set(#{communityId},issue.PARENT_DEPT_IDS)
OR find_in_set(#{communityId},issue.ALL_DEPT_IDS))
+
+
+ AND issue.ISSUE_CONTENT like concat('%', trim(#{keyword}), '%')
AND issue.ISSUE_CODE like concat('%', #{issueCode}, '%')
@@ -90,6 +94,8 @@
+
+
@@ -108,10 +114,13 @@
i.NICK_NAME,
i.DISTRIBUTE_TIME,
i.MOBILE,
+ i.USER_FACE,
+ i.GRID_ID,
i.ISSUE_CONTENT,
e.APPROVE_NUM,
e.OPPOSE_NUM,
e.COMMENT_NUM,
+ ( e.APPROVE_NUM + e.OPPOSE_NUM + e.COMMENT_NUM + e.BROWSE_NUM ) AS participantsNum,
img.IMG_URL,
i.ISSUE_ADDRESS,
i.ISSUE_LATITUDE,
diff --git a/esua-epdc/epdc-module/epdc-events/epdc-events-server/src/main/resources/mapper/item/ItemDao.xml b/esua-epdc/epdc-module/epdc-events/epdc-events-server/src/main/resources/mapper/item/ItemDao.xml
index 2990c3af..b52a4f03 100644
--- a/esua-epdc/epdc-module/epdc-events/epdc-events-server/src/main/resources/mapper/item/ItemDao.xml
+++ b/esua-epdc/epdc-module/epdc-events/epdc-events-server/src/main/resources/mapper/item/ItemDao.xml
@@ -411,7 +411,16 @@
AND eve.DEL_FLAG = '0'
WHERE
item.DEL_FLAG = '0'
+
+
AND item.ITEM_STATE = #{itemState}
+
+
+ AND item.ITEM_STATE in (0,10)
+
+
+ AND item.ITEM_CONTENT like concat('%', trim(#{keyword}), '%')
+
AND item.ID IN (
SELECT
temp.ITEM_ID
@@ -455,6 +464,8 @@
+
+
@@ -478,9 +489,12 @@
item.ISSUE_ADDRESS,
item.ISSUE_LATITUDE,
item.ISSUE_LONGITUDE,
+ item.USER_FACE,
+ item.GRID_ID,
eve.APPROVE_NUM,
eve.OPPOSE_NUM,
eve.COMMENT_NUM,
+ ( eve.APPROVE_NUM + eve.OPPOSE_NUM + eve.COMMENT_NUM + eve.BROWSE_NUM ) AS participantsNum,
item.CATEGORY_FULL_NAME as CATEGORY_NAME,
img.IMG_URL,
item.GROUP_NAME
diff --git a/esua-epdc/epdc-module/epdc-group/epdc-group-client/src/main/java/com.elink.esua.epdc/dto/topic/TopicDTO.java b/esua-epdc/epdc-module/epdc-group/epdc-group-client/src/main/java/com.elink.esua.epdc/dto/topic/TopicDTO.java
index ed660b49..90f12a83 100644
--- a/esua-epdc/epdc-module/epdc-group/epdc-group-client/src/main/java/com.elink.esua.epdc/dto/topic/TopicDTO.java
+++ b/esua-epdc/epdc-module/epdc-group/epdc-group-client/src/main/java/com.elink.esua.epdc/dto/topic/TopicDTO.java
@@ -204,5 +204,9 @@ public class TopicDTO implements Serializable {
* 更新时间
*/
private Date updatedTime;
+ /**
+ * 评论数
+ */
+ private Integer participantsNum;
}
\ No newline at end of file
diff --git a/esua-epdc/epdc-module/epdc-group/epdc-group-client/src/main/java/com.elink.esua.epdc/dto/topic/TopicDetailDTO.java b/esua-epdc/epdc-module/epdc-group/epdc-group-client/src/main/java/com.elink.esua.epdc/dto/topic/TopicDetailDTO.java
index eabb2792..73ea8072 100644
--- a/esua-epdc/epdc-module/epdc-group/epdc-group-client/src/main/java/com.elink.esua.epdc/dto/topic/TopicDetailDTO.java
+++ b/esua-epdc/epdc-module/epdc-group/epdc-group-client/src/main/java/com.elink.esua.epdc/dto/topic/TopicDetailDTO.java
@@ -56,6 +56,27 @@ public class TopicDetailDTO implements Serializable {
* 友邻社群
*/
private String groupName;
+ /**
+ * 用户头像
+ */
+ private String userFace;
+ /**
+ * 评论数
+ */
+ private Integer commentNum;
+
+ /**
+ * 浏览数
+ */
+ private Integer browseNum;
+ /**
+ * 评论数
+ */
+ private Integer participantsNum;
+ /**
+ * 网格ID
+ */
+ private Long gridId;
/**
* 所属网格详细信息
diff --git a/esua-epdc/epdc-module/epdc-group/epdc-group-server/src/main/resources/mapper/topic/TopicDao.xml b/esua-epdc/epdc-module/epdc-group/epdc-group-server/src/main/resources/mapper/topic/TopicDao.xml
index 8ffa4541..7d875611 100644
--- a/esua-epdc/epdc-module/epdc-group/epdc-group-server/src/main/resources/mapper/topic/TopicDao.xml
+++ b/esua-epdc/epdc-module/epdc-group/epdc-group-server/src/main/resources/mapper/topic/TopicDao.xml
@@ -190,12 +190,16 @@
temp.TOPIC_CONTENT,
temp.COMMENT_NUM,
temp.BROWSE_NUM,
+ ( temp.BROWSE_NUM + temp.COMMENT_NUM ) AS participantsNum,
temp.STATE
FROM
epdc_topic temp
WHERE
temp.DEL_FLAG = '0'
- AND temp.STATE IN ( 0, 5, 20 )
+ AND temp.STATE IN ( 0, 5, 20)
+
+ AND temp.STATE in (0,5,10,15)
+
AND (find_in_set(#{streetId},temp.PARENT_DEPT_IDS)
OR find_in_set(#{streetId},temp.ALL_DEPT_IDS))
@@ -238,6 +242,10 @@
+
+
+
+
@@ -254,7 +262,12 @@
tp.TOPIC_LONGITUDE,
tp.GROUP_NAME,
tp.ALL_DEPT_NAMES,
- img.IMG_URL
+ img.IMG_URL,
+ tp.USER_FACE,
+ tp.GRID_ID,
+ tp.COMMENT_NUM,
+ ( tp.BROWSE_NUM + tp.COMMENT_NUM ) AS participantsNum,
+ tp.BROWSE_NUM
FROM
epdc_topic tp
LEFT JOIN epdc_topic_img img ON tp.ID = img.REFERENCE_ID