| | |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.panzhihua.common.controller.BaseController; |
| | | import com.panzhihua.common.model.dtos.community.PageActWorkGuideDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageConvenientMerchantDTO; |
| | | import com.panzhihua.common.model.vos.LoginUserInfoVO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.community.ComActActRegistVO; |
| | | import com.panzhihua.common.model.vos.community.ComActActivityVO; |
| | | import com.panzhihua.common.model.vos.community.ComActWorkGuideVO; |
| | | import com.panzhihua.common.model.vos.community.SignactivityVO; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientMerchantVO; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientServiceCategoryVO; |
| | | import com.panzhihua.common.model.vos.jinhui.JinghuiMerchantEvaluateVO; |
| | | import com.panzhihua.common.model.vos.jinhui.JinhuiCoinGeneralTableVO; |
| | | import com.panzhihua.common.model.vos.jinhui.JinhuiGoldCoinRecordVO; |
| | | import com.panzhihua.common.model.vos.user.SysUserNoticeVO; |
| | |
| | | @RestController |
| | | @RequestMapping("/jin_hui/") |
| | | @Api(tags = {"小程序-金汇社区api"}) |
| | | public class JinHuiCommnuityApi extends BaseController |
| | | { |
| | | public class JinHuiCommnuityApi extends BaseController { |
| | | |
| | | @Resource |
| | | private CommunityService communityService; |
| | |
| | | |
| | | |
| | | @ApiOperation(value = "获取个人金汇币总币", response = JinhuiCoinGeneralTableVO.class) |
| | | @GetMapping("goldCoin/getDetails" ) |
| | | public R coinTableGetDetails() |
| | | { |
| | | return jinhuiCommunityService.coinTableGetDetails( this.getUserId()+""); |
| | | @GetMapping("goldCoin/getDetails") |
| | | public R coinTableGetDetails() { |
| | | return jinhuiCommunityService.coinTableGetDetails(this.getUserId() + ""); |
| | | } |
| | | |
| | | |
| | | @ApiOperation(value = "获取个人金汇币明细", response = JinhuiGoldCoinRecordVO.class) |
| | | @GetMapping("/record/getList") |
| | | public R recordGetList(@RequestParam("pageNum") int pageNum, |
| | | @RequestParam("pageSize") int pageSize) |
| | | { |
| | | return jinhuiCommunityService.recordGetList(pageNum,pageSize,this.getUserId()+""); |
| | | public R recordGetList(@RequestParam("pageNum") int pageNum, |
| | | @RequestParam("pageSize") int pageSize) { |
| | | return jinhuiCommunityService.recordGetList(pageNum, pageSize, this.getUserId() + ""); |
| | | } |
| | | |
| | | @ApiOperation(value = "获取个人金汇币明细详情", response = JinhuiGoldCoinRecordVO.class) |
| | | @GetMapping("/jinhuiRecord/getDetails") |
| | | public R recordGetDetails(@RequestParam("id") String id) |
| | | { |
| | | public R recordGetDetails(@RequestParam("id") String id) { |
| | | return jinhuiCommunityService.recordGetDetails(id); |
| | | } |
| | | |
| | | @ApiOperation(value = "删除金汇币记录") |
| | | @PostMapping("/record/expurgateData") |
| | | public R recordExpurgateData(@RequestParam("id") String id) |
| | | { |
| | | public R recordExpurgateData(@RequestParam("id") String id) { |
| | | return jinhuiCommunityService.recordExpurgateData(id); |
| | | } |
| | | |
| | | |
| | | |
| | | /** |
| | |
| | | * @param workGuideId |
| | | * @return 详情 |
| | | */ |
| | | @ApiOperation(value = "办事指南_详情") |
| | | @ApiOperation(value = "办事指南_详情", response = ComActWorkGuideVO.class) |
| | | @GetMapping("/detailworkguide") |
| | | public R detailWorkGuide(@RequestParam("workGuideId") String workGuideId, |
| | | @RequestParam("communityId") String communityId) |
| | | { |
| | | return jinhuiCommunityService.detailWorkGuide(workGuideId,communityId); |
| | | @RequestParam("communityId") String communityId) { |
| | | return jinhuiCommunityService.detailWorkGuide(workGuideId, communityId); |
| | | } |
| | | |
| | | /** |
| | | * 办事指南_分页 |
| | | * |
| | | * @param pageActWorkGuideDTO |
| | | * 查询参数 |
| | | * @param pageActWorkGuideDTO 查询参数 |
| | | * @return 分页集合 |
| | | */ |
| | | @ApiOperation(value = "办事指南_分页") |
| | | @ApiOperation(value = "办事指南_分页", response = ComActWorkGuideVO.class) |
| | | @PostMapping("/pageworkguide") |
| | | public R pageWorkGuide(@RequestBody PageActWorkGuideDTO pageActWorkGuideDTO) |
| | | { |
| | | public R pageWorkGuide(@RequestBody PageActWorkGuideDTO pageActWorkGuideDTO) { |
| | | return jinhuiCommunityService.pageWorkGuide(pageActWorkGuideDTO); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 删除便民服务商家 |
| | | * |
| | | * @param merchantId |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "删除便民服务商家") |
| | | @DeleteMapping("/merchant/delete") |
| | | public R deleteMerchant(@RequestParam("merchantId") String merchantId, |
| | | @RequestParam("operator") String operator) { |
| | | return jinhuiCommunityService.deleteMerchant(merchantId, operator); |
| | | } |
| | | |
| | | /** |
| | | * 分页查询便民服务商家 运营后台 |
| | | * |
| | | * @param pageConvenientMerchantDTO |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "分页查询便民服务商家", response = ConvenientMerchantVO.class) |
| | | @PostMapping("/merchant/page") |
| | | public R pageMerchant(@RequestBody PageConvenientMerchantDTO pageConvenientMerchantDTO) |
| | | { |
| | | return jinhuiCommunityService.pageMerchant(pageConvenientMerchantDTO); |
| | | } |
| | | |
| | | /** |
| | | * 获取便民服务商家详情 |
| | | * |
| | | * @param merchantId |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "获取便民服务商家详情", response = ConvenientMerchantVO.class) |
| | | @GetMapping("/merchant/get") |
| | | public R getMerchant(@RequestParam("merchantId") String merchantId) |
| | | { |
| | | return jinhuiCommunityService.getMerchant(merchantId); |
| | | } |
| | | |
| | | |
| | | |
| | | /** |
| | | * 分页查询 商家类别 |
| | | * @param |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "获取便民服务商家类别列表", response = ConvenientServiceCategoryVO.class) |
| | | @GetMapping("/getCategories") |
| | | public R getListCategories(@RequestParam("pageNum") int pageNum, |
| | | @RequestParam("pageSize") int pageSize) |
| | | { |
| | | return jinhuiCommunityService.getListCategories(pageNum,pageSize); |
| | | } |
| | | |
| | | |
| | | /*************************************************************************************************** |
| | | * |
| | | * |
| | | * 商家评论 |
| | | * |
| | | * |
| | | **************************************************************************************************/ |
| | | /** |
| | | * 商家评论列表 |
| | | * @param pageNum |
| | | * @param pageSize |
| | | * @param merchantId |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "商家评论列表", response = JinghuiMerchantEvaluateVO.class) |
| | | @GetMapping("/merchantEvaluate/getList") |
| | | public R merchantEvaluateGetList(@RequestParam("pageNum") int pageNum, |
| | | @RequestParam("pageSize") int pageSize, |
| | | @RequestParam("merchantId") String merchantId) |
| | | { |
| | | return jinhuiCommunityService.merchantEvaluateGetList(pageNum,pageSize,merchantId); |
| | | } |
| | | |
| | | /** |
| | | * 商家评论列单个详情 |
| | | * @param id |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "商家评论列单个详情", response = JinghuiMerchantEvaluateVO.class) |
| | | @GetMapping("/merchantEvaluate/getDetails") |
| | | public R merchantEvaluateGetDetails(@RequestParam("id") String id) |
| | | { |
| | | return jinhuiCommunityService.merchantEvaluateGetDetails(id); |
| | | } |
| | | |
| | | /** |
| | | * 商家评论列添加 |
| | | * @param |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "商家评论列添加") |
| | | @PostMapping("/merchantEvaluate/addData") |
| | | public R merchantEvaluateAddData(@RequestBody JinghuiMerchantEvaluateVO item) |
| | | { |
| | | return jinhuiCommunityService.merchantEvaluateAddData(item); |
| | | } |
| | | |
| | | /** |
| | | * 商家评论列编辑 |
| | | * @param item |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "商家评论列编辑") |
| | | @PostMapping("/merchantEvaluate/editData") |
| | | public R merchantEvaluateEditData(@RequestBody JinghuiMerchantEvaluateVO item) |
| | | { |
| | | return jinhuiCommunityService.merchantEvaluateEditData(item); |
| | | } |
| | | |
| | | /** |
| | | * 商家评论列删除 |
| | | * @param id |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "商家评论列删除") |
| | | @PostMapping("/merchantEvaluate/expurgateData") |
| | | public R merchantEvaluateExpurgateData(@RequestParam("id") String id) |
| | | { |
| | | return jinhuiCommunityService.merchantEvaluateExpurgateData(id); |
| | | } |
| | | |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.vos.jinhui; |
| | | |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.AllArgsConstructor; |
| | | import lombok.Builder; |
| | | import lombok.Data; |
| | | import lombok.NoArgsConstructor; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | @Data |
| | | @Builder |
| | | @AllArgsConstructor |
| | | @NoArgsConstructor |
| | | @ApiModel("金汇商家评价表") |
| | | public class JinghuiMerchantEvaluateVO implements Serializable { |
| | | private static final long serialVersionUID = -70884515430727555L; |
| | | |
| | | |
| | | @ApiModelProperty(value = "主键id") |
| | | private String id; |
| | | |
| | | @ApiModelProperty(value = "用户id") |
| | | private String userId; |
| | | |
| | | @ApiModelProperty(value = "商家id") |
| | | private String merchantId; |
| | | |
| | | @ApiModelProperty(value = "创建时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") |
| | | private Date creationTime; |
| | | |
| | | @ApiModelProperty(value = "更新时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") |
| | | private Date updateTime; |
| | | |
| | | @ApiModelProperty(value = "内容") |
| | | private String content; |
| | | |
| | | @ApiModelProperty(value = "图片url") |
| | | private String imgUrl; |
| | | |
| | | @ApiModelProperty(value = "评论人姓名") |
| | | private String userName; |
| | | |
| | | @ApiModelProperty(value = "评论人头像") |
| | | private String userUrl; |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | } |
| | |
| | | |
| | | import com.panzhihua.common.model.dtos.community.ComActWorkGuideDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageActWorkGuideDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageConvenientMerchantDTO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.community.ComActActRegistVO; |
| | | import com.panzhihua.common.model.vos.community.ComActWorkGuideClassifyVO; |
| | | import com.panzhihua.common.model.vos.community.SignactivityVO; |
| | | import com.panzhihua.common.model.vos.jinhui.JinghuiMerchantEvaluateVO; |
| | | import com.panzhihua.common.model.vos.jinhui.JinhuiCoinGeneralTableVO; |
| | | import com.panzhihua.common.model.vos.jinhui.JinhuiGoldCoinRecordVO; |
| | | import org.springframework.cloud.openfeign.FeignClient; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | | import org.springframework.web.bind.annotation.RequestBody; |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | /** |
| | | * 金汇社区 |
| | |
| | | public R recordExpurgateData(@RequestParam("id") String id); |
| | | |
| | | |
| | | /************************************************************************************************* |
| | | * |
| | | * 办事指南 |
| | | * |
| | | ***************************************************************************************************/ |
| | | |
| | | /** |
| | | * 办事指南_新增 |
| | |
| | | */ |
| | | @PostMapping("/JinhuiWorkGuide/addworkguide") |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public R addWorkGuide(@RequestBody ComActWorkGuideDTO workGuideDTO, @RequestParam("userId") Long userId); |
| | | public R addWorkGuide(@RequestBody ComActWorkGuideDTO workGuideDTO, @RequestParam("userId") String userId); |
| | | |
| | | /** |
| | | * 办事指南_编辑 |
| | |
| | | */ |
| | | @PostMapping("/JinhuiWorkGuide/editworkguide") |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public R putWorkGuide(@RequestBody ComActWorkGuideDTO workGuideDTO, @RequestParam("userId") Long userId) ; |
| | | public R putWorkGuide(@RequestBody ComActWorkGuideDTO workGuideDTO, @RequestParam("userId") String userId) ; |
| | | |
| | | /** |
| | | * 办事指南_详情 |
| | |
| | | * @return 删除结果 |
| | | */ |
| | | @PostMapping("/JinhuiWorkGuide/delectworkguide") |
| | | R delectWorkGuide(@RequestParam("workGuideId") Long workGuideId) ; |
| | | R delectWorkGuide(@RequestParam("workGuideId") String workGuideId) ; |
| | | |
| | | /** |
| | | * 分页查询办事执念-分类管理 addWorkGuideClassify 分页查询办事执念-分类管理 |
| | |
| | | * @date 2021/8/31 15:03 |
| | | */ |
| | | @GetMapping("/JinhuiWorkGuide/workGuide/classify/delete") |
| | | public R deleteWorkGuideClassify(@RequestParam("workGuideClassifyId") Long workGuideClassifyId) ; |
| | | public R deleteWorkGuideClassify(@RequestParam("workGuideClassifyId") String workGuideClassifyId) ; |
| | | |
| | | /** |
| | | * 办事指南-分类管理列表查询 getWorkGuideClassifyList 办事指南-分类管理列表查询 |
| | |
| | | * @return 办事指南列表数据 |
| | | */ |
| | | @GetMapping("/JinhuiWorkGuide/listworkguide/classify") |
| | | public R listWorkGuideByClassifyId(@RequestParam("classifyId") Long classifyId) ; |
| | | public R listWorkGuideByClassifyId(@RequestParam("classifyId") String classifyId) ; |
| | | |
| | | |
| | | /********************************************************************************************** |
| | | * |
| | | * |
| | | * 便民服务 |
| | | * |
| | | * |
| | | ************************************************************************************************/ |
| | | |
| | | /** |
| | | * 删除便民服务商家 |
| | | * |
| | | * @param merchantId |
| | | * @return |
| | | */ |
| | | @DeleteMapping("/jinhuiMerchant/delete") |
| | | public R deleteMerchant(@RequestParam("merchantId") String merchantId, @RequestParam("operator") String operator); |
| | | |
| | | /** |
| | | * 分页查询便民服务商家 运营后台 |
| | | * |
| | | * @param pageConvenientMerchantDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/jinhuiMerchant/page") |
| | | public R pageMerchant(@RequestBody PageConvenientMerchantDTO pageConvenientMerchantDTO); |
| | | |
| | | /** |
| | | * 获取便民服务商家详情 |
| | | * |
| | | * @param merchantId |
| | | * @return |
| | | */ |
| | | @GetMapping("/jinhuiMerchant/get") |
| | | public R getMerchant(@RequestParam("merchantId") String merchantId); |
| | | |
| | | |
| | | /** |
| | | * 分页查询 商家类别 |
| | | * @param |
| | | * @return |
| | | */ |
| | | @GetMapping("/jinhuiMerchant/getCategories") |
| | | public R getListCategories(@RequestParam("pageNum") int pageNum, |
| | | @RequestParam("pageSize") int pageSize); |
| | | |
| | | |
| | | /************************************************************************************************************** |
| | | * |
| | | * |
| | | * 商家评论 |
| | | * |
| | | * |
| | | *************************************************************************************************************/ |
| | | /** |
| | | * 商家评论列表 |
| | | * @param pageNum |
| | | * @param pageSize |
| | | * @param merchantId |
| | | * @return |
| | | */ |
| | | @GetMapping("/jinghuiMerchantEvaluate/getList") |
| | | public R merchantEvaluateGetList(@RequestParam("pageNum") int pageNum, |
| | | @RequestParam("pageSize") int pageSize, |
| | | @RequestParam("merchantId") String merchantId); |
| | | |
| | | /** |
| | | * 商家评论列单个详情 |
| | | * @param id |
| | | * @return |
| | | */ |
| | | @GetMapping("/jinghuiMerchantEvaluate/getDetails") |
| | | public R merchantEvaluateGetDetails(@RequestParam("id") String id); |
| | | /** |
| | | * 商家评论列添加 |
| | | * @param |
| | | * @return |
| | | */ |
| | | @PostMapping("/jinghuiMerchantEvaluate/addData") |
| | | public R merchantEvaluateAddData(@RequestBody JinghuiMerchantEvaluateVO item); |
| | | |
| | | /** |
| | | * 商家评论列编辑 |
| | | * @param item |
| | | * @return |
| | | */ |
| | | @PostMapping("/jinghuiMerchantEvaluate/editData") |
| | | public R merchantEvaluateEditData(@RequestBody JinghuiMerchantEvaluateVO item); |
| | | |
| | | /** |
| | | * 商家评论列删除 |
| | | * @param id |
| | | * @return |
| | | */ |
| | | @PostMapping("/jinghuiMerchantEvaluate/expurgateData") |
| | | public R merchantEvaluateExpurgateData(@RequestParam("id") String id); |
| | | |
| | | |
| | | |
| | |
| | | * @param pageConvenientServiceCategoryDTO |
| | | * @return 服务分类详情 |
| | | */ |
| | | IPage<ConvenientServiceCategoryVO> pageServiceCategory(@Param("page") Page page, @Param("pageConvenientServiceCategoryDTO") |
| | | IPage<ConvenientServiceCategoryVO> pageServiceCategory(@Param("page") Page page, |
| | | @Param("pageConvenientServiceCategoryDTO") |
| | | PageConvenientServiceCategoryDTO pageConvenientServiceCategoryDTO); |
| | | |
| | | /** |
| | |
| | | */ |
| | | @Service |
| | | @Slf4j |
| | | public class ConvenientMerchantServiceImpl extends ServiceImpl<ConvenientMerchantDAO, ConvenientMerchantDO> implements ConvenientMerchantService { |
| | | public class ConvenientMerchantServiceImpl extends ServiceImpl<ConvenientMerchantDAO, ConvenientMerchantDO> |
| | | implements ConvenientMerchantService { |
| | | |
| | | @Resource |
| | | private UserService userService; |
New file |
| | |
| | | package com.panzhihua.service_jinhui_community.api; |
| | | |
| | | |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.jinhui.JinghuiMerchantEvaluateVO; |
| | | import com.panzhihua.common.model.vos.jinhui.JinhuiCoinGeneralTableVO; |
| | | import com.panzhihua.service_jinhui_community.service.JinghuiMerchantEvaluateService; |
| | | import com.panzhihua.service_jinhui_community.service.JinhuiCoinGeneralTableService; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | /** |
| | | * @auther llming |
| | | * @describe 金汇商家评价 |
| | | */ |
| | | @Slf4j |
| | | @RestController |
| | | @RequestMapping("/jinghuiMerchantEvaluate") |
| | | public class JinghuiMerchantEvaluateApi |
| | | { |
| | | @Resource |
| | | private JinghuiMerchantEvaluateService evaluateService; |
| | | |
| | | |
| | | /** |
| | | * 商家评论列表 |
| | | * @param pageNum |
| | | * @param pageSize |
| | | * @param merchantId |
| | | * @return |
| | | */ |
| | | @GetMapping("/getList") |
| | | public R merchantEvaluateGetList(@RequestParam("pageNum") int pageNum, |
| | | @RequestParam("pageSize") int pageSize, |
| | | @RequestParam("merchantId") String merchantId) |
| | | { |
| | | return evaluateService.getList(pageNum,pageSize,merchantId); |
| | | } |
| | | |
| | | /** |
| | | * 商家评论列单个详情 |
| | | * @param id |
| | | * @return |
| | | */ |
| | | @GetMapping("/getDetails") |
| | | public R merchantEvaluateGetDetails(@RequestParam("id") String id) |
| | | { |
| | | return R.ok(evaluateService.getDetails(id)); |
| | | } |
| | | /** |
| | | * 商家评论列添加 |
| | | * @param |
| | | * @return |
| | | */ |
| | | @PostMapping("/addData") |
| | | public R merchantEvaluateAddData(@RequestBody JinghuiMerchantEvaluateVO item) |
| | | { |
| | | return evaluateService.addData(item); |
| | | } |
| | | |
| | | /** |
| | | * 商家评论列编辑 |
| | | * @param item |
| | | * @return |
| | | */ |
| | | @PostMapping("/editData") |
| | | public R merchantEvaluateEditData(@RequestBody JinghuiMerchantEvaluateVO item) |
| | | { |
| | | return evaluateService.editData(item); |
| | | } |
| | | |
| | | /** |
| | | * 商家评论列删除 |
| | | * @param id |
| | | * @return |
| | | */ |
| | | @PostMapping("/expurgateData") |
| | | public R merchantEvaluateExpurgateData(@RequestParam("id") String id) |
| | | { |
| | | return evaluateService.expurgateData(id); |
| | | } |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_jinhui_community.api; |
| | | |
| | | |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageConvenientMerchantDTO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.service_jinhui_community.service.JinhuiComConvenientServiceCategoriesService; |
| | | import com.panzhihua.service_jinhui_community.service.JinhuiConvenientMerchantService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | /** |
| | | * @auther llming |
| | | * @describe 金汇商家便民服务 |
| | | */ |
| | | @Slf4j |
| | | @RestController |
| | | @RequestMapping("/jinhuiMerchant") |
| | | public class JinhuiMerchantApi |
| | | { |
| | | @Resource |
| | | private JinhuiConvenientMerchantService jinhuiConvenientMerchantService; |
| | | |
| | | @Resource |
| | | private JinhuiComConvenientServiceCategoriesService categoriesService; |
| | | |
| | | |
| | | /** |
| | | * 删除便民服务商家 |
| | | * |
| | | * @param merchantId |
| | | * @return |
| | | */ |
| | | @DeleteMapping("/delete") |
| | | public R deleteMerchant(@RequestParam("merchantId") String merchantId, |
| | | @RequestParam("operator") String operator) { |
| | | return jinhuiConvenientMerchantService.deleteMerchant(merchantId, operator); |
| | | } |
| | | |
| | | /** |
| | | * 分页查询便民服务商家 运营后台 |
| | | * |
| | | * @param pageConvenientMerchantDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/page") |
| | | public R pageMerchant(@RequestBody PageConvenientMerchantDTO pageConvenientMerchantDTO) { |
| | | return jinhuiConvenientMerchantService.pageMerchant(pageConvenientMerchantDTO); |
| | | } |
| | | |
| | | /** |
| | | * 获取便民服务商家详情 |
| | | * |
| | | * @param merchantId |
| | | * @return |
| | | */ |
| | | @GetMapping("/get") |
| | | public R getMerchant(@RequestParam("merchantId") String merchantId) { |
| | | return jinhuiConvenientMerchantService.getMerchant(merchantId); |
| | | } |
| | | |
| | | /** |
| | | * 分页查询 商家类别 |
| | | * @param |
| | | * @return |
| | | */ |
| | | @GetMapping("/getCategories") |
| | | public R getListCategories(@RequestParam("pageNum") int pageNum, |
| | | @RequestParam("pageSize") int pageSize) |
| | | { |
| | | return categoriesService.getList(pageNum,pageSize); |
| | | } |
| | | |
| | | |
| | | } |
| | |
| | | */ |
| | | @PostMapping("addworkguide") |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public R addWorkGuide(@RequestBody ComActWorkGuideDTO workGuideDTO, @RequestParam("userId") Long userId) { |
| | | public R addWorkGuide(@RequestBody ComActWorkGuideDTO workGuideDTO, @RequestParam("userId") String userId) { |
| | | return workGuideService.addWorkGuide(workGuideDTO, userId); |
| | | } |
| | | |
| | |
| | | */ |
| | | @PostMapping("editworkguide") |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public R putWorkGuide(@RequestBody ComActWorkGuideDTO workGuideDTO, @RequestParam("userId") Long userId) { |
| | | public R putWorkGuide(@RequestBody ComActWorkGuideDTO workGuideDTO, @RequestParam("userId") String userId) { |
| | | return workGuideService.editWorkGuide(workGuideDTO, userId); |
| | | } |
| | | |
| | |
| | | * @return 删除结果 |
| | | */ |
| | | @PostMapping("delectworkguide") |
| | | R delectWorkGuide(@RequestParam("workGuideId") Long workGuideId) { |
| | | R delectWorkGuide(@RequestParam("workGuideId") String workGuideId) { |
| | | return workGuideService.delectWorkGuide(workGuideId); |
| | | } |
| | | |
| | |
| | | * @date 2021/8/31 15:03 |
| | | */ |
| | | @GetMapping("workGuide/classify/delete") |
| | | public R deleteWorkGuideClassify(@RequestParam("workGuideClassifyId") Long workGuideClassifyId) { |
| | | public R deleteWorkGuideClassify(@RequestParam("workGuideClassifyId") String workGuideClassifyId) { |
| | | return comActWorkGuideClassifyService.deleteWorkGuideClassify(workGuideClassifyId); |
| | | } |
| | | |
| | |
| | | * @return 办事指南列表数据 |
| | | */ |
| | | @GetMapping("listworkguide/classify") |
| | | public R listWorkGuideByClassifyId(@RequestParam("classifyId") Long classifyId) { |
| | | public R listWorkGuideByClassifyId(@RequestParam("classifyId") String classifyId) { |
| | | return workGuideService.listWorkGuideByClassifyId(classifyId); |
| | | } |
| | | |
New file |
| | |
| | | package com.panzhihua.service_jinhui_community.dao; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.panzhihua.common.model.vos.jinhui.JinghuiMerchantEvaluateVO; |
| | | import com.panzhihua.service_jinhui_community.entity.JinghuiMerchantEvaluate; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | @Mapper |
| | | public interface JinghuiMerchantEvaluateDao extends BaseMapper<JinghuiMerchantEvaluate> |
| | | { |
| | | /** |
| | | * 分页查询 |
| | | * @param |
| | | * @return |
| | | */ |
| | | IPage<JinghuiMerchantEvaluate> getList(Page page, |
| | | @Param("merchantId") String merchantId); |
| | | |
| | | JinghuiMerchantEvaluate getDetails(@Param("id") String id); |
| | | |
| | | /** |
| | | * 新增 |
| | | * @param |
| | | * @return |
| | | */ |
| | | int addData(@Param("item") JinghuiMerchantEvaluateVO item); |
| | | |
| | | |
| | | int editData(@Param("item") JinghuiMerchantEvaluateVO item); |
| | | |
| | | |
| | | int expurgateData(@Param("id") String id); |
| | | |
| | | |
| | | } |
| | |
| | | * @param pageSize 默认展示条数 |
| | | * @return 办事指南列表 |
| | | */ |
| | | List<ComActWorkGuideDetailAppletsVO> getWorkGuideListByClassifyId(@Param("classifyId") Long classifyId,@Param("pageSize") Long pageSize); |
| | | List<ComActWorkGuideDetailAppletsVO> getWorkGuideListByClassifyId(@Param("classifyId") String classifyId, |
| | | @Param("pageSize") String pageSize); |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_jinhui_community.dao; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.panzhihua.common.model.vos.jinhui.JinhuiGoldCoinRecordVO; |
| | | import com.panzhihua.service_jinhui_community.entity.JinhuiComConvenientServiceCategories; |
| | | import com.panzhihua.service_jinhui_community.entity.JinhuiGoldCoinRecord; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | @Mapper |
| | | public interface JinhuiComConvenientServiceCategoriesDao extends BaseMapper<JinhuiComConvenientServiceCategories> |
| | | { |
| | | /** |
| | | * 分页查询 |
| | | * @param |
| | | * @return |
| | | */ |
| | | IPage<JinhuiComConvenientServiceCategories> getList(Page page); |
| | | |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_jinhui_community.dao; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.panzhihua.common.model.dtos.PageBaseDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.*; |
| | | import com.panzhihua.common.model.vos.community.StatisticsCommVO; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenMerchantStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientConsultationStatisticsVO; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientMerchantVO; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientViewStatisticsVO; |
| | | import com.panzhihua.common.model.vos.community.convenient.ExportMerchantVO; |
| | | import com.panzhihua.service_jinhui_community.entity.JinhuiConvenientMerchant; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @title: ConvenientMerchantDAO |
| | | * @projectName: 成都呐喊信息技术有限公司-智慧社区项目 |
| | | * @description: 便民服务商家DAO |
| | | * @author: hans |
| | | * @date: 2021/09/16 16:13 |
| | | */ |
| | | @Mapper |
| | | public interface JinhuiConvenientMerchantDao extends BaseMapper<JinhuiConvenientMerchant> |
| | | { |
| | | /** |
| | | * 删除便民服务商家 |
| | | * |
| | | * @param merchantId |
| | | * @param operator |
| | | * @return |
| | | */ |
| | | int deleteMerchantById(@Param("merchantId") String merchantId, @Param("operator") String operator); |
| | | |
| | | /** |
| | | * 分页查询便民服务商家 运营后台 |
| | | * |
| | | * @param page 分页参数 |
| | | * @param pageConvenientMerchantDTO |
| | | * @return |
| | | */ |
| | | IPage<ConvenientMerchantVO> pageMerchant(@Param("page") Page page, |
| | | @Param("pageConvenientMerchantDTO") PageConvenientMerchantDTO pageConvenientMerchantDTO); |
| | | |
| | | /** |
| | | * 查询商家信息 |
| | | * |
| | | * @param merchantId |
| | | * @return |
| | | */ |
| | | ConvenientMerchantVO selectMerchantById(@Param("merchantId") String merchantId); |
| | | |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_jinhui_community.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.AllArgsConstructor; |
| | | import lombok.Builder; |
| | | import lombok.Data; |
| | | import lombok.NoArgsConstructor; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | @Data |
| | | @Builder |
| | | @AllArgsConstructor |
| | | @NoArgsConstructor |
| | | @ApiModel("金汇商家评价表") |
| | | public class JinghuiMerchantEvaluate implements Serializable { |
| | | private static final long serialVersionUID = -70884515430727555L; |
| | | |
| | | |
| | | @ApiModelProperty(value = "主键id") |
| | | private String id; |
| | | |
| | | @ApiModelProperty(value = "用户id") |
| | | private String userId; |
| | | |
| | | @ApiModelProperty(value = "商家id") |
| | | private String merchantId; |
| | | |
| | | @ApiModelProperty(value = "创建时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") |
| | | private Date creationTime; |
| | | |
| | | @ApiModelProperty(value = "更新时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") |
| | | private Date updateTime; |
| | | |
| | | @ApiModelProperty(value = "内容") |
| | | private String content; |
| | | |
| | | @ApiModelProperty(value = "图片url") |
| | | private String imgUrl; |
| | | |
| | | @TableField(exist = false) |
| | | @ApiModelProperty(value = "评论人姓名") |
| | | private String userName; |
| | | |
| | | @TableField(exist = false) |
| | | @ApiModelProperty(value = "评论人头像") |
| | | private String userUrl; |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_jinhui_community.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | /** |
| | | * 商家分类表 |
| | | */ |
| | | |
| | | @Data |
| | | @TableName(value = "jinhui_com_convenient_service_categories") |
| | | public class JinhuiComConvenientServiceCategories implements Serializable |
| | | { |
| | | |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | |
| | | @ApiModelProperty(value = "主键") |
| | | private String id; |
| | | |
| | | @ApiModelProperty(value = "分类名称") |
| | | private String name; |
| | | |
| | | @ApiModelProperty(value = "分类图标") |
| | | private String icon; |
| | | |
| | | @ApiModelProperty(value = "备注") |
| | | private String remark; |
| | | |
| | | @ApiModelProperty(value = "权重,默认1") |
| | | private String weight; |
| | | |
| | | @ApiModelProperty(value = "是否删除") |
| | | private String isDel; |
| | | |
| | | @ApiModelProperty(value = "创建时间") |
| | | private String createdAt; |
| | | |
| | | @ApiModelProperty(value = "创建人") |
| | | private String createdBy; |
| | | |
| | | @ApiModelProperty(value = "更新时间") |
| | | private String updatedAt; |
| | | |
| | | @ApiModelProperty(value = "更新人") |
| | | private String updatedBy; |
| | | |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_jinhui_community.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | import java.math.BigDecimal; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @title: ConvenientMerchantDO |
| | | * @projectName: 成都呐喊信息技术有限公司-智慧社区项目 |
| | | * @description: 便民服务商家DO |
| | | * @author: hans |
| | | * @date: 2021/09/16 16:04 |
| | | */ |
| | | @Data |
| | | @TableName(value = "jinhui_com_convenient_merchants") |
| | | public class JinhuiConvenientMerchant implements Serializable { |
| | | |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 主键id |
| | | */ |
| | | @TableId(type = IdType.ASSIGN_ID) |
| | | private Long id; |
| | | /** |
| | | * 商家名称 |
| | | */ |
| | | private String name; |
| | | /** |
| | | * 社区id |
| | | */ |
| | | private Long communityId; |
| | | /** |
| | | * 社区名称 |
| | | */ |
| | | private String communityName; |
| | | /** |
| | | * 商家logo |
| | | */ |
| | | private String logo; |
| | | /** |
| | | * 联系人 |
| | | */ |
| | | private String contacts; |
| | | /** |
| | | * 身份证号码 |
| | | */ |
| | | private String idCard; |
| | | /** |
| | | * 咨询电话 |
| | | */ |
| | | private String phone; |
| | | /** |
| | | * 商家地址 |
| | | */ |
| | | private String address; |
| | | |
| | | /** |
| | | * 详细地址 |
| | | */ |
| | | private String detailedAddress; |
| | | /** |
| | | * 纬度 |
| | | */ |
| | | private String lat; |
| | | /** |
| | | * 经度 |
| | | */ |
| | | private String lon; |
| | | /** |
| | | * 营业开始时间 |
| | | */ |
| | | private Date beginAt; |
| | | /** |
| | | * 营业截止时间 |
| | | */ |
| | | private Date endAt; |
| | | /** |
| | | * 营业周期 |
| | | */ |
| | | private String period; |
| | | /** |
| | | * 商家介绍 |
| | | */ |
| | | private String introduction; |
| | | /** |
| | | * 营业状态 |
| | | */ |
| | | private Boolean businessStatus; |
| | | /** |
| | | * 商家绑定用户id |
| | | */ |
| | | private Long userId; |
| | | /** |
| | | * 咨询量 |
| | | */ |
| | | private Integer consultationVolume; |
| | | /** |
| | | * 浏览量 |
| | | */ |
| | | private Integer viewNum; |
| | | /** |
| | | * 是否删除 |
| | | */ |
| | | private Boolean isDel; |
| | | /** |
| | | * 创建时间 |
| | | */ |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Date createdAt; |
| | | |
| | | /** |
| | | * 创建人 |
| | | */ |
| | | private Long createdBy; |
| | | /** |
| | | * 更新时间 |
| | | */ |
| | | @TableField(fill = FieldFill.UPDATE) |
| | | private Date updatedAt; |
| | | /** |
| | | * 更新人 |
| | | */ |
| | | private Long updatedBy; |
| | | |
| | | private String areaCode; |
| | | |
| | | /** |
| | | * 服务范围 |
| | | */ |
| | | private Integer serviceRange; |
| | | |
| | | /** |
| | | * 手机号 |
| | | */ |
| | | private String mobilePhone; |
| | | |
| | | /** |
| | | * 店铺销量 |
| | | */ |
| | | private Integer sale; |
| | | |
| | | /** |
| | | * 店铺销售额 |
| | | */ |
| | | private BigDecimal saleVolume; |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_jinhui_community.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.jinhui.JinghuiMerchantEvaluateVO; |
| | | import com.panzhihua.service_jinhui_community.entity.JinghuiMerchantEvaluate; |
| | | |
| | | public interface JinghuiMerchantEvaluateService extends IService<JinghuiMerchantEvaluate> |
| | | { |
| | | /** |
| | | * 分页查询 |
| | | * @param |
| | | * @return |
| | | */ |
| | | R getList(int pageNum,int pageSize,String merchantId); |
| | | |
| | | JinghuiMerchantEvaluate getDetails(String id); |
| | | /** |
| | | * 新增 |
| | | * @param |
| | | * @return |
| | | */ |
| | | R addData(JinghuiMerchantEvaluateVO jinhuiGoldCoinRecordVO); |
| | | |
| | | R editData(JinghuiMerchantEvaluateVO jinhuiGoldCoinRecordVO); |
| | | |
| | | R expurgateData(String id); |
| | | } |
| | |
| | | * @author txb |
| | | * @date 2021/8/31 15:03 |
| | | */ |
| | | R deleteWorkGuideClassify(Long workGuideClassifyId); |
| | | R deleteWorkGuideClassify(String workGuideClassifyId); |
| | | |
| | | /** |
| | | * 办事指南-分类管理列表查询 getWorkGuideClassifyList 办事指南-分类管理列表查询 |
| | |
| | | * 办事指南信息 |
| | | * @return 新增结果 |
| | | */ |
| | | R addWorkGuide(ComActWorkGuideDTO workGuideDTO, Long userId); |
| | | R addWorkGuide(ComActWorkGuideDTO workGuideDTO, String userId); |
| | | |
| | | /** |
| | | * 办事指南_编辑 |
| | |
| | | * 编辑内容 |
| | | * @return 编辑结果 |
| | | */ |
| | | R editWorkGuide(ComActWorkGuideDTO workGuideDTO, Long userId); |
| | | R editWorkGuide(ComActWorkGuideDTO workGuideDTO, String userId); |
| | | |
| | | /** |
| | | * 办事指南_详情 |
| | |
| | | * 办事指南id |
| | | * @return 删除结果 |
| | | */ |
| | | R delectWorkGuide(Long workGuideId); |
| | | R delectWorkGuide(String workGuideId); |
| | | |
| | | /** |
| | | * 办事指南列表-按分类查询 |
| | |
| | | * @param classifyId 办事指南分类id |
| | | * @return 办事指南列表数据 |
| | | */ |
| | | R listWorkGuideByClassifyId(Long classifyId); |
| | | R listWorkGuideByClassifyId(String classifyId); |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_jinhui_community.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.jinhui.JinhuiGoldCoinRecordVO; |
| | | import com.panzhihua.service_jinhui_community.entity.JinhuiComConvenientServiceCategories; |
| | | import com.panzhihua.service_jinhui_community.entity.JinhuiGoldCoinRecord; |
| | | |
| | | public interface JinhuiComConvenientServiceCategoriesService extends IService<JinhuiComConvenientServiceCategories> |
| | | { |
| | | /** |
| | | * 分页查询 |
| | | * @param |
| | | * @return |
| | | */ |
| | | R getList(int pageNum,int pageSize); |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_jinhui_community.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.panzhihua.common.model.dtos.community.convenient.*; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientMerchantVO; |
| | | import com.panzhihua.service_jinhui_community.entity.JinhuiConvenientMerchant; |
| | | |
| | | /** |
| | | * @title: ConvenientMerchantService |
| | | * @projectName: 成都呐喊信息技术有限公司-智慧社区项目 |
| | | * @description: 便民服务商家服务类 |
| | | * @author: hans |
| | | * @date: 2021/09/16 16:02 |
| | | */ |
| | | public interface JinhuiConvenientMerchantService extends IService<JinhuiConvenientMerchant> { |
| | | |
| | | |
| | | /** |
| | | * 删除便民服务商家 |
| | | * @param merchantId 商家id |
| | | * @param operator 操作人员 |
| | | * @return |
| | | */ |
| | | R deleteMerchant(String merchantId, String operator); |
| | | |
| | | /** |
| | | * 分页查询便民服务商家 |
| | | * @param pageConvenientMerchantDTO |
| | | * @return |
| | | */ |
| | | R pageMerchant(PageConvenientMerchantDTO pageConvenientMerchantDTO); |
| | | |
| | | /** |
| | | * 获取便民服务商家详情 |
| | | * @param merchantId |
| | | * @return |
| | | */ |
| | | R getMerchant(String merchantId); |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_jinhui_community.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.jinhui.JinghuiMerchantEvaluateVO; |
| | | import com.panzhihua.service_jinhui_community.dao.JinghuiMerchantEvaluateDao; |
| | | import com.panzhihua.service_jinhui_community.entity.JinghuiMerchantEvaluate; |
| | | import com.panzhihua.service_jinhui_community.service.JinghuiMerchantEvaluateService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | |
| | | @Slf4j |
| | | @Service |
| | | public class JinghuiMerchantEvaluateServiceImpl extends ServiceImpl<JinghuiMerchantEvaluateDao, |
| | | JinghuiMerchantEvaluate> implements JinghuiMerchantEvaluateService |
| | | { |
| | | |
| | | @Override |
| | | public R getList(int pageNum,int pageSize,String merchantId) |
| | | { |
| | | Page page = new Page<JinghuiMerchantEvaluate>(pageNum,pageSize); |
| | | return R.ok(baseMapper.getList(page,merchantId)); |
| | | } |
| | | |
| | | @Override |
| | | public JinghuiMerchantEvaluate getDetails(String id) { |
| | | return baseMapper.getDetails(id); |
| | | } |
| | | |
| | | |
| | | @Override |
| | | public R addData(JinghuiMerchantEvaluateVO volunteerTypeVO) |
| | | { |
| | | int num= baseMapper.addData(volunteerTypeVO); |
| | | if(num>0) |
| | | { |
| | | return R.ok(); |
| | | } |
| | | return R.fail("添加失败"); |
| | | } |
| | | |
| | | @Override |
| | | public R editData(JinghuiMerchantEvaluateVO volunteerTypeVO) { |
| | | int num= baseMapper.editData(volunteerTypeVO); |
| | | if(num>0) |
| | | { |
| | | return R.ok(); |
| | | } |
| | | return R.fail("添加失败"); |
| | | } |
| | | |
| | | @Override |
| | | public R expurgateData(String id) { |
| | | int num= baseMapper.expurgateData(id); |
| | | if(num>0) |
| | | { |
| | | return R.ok(); |
| | | } |
| | | return R.fail("添加失败"); |
| | | } |
| | | } |
| | |
| | | } |
| | | |
| | | @Override |
| | | public R deleteWorkGuideClassify(Long workGuideClassifyId) { |
| | | public R deleteWorkGuideClassify(String workGuideClassifyId) { |
| | | // 查询特殊群体人员 |
| | | JinhuiComActWorkGuideClassify comActWorkGuideClassifyDO = comActWorkGuideClassifyDAO.selectById(workGuideClassifyId); |
| | | JinhuiComActWorkGuideClassify comActWorkGuideClassifyDO = |
| | | comActWorkGuideClassifyDAO.selectById(workGuideClassifyId); |
| | | if (comActWorkGuideClassifyDO == null) { |
| | | return R.fail("办事指南分类不存在"); |
| | | } |
| | |
| | | ComActDAO comActDAO; |
| | | |
| | | @Override |
| | | public R addWorkGuide(ComActWorkGuideDTO workGuideDTO, Long userId) { |
| | | public R addWorkGuide(ComActWorkGuideDTO workGuideDTO, String userId) { |
| | | JinhuiComActWorkGuide comActWorkGuideDO = new JinhuiComActWorkGuide(); |
| | | BeanUtils.copyProperties(workGuideDTO, comActWorkGuideDO); |
| | | comActWorkGuideDO.setCreateBy(userId+""); |
| | |
| | | } |
| | | |
| | | @Override |
| | | public R editWorkGuide(ComActWorkGuideDTO workGuideDTO, Long userId) { |
| | | public R editWorkGuide(ComActWorkGuideDTO workGuideDTO, String userId) { |
| | | if (workGuideDTO.getId() == 0L) { |
| | | return R.fail("Id有误!"); |
| | | } |
| | |
| | | } |
| | | |
| | | @Override |
| | | public R delectWorkGuide(Long workGuideId) { |
| | | public R delectWorkGuide(String workGuideId) { |
| | | this.baseMapper.deleteById(workGuideId); |
| | | workGuideMaterialDAO.delete(new LambdaQueryWrapper<JinhuiComActWorkGuideMaterial>() |
| | | .eq(JinhuiComActWorkGuideMaterial::getWorkGuideId, workGuideId)); |
| | |
| | | List<ComActWorkGuideAppletsVO> workGuideClassifyList = comActWorkGuideClassifyDAO.listWorkGuideClassify(pageActWorkGuideDTO.getAreaCode()); |
| | | //通过办事指南分类查询分类下办事指南 |
| | | workGuideClassifyList.forEach(workGuideClassify -> { |
| | | List<ComActWorkGuideDetailAppletsVO> workGuideList = this.baseMapper.getWorkGuideListByClassifyId(workGuideClassify.getId(),10L); |
| | | List<ComActWorkGuideDetailAppletsVO> workGuideList = |
| | | this.baseMapper.getWorkGuideListByClassifyId(workGuideClassify.getId()+"","10"); |
| | | if(workGuideList != null && workGuideList.size() > 0){ |
| | | workGuideClassify.setGuideDetailList(workGuideList); |
| | | //分类下办事指南数据大于0加入到结果集中向小程序展示 |
| | |
| | | * @return 办事指南列表数据 |
| | | */ |
| | | @Override |
| | | public R listWorkGuideByClassifyId(Long classifyId){ |
| | | public R listWorkGuideByClassifyId(String classifyId){ |
| | | return R.ok(this.baseMapper.getWorkGuideListByClassifyId(classifyId,null)); |
| | | } |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_jinhui_community.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.jinhui.JinhuiCoinGeneralTableVO; |
| | | import com.panzhihua.service_jinhui_community.dao.JinhuiCoinGeneralTableDao; |
| | | import com.panzhihua.service_jinhui_community.dao.JinhuiComConvenientServiceCategoriesDao; |
| | | import com.panzhihua.service_jinhui_community.entity.JinhuiCoinGeneralTable; |
| | | import com.panzhihua.service_jinhui_community.entity.JinhuiComConvenientServiceCategories; |
| | | import com.panzhihua.service_jinhui_community.service.JinhuiCoinGeneralTableService; |
| | | import com.panzhihua.service_jinhui_community.service.JinhuiComConvenientServiceCategoriesService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | |
| | | @Slf4j |
| | | @Service |
| | | public class JinhuiComConvenientServiceCategoriesServiceImpl extends ServiceImpl<JinhuiComConvenientServiceCategoriesDao, |
| | | JinhuiComConvenientServiceCategories> implements JinhuiComConvenientServiceCategoriesService |
| | | { |
| | | |
| | | @Override |
| | | public R getList(int pageNum,int pageSize) |
| | | { |
| | | Page page = new Page<>(pageNum,pageSize); |
| | | return R.ok(baseMapper.getList(page)); |
| | | } |
| | | |
| | | // @Override |
| | | // public JinhuiCoinGeneralTable getDetails(String userId) { |
| | | // return baseMapper.getDetails(userId); |
| | | // } |
| | | // |
| | | // |
| | | // @Override |
| | | // public R addData(JinhuiCoinGeneralTableVO volunteerTypeVO) |
| | | // { |
| | | // int num= baseMapper.addData(volunteerTypeVO); |
| | | // if(num>0) |
| | | // { |
| | | // return R.ok(); |
| | | // } |
| | | // return R.fail("添加失败"); |
| | | // } |
| | | // |
| | | // @Override |
| | | // public R editData(JinhuiCoinGeneralTableVO volunteerTypeVO) { |
| | | // int num= baseMapper.editData(volunteerTypeVO); |
| | | // if(num>0) |
| | | // { |
| | | // return R.ok(); |
| | | // } |
| | | // return R.fail("添加失败"); |
| | | // } |
| | | // |
| | | // @Override |
| | | // public R expurgateData(String id) { |
| | | // int num= baseMapper.expurgateData(id); |
| | | // if(num>0) |
| | | // { |
| | | // return R.ok(); |
| | | // } |
| | | // return R.fail("添加失败"); |
| | | // } |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_jinhui_community.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageConvenientMerchantDTO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientMerchantVO; |
| | | import com.panzhihua.service_jinhui_community.dao.JinhuiConvenientMerchantDao; |
| | | import com.panzhihua.service_jinhui_community.entity.JinhuiConvenientMerchant; |
| | | import com.panzhihua.service_jinhui_community.service.JinhuiConvenientMerchantService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | /** |
| | | * @title: ConvenientMerchantServiceImpl |
| | | * @projectName: 成都呐喊信息技术有限公司-智慧社区项目 |
| | | * @description: 便民服务商家服务实现类 |
| | | * @author: hans |
| | | * @date: 2021/09/16 16:14 |
| | | */ |
| | | @Service |
| | | @Slf4j |
| | | public class JinhuiConvenientMerchantServiceImpl extends ServiceImpl<JinhuiConvenientMerchantDao, |
| | | JinhuiConvenientMerchant> implements JinhuiConvenientMerchantService { |
| | | |
| | | private static final String DQ = "510402"; |
| | | private static final String RHQ = "510411"; |
| | | |
| | | |
| | | @Override |
| | | public R deleteMerchant(String merchantId, String operator) { |
| | | int result = this.baseMapper.deleteMerchantById(merchantId, operator); |
| | | if (result > 0) { |
| | | return R.ok(); |
| | | } |
| | | return R.fail("删除失败"); |
| | | } |
| | | |
| | | @Override |
| | | public R pageMerchant(PageConvenientMerchantDTO pageConvenientMerchantDTO) { |
| | | Page page = new Page<>(); |
| | | page.setSize(pageConvenientMerchantDTO.getPageSize()); |
| | | page.setCurrent(pageConvenientMerchantDTO.getPageNum()); |
| | | IPage<ConvenientMerchantVO> iPage = this.baseMapper.pageMerchant(page, pageConvenientMerchantDTO); |
| | | return R.ok(iPage); |
| | | } |
| | | |
| | | @Override |
| | | public R getMerchant(String merchantId) { |
| | | ConvenientMerchantVO convenientMerchantVO = this.baseMapper.selectMerchantById(merchantId); |
| | | return R.ok(convenientMerchantVO); |
| | | } |
| | | |
| | | |
| | | |
| | | } |
New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.panzhihua.service_jinhui_community.dao.JinghuiMerchantEvaluateDao"> |
| | | |
| | | <resultMap type="com.panzhihua.service_jinhui_community.entity.JinghuiMerchantEvaluate" id="itemMap"> |
| | | <result property="id" column="id" /> |
| | | <result property="userId" column="user_id" /> |
| | | <result property="merchantId" column="merchant_id" /> |
| | | <result property="creationTime" column="creation_time" /> |
| | | <result property="updateTime" column="update_time" /> |
| | | <result property="content" column="content" /> |
| | | <result property="imgUrl" column="img_url" /> |
| | | |
| | | </resultMap> |
| | | |
| | | <!-- 分页查询 --> |
| | | <select id="getList" resultMap="itemMap"> |
| | | select |
| | | id, |
| | | merchant_id, |
| | | user_id, |
| | | (SELECT su.name from sys_user as su where jinghui_merchant_evaluate.user_id=su.user_id) as userName, |
| | | (SELECT su.image_url from sys_user as su where jinghui_merchant_evaluate.user_id=su.user_id) as userUrl, |
| | | content, |
| | | creation_time, |
| | | img_url |
| | | from jinghui_merchant_evaluate |
| | | where merchant_id=#{merchantId} |
| | | order by creation_time desc |
| | | </select> |
| | | |
| | | |
| | | <select id="getDetails" resultMap="itemMap"> |
| | | select |
| | | id, |
| | | merchant_id, |
| | | user_id, |
| | | (SELECT su.name from sys_user as su where jinghui_merchant_evaluate.user_id=su.user_id) as userName, |
| | | (SELECT su.image_url from sys_user as su where jinghui_merchant_evaluate.user_id=su.user_id) as userUrl, |
| | | content, |
| | | creation_time, |
| | | img_url |
| | | from jinghui_merchant_evaluate |
| | | where |
| | | id=#{id} |
| | | </select> |
| | | |
| | | <insert id="addData"> |
| | | insert into jinghui_merchant_evaluate |
| | | <trim prefix="(" suffix=")" suffixOverrides=","> |
| | | <if test="item.id != null" > |
| | | id, |
| | | </if> |
| | | <if test="item.userId != null and item.userId != '' "> |
| | | user_id, |
| | | </if> |
| | | <if test="item.goldCoin != null and item.goldCoin != '' "> |
| | | merchant_id, |
| | | </if> |
| | | <if test="item.content != null and item.content != '' "> |
| | | content, |
| | | </if> |
| | | <if test="item.imgUrl != null and item.imgUrl != '' "> |
| | | img_url, |
| | | </if> |
| | | creation_time |
| | | </trim> |
| | | values |
| | | <trim prefix="(" suffix=")" suffixOverrides=","> |
| | | <if test="item.id != null" > |
| | | #{item.id}, |
| | | </if> |
| | | <if test="item.userId != null and item.userId != '' "> |
| | | #{item.userId}, |
| | | </if> |
| | | <if test="item.goldCoin != null and item.goldCoin != '' "> |
| | | #{item.goldCoin}, |
| | | </if> |
| | | <if test="item.content != null and item.content != '' "> |
| | | #{item.content}, |
| | | </if> |
| | | <if test="item.imgUrl != null and item.imgUrl != '' "> |
| | | #{item.imgUrl}, |
| | | </if> |
| | | sysdate() |
| | | </trim> |
| | | </insert> |
| | | |
| | | <update id="editData"> |
| | | update jinghui_merchant_evaluate |
| | | <set> |
| | | <if test="item.id != null" > |
| | | id=#{item.id}, |
| | | </if> |
| | | <if test="item.userId != null and item.userId != '' "> |
| | | user_id=#{item.userId}, |
| | | </if> |
| | | <if test="item.goldCoin != null and item.goldCoin != '' "> |
| | | merchant_id=#{item.goldCoin}, |
| | | </if> |
| | | <if test="item.content != null and item.content != '' "> |
| | | content=#{item.content}, |
| | | </if> |
| | | <if test="item.imgUrl != null and item.imgUrl != '' "> |
| | | img_url=#{item.imgUrl}, |
| | | </if> |
| | | update_time=sysdate() |
| | | </set> |
| | | where id = #{item.id} |
| | | </update> |
| | | |
| | | <delete id="expurgateData" parameterType="String"> |
| | | delete from jinghui_merchant_evaluate where id=#{id} |
| | | </delete> |
| | | |
| | | </mapper> |
New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.panzhihua.service_jinhui_community.dao.JinhuiConvenientMerchantDao"> |
| | | |
| | | <!-- 通用查询映射结果 --> |
| | | <resultMap id="BaseResultMap" type="com.panzhihua.service_jinhui_community.entity.JinhuiConvenientMerchant"> |
| | | <id column="id" property="id" /> |
| | | <id column="name" property="name" /> |
| | | <id column="community_id" property="communityId" /> |
| | | <id column="community_name" property="communityName" /> |
| | | <id column="logo" property="logo" /> |
| | | <id column="contacts" property="contacts" /> |
| | | <id column="id_card" property="idCard" /> |
| | | <id column="phone" property="phone" /> |
| | | <id column="address" property="address" /> |
| | | <id column="address" property="address" /> |
| | | <id column="detailed_address" property="detailedAddress" /> |
| | | <id column="lat" property="lat" /> |
| | | <id column="lon" property="lon" /> |
| | | <id column="begin_at" property="beginAt" /> |
| | | <id column="end_at" property="endAt" /> |
| | | <id column="period" property="period" /> |
| | | <id column="introduction" property="introduction" /> |
| | | <id column="business_status" property="businessStatus" /> |
| | | <id column="user_id" property="userId" /> |
| | | <id column="consultation_volume" property="consultationVolume" /> |
| | | <id column="view_num" property="viewNum" /> |
| | | <id column="is_del" property="isDel" /> |
| | | <id column="created_at" property="createdAt" /> |
| | | <id column="created_by" property="createdBy" /> |
| | | <id column="updated_at" property="updatedAt" /> |
| | | <id column="updated_by" property="updatedBy" /> |
| | | <id column="area_code" property="areaCode" /> |
| | | <id column="service_range" property="serviceRange" /> |
| | | <id column="mobile_phone" property="mobilePhone" /> |
| | | </resultMap> |
| | | |
| | | <!-- 通用查询结果列 --> |
| | | <sql id="Base_Column_List"> |
| | | id,`name`,community_id,community_name,logo,contacts,id_card,phone,address,lat,lon,begin_at,end_at, |
| | | period,introduction,business_status,user_id,consultation_volume,is_del,created_at,created_by,updated_at, |
| | | updated_by,area_code,service_range,mobile_phone,detailed_address |
| | | </sql> |
| | | <select id="pageMerchant" resultType="com.panzhihua.common.model.vos.community.convenient.ConvenientMerchantVO"> |
| | | SELECT ccm.*, su.account, su.status AS accountStatus |
| | | FROM jinhui_com_convenient_merchants ccm |
| | | LEFT JOIN sys_user su ON ccm.user_id = su.user_id |
| | | WHERE ccm.is_del = 0 |
| | | <if test="pageConvenientMerchantDTO.accountStatus != null"> |
| | | AND su.status = #{pageConvenientMerchantDTO.accountStatus} |
| | | </if> |
| | | <if test="pageConvenientMerchantDTO.communityId != null and pageConvenientMerchantDTO.communityId != 0"> |
| | | AND ccm.community_id = ${pageConvenientMerchantDTO.communityId} |
| | | </if> |
| | | <if test="pageConvenientMerchantDTO.areaCode != null and pageConvenientMerchantDTO.areaCode != ''"> |
| | | AND ccm.area_code = ${pageConvenientMerchantDTO.areaCode} |
| | | </if> |
| | | <if test="pageConvenientMerchantDTO.businessStatus != null"> |
| | | AND ccm.business_status = #{pageConvenientMerchantDTO.businessStatus} |
| | | </if> |
| | | <if test="pageConvenientMerchantDTO.keyword != null and pageConvenientMerchantDTO.keyword != """> |
| | | AND ( |
| | | ccm.name LIKE CONCAT('%', #{pageConvenientMerchantDTO.keyword}, '%') |
| | | OR ccm.address LIKE CONCAT('%', #{pageConvenientMerchantDTO.keyword}, '%') |
| | | OR ccm.phone LIKE CONCAT('%', #{pageConvenientMerchantDTO.keyword}, '%') |
| | | ) |
| | | </if> |
| | | GROUP BY ccm.id ORDER BY ccm.created_at DESC |
| | | </select> |
| | | <select id="selectMerchantById" resultType="com.panzhihua.common.model.vos.community.convenient.ConvenientMerchantVO"> |
| | | SELECT ccm.*, su.account, su.status AS accountStatus |
| | | FROM jinhui_com_convenient_merchants ccm |
| | | LEFT JOIN sys_user su ON ccm.user_id = su.user_id |
| | | WHERE ccm.id = #{merchantId} |
| | | </select> |
| | | |
| | | |
| | | |
| | | <update id="deleteMerchantById"> |
| | | UPDATE jinhui_com_convenient_merchants SET is_del = 1, updated_by = #{operator} WHERE id = #{merchantId} |
| | | </update> |
| | | |
| | | </mapper> |
New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.panzhihua.service_jinhui_community.dao.JinhuiComConvenientServiceCategoriesDao"> |
| | | |
| | | <!-- 通用查询映射结果 --> |
| | | <resultMap id="BaseResultMap" type="com.panzhihua.service_jinhui_community.entity.JinhuiComConvenientServiceCategories"> |
| | | <id column="id" property="id" /> |
| | | <id column="name" property="name" /> |
| | | <id column="icon" property="icon" /> |
| | | <id column="remark" property="remark" /> |
| | | <id column="weight" property="weight" /> |
| | | <id column="is_del" property="isDel" /> |
| | | <id column="created_at" property="createdAt" /> |
| | | <id column="created_by" property="createdBy" /> |
| | | <id column="updated_at" property="updatedAt" /> |
| | | <id column="updated_by" property="updatedBy" /> |
| | | </resultMap> |
| | | |
| | | <!-- 通用查询结果列 --> |
| | | <sql id="Base_Column_List"> |
| | | id,`name`,icon,remark,weight,is_del,created_at,created_by,updated_at,updated_by |
| | | </sql> |
| | | |
| | | <!-- 分页查询 --> |
| | | <select id="getList" resultMap="BaseResultMap"> |
| | | select |
| | | id, |
| | | name, |
| | | icon, |
| | | remark, |
| | | weight, |
| | | is_del, |
| | | created_at, |
| | | created_by, |
| | | updated_at, |
| | | updated_by, |
| | | parent_id, |
| | | area_code |
| | | from jinhui_com_convenient_service_categories |
| | | order by created_at desc |
| | | </select> |
| | | |
| | | |
| | | |
| | | </mapper> |