| | |
| | | import com.panzhihua.common.constants.NeighborCircleConstants; |
| | | import javax.annotation.Resource; |
| | | |
| | | import com.panzhihua.common.model.vos.neighbor.*; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import com.panzhihua.common.controller.BaseController; |
| | | import com.panzhihua.common.model.dtos.neighbor.*; |
| | | import com.panzhihua.common.model.vos.LoginUserInfoVO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.neighbor.ComActNeighborCircleAppVO; |
| | | import com.panzhihua.common.model.vos.neighbor.ComActNeighborCircleDetailAppVO; |
| | | import com.panzhihua.common.model.vos.neighbor.ComActNeighborCircleTopicAppVO; |
| | | import com.panzhihua.common.model.vos.neighbor.ComActNeighborCommentReplyAppVO; |
| | | import com.panzhihua.common.service.community.CommunityService; |
| | | import com.panzhihua.common.utlis.StringUtils; |
| | | |
| | |
| | | circleTopicAppDTO.setCommunityId(loginUserInfo.getCommunityId()); |
| | | return communityService.deleteNeighborByApp(circleTopicAppDTO); |
| | | } |
| | | |
| | | /** |
| | | * 分页查询邻里圈列表 |
| | | * |
| | | * @param neighborCircleAppDTO |
| | | * 请求参数 |
| | | * @return 邻里圈列表 |
| | | */ |
| | | @ApiOperation(value = "新版接单问题",response =ComActNeighborCircleAppVO.class ) |
| | | @PostMapping("selectSolve") |
| | | public R selectSolve(@RequestBody ComActNeighborCircleAppDTO neighborCircleAppDTO) { |
| | | return communityService.selectSolve(neighborCircleAppDTO); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 修改数据 |
| | | * @param editNeighborCircleAdminVO |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "接单 反馈",response =ComActNeighborCircleAppVO.class ) |
| | | @PostMapping("update") |
| | | public R order(@RequestBody EditNeighborCircleAdminVO editNeighborCircleAdminVO){ |
| | | return this.communityService.order(editNeighborCircleAdminVO); |
| | | } |
| | | } |
| | | |
| | |
| | | @ApiModelProperty("使用类型(1.邻里圈 2.问题清单 3.需求清单)") |
| | | private Integer belongType; |
| | | |
| | | @ApiModelProperty(value = "处理状态 0 否 1是", example = "1") |
| | | private Integer solveStatus; |
| | | |
| | | @ApiModelProperty(value = "接单人id", example = "1") |
| | | private Long solveId; |
| | | |
| | | /** |
| | | * 使用类型(1.邻里圈 2.问题清单 3.需求清单) |
| | | */ |
| | |
| | | |
| | | @ApiModelProperty("使用类型(1.邻里圈 2.问题清单 3.需求清单)") |
| | | private Integer belongType; |
| | | @ApiModelProperty("处理状态 0 否 1是") |
| | | private Integer solveStatus; |
| | | } |
| | |
| | | |
| | | @ApiModelProperty("社区名称") |
| | | private String communityName; |
| | | @ApiModelProperty("处理状态 0 否 1是") |
| | | private Integer solveStatus; |
| | | @ApiModelProperty("接单状态 0 否 1是") |
| | | private Integer orderStatus; |
| | | @ApiModelProperty("接单人id") |
| | | private Long solveId; |
| | | @ApiModelProperty("反馈内容") |
| | | private String solveContent; |
| | | @ApiModelProperty("反馈图片") |
| | | private String solveUrl; |
| | | |
| | | } |
| | |
| | | @ApiModelProperty("驳回原因") |
| | | private String refuseReason; |
| | | |
| | | @ApiModelProperty("处理状态 0 否 1是") |
| | | private Integer solveStatus; |
| | | @ApiModelProperty("接单状态 0 否 1是") |
| | | private Integer orderStatus; |
| | | @ApiModelProperty("接单人id") |
| | | private Long solveId; |
| | | @ApiModelProperty("反馈内容") |
| | | private String solveContent; |
| | | @ApiModelProperty("反馈图片") |
| | | private String solveUrl; |
| | | @ApiModelProperty("接单人名称") |
| | | private String solveName; |
| | | @ApiModelProperty("接单时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") |
| | | private Date orderTime; |
| | | @ApiModelProperty("处理时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") |
| | | private Date solveTime; |
| | | |
| | | private Long topicId; |
| | | |
| | | private Long releaseId; |
| | | |
| | | } |
| | |
| | | @ApiModelProperty("头像") |
| | | private String imageUrl; |
| | | |
| | | @ApiModelProperty("处理状态 0 否 1是") |
| | | private Integer solveStatus; |
| | | @ApiModelProperty("接单状态 0 否 1是") |
| | | private Integer orderStatus; |
| | | @ApiModelProperty("接单人id") |
| | | private Long solveId; |
| | | @ApiModelProperty("反馈内容") |
| | | private String solveContent; |
| | | @ApiModelProperty("反馈图片") |
| | | private String solveUrl; |
| | | @ApiModelProperty("接单人名称") |
| | | private String solveName; |
| | | @ApiModelProperty("接单时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") |
| | | private Date orderTime; |
| | | @ApiModelProperty("处理时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") |
| | | private Date solveTime; |
| | | } |
| | |
| | | @ApiModelProperty("使用类型(1.邻里圈 2.问题清单 3.需求清单)") |
| | | private Integer belongType; |
| | | |
| | | @ApiModelProperty("接单状态 0 否 1是") |
| | | private Integer orderStatus; |
| | | |
| | | @ApiModelProperty("处理状态 0 否 1是") |
| | | private Integer solveStatus; |
| | | |
| | | @ApiModelProperty("接单人id") |
| | | private Long solveId; |
| | | @ApiModelProperty("反馈内容") |
| | | private String solveContent; |
| | | @ApiModelProperty("反馈图片") |
| | | private String solveUrl; |
| | | |
| | | |
| | | /** |
| | | * 使用类型(1.邻里圈 2.问题清单 3.需求清单) |
| | | */ |
| | |
| | | @PostMapping("/neighbor/deleteNeighborByApp") |
| | | R deleteNeighborByApp(@RequestBody DeleteNeighborCircleAppDTO circleTopicAppDTO); |
| | | |
| | | |
| | | /** |
| | | * 分页查询邻里圈列表 |
| | | * |
| | | * @param neighborCircleAppDTO |
| | | * 请求参数 |
| | | * @return 邻里圈列表 |
| | | */ |
| | | @PostMapping("/neighbor/selectSolve") |
| | | R selectSolve(@RequestBody ComActNeighborCircleAppDTO neighborCircleAppDTO); |
| | | |
| | | |
| | | /** |
| | | * 修改数据 |
| | | * @param editNeighborCircleAdminVO |
| | | * @return |
| | | */ |
| | | @PostMapping("/neighbor/update") |
| | | R order(@RequestBody EditNeighborCircleAdminVO editNeighborCircleAdminVO); |
| | | |
| | | /** |
| | | * 获取系统配置value |
| | | * @param key 系统配置code |
| | |
| | | return communityService.pageNeighborTopicByAdmin(circleTopicAdminDTO); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 分页查询邻里圈列表 |
| | | * |
| | | * @param neighborCircleAppDTO |
| | | * 请求参数 |
| | | * @return 邻里圈列表 |
| | | */ |
| | | @ApiOperation(value = "新版接单问题",response =ComActNeighborCircleAppVO.class ) |
| | | @PostMapping("selectSolve") |
| | | public R selectSolve(@RequestBody ComActNeighborCircleAppDTO neighborCircleAppDTO) { |
| | | return communityService.selectSolve(neighborCircleAppDTO); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 修改数据 |
| | | * @param editNeighborCircleAdminVO |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "接单 反馈",response =ComActNeighborCircleAppVO.class ) |
| | | @PostMapping("update") |
| | | public R order(@RequestBody EditNeighborCircleAdminVO editNeighborCircleAdminVO){ |
| | | return this.communityService.order(editNeighborCircleAdminVO); |
| | | } |
| | | |
| | | } |
| | |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | import com.panzhihua.service_community.model.dos.ComActNeighborCircleDO; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | |
| | | @PostMapping("pageNeighborByApp") |
| | | public R pageNeighbor(@RequestBody ComActNeighborCircleAppDTO neighborCircleAppDTO) { |
| | | return comActNeighborCircleService.pageNeighborByApp(neighborCircleAppDTO); |
| | | } |
| | | |
| | | /** |
| | | * 分页查询邻里圈列表 |
| | | * |
| | | * @param neighborCircleAppDTO |
| | | * 请求参数 |
| | | * @return 邻里圈列表 |
| | | */ |
| | | @PostMapping("selectSolve") |
| | | public R selectSolve(@RequestBody ComActNeighborCircleAppDTO neighborCircleAppDTO) { |
| | | return comActNeighborCircleService.selectSolve(neighborCircleAppDTO); |
| | | } |
| | | |
| | | /** |
| | |
| | | return comActNeighborCircleService.deleteNeighborByApp(circleTopicAppDTO); |
| | | } |
| | | |
| | | /** |
| | | * 修改数据 |
| | | * @param editNeighborCircleAdminVO |
| | | * @return |
| | | */ |
| | | @PostMapping("update") |
| | | public R order(@RequestBody EditNeighborCircleAdminVO editNeighborCircleAdminVO){ |
| | | return this.comActNeighborCircleService.orderAndSolve(editNeighborCircleAdminVO); |
| | | } |
| | | |
| | | } |
| | |
| | | */ |
| | | IPage<ComActNeighborCircleAppVO> pageNeighborByApp(Page page, @Param("neighborCircleAppDTO") ComActNeighborCircleAppDTO neighborCircleAppDTO); |
| | | |
| | | /** |
| | | * 分页查询邻里圈列表 |
| | | * @param neighborCircleAppDTO 请求参数 |
| | | * @return 邻里圈列表 |
| | | */ |
| | | IPage<ComActNeighborCircleAppVO> selectSolve(Page page, @Param("neighborCircleAppDTO") ComActNeighborCircleAppDTO neighborCircleAppDTO); |
| | | |
| | | @Select("<script> " + "select canc.id,su.nick_name as name,su.image_url as headUrl,canc.release_content " |
| | | + ",canc.release_images,canc.comment_num,canc.fabulous_num,canc.forward_num,canc.views_num,canct.name as topicName,canc.refuse_reason " |
| | | + ",canc.is_boutique,canc.create_at,canc.reply_at,su.community_id,canc.type from com_act_neighbor_circle as canc " |
| | | + ",canc.is_boutique,canc.create_at,canc.reply_at,su.community_id,canc.type,order_status,solve_status,solve_id,solve_content,solve_url,order_time,solve_time,t.name as solveName,canc.release_id from com_act_neighbor_circle as canc " |
| | | + " left join sys_user as su on su.user_id = canc.release_id " |
| | | + " left join sys_user as t on t.user_id = canc.solve_id " |
| | | + " left join com_act_neighbor_circle_topic as canct on canct.id = canc.topic_id where canc.id = #{circleId} and canc.is_del = 2" |
| | | + " </script>") |
| | | ComActNeighborCircleDetailAppVO neighborDetailByApp(@Param("circleId") Long circleId); |
| | |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | |
| | | */ |
| | | private Integer belongType; |
| | | |
| | | private Integer solveStatus; |
| | | |
| | | private Integer orderStatus; |
| | | |
| | | private Long solveId; |
| | | |
| | | private String solveContent; |
| | | |
| | | private String solveUrl; |
| | | |
| | | private Date orderTime; |
| | | |
| | | private Date solveTime; |
| | | |
| | | @Override |
| | | public String toString() { |
| | | return "ComActNeighborCircleDO{" + "id=" + id + ", releaseId=" + releaseId + ", releasePhone=" + releasePhone |
| | |
| | | R pageNeighborByApp(ComActNeighborCircleAppDTO neighborCircleAppDTO); |
| | | |
| | | /** |
| | | * 分页查询邻里圈列表 |
| | | * |
| | | * @param neighborCircleAppDTO |
| | | * 请求参数 |
| | | * @return 邻里圈列表 |
| | | */ |
| | | R selectSolve(ComActNeighborCircleAppDTO neighborCircleAppDTO); |
| | | |
| | | /** |
| | | * 用户发布邻里圈审核 |
| | | * |
| | | * @param addNeighborCircleAppDTO |
| | |
| | | */ |
| | | R deleteNeighborByApp(DeleteNeighborCircleAppDTO circleTopicAppDTO); |
| | | |
| | | /** |
| | | * 接单 处理接口 |
| | | * @param editNeighborCircleAdminVO |
| | | * @return |
| | | */ |
| | | R orderAndSolve(EditNeighborCircleAdminVO editNeighborCircleAdminVO); |
| | | |
| | | } |
| | |
| | | return R.ok(doPager); |
| | | } |
| | | |
| | | @Override |
| | | public R selectSolve(ComActNeighborCircleAppDTO neighborCircleAppDTO) { |
| | | IPage<ComActNeighborCircleAppVO> doPager=this.baseMapper.selectSolve(new Page<ComActNeighborCircleDO>(neighborCircleAppDTO.getPageNum(),neighborCircleAppDTO.getPageSize()),neighborCircleAppDTO); |
| | | if (!doPager.getRecords().isEmpty()) { |
| | | for (ComActNeighborCircleAppVO circleAppVO : doPager.getRecords()) { |
| | | if (neighborCircleAppDTO.getSolveId() != null) { |
| | | // 查询点赞信息 |
| | | ComActNeighborCircleFabulousDO circleFabulousDO = |
| | | comActNeighborCircleFabulousDAO.selectOne(new QueryWrapper<ComActNeighborCircleFabulousDO>() |
| | | .lambda().eq(ComActNeighborCircleFabulousDO::getParentId, circleAppVO.getId()) |
| | | .eq(ComActNeighborCircleFabulousDO::getUserId, neighborCircleAppDTO.getUserId()) |
| | | .eq(ComActNeighborCircleFabulousDO::getType, ComActNeighborCircleFabulousDO.type.llq) |
| | | .eq(ComActNeighborCircleFabulousDO::getIsEffective, |
| | | ComActNeighborCircleFabulousDO.isEffective.yes)); |
| | | if (circleFabulousDO != null) { |
| | | circleAppVO.setHaveSign(1); |
| | | } else { |
| | | circleAppVO.setHaveSign(2); |
| | | } |
| | | } |
| | | |
| | | if (circleAppVO.getType() != null && circleAppVO.getType().equals(ComActNeighborCircleDO.type.admin)) { |
| | | ComActDO actDO = comActDAO.selectById(circleAppVO.getCommunityId()); |
| | | if (actDO != null) { |
| | | circleAppVO.setName(actDO.getName()); |
| | | } |
| | | } |
| | | |
| | | } |
| | | } |
| | | return R.ok(doPager); |
| | | } |
| | | |
| | | /** |
| | | * 用户发布邻里圈审核 |
| | | * |
| | |
| | | |
| | | @Override |
| | | public R detailNeighborByAdmin(Long id) { |
| | | ComActNeighborCircleDO comActNeighborCircleDO = this.baseMapper.selectById(id); |
| | | ComActNeighborCircleDetailAppVO comActNeighborCircleDO = |
| | | this.baseMapper.neighborDetailByApp(id); |
| | | if (comActNeighborCircleDO == null) { |
| | | return R.fail("id有误"); |
| | | } |
| | |
| | | } |
| | | return R.fail(); |
| | | } |
| | | |
| | | @Override |
| | | public R orderAndSolve(EditNeighborCircleAdminVO editNeighborCircleAdminVO) { |
| | | ComActNeighborCircleDO comActNeighborCircleDO=new ComActNeighborCircleDO(); |
| | | BeanUtils.copyProperties(editNeighborCircleAdminVO,comActNeighborCircleDO); |
| | | if(comActNeighborCircleDO.getSolveStatus()!=null){ |
| | | comActNeighborCircleDO.setSolveTime(new Date()); |
| | | } |
| | | if(comActNeighborCircleDO.getOrderStatus()!=null){ |
| | | comActNeighborCircleDO.setOrderTime(new Date()); |
| | | } |
| | | return R.ok(this.baseMapper.updateById(comActNeighborCircleDO)); |
| | | } |
| | | } |
| | |
| | | SELECT |
| | | nc.*, |
| | | u.`nick_name` AS releaseName,u.image_url,canct.`name` as topicName ,u.`type` as userType |
| | | ,u.name as communityName |
| | | ,u.name as communityName,nc.solve_status |
| | | FROM |
| | | com_act_neighbor_circle nc |
| | | LEFT JOIN sys_user u ON nc.release_id = u.user_id |
| | |
| | | ORDER BY t1.id DESC |
| | | </select> |
| | | |
| | | <select id="selectSolve" resultType="com.panzhihua.common.model.vos.neighbor.ComActNeighborCircleAppVO"> |
| | | select canc.id,canc.release_content,canc.release_images,canc.status,canc.create_at,canct.name as topicName |
| | | ,canc.comment_num,canc.fabulous_num,canc.forward_num,canc.views_num,canc.refuse_reason,su.nick_name as name,su.image_url as headUrl,canc.solve_status |
| | | from com_act_neighbor_circle as canc left join sys_user as su on su.user_id = canc.release_id |
| | | left join com_act_neighbor_circle_topic as canct on canct.id = canc.topic_id |
| | | <where> |
| | | <if test="neighborCircleAppDTO.solveId !=null"> |
| | | and canc.solve_id =#{neighborCircleAppDTO.solveId} |
| | | </if> |
| | | <if test="neighborCircleAppDTO.solveStatus !=null"> |
| | | and canc.solve_status =#{neighborCircleAppDTO.solveStatus} |
| | | </if> |
| | | <if test="neighborCircleAppDTO.belongType !=null"> |
| | | and canc.belong_type =#{neighborCircleAppDTO.belongType} |
| | | </if> |
| | | </where> order by create_at desc |
| | | </select> |
| | | |
| | | </mapper> |
| | |
| | | select |
| | | m.id, m.org_id, m.name, m.id_card, m.photo_path, m.join_time, m.employment_time, m.audit_result, m.create_at, m.update_at, |
| | | m.community_id, u.user_id, m.refuse_reason, m.phone, m.type, m.position, m.check_unit_id, m.function, m.specialty_category, |
| | | m.specialty_name, m.position_two, IFNULL(m.org_Name,cpo.`name`) as orgName,cpcu.name as checkUnitName,t2.partyTime,t2.partyInterval, |
| | | canct.name as specialty_name, m.position_two, IFNULL(m.org_Name,cpo.`name`) as orgName,cpcu.name as checkUnitName,t2.partyTime,t2.partyInterval, |
| | | TIMESTAMPDIFF( |
| | | YEAR, |
| | | m.employment_time, |
| | |
| | | LEFT JOIN sys_user u ON m.id_card = u.id_card and u.type = 1 |
| | | LEFT JOIN com_pb_org as cpo on cpo.id = m.org_id |
| | | LEFT JOIN com_pb_check_unit as cpcu ON m.check_unit_id = cpcu.id |
| | | LEFT JOIN com_act_neighbor_circle_topic canct on m.specialty_category = canct.id |
| | | LEFT JOIN (select t1.user_id,sum(t.duration) as partyTime,sum(t.reward_integral) as partyInterval from com_act_activity t LEFT JOIN com_act_act_regist t1 on t.id = t1.activity_id where t.type = 3 |
| | | GROUP BY t1.user_id ) t2 on u.user_id = t2.user_id |
| | | where m.audit_result = 1 |