lidongdong
2023-08-28 ac762de6529d1a34e23db1a5c6f41ad41a93277a
新增商家端商家类型
10个文件已修改
86 ■■■■ 已修改文件
springcloud_k8s_panzhihuazhihuishequ/applets/src/main/java/com/panzhihua/applets/api/VolunteerActivitiesPeopleApi.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/common/src/main/java/com/panzhihua/common/model/vos/community/VolunteerTypeVO.java 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/common/src/main/java/com/panzhihua/common/service/community/CommunityService.java 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/community_backstage/src/main/java/com/panzhihua/community_backstage/api/VolunteerTypeApi.java 46 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/api/VolunteerTypeApi.java 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/dao/VolunteerTypeDao.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/entity/VolunteerType.java 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/VolunteerTypeService.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/VolunteerTypeServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/resources/mapper/VolunteerTypeMapper.xml 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/applets/src/main/java/com/panzhihua/applets/api/VolunteerActivitiesPeopleApi.java
@@ -167,7 +167,7 @@
    public R volunteerTypeGetList(@RequestParam("pageNum")  int pageNum,
                                  @RequestParam("pageSize")  int pageSize)
    {
        return volunteerActivitiesPeople.volunteerTypeGetList(pageNum,pageSize);
        return volunteerActivitiesPeople.volunteerTypeGetList(pageNum,pageSize,"1");
    }
    /**************************************************************************************************
springcloud_k8s_panzhihuazhihuishequ/common/src/main/java/com/panzhihua/common/model/vos/community/VolunteerTypeVO.java
@@ -39,4 +39,10 @@
     */
    @ApiModelProperty(value = "社区id")
    private String communityId;
    /**
     * 状态类型
     */
    @ApiModelProperty(value = "1 志愿者活动    2 商家类型")
    private String type;
}
springcloud_k8s_panzhihuazhihuishequ/common/src/main/java/com/panzhihua/common/service/community/CommunityService.java
@@ -11334,7 +11334,8 @@
     */
    @GetMapping("/VolunteerType/volunteerTypeGetList")
    public R volunteerTypeGetList(@RequestParam("pageNum")  int pageNum,
                                  @RequestParam("pageSize")  int pageSize);
                                  @RequestParam("pageSize")  int pageSize,
                                  @RequestParam("type")   String type);
    /**
     * 新增
springcloud_k8s_panzhihuazhihuishequ/community_backstage/src/main/java/com/panzhihua/community_backstage/api/VolunteerTypeApi.java
@@ -32,7 +32,7 @@
    public R volunteerTypeGetList(@RequestParam("pageNum")  int pageNum,
                                  @RequestParam("pageSize")  int pageSize)
    {
        return communityService.volunteerTypeGetList(pageNum,pageSize);
        return communityService.volunteerTypeGetList(pageNum,pageSize,"1");
    }
    /**
@@ -57,6 +57,8 @@
        {
            volunteerTypeVO.setCommunityId(getLoginUserInfo().getCommunityId()+"");
        }
        volunteerTypeVO.setType("1");
        return communityService.insertvolunteerType(volunteerTypeVO);
    }
@@ -97,5 +99,47 @@
    }
    /**
     * 商家状态
     */
    /**
     * 分页查询
     * @param
     * @return
     */
    @GetMapping("/merchant/volunteerTypeGetList")
    public R merchantvolunteerTypeGetList(@RequestParam("pageNum")  int pageNum,
                                  @RequestParam("pageSize")  int pageSize)
    {
        return communityService.volunteerTypeGetList(pageNum,pageSize,"2");
    }
    /**
     * 新增
     * @param
     * @return
     */
    @PostMapping("/merchant/insertvolunteerType")
    public R merchantinsertvolunteerType(@RequestBody VolunteerTypeVO volunteerTypeVO)
    {
        if(volunteerTypeVO==null)
        {
            return R.fail("参数不能为空");
        }
        if(StringUtils.isEmpty(volunteerTypeVO.getName()))
        {
            return  R.fail("活动类型不能为空");
        }
        if(StringUtils.isEmpty(volunteerTypeVO.getCommunityId()))
        {
            volunteerTypeVO.setCommunityId(getLoginUserInfo().getCommunityId()+"");
        }
        volunteerTypeVO.setType("2");
        return communityService.insertvolunteerType(volunteerTypeVO);
    }
}
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/api/VolunteerTypeApi.java
@@ -24,9 +24,10 @@
     */
    @GetMapping("/volunteerTypeGetList")
    public R volunteerTypeGetList(@RequestParam("pageNum")  int pageNum,
                                  @RequestParam("pageSize")  int pageSize)
                                  @RequestParam("pageSize")  int pageSize,
                                  @RequestParam("type")   String type)
    {
        return volunteerTypeService.volunteerTypeGetList(pageNum,pageSize);
        return volunteerTypeService.volunteerTypeGetList(pageNum,pageSize,type);
    }
    /**
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/dao/VolunteerTypeDao.java
@@ -21,7 +21,7 @@
     * @param
     * @return
     */
    IPage<VolunteerType> volunteerTypeGetList(Page page);
    IPage<VolunteerType> volunteerTypeGetList(Page page,@Param("type") String type);
    /**
     * 新增
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/entity/VolunteerType.java
@@ -47,9 +47,11 @@
     * 社区id
     */
    @ApiModelProperty(value = "社区id")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private String communityId;
    @ApiModelProperty(value = "1 志愿者活动    2 商家类型")
    private String type;
}
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/VolunteerTypeService.java
@@ -14,7 +14,7 @@
     * @param
     * @return
     */
    R volunteerTypeGetList(int pageNum,int pageSize);
    R volunteerTypeGetList(int pageNum,int pageSize,String type);
    /**
     * 新增
     * @param
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/VolunteerTypeServiceImpl.java
@@ -18,10 +18,10 @@
public class VolunteerTypeServiceImpl  extends ServiceImpl<VolunteerTypeDao,
        VolunteerType> implements VolunteerTypeService {
    @Override
    public R volunteerTypeGetList(int pageNum,int pageSize)
    public R volunteerTypeGetList(int pageNum,int pageSize,String type)
    {
        Page page = new Page<VolunteerActivity>(pageNum,pageSize);
        return R.ok(baseMapper.volunteerTypeGetList(page));
        return R.ok(baseMapper.volunteerTypeGetList(page,type));
    }
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/resources/mapper/VolunteerTypeMapper.xml
@@ -8,6 +8,7 @@
        <result property="creationTime" column="creation_time" />
        <result property="updateTime" column="update_time" />
        <result property="communityId" column="community_id" />
        <result property="type" column="type" />
    </resultMap>
    <!-- 分页查询 -->
@@ -17,8 +18,10 @@
        name,
        creation_time,
        community_id,
        type,
        update_time
        from volunteer_type
        where type=#{type}
        order by creation_time desc
    </select>
@@ -34,6 +37,9 @@
            <if test="volunteerTypeVO.communityId != null">
                community_id,
            </if>
            <if test="volunteerTypeVO.type != null">
                type,
            </if>
            creation_time
        </trim>
        values
@@ -46,6 +52,9 @@
            </if>
            <if test="volunteerTypeVO.communityId != null">
                #{volunteerTypeVO.communityId},
            </if>
            <if test="volunteerTypeVO.type != null">
                #{volunteerTypeVO.type},
            </if>
            sysdate()
        </trim>
@@ -63,6 +72,9 @@
            <if test="volunteerTypeVO.communityId != null">
                community_id=#{volunteerTypeVO.communityId},
            </if>
            <if test="volunteerTypeVO.type != null">
                type=#{volunteerTypeVO.type},
            </if>
            update_time=sysdate()
        </set>
        where id = #{volunteerTypeVO.id}