Merge branch 'huacheng_test' of http://gitlab.nhys.cdnhxx.com/root/zhihuishequ into huacheng_test
| | |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | |
| | | import static java.util.Objects.isNull; |
| | | |
| | | /** |
| | | * @auther lyq |
| | | * @create 2021-04-14 15:02:49 |
| | |
| | | @ApiOperation(value = "查询社区邻里圈话题列表", response = ComActNeighborCircleTopicAppVO.class) |
| | | @GetMapping("topic/list") |
| | | public R getNeighborTopicByApp( |
| | | @RequestParam(value = "name",defaultValue = "",required = false) String name) { |
| | | return communityService.getNeighborTopicByApp(name); |
| | | @RequestParam(value = "name",defaultValue = "",required = false) String name, |
| | | @RequestParam(value = "belongType", defaultValue = "1", required = false) Integer belongType) { |
| | | return communityService.getNeighborTopicByApp(name, belongType); |
| | | } |
| | | |
| | | @ApiOperation(value = "用户删除邻里圈") |
| | |
| | | package com.panzhihua.common.model.vos.community; |
| | | |
| | | import com.fasterxml.jackson.databind.annotation.JsonSerialize; |
| | | import com.fasterxml.jackson.databind.ser.std.ToStringSerializer; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | |
| | | @Data |
| | | @ApiModel |
| | | public class ComActAnnouncementVO { |
| | | |
| | | @JsonSerialize(using = ToStringSerializer.class) |
| | | private Long id; |
| | | |
| | | /** |
| | |
| | | @Data |
| | | @ApiModel |
| | | public class ComActColumnVO { |
| | | |
| | | @JsonSerialize(using = ToStringSerializer.class) |
| | | private Long id; |
| | | |
| | | /** |
| | | * 分类名称 |
| | | */ |
| | | @ApiModelProperty(value = "分类名称") |
| | | @JsonSerialize(using = ToStringSerializer.class) |
| | | private String name; |
| | | |
| | | /** |
| | |
| | | * @return 邻里圈话题列表 |
| | | */ |
| | | @GetMapping("/neighbor/getNeighborTopicByApp") |
| | | R getNeighborTopicByApp(@RequestParam("name") String name); |
| | | R getNeighborTopicByApp(@RequestParam("name") String name, @RequestParam("belongType") Integer belongType); |
| | | |
| | | /** |
| | | * 删除话题 |
| | |
| | | * @return 邻里圈话题列表 |
| | | */ |
| | | @GetMapping("getNeighborTopicByApp") |
| | | public R getNeighborTopicByApp(@RequestParam("name") String name) { |
| | | return comActNeighborCircleTopicService.getNeighborTopicByApp(name); |
| | | public R getNeighborTopicByApp(@RequestParam("name") String name, @RequestParam("belongType") Integer belongType) { |
| | | return comActNeighborCircleTopicService.getNeighborTopicByApp(name, belongType); |
| | | } |
| | | |
| | | /** |
| | |
| | | * @param commonPage |
| | | * @return |
| | | */ |
| | | IPage<ComActColumn> pageList(Page page, @Param("commonPage") CommonPage commonPage); |
| | | IPage<ComActColumnVO> pageList(Page page, @Param("commonPage") CommonPage commonPage); |
| | | |
| | | /** |
| | | * 项目级联查询 |
| | |
| | | * 社区id |
| | | * @return 邻里圈话题列表 |
| | | */ |
| | | List<ComActNeighborCircleTopicAppVO> getNeighborTopicByApp(@Param("name") String name); |
| | | List<ComActNeighborCircleTopicAppVO> getNeighborTopicByApp(@Param("name") String name, @Param("belongType") Integer belongType); |
| | | |
| | | /** |
| | | * 添加邻里圈话题热度 |
| | |
| | | import com.panzhihua.common.model.dtos.neighbor.AddNeighborCircleTopicAdminDTO; |
| | | import com.panzhihua.common.model.dtos.neighbor.AddNeighborCircleTopicAppDTO; |
| | | import com.panzhihua.common.model.dtos.neighbor.ComActNeighborCircleTopicAdminDTO; |
| | | import com.panzhihua.common.model.dtos.neighbor.DeleteNeighborCircleAppDTO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.service_community.model.dos.ComActNeighborCircleTopicDO; |
| | | |
| | |
| | | * 社区id |
| | | * @return 邻里圈话题列表 |
| | | */ |
| | | R getNeighborTopicByApp(String name); |
| | | R getNeighborTopicByApp(String name, Integer belongType); |
| | | |
| | | /** |
| | | * 小程序-用户新增话题 |
| | |
| | | |
| | | import com.panzhihua.service_community.dao.ComActNeighborCircleDAO; |
| | | import com.panzhihua.service_community.model.dos.ComActNeighborCircleDO; |
| | | import com.panzhihua.service_community.service.ComActNeighborCircleService; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | |
| | | import com.panzhihua.common.model.dtos.neighbor.AddNeighborCircleTopicAdminDTO; |
| | | import com.panzhihua.common.model.dtos.neighbor.AddNeighborCircleTopicAppDTO; |
| | | import com.panzhihua.common.model.dtos.neighbor.ComActNeighborCircleTopicAdminDTO; |
| | | import com.panzhihua.common.model.dtos.neighbor.DeleteNeighborCircleAppDTO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.utlis.StringUtils; |
| | | import com.panzhihua.service_community.dao.ComActNeighborCircleTopicMapper; |
| | | import com.panzhihua.service_community.model.dos.ComActNeighborCircleTopicDO; |
| | | import com.panzhihua.service_community.service.ComActNeighborCircleTopicService; |
| | |
| | | * @return 邻里圈话题列表 |
| | | */ |
| | | @Override |
| | | public R getNeighborTopicByApp(String name){ |
| | | return R.ok(this.baseMapper.getNeighborTopicByApp(name)); |
| | | public R getNeighborTopicByApp(String name, Integer belongType){ |
| | | return R.ok(this.baseMapper.getNeighborTopicByApp(name, belongType)); |
| | | } |
| | | |
| | | /** |
| | |
| | | |
| | | <select id="getNeighborTopicByApp" resultType="com.panzhihua.common.model.vos.neighbor.ComActNeighborCircleTopicAppVO"> |
| | | SELECT canct.id, canct.`name`,`logo`, canct.hot_num |
| | | from com_act_neighbor_circle_topic as canct where canct.`status` = 1 |
| | | from com_act_neighbor_circle_topic as canct where canct.`status` = 1 AND canct.belong_type = #{belongType} |
| | | <if test="name != null and name != """> |
| | | and canct.`name` like concat('%',#{name},'%') |
| | | </if> |