| | |
| | | promotionWishService.deleteRecommend(id); |
| | | return R.ok(); |
| | | } |
| | | |
| | | /** |
| | | * 展示隐藏 |
| | | * @param id |
| | | * @return |
| | | */ |
| | | @ApiOperation("展示隐藏") |
| | | @GetMapping("/show-hide/{id}") |
| | | public R<?> showHide( |
| | | @ApiParam(name = "id", value = "求购id", required = true) @NotNull(message = "求购id不能为空") @PathVariable("id") Long id) { |
| | | promotionWishService.showHide(id); |
| | | return R.ok(); |
| | | } |
| | | } |
| | |
| | | @ApiModelProperty(value = "会员id") |
| | | private Long memberId; |
| | | |
| | | @ApiModelProperty(value = "是否展示标志(1:是0:否)") |
| | | private Integer showFlag; |
| | | |
| | | |
| | | @ApiModelProperty(value = "求购商品列表") |
| | | private List<MgtPromotionWishListVO> wishListVOList; |
| | | |
| | |
| | | @ApiModelProperty(value = "删除标志(0代表存在 1代表删除)") |
| | | private Integer delFlag; |
| | | |
| | | @ApiModelProperty(value = "是否展示标志(1:是0:否)") |
| | | private Integer showFlag; |
| | | |
| | | |
| | | } |
| | |
| | | */ |
| | | ForepartPromotionWishVO getPromotionWishDetails(Long id); |
| | | |
| | | /** |
| | | * 展示隐藏 |
| | | * @param id |
| | | */ |
| | | void showHide(Long id); |
| | | } |
| | |
| | | } |
| | | return vo; |
| | | } |
| | | |
| | | /** |
| | | * 显示隐藏 |
| | | * @param id |
| | | */ |
| | | @Override |
| | | public void showHide(Long id) { |
| | | PromotionWish promotionWish = this.getById(id); |
| | | if (StringUtils.isNotNull(promotionWish)) { |
| | | promotionWish.setShowFlag(promotionWish.getShowFlag() == DisabledEnum.YES.getCode() |
| | | ? DisabledEnum.NO.getCode() : DisabledEnum.YES.getCode()); |
| | | this.updateById(promotionWish); |
| | | } |
| | | } |
| | | } |
| | |
| | | LEFT JOIN t_promotion_wish_list tpwl ON tpw.id = tpwl.wish_id |
| | | LEFT JOIN t_promotion_wish_recommend tpwr ON tpwr.wish_id = tpw.id |
| | | <where> |
| | | tpw.del_flag = 0 AND tpw.member_id = #{memberId} |
| | | tpw.del_flag = 0 AND tpw.show_flag = 1 AND tpw.member_id = #{memberId} |
| | | </where> |
| | | GROUP BY tpw.id |
| | | </select> |