Merge branch 'test' into 'master'
Test
See merge request root/zhihuishequ!161
| | |
| | | import com.panzhihua.common.model.dtos.community.CancelRecordDTO; |
| | | import com.panzhihua.common.model.dtos.community.OperationDetailDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageUserReserveDTO; |
| | | import com.panzhihua.common.model.vos.LoginUserInfoVO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.community.ComActReserveCommitVO; |
| | | import com.panzhihua.common.service.community.CommunityService; |
| | |
| | | @ApiOperation("取消预约/登记") |
| | | @PostMapping("/cancelReserve") |
| | | public R userCancelReserve(@RequestBody CancelRecordDTO cancelRecordDTO){ |
| | | cancelRecordDTO.setUserId(this.getUserId()); |
| | | return communityService.userCancelReserve(cancelRecordDTO); |
| | | } |
| | | |
| | |
| | | comActReserveOperationRecordDO.setUserId(this.getUserId()); |
| | | return communityService.reserveOperation(comActReserveOperationRecordDO); |
| | | } |
| | | |
| | | @ApiOperation("预约登记列表") |
| | | @GetMapping("/list") |
| | | public R list(@RequestParam("communityId") Long communityId){ |
| | | LoginUserInfoVO loginUserInfo = this.getLoginUserInfoSureNoLogin(); |
| | | if(loginUserInfo != null){ |
| | | communityId = loginUserInfo.getCommunityId(); |
| | | } |
| | | return communityService.reserveListApplets(communityId); |
| | | } |
| | | } |
| | |
| | | private String remark; |
| | | |
| | | private Integer status; |
| | | |
| | | @ApiModelProperty(value = "用户id",hidden = true) |
| | | private Long userId; |
| | | } |
| | |
| | | */ |
| | | @GetMapping("/listworkguide/classify") |
| | | R listWorkGuideByClassifyId(@RequestParam("classifyId") Long classifyId); |
| | | |
| | | /** |
| | | * 小程序查询所有进行中的预约登记 |
| | | * @param communityId 社区id |
| | | * @return 社区所有进行中的预约登记列表 |
| | | */ |
| | | @GetMapping("/reserve/list") |
| | | R reserveListApplets(@RequestParam("communityId") Long communityId); |
| | | } |
| | |
| | | public R registerDetailedDetailAdmin(@RequestParam("reserveRecordId") Long reserveRecordId){ |
| | | return comActReserveRecordService.registerDetailedDetailAdmin(reserveRecordId); |
| | | } |
| | | |
| | | /** |
| | | * 小程序查询所有进行中的预约登记 |
| | | * @param communityId 社区id |
| | | * @return 社区所有进行中的预约登记列表 |
| | | */ |
| | | @GetMapping("/list") |
| | | public R list(@RequestParam("communityId") Long communityId){ |
| | | return comActReserveService.reserveListApplets(communityId); |
| | | } |
| | | } |
| | |
| | | "w.evaluate " + |
| | | "FROM " + |
| | | "com_act_micro_wish w " + |
| | | "JOIN sys_user u ON w.sponsor_id = u.user_id " + |
| | | "LEFT JOIN sys_user u ON w.sponsor_id = u.user_id " + |
| | | "LEFT JOIN com_pb_service_team su ON w.responsible_id = su.id " + |
| | | "LEFT JOIN com_act_micro_wish_user wu ON w.id = wu.micro_wish_id " + |
| | | "WHERE " + |
| | |
| | | */ |
| | | void addReserveCountById(@Param("reserveId") Long reserveId); |
| | | |
| | | /** |
| | | * 小程序查询所有进行中的预约登记 |
| | | * @param communityId 社区id |
| | | * @return 社区所有进行中的预约登记列表 |
| | | */ |
| | | List<ComActReserveIndexVo> getReserveIndexList(@Param("communityId") Long communityId); |
| | | |
| | | } |
| | |
| | | private Date createTime; |
| | | |
| | | /** |
| | | *操作类型 1已提交 2审核通过 3 驳回 4完成集心 5 分配 6 完成 |
| | | *操作类型 1已提交 2审核通过 3 驳回 4完成集心 5 分配 6 完成 7反馈 |
| | | */ |
| | | private Integer type; |
| | | |
| | | /** |
| | | * 操作备注 |
| | | */ |
| | | private String remark; |
| | | |
| | | /** |
| | | * 反馈图片url |
| | | */ |
| | | private String imgUrl; |
| | | |
| | | @Override |
| | | public String toString() { |
| | |
| | | '}'; |
| | | } |
| | | /** |
| | | *操作类型 1已提交 2审核通过 3 驳回 4完成集心 5 分配 6 完成 |
| | | *操作类型 1已提交 2审核通过 3 驳回 4完成集心 5 分配 6 完成 7反馈 |
| | | */ |
| | | public interface type{ |
| | | int ytj=1; |
| | |
| | | int jx=4; |
| | | int fp=5; |
| | | int wc=6; |
| | | int fk=7; |
| | | } |
| | | } |
| | |
| | | * @return |
| | | */ |
| | | R getByWishId(Long id); |
| | | |
| | | /** |
| | | * 添加微心愿操作记录 |
| | | * @param content 操作内容 |
| | | * @param userId 操作用户id |
| | | * @param wishId 微心愿id |
| | | * @param type 操作类型 |
| | | * @param remark 操作备注 |
| | | */ |
| | | void addOperationRecord(String content,Long userId,Long wishId,Integer type,String remark); |
| | | } |
| | |
| | | */ |
| | | R getById(Long id,Long userId,Long recordId,Integer isBack); |
| | | |
| | | /** |
| | | * 小程序查询所有进行中的预约登记 |
| | | * @param communityId 社区id |
| | | * @return 社区所有进行中的预约登记列表 |
| | | */ |
| | | R reserveListApplets(Long communityId); |
| | | |
| | | } |
| | |
| | | cmActEasyPhotoDO.setIsReportUrban(ComActEasyPhotoVO.isReportUrban.yes); |
| | | cmActEasyPhotoDO.setTransferReason(comActEasyPhotoVO.getTransferReason()); |
| | | cmActEasyPhotoDO.setTransferTime(nowDate); |
| | | |
| | | } else { |
| | | cmActEasyPhotoDO.setIsReportUrban(ComActEasyPhotoVO.isReportUrban.no); |
| | | } |
| | |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @auther lyq |
| | |
| | | public R getByWishId(Long id) { |
| | | return R.ok(comActMicroWishOperationRecordMapper.getByWishId(id)); |
| | | } |
| | | |
| | | /** |
| | | * 微心愿添加操作记录 |
| | | * @param content 操作内容 |
| | | * @param userId 操作用户id |
| | | * @param wishId 微心愿id |
| | | * @param type 操作类型 |
| | | * @param remark 操作备注 |
| | | */ |
| | | @Override |
| | | public void addOperationRecord(String content,Long userId,Long wishId,Integer type,String remark){ |
| | | ComActMicroWishOperationRecordDO wishOperationRecordDO = new ComActMicroWishOperationRecordDO(); |
| | | wishOperationRecordDO.setWishId(wishId); |
| | | wishOperationRecordDO.setUserId(userId); |
| | | wishOperationRecordDO.setType(type); |
| | | wishOperationRecordDO.setRemark(remark); |
| | | wishOperationRecordDO.setContent(content); |
| | | wishOperationRecordDO.setCreateTime(new Date()); |
| | | this.baseMapper.insert(wishOperationRecordDO); |
| | | } |
| | | } |
| | |
| | | BeanUtils.copyProperties(commentDO, vo); |
| | | String name = user.getName() == null ? user.getNickName() : user.getName(); |
| | | vo.setUserName(name); |
| | | vo.setUserPhone(user.getPhone()); |
| | | return R.ok(vo); |
| | | } |
| | | |
| | |
| | | comActReserveOperationRecordDO.setReserveContent(CANCEL); |
| | | comActReserveOperationRecordDO.setPhone(comActReserveRecordDO.getPhone()); |
| | | comActReserveOperationRecordDO.setStatus(ComActReserveOperationRecordDO.status.qx); |
| | | comActReserveOperationRecordDO.setUserId(comActReserveRecordDO.getUserId()); |
| | | comActReserveOperationRecordDO.setUserId(comActReserveRecord.getUserId()); |
| | | comActReserveOperationRecordDO.setReserveTime(DateUtil.date()); |
| | | comActReserveOperationRecordMapper.insert(comActReserveOperationRecordDO); |
| | | return R.ok(); |
| | |
| | | if(reserveRecordDO != null){ |
| | | //更新预约记录社区备注字段 |
| | | reserveRecordDO.setActRemark(reserveRecordDTO.getRemark()); |
| | | reserveRecordDO.setHandleId(userId); |
| | | comActReserveRecordMapper.updateById(reserveRecordDO); |
| | | //取消预约返还可参加名额 |
| | | comActReserveMapper.addReserveCountById(reserveRecordDO.getReserveId()); |
| | | //添加操作记录 |
| | | comActReserveOperationRecordService.addReserveOperationRecord(reserveRecordDO.getReserveId() |
| | | ,reserveRecordDO.getId(),reserveRecordDO.getUserId(),ComActReserveOperationRecordDO.type.sq,null |
| | | ,"社区管理员取消预约",reserveRecordDTO.getRemark(),ComActReserveOperationRecordDO.status.qx,userId,null); |
| | | ,"社区管理员取消预约",reserveRecordDTO.getRemark(),ComActReserveOperationRecordDO.status.qx,userId,new Date()); |
| | | } |
| | | }); |
| | | return R.ok(); |
| | |
| | | import com.google.common.collect.Lists; |
| | | import com.panzhihua.common.model.dtos.community.reserve.*; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.community.ComActReserveIndexVo; |
| | | import com.panzhihua.common.model.vos.community.questnaire.QuestnaiteSubSelectionVO; |
| | | import com.panzhihua.common.model.vos.community.questnaire.QuestnaiteSubVO; |
| | | import com.panzhihua.common.model.vos.community.reserve.*; |
| | |
| | | public R pageReserveList(PageUserReserveDTO pageUserReserveDTO) { |
| | | return R.ok(comActReserveRecordMapper.pageReserveList(new Page<ComActReserveDO>(pageUserReserveDTO.getPageNum(), pageUserReserveDTO.getPageSize()),pageUserReserveDTO)); |
| | | } |
| | | |
| | | /** |
| | | * 小程序查询所有进行中的预约登记 |
| | | * @param communityId 社区id |
| | | * @return 社区所有进行中的预约登记列表 |
| | | */ |
| | | @Override |
| | | public R reserveListApplets(Long communityId){ |
| | | return R.ok(this.baseMapper.getReserveIndexList(communityId)); |
| | | } |
| | | } |
| | |
| | | if (!iPage.getRecords().isEmpty()) { |
| | | iPage.getRecords().forEach(comActWorkGuideVO -> { |
| | | ComActWorkGuideClassifyDO comActWorkGuideClassifyDO = comActWorkGuideClassifyDAO.selectById(comActWorkGuideVO.getClassify()); |
| | | comActWorkGuideVO.setClassifyName(comActWorkGuideClassifyDO.getClassifyName()); |
| | | if (comActWorkGuideClassifyDO != null) { |
| | | comActWorkGuideVO.setClassifyName(comActWorkGuideClassifyDO.getClassifyName()); |
| | | } |
| | | }); |
| | | } |
| | | return R.ok(iPage); |
| | |
| | | <result column="user_id" property="userId" /> |
| | | <result column="wish_id" property="wishId" /> |
| | | <result column="create_time" property="createTime" /> |
| | | <result column="remark" property="remark" /> |
| | | <result column="img_url" property="imgUrl" /> |
| | | <result column="type" property="type"/> |
| | | </resultMap> |
| | | |
| | | <!-- 通用查询结果列 --> |
| | | <sql id="Base_Column_List"> |
| | | id, content, user_id, wish_id, create_time |
| | | id, content, user_id, wish_id, create_time, remark, img_url |
| | | </sql> |
| | | |
| | | <select id="getByWishId" resultType="com.panzhihua.common.model.vos.community.ComActMicroWishOperationRecordVO"> |
| | |
| | | su.nick_name like concat (#{neighborCircleAppDTO.keyWord},'%') or |
| | | canc.release_content like concat (#{neighborCircleAppDTO.keyWord},'%')) |
| | | </if> |
| | | <if test='neighborCircleAppDTO.type != null and neighborCircleAppDTO.type == 1'> |
| | | order by canc.hot_num desc |
| | | </if> |
| | | <if test='neighborCircleAppDTO.type != null and neighborCircleAppDTO.type == 2'> |
| | | order by canc.create_at desc |
| | | </if> |
| | | <if test='neighborCircleAppDTO.type != null and neighborCircleAppDTO.type == 3'> |
| | | order by canc.is_boutique asc |
| | | </if> |
| | | order by canc.create_at desc |
| | | </select> |
| | | |
| | | <update id="addHotNum"> |
| | |
| | | <update id="addReserveCountById"> |
| | | update com_act_reserve set join_count = join_count - 1 where id = #{reserveId} |
| | | </update> |
| | | |
| | | <select id="getReserveIndexList" resultType="com.panzhihua.common.model.vos.community.ComActReserveIndexVo"> |
| | | select id,title,type,img_type,img_url,adver_position_top,adver_position_application from com_act_reserve where `status` = 2 and is_del = 2 |
| | | and community_id = #{communityId} |
| | | </select> |
| | | </mapper> |
| | |
| | | SELECT cawgc.id, cawgc.classify_name, cawgc.picture_url,( SELECT count( id ) FROM com_act_work_guide WHERE classify = cawgc.id ) AS `count` |
| | | FROM |
| | | com_act_work_guide_classify AS cawgc |
| | | order by `count` asc |
| | | </select> |
| | | |
| | | </mapper> |