Merge remote-tracking branch 'origin/zigonggao_dev' into zigonggao_dev
| | |
| | | user.setMasterIds(config.getMasterIds()); |
| | | user.setRoleIds("2"); |
| | | user.setUserType("2"); |
| | | user.setIsDivisionHead("1"); |
| | | user.setStatus(config.getStatus()); |
| | | user.setUpdateTime(LocalDateTime.now()); |
| | | //提示用户名或密码错误 |
| | |
| | | config.setCreateTime(LocalDateTime.now()); |
| | | config.setUpdateTime(LocalDateTime.now()); |
| | | config.setUserId(Snowflake.getId()+""); |
| | | config.setIsDivisionHead("1"); |
| | | return toAjax(IUserService.insertConfig(config)); |
| | | } |
| | | |
| | |
| | | SysUser user=IUserService.selectData(userId,null,null); |
| | | user.setUserType("4"); |
| | | user.setRoleIds("4"); |
| | | user.setIsDivisionHead("2"); |
| | | return toAjax(IUserService.updateConfig(user)); |
| | | } |
| | | |
| | |
| | | config.setUserId(user.getUserId()); |
| | | config.setCreateBy(user.getUserId()+""); |
| | | config.setUserType("3"); |
| | | |
| | | config.setIsDivisionHead("1"); |
| | | config.setUpdateTime(LocalDateTime.now()); |
| | | return toAjax(IUserService.updateConfig(config)); |
| | | } |
| | |
| | | config.setUserId(user2.getUserId()); |
| | | config.setCreateBy(user2.getUserId()+""); |
| | | config.setUserType("3"); |
| | | |
| | | config.setIsDivisionHead("1"); |
| | | config.setUpdateTime(LocalDateTime.now()); |
| | | return toAjax(IUserService.updateConfig(config)); |
| | | } |
| | |
| | | config.setCreateBy(sysUser.getUserId()+""); |
| | | config.setUserId(Snowflake.getId()+""); |
| | | config.setUserType("3"); |
| | | config.setIsDivisionHead("1"); |
| | | |
| | | config.setCreateTime(LocalDateTime.now()); |
| | | config.setUpdateTime(LocalDateTime.now()); |
| | |
| | | //默认 1系统后台用户 |
| | | newSysUser.setUserType("4"); |
| | | newSysUser.setRoleIds("4"); |
| | | newSysUser.setIsDivisionHead("2"); |
| | | newSysUser.setPhonenumber(huaChengSysUser.getPhone()); |
| | | newSysUser.setUserId(huaChengSysUser.getUserId()); |
| | | newSysUser.setUserName(huaChengSysUser.getNickName()); |
| | |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | import com.panzhihua.common.model.dtos.user.SysUserFeedbackDTO; |
| | | import com.panzhihua.common.service.user.UserService; |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import io.swagger.annotations.ApiParam; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | | import org.springframework.web.bind.annotation.RequestBody; |
| | |
| | | public class ComPropertyApi extends BaseController { |
| | | @Resource |
| | | private CommunityService communityService; |
| | | @Resource |
| | | private UserService userService; |
| | | |
| | | /** |
| | | * 分页查询所有数据 |
| | |
| | | public R detailProperty(@RequestParam("id") Long id) { |
| | | return this.communityService.detailProperty(id); |
| | | } |
| | | |
| | | @ApiOperation("新增投诉建议或问题留言") |
| | | @PostMapping("addFeedBack") |
| | | public R addFeedBack(@RequestBody SysUserFeedbackDTO sysUserFeedbackDTO){ |
| | | return userService.addFeedback(sysUserFeedbackDTO); |
| | | } |
| | | |
| | | @ApiOperation("查看自己的投诉建议或问题留言记录") |
| | | @GetMapping("myFeedBack") |
| | | public R myFeedBack(@ApiParam("类型:1问题留言2投诉建议") @RequestParam(value = "type",required = false)Integer type){ |
| | | return userService.myFeedBack(this.getLoginUserInfo().getUserId(),type); |
| | | } |
| | | |
| | | @ApiOperation("通知公告列表") |
| | | @GetMapping("notice") |
| | | public R noticeList(@RequestParam("page")Integer page,@RequestParam("size")Integer size,@RequestParam("propertyId")Long propertyId){ |
| | | return communityService.noticeList(page,size,propertyId); |
| | | } |
| | | |
| | | } |
| | |
| | | |
| | | import cn.hutool.core.date.DateUtil; |
| | | import com.panzhihua.applets.model.dtos.IDTO; |
| | | import com.panzhihua.common.constants.Constants; |
| | | import com.panzhihua.common.controller.BaseController; |
| | | import com.panzhihua.common.model.dtos.property.CommonPage; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.property.ComPropertyRepairVO; |
| | | import com.panzhihua.common.service.property.PropertyService; |
| | | import com.panzhihua.common.utlis.RSAUtils; |
| | | import com.panzhihua.common.utlis.StringUtils; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | |
| | | } |
| | | |
| | | /** |
| | | * 分页查询所有数据 |
| | | * @return 所有数据 |
| | | */ |
| | | @ApiOperation("小程序列表接口-脱敏") |
| | | @PostMapping("/desensitize/queryAll") |
| | | public R selectAllDesensitize(@RequestBody CommonPage commonPage) { |
| | | commonPage.setUserId(this.getUserId()); |
| | | return this.propertyService.comPropertyRepairSelectAllDesensitize(commonPage); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 小程序添加报修 |
| | | * @param comPropertyRepairVO |
| | | * @return |
| | |
| | | comPropertyRepairVO.setCreateTime(DateUtil.date()); |
| | | comPropertyRepairVO.setCreateBy(this.getUserId()); |
| | | comPropertyRepairVO.setRepairStatus(ComPropertyRepairVO.status.dcl); |
| | | return this.propertyService.comPropertyRepairInsert(comPropertyRepairVO); |
| | | } |
| | | |
| | | /** |
| | | * 小程序添加报修 脱敏 |
| | | * @param comPropertyRepairVO |
| | | * @return |
| | | */ |
| | | @ApiOperation("小程序添加报修-脱敏") |
| | | @PostMapping("desensitizeInsert") |
| | | public R desensitizeInsert(@RequestBody ComPropertyRepairVO comPropertyRepairVO) { |
| | | comPropertyRepairVO.setCreateTime(DateUtil.date()); |
| | | comPropertyRepairVO.setCreateBy(this.getUserId()); |
| | | comPropertyRepairVO.setRepairStatus(ComPropertyRepairVO.status.dcl); |
| | | try { |
| | | comPropertyRepairVO.setRepairName(RSAUtils.decrypt(comPropertyRepairVO.getRepairName(), Constants.PRIVATE_KEY)); |
| | | comPropertyRepairVO.setRepairPhone(RSAUtils.decrypt(comPropertyRepairVO.getRepairPhone(), Constants.PRIVATE_KEY)); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | } |
| | | return this.propertyService.comPropertyRepairInsert(comPropertyRepairVO); |
| | | } |
| | | |
| | |
| | | return this.propertyService.comPropertyRepairSelectOne(id); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 通过主键查询单条数据 |
| | | * |
| | | * @param id 主键 |
| | | * @return 单条数据 |
| | | */ |
| | | @ApiOperation("详情接口") |
| | | @GetMapping("desensitize/{id}") |
| | | public R selectOneDesensitize(@PathVariable("id") Long id) { |
| | | return this.propertyService.comPropertyRepairSelectOneDesensitize(id); |
| | | } |
| | | |
| | | |
| | | |
| | | /** |
| | | * 删除数据 |
| | | * |
| | |
| | | package com.panzhihua.applets.api; |
| | | |
| | | import java.io.File; |
| | | import java.io.FileNotFoundException; |
| | | import java.io.IOException; |
| | | import java.io.InputStream; |
| | | import java.util.*; |
| | | import java.util.concurrent.TimeUnit; |
| | | import java.util.concurrent.atomic.AtomicBoolean; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletRequest; |
| | | |
| | | import com.jcraft.jsch.SftpException; |
| | | import com.panzhihua.applets.config.MinioUtil; |
| | | import com.panzhihua.applets.umf.UmfPayUtil; |
| | | import com.panzhihua.common.controller.BaseController; |
| | |
| | | import org.springframework.util.ObjectUtils; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import com.alibaba.fastjson.JSON; |
| | | import com.panzhihua.applets.config.WxMaConfiguration; |
| | | import com.panzhihua.common.constants.Constants; |
| | |
| | | import com.panzhihua.common.service.community.CommunityService; |
| | | import com.panzhihua.common.utlis.HttpUtils; |
| | | import com.panzhihua.common.utlis.SFTPUtil; |
| | | |
| | | import cn.binarywang.wx.miniapp.api.WxMaSecCheckService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | |
| | | public R detailCommunity(@RequestParam("id") Long id) { |
| | | return communityService.detailCommunity(id); |
| | | } |
| | | |
| | | @ApiOperation(value = "获取问题清单,需求清单,报道服务活动数量",response = DataCount.class) |
| | | @GetMapping("/dataCount") |
| | | public R dataCount(){ |
| | | return communityService.dataCount(); |
| | | } |
| | | } |
| | |
| | | return communityService.pageDiscussApplets(pageComActDiscussDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "一起议-分页查询-脱敏", response = ComActDiscussVO.class) |
| | | @PostMapping("pageDiscussDesensitize") |
| | | public R pageDiscussDesensitize(@RequestBody PageComActDiscussDTO pageComActDiscussDTO) { |
| | | if (Objects.isNull(pageComActDiscussDTO.getType())) { |
| | | return R.fail("查询类型不能为空"); |
| | | } |
| | | LoginUserInfoVO loginUserInfo = this.getLoginUserInfoSureNoLogin(); |
| | | if (loginUserInfo != null) { |
| | | pageComActDiscussDTO.setCommunityId(loginUserInfo.getCommunityId()); |
| | | pageComActDiscussDTO.setLoginUserId(loginUserInfo.getUserId()); |
| | | |
| | | Integer isMy = pageComActDiscussDTO.getIsMy(); |
| | | if (null != isMy && isMy.intValue() == 1) { |
| | | pageComActDiscussDTO.setUserId(loginUserInfo.getUserId()); |
| | | } |
| | | } |
| | | return communityService.pageDiscussAppletsDesensitize(pageComActDiscussDTO); |
| | | } |
| | | |
| | | |
| | | @ApiOperation(value = "一起议-回复") |
| | | @PostMapping("discusscomment") |
| | | public R addDiscussComment(@RequestBody ComActDiscussCommentDTO comActDiscussCommentDTO) { |
| | |
| | | return communityService.detailDiscussApplets(id, userId); |
| | | } |
| | | |
| | | @ApiOperation(value = "一起议-详情-脱敏", response = ComActDiscussVO.class) |
| | | @GetMapping("discussDesensitize") |
| | | @ApiImplicitParam(name = "id", value = "一起议主键", required = true) |
| | | public R detailDiscussDesensitize(@RequestParam("id") Long id) { |
| | | Long userId = 0L; |
| | | LoginUserInfoVO loginUserInfo = this.getLoginUserInfoSureNoLogin(); |
| | | if (loginUserInfo != null) { |
| | | userId = loginUserInfo.getUserId(); |
| | | } |
| | | return communityService.detailDiscussAppletsDesensitize(id, userId); |
| | | } |
| | | |
| | | @ApiOperation(value = "一起议-评论-分页查询", response = ComActDiscussCommentVO.class) |
| | | @PostMapping("pagediscusscomment") |
| | | public R pageDiscussComment(@RequestBody PageComActDiscussCommentDTO pageComActDiscussCommentDTO) { |
| | |
| | | return communityService.pageDiscussCommentApplets(pageComActDiscussCommentDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "一起议-评论-分页查询-脱敏", response = ComActDiscussCommentVO.class) |
| | | @PostMapping("pageDiscussCommentDesensitize") |
| | | public R pageDiscussCommentDesensitize(@RequestBody PageComActDiscussCommentDTO pageComActDiscussCommentDTO) { |
| | | Long id = pageComActDiscussCommentDTO.getId(); |
| | | if (null == id || 0 == id) { |
| | | return R.fail("一起议主键不能为空"); |
| | | } |
| | | Long userId = 0L; |
| | | LoginUserInfoVO loginUserInfo = this.getLoginUserInfoSureNoLogin(); |
| | | if (loginUserInfo != null) { |
| | | userId = loginUserInfo.getUserId(); |
| | | } |
| | | pageComActDiscussCommentDTO.setLoginUserId(userId); |
| | | return communityService.pageDiscussCommentAppletsDesensitize(pageComActDiscussCommentDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "一起议-评论-回复") |
| | | @PostMapping("discusscommentback") |
| | | public R addDiscussCommentBack(@RequestBody ComActDiscussCommentDTO comActDiscussCommentDTO) { |
| | |
| | | return communityService.pageEasyPhotoApplets(comActEasyPhotoVO); |
| | | } |
| | | |
| | | @ApiOperation(value = "分页展示社区随手拍-脱敏", response = ComActEasyPhotoVO.class) |
| | | @PostMapping("pageEasyPhotoDesensitize") |
| | | public R pageEasyPhotoDesensitize(@RequestBody ComActEasyPhotoVO comActEasyPhotoVO) { |
| | | LoginUserInfoVO loginUserInfo = this.getLoginUserInfoSureNoLogin(); |
| | | if (loginUserInfo != null) { |
| | | comActEasyPhotoVO.setCommunityId(loginUserInfo.getCommunityId()); |
| | | comActEasyPhotoVO.setLogInUserId(loginUserInfo.getUserId()); |
| | | comActEasyPhotoVO.setIsDpcMember(loginUserInfo.getIsDpcMember()); |
| | | } |
| | | return communityService.pageEasyPhotoAppletsDesensitize(comActEasyPhotoVO); |
| | | } |
| | | |
| | | @ApiOperation("上传随手拍") |
| | | @PostMapping("easyphoto") |
| | | public R addEasyPhoto(@RequestBody @Validated(AddGroup.class) ComActEasyPhotoVO comActEasyPhotoVO) { |
| | |
| | | } |
| | | return communityService.detailEasyPhoto(id, userId); |
| | | } |
| | | @ApiOperation(value = "随手拍详情-脱敏", response = ComActEasyPhotoVO.class) |
| | | @GetMapping("detailEasyPhotoDesensitize") |
| | | @ApiImplicitParam(name = "id", value = "随手拍主键") |
| | | public R detailEasyPhotoDesensitize(@RequestParam("id") Long id) { |
| | | Long userId = 0L; |
| | | LoginUserInfoVO loginUserInfo = this.getLoginUserInfoSureNoLogin(); |
| | | if (loginUserInfo != null) { |
| | | userId = loginUserInfo.getUserId(); |
| | | } |
| | | return communityService.detailEasyPhotoDesensitize(id, userId); |
| | | } |
| | | |
| | | @ApiOperation(value = "随手拍--评论--分页查询", response = ComActEasyPhotoCommentVO.class) |
| | | @PostMapping("pagecomacteasyphotocomment") |
| | |
| | | } |
| | | pageComActEasyPhotoCommentDTO.setUserId(userId); |
| | | return communityService.pageComActEasyPhotoComment(pageComActEasyPhotoCommentDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "随手拍--评论--分页查询-脱敏", response = ComActEasyPhotoCommentVO.class) |
| | | @PostMapping("pageComActEasyPhotoCommentDesensitize") |
| | | public R pageComActEasyPhotoCommentDesensitize(@RequestBody PageComActEasyPhotoCommentDTO pageComActEasyPhotoCommentDTO) { |
| | | Long userId = 0L; |
| | | LoginUserInfoVO loginUserInfo = this.getLoginUserInfoSureNoLogin(); |
| | | if (loginUserInfo != null) { |
| | | userId = loginUserInfo.getUserId(); |
| | | } |
| | | pageComActEasyPhotoCommentDTO.setUserId(userId); |
| | | return communityService.pageComActEasyPhotoCommentDesensitize(pageComActEasyPhotoCommentDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "随手拍--评论--新增评论") |
| | |
| | | return communityService.pageMicroWishApplets(comActMicroWishVO); |
| | | } |
| | | |
| | | @ApiOperation(value = "分页展示社区微心愿-脱敏", response = ComActMicroWishVO.class) |
| | | @PostMapping("pageMicroWishDesensitize") |
| | | public R pageMicroWishDesensitize(@RequestBody ComActMicroWishVO comActMicroWishVO) { |
| | | LoginUserInfoVO loginUserInfo = this.getLoginUserInfoSureNoLogin(); |
| | | if (loginUserInfo != null) { |
| | | comActMicroWishVO.setCommunityId(loginUserInfo.getCommunityId()); |
| | | comActMicroWishVO.setResponsibleId(loginUserInfo.getUserId());// 责任人暂时放登录用户id |
| | | } |
| | | comActMicroWishVO.setIsApplets(1); |
| | | comActMicroWishVO.setIsPageMyWish(null); |
| | | return communityService.pageMicroWishAppletsDesensitize(comActMicroWishVO); |
| | | } |
| | | |
| | | @ApiOperation("发布微心愿") |
| | | @PostMapping("microwish") |
| | | public R addMicroWish(@RequestBody @Validated(AddGroup.class) ComActMicroWishVO comActMicroWishVO) { |
| | |
| | | userId = loginUserInfo.getUserId(); |
| | | } |
| | | return communityService.detailMicroWish(id, userId); |
| | | } |
| | | |
| | | @ApiOperation(value = "心愿详情-脱敏", response = ComActMicroWishVO.class) |
| | | @GetMapping("microwishDesensitize") |
| | | @ApiImplicitParam(name = "id", value = "微心愿主键") |
| | | public R detailMicroWishDesensitize(@RequestParam("id") Long id) { |
| | | Long userId = 0L; |
| | | LoginUserInfoVO loginUserInfo = this.getLoginUserInfoSureNoLogin(); |
| | | if (loginUserInfo != null) { |
| | | userId = loginUserInfo.getUserId(); |
| | | } |
| | | return communityService.detailMicroWishDesensitize(id, userId); |
| | | } |
| | | |
| | | @ApiOperation("点赞/取消点赞微心愿") |
| | |
| | | return communityService.getUserRewards(userId, communityId); |
| | | } |
| | | |
| | | @ApiOperation(value = "获取普达首页弹窗接口", response = ComActEasyPhotoRewardVO.class) |
| | | @GetMapping("getUserRewardsNew") |
| | | public R getUserRewardsNew(@RequestParam("communityId") Long communityId) { |
| | | Long userId = 0L; |
| | | LoginUserInfoVO loginUserInfo = this.getLoginUserInfoSureNoLogin(); |
| | | if (loginUserInfo != null) { |
| | | userId = loginUserInfo.getUserId(); |
| | | communityId = loginUserInfo.getCommunityId(); |
| | | } |
| | | return communityService.getUserRewardsNew(userId, communityId); |
| | | } |
| | | |
| | | @ApiOperation(value = "读取用户随手拍奖励") |
| | | @PostMapping("readUserReward") |
| | | public R readUserReward() { |
| | |
| | | public R tfLogin(@RequestBody UuLoginVO uuLoginVO){ |
| | | try { |
| | | uuLoginVO.setMobile(RSAUtils.decrypt(uuLoginVO.getMobile(), Constants.PRIVATE_KEY)); |
| | | //测试是否能正常添加用户 |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | return R.fail(); |
| | |
| | | @ApiOperation(value = "查询当前用户党员信息") |
| | | @GetMapping("/getPartyMember") |
| | | public R getPartyMember(@RequestParam("type")Integer type){ |
| | | return partyBuildingService.getPartyMember(this.getLoginUserInfo().getPhone(),type); |
| | | LoginUserInfoVO loginUserInfo = this.getLoginUserInfo(); |
| | | if (StrUtil.isEmpty(loginUserInfo.getPhone())){ |
| | | return R.fail("请先实名认证"); |
| | | } |
| | | return partyBuildingService.getPartyMember(loginUserInfo.getPhone(),type); |
| | | } |
| | | @ApiOperation(value = "查询报道单位详情") |
| | | @GetMapping("/comPbCheckUnit/detailByPhone") |
| | |
| | | import com.panzhihua.common.model.dtos.community.social.PageProjectDTO; |
| | | import com.panzhihua.common.model.vos.community.rentHouse.WxPayOrderVO; |
| | | import com.panzhihua.common.utlis.DateUtils; |
| | | import io.swagger.annotations.ApiParam; |
| | | import org.apache.commons.lang.StringUtils; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.data.redis.core.StringRedisTemplate; |
| | |
| | | public R selectAutomessageSysUserById(@RequestParam("id")Long id){ |
| | | return communityService.selectAutomessageSysUserById(id); |
| | | } |
| | | |
| | | @ApiOperation("新增投诉建议或问题留言") |
| | | @PostMapping("addFeedBack") |
| | | public R addFeedBack(@RequestBody SysUserFeedbackDTO sysUserFeedbackDTO){ |
| | | return userService.addFeedback(sysUserFeedbackDTO); |
| | | } |
| | | |
| | | @ApiOperation("查看自己的投诉建议或问题留言记录") |
| | | @GetMapping("myFeedBack") |
| | | public R myFeedBack(@ApiParam("类型:1问题留言2投诉建议") @RequestParam(value = "type",required = false)Integer type){ |
| | | return userService.myFeedBack(this.getLoginUserInfo().getUserId(),type); |
| | | } |
| | | |
| | | } |
| | |
| | | package com.panzhihua.applets.api; |
| | | |
| | | import java.io.*; |
| | | import java.net.HttpURLConnection; |
| | | import java.net.URL; |
| | | import java.nio.charset.StandardCharsets; |
| | | import java.util.*; |
| | | import java.util.concurrent.TimeUnit; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | import com.panzhihua.common.api.LcApiConstants; |
| | | import com.alibaba.fastjson.JSON; |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.panzhihua.applets.config.WxMaConfiguration; |
| | | import com.panzhihua.common.constants.UserConstants; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.utlis.HttpClientUtil; |
| | | import com.panzhihua.common.utlis.StringUtils; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.data.redis.core.StringRedisTemplate; |
| | | import org.springframework.data.redis.core.ValueOperations; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import com.alibaba.fastjson.JSON; |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.panzhihua.common.constants.UserConstants; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.utlis.HttpClientUtil; |
| | | import com.panzhihua.common.utlis.StringUtils; |
| | | |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import javax.annotation.Resource; |
| | | import java.io.*; |
| | | import java.net.HttpURLConnection; |
| | | import java.net.URL; |
| | | import java.nio.charset.StandardCharsets; |
| | | import java.util.*; |
| | | import java.util.concurrent.TimeUnit; |
| | | |
| | | @Slf4j |
| | | @RestController |
| | |
| | | |
| | | @Resource |
| | | private StringRedisTemplate stringRedisTemplate; |
| | | |
| | | // 公众号appid |
| | | private List<String> appidList = new ArrayList<String>() { |
| | | { |
| | |
| | | /** |
| | | * 根据文章链接抓取文章内容 |
| | | * |
| | | * @param url |
| | | * 文章链接 |
| | | * @param url 文章链接 |
| | | * @return 文章内容 |
| | | */ |
| | | public static String getActicle(String url) { |
| | |
| | | /** |
| | | * 获取token |
| | | * |
| | | * @param appid |
| | | * 公众号appid |
| | | * @param secret |
| | | * 公众号secret |
| | | * @param appid 公众号appid |
| | | * @param secret 公众号secret |
| | | * @return token |
| | | */ |
| | | private String getToken(String appid, String secret) throws IOException { |
| | | // access_token接口https请求方式: GET |
| | | // https://api.weixin.qq.com/cgi-bin/token?grant_type=client_credential&appid=APPID&secret=APPSECRET |
| | | |
| | | String path = " https://api.weixin.qq.com/cgi-bin/token?grant_type=client_credential"; |
| | | URL url = new URL(path + "&appid=" + appid + "&secret=" + secret); |
| | | HttpURLConnection connection = (HttpURLConnection)url.openConnection(); |
| | |
| | | sb.append(new String(b, 0, len)); |
| | | } |
| | | |
| | | // System.out.println(sb.toString()); |
| | | in.close(); |
| | | |
| | | |
| | | return sb.toString(); |
| | | |
| | | } |
| | | |
| | | /** |
| | | * 通过token获取公众号文章 |
| | | * |
| | | * @param token |
| | | * token |
| | | * @param token token |
| | | * @return 获取的文章列表结果 |
| | | */ |
| | | private String getContentList(String token) throws IOException { |
| | | String path = " https://api.weixin.qq.com/cgi-bin/material/batchget_material?access_token=" + token; |
| | | URL url = new URL(path); |
| | | HttpURLConnection connection = (HttpURLConnection)url.openConnection(); |
| | | HttpURLConnection connection = (HttpURLConnection) url.openConnection(); |
| | | connection.setRequestMethod("POST"); |
| | | connection.setDoOutput(true); |
| | | connection.setRequestProperty("content-type", "application/json;charset=utf-8"); |
| | |
| | | if (!appidList.isEmpty()) { |
| | | for (int i = 0; i < appidList.size(); i++) { |
| | | String token = officialApi.getToken(appidList.get(i), secretList.get(i)); |
| | | log.info("通过appid:" + appidList.get(i) + "获取token返回参数:" + token); |
| | | JSONObject tokenJson = JSON.parseObject(token); |
| | | if (StringUtils.isNotEmpty(tokenJson)) { |
| | | tokenList.add(tokenJson.getString("access_token")); |
| | | if (StringUtils.isNotEmpty(token)) { |
| | | tokenList.add(token); |
| | | } |
| | | } |
| | | } |
| | | } |
| | | List<JSONObject> resultList = new ArrayList<>(); |
| | | Boolean newsListKey = stringRedisTemplate.hasKey(UserConstants.NEWS_LIST); |
| | | if(newsListKey != null && newsListKey){ |
| | | if (newsListKey != null && newsListKey) { |
| | | String json = valueOperations.get(UserConstants.NEWS_LIST); |
| | | resultList = JSON.parseArray(json,JSONObject.class); |
| | | resultList = JSON.parseArray(json, JSONObject.class); |
| | | return R.ok(resultList); |
| | | } |
| | | if (!tokenList.isEmpty()) { |
| | | for (String token:tokenList) { |
| | | for (String token : tokenList) { |
| | | try { |
| | | String url = "https://api.weixin.qq.com/cgi-bin/material/batchget_material?access_token=" + token; |
| | | String result = getActicle(url); |
| | |
| | | // String fileName = uuid + "/images." + FilenameUtils.getExtension(file.getOriginalFilename()); |
| | | String fileName = s.append(name).toString(); |
| | | String contentType = file.getContentType(); |
| | | minioClient.putObject(minioProperties.getBucket(), fileName, input, contentType); |
| | | minioClient.putObject(minioProperties.getBucket(), fileName, input, "application/octet-stream"); |
| | | StringBuilder fileUrl = new StringBuilder(minioProperties.getUrl()); |
| | | String url = fileUrl.append(fileName).toString(); |
| | | return fileName; |
| | |
| | | } |
| | | |
| | | public static void main(String[] args) throws Exception{ |
| | | String ryo7M3n8loC5Abcd = MyAESUtil.Encrypt("{\"order_status\":\"9\",\"wash_name\":null,\"wash_mobile\":null,\"phone\":\"15828259512\"}", "Ryo7M3n8loC5Abcd"); |
| | | // String ryo7M3n8loC5Abcd = MyAESUtil.Decrypt("Ixp8WMuJ9bnKhiBKmKWq\/rQXQ7SaWc3fHLB1e\/PzAvIEN0CH1nXtMCBzMegT49on31S+3Itop388Yc0EGVx30GGVlG81p7ssiqHlLRna2i903Rid9hqbjZdrBomiy2jp", "Ryo7M3n8loC5Abcd"); |
| | | String ryo7M3n8loC5Abcd = MyAESUtil.Encrypt("{\"order_status\":\"6\",\"wash_name\":null,\"wash_mobile\":null,\"phone\":\"13699017236\"}", "Ryo7M3n8loC5Abcd"); |
| | | // String ryo7M3n8loC5Abcd = MyAESUtil.Decrypt("Ixp8WMuJ9bnKhiBKmKWq\\/rQXQ7SaWc3fHLB1e\\/PzAvIEN0CH1nXtMCBzMegT49on31S+3Itop388Yc0EGVx30GGVlG81p7ssiqHlLRna2i903Rid9hqbjZdrBomiy2jp", "Ryo7M3n8loC5Abcd"); |
| | | // String ryo7M3n8loC5Abcd = MyAESUtil.Decrypt("0H4upa36EW9AFSNcoF9rVX6D5enB9T/9P1hWxLf/NgiGCueg159vz7Ex6+tPAR83aQLPyGeuF74Y5C9VpzQjL7brj8aWdMmnWJp/W1i5lpM=", "Ryo7M3n8loC5Abcd"); |
| | | // 订单完成13980596944 {"aesString":"0H4upa36EW9AFSNcoF9rVX6D5enB9T\/9P1hWxLf\/NgiGCueg159vz7Ex6+tPAR83aQLPyGeuF74Y5C9VpzQjL2IYlgC9A6hhT82p\/kQTjTk="} |
| | | // 取消订单13980596944 {"aesString":"0H4upa36EW9AFSNcoF9rVfYjNQ0z81u6AWDcCU9O9DqGCueg159vz7Ex6+tPAR83aQLPyGeuF74Y5C9VpzQjL2IYlgC9A6hhT82p\/kQTjTk="} |
| | | System.out.println(ryo7M3n8loC5Abcd); |
| | | } |
| | | } |
New file |
| | |
| | | package com.panzhihua.applets_backstage.api; |
| | | |
| | | import com.panzhihua.common.controller.BaseController; |
| | | import com.panzhihua.common.model.dtos.property.CommonPage; |
| | | import com.panzhihua.common.model.dtos.user.SysUserFeedbackDTO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.community.ComPropertyVO; |
| | | import com.panzhihua.common.service.community.CommunityService; |
| | | import com.panzhihua.common.service.user.UserService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import io.swagger.annotations.ApiParam; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | /** |
| | | * @author zts |
| | | */ |
| | | @Slf4j |
| | | @Api(tags = {"物业公司"}) |
| | | @RestController |
| | | @RequestMapping("/comProperty") |
| | | public class ComPropertyApi extends BaseController { |
| | | @Resource |
| | | private CommunityService communityService; |
| | | @Resource |
| | | private UserService userService; |
| | | |
| | | /** |
| | | * 分页查询所有数据 |
| | | * |
| | | * @param commonPage 查询实体 |
| | | * @return 所有数据 |
| | | */ |
| | | @ApiOperation(value = "物业公司列表",response = ComPropertyVO.class) |
| | | @PostMapping("queryAll") |
| | | public R selectAll(@RequestBody CommonPage commonPage) { |
| | | commonPage.setParamId(this.getCommunityId()); |
| | | return this.communityService.comPropertySelectAll(commonPage); |
| | | } |
| | | |
| | | @ApiOperation(value = "物业公司详情", response = ComPropertyVO.class) |
| | | @ApiImplicitParam(name = "id", value = "物业公司id", required = true) |
| | | @GetMapping("detail") |
| | | public R detailProperty(@RequestParam("id") Long id) { |
| | | return this.communityService.detailProperty(id); |
| | | } |
| | | |
| | | @ApiOperation("新增投诉建议或问题留言") |
| | | @PostMapping("addFeedBack") |
| | | public R addFeedBack(@RequestBody SysUserFeedbackDTO sysUserFeedbackDTO){ |
| | | return userService.addFeedback(sysUserFeedbackDTO); |
| | | } |
| | | |
| | | @ApiOperation("查看自己的投诉建议或问题留言记录") |
| | | @GetMapping("myFeedBack") |
| | | public R myFeedBack(@ApiParam("类型:1问题留言2投诉建议") @RequestParam(value = "type",required = false)Integer type){ |
| | | return userService.myFeedBack(this.getLoginUserInfo().getUserId(),type); |
| | | } |
| | | |
| | | @ApiOperation(value = "通知公告列表",response = ComPropertyVO.class) |
| | | @GetMapping("notice") |
| | | public R noticeList(@RequestParam("page")Integer page,@RequestParam("size")Integer size,@RequestParam("propertyId")Long propertyId){ |
| | | return communityService.noticeList(page,size,propertyId); |
| | | } |
| | | |
| | | } |
| | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import javax.validation.Valid; |
| | | |
| | | import com.panzhihua.common.model.dtos.community.convenient.*; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientElevatingPointVO; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientGoodsCategoryVO; |
| | | import com.panzhihua.common.utlis.MimeTypeUtils; |
| | | import org.apache.commons.io.FilenameUtils; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | |
| | | import com.panzhihua.common.model.dtos.community.PageComCvtBusinessDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComCvtCategoryDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComCvtServeDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.ConvenientMerchantDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.ConvenientServiceCategoryDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.DisableOrEnableConvenientMerchantDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageConvenientMerchantDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageConvenientServiceCategoryDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.ResetPasswordConvenientMerchantDTO; |
| | | import com.panzhihua.common.model.vos.LoginUserInfoVO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.community.ComActVO; |
| | |
| | | public R getAllServiceCategories() { |
| | | return communityService.getAllServiceCategories(this.getAreaCode()); |
| | | } |
| | | |
| | | |
| | | @ApiOperation(value = "分页查询自提点", response = ConvenientElevatingPointVO.class) |
| | | @PostMapping("/point/page") |
| | | public R pagePoint(@RequestBody PageConvenientElevatingPointDTO pageConvenientElevatingPointDTO) { |
| | | return communityService.pagePoint(pageConvenientElevatingPointDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "新增自提点") |
| | | @PostMapping("/point/add") |
| | | public R addPoint(@RequestBody @Validated(AddGroup.class) ConvenientElevatingPointDTO convenientElevatingPointDTO) { |
| | | convenientElevatingPointDTO.setCreatedBy(this.getUserId()); |
| | | return communityService.addPoint(convenientElevatingPointDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "编辑自提点") |
| | | @PutMapping("/point/put") |
| | | public R putPoint(@RequestBody @Validated(PutGroup.class) ConvenientElevatingPointDTO convenientElevatingPointDTO) { |
| | | convenientElevatingPointDTO.setUpdatedBy(this.getUserId()); |
| | | convenientElevatingPointDTO.setCreatedBy(this.getUserId()); |
| | | return communityService.putPoint(convenientElevatingPointDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "删除自提点") |
| | | @DeleteMapping("/point/delete") |
| | | public R deletePoint(@RequestParam("pointId") @ApiParam(value = "自提点id", required = true) |
| | | Long pointId) { |
| | | return communityService.deletePoint(pointId, this.getUserId()); |
| | | } |
| | | @ApiOperation(value = "自提点详情") |
| | | @GetMapping("/point/detail") |
| | | public R detailPoint(@RequestParam("pointId") @ApiParam(value = "自提点id", required = true) Long pointId) { |
| | | return communityService.detailPoint(pointId); |
| | | } |
| | | |
| | | |
| | | @ApiOperation(value = "新增商品分类") |
| | | @PostMapping("/goodsCategory/add") |
| | | public R addGoodsCategory(@RequestBody @Validated(AddGroup.class) ConvenientGoodsCategoryDTO convenientGoodsCategoryDTO) { |
| | | convenientGoodsCategoryDTO.setCreatedBy(this.getUserId()); |
| | | convenientGoodsCategoryDTO.setAreaCode(this.getAreaCode()); |
| | | return communityService.addGoodsCategory(convenientGoodsCategoryDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "编辑商品分类") |
| | | @PutMapping("/goodsCategory/put") |
| | | public R putGoodsCategory(@RequestBody @Validated(PutGroup.class) ConvenientGoodsCategoryDTO convenientGoodsCategoryDTO) { |
| | | convenientGoodsCategoryDTO.setUpdatedBy(this.getUserId()); |
| | | return communityService.putGoodsCategory(convenientGoodsCategoryDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "删除商品分类") |
| | | @DeleteMapping("/goodsCategory/delete") |
| | | public R deleteGoodsCategory(@RequestParam("categoryId") @ApiParam(value = "商品分类id", required = true) Long categoryId) { |
| | | return communityService.deleteGoodsCategory(categoryId, this.getUserId()); |
| | | } |
| | | |
| | | @ApiOperation(value = "查询商品分类详情", response = ConvenientGoodsCategoryVO.class) |
| | | @GetMapping("/goodsCategory/get") |
| | | public R getGoodsCategory(@RequestParam("categoryId") @ApiParam(value = "商品分类id", required = true) Long categoryId) { |
| | | return communityService.getGoodsCategory(categoryId); |
| | | } |
| | | |
| | | @ApiOperation(value = "分页查询商品分类", response = ConvenientGoodsCategoryVO.class) |
| | | @PostMapping("/goodsCategory/page") |
| | | public R pageGoodsCategory(@RequestBody PageConvenientGoodsCategoryDTO pageConvenientGoodsCategoryDTO) { |
| | | pageConvenientGoodsCategoryDTO.setAreaCode(this.getAreaCode()); |
| | | return communityService.pageGoodsCategory(pageConvenientGoodsCategoryDTO); |
| | | } |
| | | |
| | | } |
| | |
| | | } |
| | | |
| | | |
| | | @GetMapping("/getAllCommunityList") |
| | | @ApiOperation(value = "获取当前账号下的社区/村落列表",response = StreetVO.class) |
| | | public R communityList(){ |
| | | return userService.getAllCommunityList(); |
| | | } |
| | | |
| | | } |
| | |
| | | public R deleteFeedback(@RequestParam("id") Long id) { |
| | | return userService.deleteFeedback(id); |
| | | } |
| | | |
| | | @ApiOperation("回复意见反馈或修改意见反馈回复") |
| | | @PostMapping("feedback") |
| | | public R replyFeedBack(@RequestBody SysUserFeedbackVO sysUserFeedbackVO){ |
| | | return userService.updateFeedBack(sysUserFeedbackVO); |
| | | } |
| | | } |
| | |
| | | |
| | | import com.panzhihua.common.controller.BaseController; |
| | | import com.panzhihua.common.interfaces.OperLog; |
| | | import com.panzhihua.common.model.dtos.user.SysUserFeedbackDTO; |
| | | import com.panzhihua.common.model.vos.LoginUserInfoVO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.user.ChangePasswordVO; |
| | |
| | | import com.panzhihua.common.utlis.StringUtils; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import io.swagger.annotations.ApiParam; |
| | | import org.springframework.data.redis.core.StringRedisTemplate; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | |
| | | return R.ok(); |
| | | } |
| | | |
| | | @ApiOperation("新增投诉建议或问题留言") |
| | | @PostMapping("addFeedBack") |
| | | public R addFeedBack(@RequestBody SysUserFeedbackDTO sysUserFeedbackDTO){ |
| | | return userService.addFeedback(sysUserFeedbackDTO); |
| | | } |
| | | |
| | | @ApiOperation("查看自己的投诉建议或问题留言记录") |
| | | @GetMapping("myFeedBack") |
| | | public R myFeedBack(@ApiParam("类型:1问题留言2投诉建议") @RequestParam(value = "type",required = false)Integer type){ |
| | | return userService.myFeedBack(this.getLoginUserInfo().getUserId(),type); |
| | | } |
| | | |
| | | |
| | | } |
| | |
| | | if (r1.getCode()== Constants.SUCCESS){ |
| | | loginUserInfoVO.setType(13); |
| | | } |
| | | R r2 = userService.propertyCheck(loginUserInfoVO.getPhone()); |
| | | if (r2.getCode() == Constants.SUCCESS){ |
| | | loginUserInfoVO.setPropertyId((Long)r2.getData()); |
| | | } |
| | | } |
| | | return new UsernamePasswordAuthenticationToken(loginUserInfoVO, password, grantedAuthorityList); |
| | | } |
| | |
| | | //是否为专家登陆 |
| | | if (nonNull(loginUserInfoVO.getPhone())){ |
| | | R r1 = communityService.isExpert(loginUserInfoVO.getPhone()); |
| | | if (r1.getCode()== Constants.SUCCESS){ |
| | | if (r1.getCode() == Constants.SUCCESS){ |
| | | loginUserInfoVO.setType(13); |
| | | } |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.dtos.community; |
| | | |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | @Data |
| | | public class ComActProceedingsDTO implements Serializable { |
| | | /** |
| | | * 主键id |
| | | */ |
| | | @ApiModelProperty("id") |
| | | private Long id; |
| | | |
| | | /** |
| | | * 姓名 |
| | | */ |
| | | @ApiModelProperty("姓名") |
| | | private String name; |
| | | |
| | | /** |
| | | * 所属单位名 |
| | | */ |
| | | @ApiModelProperty("所属单位名") |
| | | private String unitName; |
| | | |
| | | /** |
| | | * 所属单位id |
| | | */ |
| | | @ApiModelProperty("所属单位id") |
| | | private Long unitId; |
| | | |
| | | /** |
| | | * 简介 |
| | | */ |
| | | @ApiModelProperty("简介") |
| | | private String introduce; |
| | | |
| | | /** |
| | | * 是否删除0否1是 |
| | | */ |
| | | @ApiModelProperty("是否删除") |
| | | private Boolean delFlag; |
| | | |
| | | /** |
| | | * 状态0可用1禁用 |
| | | */ |
| | | @ApiModelProperty("是否可用") |
| | | private Boolean status; |
| | | |
| | | /** |
| | | * 创建时间 |
| | | */ |
| | | private Date createTime; |
| | | |
| | | /** |
| | | * 创建人 |
| | | */ |
| | | private String createBy; |
| | | |
| | | /** |
| | | * 修改时间 |
| | | */ |
| | | private Date updateTime; |
| | | |
| | | /** |
| | | * 修改人 |
| | | */ |
| | | private Date updateBy; |
| | | |
| | | private String workTime; |
| | | private String logo; |
| | | |
| | | private static final long serialVersionUID = 1L; |
| | | } |
| | |
| | | |
| | | @ApiModelProperty(value = "社区id") |
| | | private Long communityId; |
| | | |
| | | @ApiModelProperty("物业公司Id") |
| | | private Long propertyId; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.dtos.community.convenient; |
| | | |
| | | import com.panzhihua.common.validated.AddGroup; |
| | | import com.panzhihua.common.validated.PutGroup; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | import org.hibernate.validator.constraints.Length; |
| | | |
| | | import javax.validation.constraints.NotBlank; |
| | | import javax.validation.constraints.NotNull; |
| | | |
| | | /** |
| | | * @ClassName: ConvenientElevatingPointDTO |
| | | * @Author: yh |
| | | * @Date: 2022/11/8 10:10 |
| | | * @Description: 新增/编辑便民服务自提点 |
| | | */ |
| | | @Data |
| | | @ApiModel("新增/编辑便民服务自提点") |
| | | public class ConvenientElevatingPointDTO { |
| | | |
| | | @ApiModelProperty("自提点ID") |
| | | @NotNull(groups = {PutGroup.class}, message = "自提点ID不能为空") |
| | | private Long id; |
| | | |
| | | @ApiModelProperty("自提点名称") |
| | | @NotBlank(groups = {AddGroup.class}, message = "自提点名称不能为空") |
| | | @Length(groups = {AddGroup.class}, max = 30, message = "自提点名称最多支持30个字符") |
| | | private String name; |
| | | |
| | | @ApiModelProperty("联系人") |
| | | @NotBlank(groups = {AddGroup.class}, message = "联系人不能为空") |
| | | private String contacts; |
| | | |
| | | |
| | | @ApiModelProperty("联系电话") |
| | | @NotBlank(groups = {AddGroup.class}, message = "联系电话不能为空") |
| | | private String phone; |
| | | |
| | | @ApiModelProperty("微信账号") |
| | | @NotBlank(groups = {AddGroup.class}, message = "微信账号不能为空") |
| | | private String wechatAccount; |
| | | |
| | | @ApiModelProperty("详细地址") |
| | | @NotBlank(groups = {AddGroup.class}, message = "详细地址不能为空") |
| | | private String address; |
| | | |
| | | @ApiModelProperty("纬度") |
| | | @NotBlank(groups = {AddGroup.class}, message = "纬度不能为空") |
| | | private String lat; |
| | | |
| | | @ApiModelProperty("经度") |
| | | @NotBlank(groups = {AddGroup.class}, message = "经度不能为空") |
| | | private String lon; |
| | | |
| | | |
| | | @ApiModelProperty("状态,1.显示 2.隐藏") |
| | | @NotNull(groups = {AddGroup.class}, message = "状态不能为空") |
| | | private Integer businessStatus; |
| | | |
| | | |
| | | @ApiModelProperty(value = "所属社区id") |
| | | @NotNull(groups = {AddGroup.class}, message = "所属社区id不能为空") |
| | | private String communityId; |
| | | |
| | | @ApiModelProperty(value = "创建人", hidden = true) |
| | | private Long createdBy; |
| | | |
| | | @ApiModelProperty(value = "更新人", hidden = true) |
| | | private Long updatedBy; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.dtos.community.convenient; |
| | | |
| | | import com.panzhihua.common.validated.AddGroup; |
| | | import com.panzhihua.common.validated.PutGroup; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import javax.validation.constraints.NotBlank; |
| | | import javax.validation.constraints.NotNull; |
| | | |
| | | /** |
| | | * @title: ConvenientGoodsCategoryDTO |
| | | * @projectName: 成都呐喊信息技术有限公司-智慧社区项目 |
| | | * @description: 新增/编辑商品务分类 |
| | | * @author: yh |
| | | * @date: 2022-10-21 09:36:09 |
| | | */ |
| | | @Data |
| | | @ApiModel("新增/编辑商品务分类") |
| | | public class ConvenientGoodsCategoryDTO { |
| | | |
| | | @ApiModelProperty("分类ID") |
| | | @NotNull(groups = {PutGroup.class}, message = "分类id不能为空") |
| | | private Long id; |
| | | |
| | | @ApiModelProperty("分类名称") |
| | | @NotBlank(groups = {AddGroup.class}, message = "分类名称不能为空") |
| | | private String name; |
| | | |
| | | |
| | | @ApiModelProperty("备注") |
| | | private String remark; |
| | | |
| | | @ApiModelProperty("权重") |
| | | @NotNull(groups = {AddGroup.class}, message = "权重不能为空") |
| | | private Integer weight; |
| | | |
| | | @ApiModelProperty(value = "创建人", hidden = true) |
| | | private Long createdBy; |
| | | |
| | | @ApiModelProperty(value = "更新人", hidden = true) |
| | | private Long updatedBy; |
| | | |
| | | private String areaCode; |
| | | } |
| | |
| | | |
| | | private String areaCode; |
| | | |
| | | @ApiModelProperty("服务范围") |
| | | private Integer serviceRange; |
| | | |
| | | public String getPeriod() { |
| | | return period.name(); |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.dtos.community.convenient; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import javax.validation.constraints.Min; |
| | | import javax.validation.constraints.NotNull; |
| | | |
| | | /** |
| | | * @title: PageConvenientElevatingPointDTO |
| | | * @projectName: 成都呐喊信息技术有限公司-智慧社区项目 |
| | | * @description: 分页查询便民服务自提点请求参数 |
| | | * @author: yh |
| | | * @date: 2022-10-21 09:36:09 |
| | | */ |
| | | @Data |
| | | @ApiModel("分页查询便民服务自提点请求参数") |
| | | public class PageConvenientElevatingPointDTO { |
| | | |
| | | @ApiModelProperty("关键词") |
| | | private String keyword; |
| | | |
| | | @ApiModelProperty("社区id") |
| | | private Long communityId; |
| | | |
| | | |
| | | @ApiModelProperty("营业状态(1.显示 2.隐藏)") |
| | | private Integer businessStatus; |
| | | |
| | | @ApiModelProperty(value = "分页-当前页数", example = "1") |
| | | @NotNull(message = "分页参数不能为空") |
| | | @Min(value = 1) |
| | | private Long pageNum; |
| | | |
| | | @ApiModelProperty(value = "分页-每页记录数", example = "10") |
| | | @NotNull(message = "分页参数不能为空") |
| | | @Min(value = 1) |
| | | private Long pageSize; |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.dtos.community.convenient; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @title: PageConvenientGoodsCategoryDTO |
| | | * @projectName: 成都呐喊信息技术有限公司-智慧社区项目 |
| | | * @description: 分页查询商品分类请求参数 |
| | | * @author: yh |
| | | * @date: 2022-10-21 09:36:09 |
| | | */ |
| | | @Data |
| | | @ApiModel("分页查询商品分类请求参数") |
| | | public class PageConvenientGoodsCategoryDTO { |
| | | |
| | | @ApiModelProperty("分类名称") |
| | | private String name; |
| | | |
| | | @ApiModelProperty(value = "分页-当前页数", example = "1") |
| | | private Long pageNum; |
| | | |
| | | @ApiModelProperty(value = "分页-每页记录数", example = "10") |
| | | private Long pageSize; |
| | | |
| | | private String areaCode; |
| | | } |
| | |
| | | private String unit; |
| | | private String unitId; |
| | | |
| | | @ApiModelProperty("appId,区分西区或花城") |
| | | private String appId; |
| | | |
| | | |
| | | |
| | | } |
| | |
| | | |
| | | @ApiModelProperty(value = "appid", hidden = true) |
| | | private String appid; |
| | | |
| | | @ApiModelProperty("物业公司id") |
| | | private Long propertyId; |
| | | @ApiModelProperty("1是社区团队 2党员先锋") |
| | | private Integer type; |
| | | } |
| | |
| | | private Long streetId; |
| | | @ApiModelProperty("关键字") |
| | | private String keyword; |
| | | @ApiModelProperty("物业公司id") |
| | | private Long propertyId; |
| | | @ApiModelProperty("1是社区团队 2党员先锋") |
| | | private Integer type; |
| | | } |
| | |
| | | @ApiModelProperty(value = "分页-每页记录数", example = "10") |
| | | @NotNull |
| | | private Long pageSize; |
| | | @ApiModelProperty("物业id") |
| | | private Long propertyId; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.dtos.shop; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @auther yh |
| | | * @create 2022-10-21 09:36:09 |
| | | * @describe 查询商品请求参数 |
| | | */ |
| | | @Data |
| | | @ApiModel("查询商品请求参数") |
| | | public class ComShopFlowerGoodsDTO { |
| | | |
| | | @ApiModelProperty(value = "分页-当前页数", example = "1") |
| | | private Long pageNum = 1L; |
| | | |
| | | @ApiModelProperty(value = "分页-每页记录数", example = "10") |
| | | private Long pageSize = 10L; |
| | | |
| | | @ApiModelProperty("商品名称") |
| | | private String name; |
| | | |
| | | @ApiModelProperty("店铺id") |
| | | private Long storeId; |
| | | |
| | | @ApiModelProperty("商品状态(1.出售中 2.已下架 3.回收站)") |
| | | private Integer status; |
| | | |
| | | @ApiModelProperty("配送方式(1.商家配送 2.快递物流)") |
| | | private Integer deliveryType; |
| | | |
| | | @ApiModelProperty(hidden = true) |
| | | private Long userId; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.dtos.shop; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @auther yh |
| | | * @describe 分页查询商品 |
| | | */ |
| | | @ApiModel("分页查询商品") |
| | | @Data |
| | | public class PageComShopFlowerGoodsDTO { |
| | | |
| | | @ApiModelProperty(value = "商品名称") |
| | | private String name; |
| | | |
| | | @ApiModelProperty(value = "店铺名称") |
| | | private String storeName; |
| | | @ApiModelProperty(value = "店铺Id") |
| | | private Long storeId; |
| | | |
| | | @ApiModelProperty(value = "商品状态(1.出售中 2.已下架 3.回收站)", example = "1") |
| | | private Integer status; |
| | | |
| | | @ApiModelProperty(value = "分页-当前页数", example = "1") |
| | | private Long pageNum; |
| | | |
| | | @ApiModelProperty(value = "分页-每页记录数", example = "10") |
| | | private Long pageSize; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.dtos.shop; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @auther yh |
| | | * @create 2022-10-21 09:36:09 |
| | | * @describe 分页查询店铺 |
| | | */ |
| | | @Data |
| | | @ApiModel("分页查询店铺") |
| | | public class PageComShopFlowerStoreDTO { |
| | | |
| | | @ApiModelProperty(value = "分页-当前页数", example = "1") |
| | | private Long pageNum = 1L; |
| | | @ApiModelProperty(value = "商家姓名") |
| | | private String contacts; |
| | | @ApiModelProperty(value = "商家账号") |
| | | private String account; |
| | | @ApiModelProperty(value = "店铺名称") |
| | | private String name; |
| | | @ApiModelProperty(value = "配送方式(1.自提 2.快递)") |
| | | private Integer deliveryType; |
| | | @ApiModelProperty(value = "店铺状态(1.启用 2.禁用)") |
| | | private Integer status; |
| | | |
| | | @ApiModelProperty(value = "分页-每页记录数", example = "10") |
| | | private Long pageSize = 10L; |
| | | |
| | | @ApiModelProperty("店铺id") |
| | | private Long storeId; |
| | | } |
| | |
| | | private String phone; |
| | | |
| | | private String areaCode; |
| | | |
| | | private Integer type; |
| | | } |
| | |
| | | |
| | | @ApiModelProperty(value = "状态 0", hidden = true) |
| | | private Integer status; |
| | | |
| | | @ApiModelProperty("1投诉建议2问题留言") |
| | | private Integer type; |
| | | |
| | | @ApiModelProperty("页数") |
| | | private Integer page; |
| | | |
| | | @ApiModelProperty("每页大小") |
| | | private Integer size; |
| | | |
| | | @ApiModelProperty("用户昵称") |
| | | private String nickName; |
| | | |
| | | @ApiModelProperty("用户姓名") |
| | | private String name; |
| | | |
| | | @ApiModelProperty("电话") |
| | | private String phone; |
| | | } |
| | |
| | | |
| | | @ApiModelProperty("权限等级1-5:超管-行业分中心-街道-社区-专家") |
| | | private Integer level; |
| | | |
| | | @ApiModelProperty("物业公司id") |
| | | private Long propertyId; |
| | | } |
| | |
| | | package com.panzhihua.common.model.vos.community; |
| | | |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import com.fasterxml.jackson.databind.annotation.JsonSerialize; |
| | | import com.fasterxml.jackson.databind.ser.std.ToStringSerializer; |
| | | import io.swagger.annotations.ApiModel; |
| | |
| | | * 创建时间 |
| | | */ |
| | | @ApiModelProperty(value = "创建时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private Date createTime; |
| | | |
| | | /** |
| | |
| | | |
| | | @ApiModelProperty("分类名称") |
| | | private String columnName; |
| | | |
| | | @ApiModelProperty("propertyId") |
| | | private Long propertyId; |
| | | } |
| | |
| | | @ApiModelProperty("显示时间") |
| | | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") |
| | | private Date releaseTime; |
| | | |
| | | /** |
| | | * 是否置顶 |
| | | * */ |
| | | @ApiModelProperty("广告是否置顶0否1是") |
| | | private Integer onTop; |
| | | |
| | | /** |
| | | * 图片链接 |
| | | * */ |
| | | @ApiModelProperty("图片链接") |
| | | private String imageUrl; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.vos.community; |
| | | |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | |
| | | public class ComActProceedingsVO implements Serializable { |
| | | /** |
| | | * 主键id |
| | | */ |
| | | @ApiModelProperty("id") |
| | | private Long id; |
| | | |
| | | /** |
| | | * 姓名 |
| | | */ |
| | | @ApiModelProperty("姓名") |
| | | private String name; |
| | | |
| | | /** |
| | | * 所属单位名 |
| | | */ |
| | | @ApiModelProperty("所属单位名") |
| | | private String unitName; |
| | | |
| | | /** |
| | | * 所属单位id |
| | | */ |
| | | @ApiModelProperty("所属单位id") |
| | | private Long unitId; |
| | | |
| | | /** |
| | | * 简介 |
| | | */ |
| | | @ApiModelProperty("简介") |
| | | private String introduce; |
| | | |
| | | /** |
| | | * 是否删除0否1是 |
| | | */ |
| | | @ApiModelProperty("是否删除") |
| | | private Boolean delFlag; |
| | | |
| | | /** |
| | | * 状态0可用1禁用 |
| | | */ |
| | | @ApiModelProperty("是否可用") |
| | | private Boolean status; |
| | | |
| | | /** |
| | | * 创建时间 |
| | | */ |
| | | private Date createTime; |
| | | |
| | | /** |
| | | * 创建人 |
| | | */ |
| | | private String createBy; |
| | | |
| | | /** |
| | | * 修改时间 |
| | | */ |
| | | private Date updateTime; |
| | | |
| | | /** |
| | | * 修改人 |
| | | */ |
| | | private Date updateBy; |
| | | |
| | | @ApiModelProperty("工作时间") |
| | | private String workTime; |
| | | |
| | | private static final long serialVersionUID = 1L; |
| | | } |
| | |
| | | private String universityName; |
| | | |
| | | private String communityName; |
| | | @ApiModelProperty("物业公司Id") |
| | | private Long propertyId; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.vos.community; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | @Data |
| | | @ApiModel("问题清单、需求清单、报到服务活动数量") |
| | | public class DataCount { |
| | | @ApiModelProperty("问题清单数") |
| | | private Integer questions; |
| | | @ApiModelProperty("需求清单数") |
| | | private Integer demands; |
| | | @ApiModelProperty("报道服务活动数") |
| | | private Integer activities; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.vos.community.convenient; |
| | | |
| | | 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; |
| | | |
| | | /** |
| | | * @ClassName: ConvenientElevatingPointVO |
| | | * @Author: yh |
| | | * @Date: 2022/11/8 9:54 |
| | | * @Description: 便民服自提点 |
| | | */ |
| | | @Data |
| | | @ApiModel("便民服自提点") |
| | | public class ConvenientElevatingPointVO { |
| | | /** |
| | | * 主键id |
| | | */ |
| | | @ApiModelProperty("主键id") |
| | | @JsonSerialize(using = ToStringSerializer.class) |
| | | private Long id; |
| | | /** |
| | | * 自提点名称 |
| | | */ |
| | | @ApiModelProperty("自提点名称") |
| | | private String name; |
| | | /** |
| | | * 社区id |
| | | */ |
| | | @ApiModelProperty("社区id") |
| | | private String communityId; |
| | | /** |
| | | * 社区名称 |
| | | */ |
| | | @ApiModelProperty("社区名称") |
| | | private String communityName; |
| | | /** |
| | | * 提货点地址 |
| | | */ |
| | | @ApiModelProperty("提货点地址") |
| | | private String address; |
| | | /** |
| | | * 联系人 |
| | | */ |
| | | @ApiModelProperty("联系人") |
| | | private String contacts; |
| | | /** |
| | | * 纬度 |
| | | */ |
| | | @ApiModelProperty("纬度") |
| | | private String lat; |
| | | /** |
| | | * 经度 |
| | | */ |
| | | @ApiModelProperty("经度") |
| | | private String lon; |
| | | /** |
| | | * 联系电话 |
| | | */ |
| | | @ApiModelProperty("联系电话") |
| | | private String phone; |
| | | /** |
| | | * 微信账号 |
| | | */ |
| | | @ApiModelProperty("微信账号") |
| | | private String wechatAccount; |
| | | /** |
| | | * 状态,1:显示,2:隐藏 |
| | | */ |
| | | @ApiModelProperty("状态,1:显示,2:隐藏") |
| | | private Integer businessStatus; |
| | | /** |
| | | * 累计商品数量 |
| | | */ |
| | | @ApiModelProperty("累计商品数量") |
| | | private Long cumulativeGoodsNum; |
| | | /** |
| | | * 待提货数量 |
| | | */ |
| | | @ApiModelProperty("待提货数量") |
| | | private Long prepareGoodsNum; |
| | | /** |
| | | * 已提货数量 |
| | | */ |
| | | @ApiModelProperty("已提货数量") |
| | | private Long alreadyGoodsNum; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.vos.community.convenient; |
| | | |
| | | 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; |
| | | |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @title: ConvenientGoodsCategoryVO |
| | | * @projectName: 成都呐喊信息技术有限公司-智慧社区项目 |
| | | * @description: 商品分类信息 |
| | | * @author: yh |
| | | * @date: 2022-10-21 09:36:09 |
| | | */ |
| | | @Data |
| | | @ApiModel("商品分类信息") |
| | | public class ConvenientGoodsCategoryVO { |
| | | |
| | | @ApiModelProperty("分类ID") |
| | | @JsonSerialize(using = ToStringSerializer.class) |
| | | private Long id; |
| | | |
| | | @ApiModelProperty("分类名称") |
| | | private String name; |
| | | |
| | | @ApiModelProperty("备注") |
| | | private String remark; |
| | | |
| | | @ApiModelProperty("权重") |
| | | private Integer weight; |
| | | |
| | | @ApiModelProperty("创建人") |
| | | private String createdBy; |
| | | |
| | | @ApiModelProperty("创建时间") |
| | | private Date createdAt; |
| | | } |
| | |
| | | private String jumpUrl; |
| | | @ApiModelProperty("跳转类型") |
| | | private String jumpType; |
| | | @ApiModelProperty("banner图片地址") |
| | | private String imageUrl; |
| | | } |
| | |
| | | private Integer choice; |
| | | @ApiModelProperty("排序方式 正序 ASC") |
| | | private String sort; |
| | | |
| | | private String appId; |
| | | } |
| | |
| | | |
| | | @ApiModelProperty("排序方式 正序 ASC") |
| | | private String sort; |
| | | |
| | | private String appId; |
| | | } |
| | |
| | | /**调解上传图片地址列表,逗号进行分割*/ |
| | | @ApiModelProperty(name = "images", value = "调解上传图片地址列表,逗号进行分割") |
| | | private List<ComEventRequestImageVO> images; |
| | | private String appId; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.vos.shop; |
| | | |
| | | import com.panzhihua.common.validated.AddGroup; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import javax.validation.constraints.Digits; |
| | | import javax.validation.constraints.Min; |
| | | import java.math.BigDecimal; |
| | | |
| | | /** |
| | | * @auther yh |
| | | * @describe |
| | | */ |
| | | @Data |
| | | @ApiModel("商品规格") |
| | | public class AddShopFlowerGoodsAttrVO { |
| | | |
| | | @ApiModelProperty("商品规格Id:编辑必传") |
| | | private Long goodsAttrId; |
| | | |
| | | @ApiModelProperty("商品规格") |
| | | private String goodsAttrName; |
| | | |
| | | @ApiModelProperty("原价") |
| | | @Min(groups = {AddGroup.class}, value = 0, message = "原价最小值为0") |
| | | @Digits(groups = {AddGroup.class}, integer = 8, fraction = 2) |
| | | private BigDecimal price; |
| | | |
| | | @ApiModelProperty("包邮价") |
| | | // @Min(groups = {AddGroup.class}, value = 0, message = "包邮价最小值为0") |
| | | // @Digits(groups = {AddGroup.class}, integer = 8, fraction = 2) |
| | | private BigDecimal freeShippingPrice; |
| | | |
| | | @ApiModelProperty("拼单价") |
| | | // @Min(groups = {AddGroup.class}, value = 0, message = "拼单价最小值为0") |
| | | // @Digits(groups = {AddGroup.class}, integer = 8, fraction = 2) |
| | | private BigDecimal collatePrice; |
| | | |
| | | @ApiModelProperty("商品规格图") |
| | | private String attrPic; |
| | | |
| | | @ApiModelProperty("库存") |
| | | private Integer stock; |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.vos.shop; |
| | | |
| | | import com.panzhihua.common.validated.AddGroup; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import javax.validation.Valid; |
| | | import javax.validation.constraints.Digits; |
| | | import javax.validation.constraints.Min; |
| | | import java.math.BigDecimal; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @auther yh |
| | | * @describe 商品 |
| | | */ |
| | | @Data |
| | | @ApiModel("添加商品") |
| | | public class AddShopFlowerGoodsVO { |
| | | |
| | | @ApiModelProperty("店铺id") |
| | | private Long storeId; |
| | | |
| | | @ApiModelProperty("商品名称") |
| | | private String name; |
| | | |
| | | @ApiModelProperty("商品现价") |
| | | @Min(groups = {AddGroup.class}, value = 0, message = "价格最小值为0") |
| | | @Digits(groups = {AddGroup.class}, integer = 8, fraction = 2) |
| | | private BigDecimal price; |
| | | |
| | | @ApiModelProperty("商品单位") |
| | | private String unit; |
| | | |
| | | @ApiModelProperty("商品状态(1.出售中 2.已下架 3.回收站)") |
| | | private Integer status; |
| | | |
| | | @ApiModelProperty("商品主图") |
| | | private String goodsPic; |
| | | |
| | | @ApiModelProperty("商品图片") |
| | | private String images; |
| | | |
| | | @ApiModelProperty("商品详情") |
| | | private String details; |
| | | |
| | | /** |
| | | * 配送方式(1.商家配送 2.快递物流) |
| | | */ |
| | | @ApiModelProperty(value = "配送方式(1.商家配送 2.快递物流)", hidden = true) |
| | | private Integer deliveryType; |
| | | |
| | | @ApiModelProperty("商品规格") |
| | | @Valid |
| | | private List<AddShopFlowerGoodsAttrVO> goodsAttrVOList; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.vos.shop; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.math.BigDecimal; |
| | | |
| | | /** |
| | | * @auther yh |
| | | * @create 2022-10-21 09:36:09 |
| | | * @describe 商品规格信息 |
| | | */ |
| | | @Data |
| | | @ApiModel("商品规格信息") |
| | | public class ComShopFlowerGoodsAttrVO { |
| | | |
| | | /** |
| | | * 商品规格id |
| | | */ |
| | | @ApiModelProperty("商品规格id") |
| | | private Long id; |
| | | |
| | | /** |
| | | * 商品id |
| | | */ |
| | | @ApiModelProperty("商品id") |
| | | private Long goodsId; |
| | | |
| | | /** |
| | | * 店铺id |
| | | */ |
| | | @ApiModelProperty("店铺id") |
| | | private Long storeId; |
| | | |
| | | /** |
| | | * 商品名称 |
| | | */ |
| | | @ApiModelProperty("商品名称") |
| | | private String goodsName; |
| | | |
| | | /** |
| | | * 商品规格 |
| | | */ |
| | | @ApiModelProperty("商品规格") |
| | | private String goodsAttrName; |
| | | |
| | | /** |
| | | * 商品规格库存 |
| | | */ |
| | | @ApiModelProperty("商品规格库存") |
| | | private Integer stock; |
| | | |
| | | /** |
| | | * 商品规格销量 |
| | | */ |
| | | @ApiModelProperty("商品规格销量") |
| | | private Integer sale; |
| | | |
| | | /** |
| | | * 商品规格图 |
| | | */ |
| | | @ApiModelProperty("商品规格图") |
| | | private String attrPic; |
| | | |
| | | /** |
| | | * 是否是默认规格(1.是 2.否) |
| | | */ |
| | | @ApiModelProperty("是否是默认规格(1.是 2.否)") |
| | | private Integer isDefault; |
| | | |
| | | /** |
| | | * 规格价格 |
| | | */ |
| | | @ApiModelProperty("规格价格") |
| | | private BigDecimal price; |
| | | |
| | | |
| | | /** |
| | | * 包邮价 |
| | | */ |
| | | @ApiModelProperty("包邮价") |
| | | private BigDecimal freeShippingPrice; |
| | | /** |
| | | * 拼单价 |
| | | */ |
| | | @ApiModelProperty("拼单价") |
| | | private BigDecimal collatePrice; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.vos.shop; |
| | | |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientMerchantVO; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.math.BigDecimal; |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @auther yh |
| | | * @create 2022-10-21 09:36:09 |
| | | * @describe 商品信息 |
| | | */ |
| | | @Data |
| | | @ApiModel("商品信息") |
| | | public class ComShopFlowerGoodsVO { |
| | | |
| | | /** |
| | | * 商品id |
| | | */ |
| | | @ApiModelProperty("商品id") |
| | | private Long id; |
| | | |
| | | /** |
| | | * 商品名称 |
| | | */ |
| | | @ApiModelProperty("商品名称") |
| | | private String name; |
| | | |
| | | /** |
| | | * 店铺id |
| | | */ |
| | | @ApiModelProperty("店铺id") |
| | | private Long storeId; |
| | | |
| | | /** |
| | | * 商品主图 |
| | | */ |
| | | @ApiModelProperty("商品主图") |
| | | private String goodsPic; |
| | | |
| | | /** |
| | | * 商品展示图 |
| | | */ |
| | | @ApiModelProperty("商品展示图") |
| | | private String images; |
| | | |
| | | /** |
| | | * 商品状态(1.出售中 2.已下架 3.回收站) |
| | | */ |
| | | @ApiModelProperty("商品状态(1.出售中 2.已下架 3.回收站)") |
| | | private Integer status; |
| | | |
| | | /** |
| | | * 商品销量 |
| | | */ |
| | | @ApiModelProperty("商品销量") |
| | | private Integer sale; |
| | | |
| | | /** |
| | | * 商品原价 |
| | | */ |
| | | @ApiModelProperty("商品原价") |
| | | private BigDecimal originalPrice; |
| | | |
| | | /** |
| | | * 商品现价 |
| | | */ |
| | | @ApiModelProperty("商品现价") |
| | | private BigDecimal price; |
| | | |
| | | /** |
| | | * 商品单位 |
| | | */ |
| | | @ApiModelProperty("商品单位") |
| | | private String unit; |
| | | |
| | | /** |
| | | * 商品排序 |
| | | */ |
| | | @ApiModelProperty("商品排序") |
| | | private Integer order; |
| | | |
| | | /** |
| | | * 商品总库存 |
| | | */ |
| | | @ApiModelProperty("商品总库存") |
| | | private Integer stock; |
| | | |
| | | /** |
| | | * 商品详情 |
| | | */ |
| | | @ApiModelProperty("商品详情") |
| | | private String details; |
| | | |
| | | /** |
| | | * 配送方式(1.商家配送 2.快递物流) |
| | | */ |
| | | @ApiModelProperty("配送方式(1.商家配送 2.快递物流)") |
| | | private Integer deliveryType; |
| | | |
| | | /** |
| | | * 商品规格列表 |
| | | */ |
| | | @ApiModelProperty("商品规格列表") |
| | | private List<ComShopFlowerGoodsAttrVO> goodsAttrList; |
| | | |
| | | /** |
| | | * 店铺信息 |
| | | */ |
| | | @ApiModelProperty("商品店铺信息") |
| | | private ConvenientMerchantVO convenientMerchantVO; |
| | | |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") |
| | | @ApiModelProperty("创建时间") |
| | | private Date createAt; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.vos.shop; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.math.BigDecimal; |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @auther yh |
| | | * @describe * @describe 商品VO |
| | | */ |
| | | @Data |
| | | @ApiModel("商品") |
| | | public class PageShopFlowerGoodsVO { |
| | | |
| | | @ApiModelProperty("商品id") |
| | | private Long id; |
| | | |
| | | @ApiModelProperty("商品分类id") |
| | | private Long typeId; |
| | | |
| | | @ApiModelProperty("商品名称") |
| | | private String name; |
| | | |
| | | @ApiModelProperty("商铺名称") |
| | | private String storeName; |
| | | |
| | | @ApiModelProperty("店铺id") |
| | | private Long storeId; |
| | | |
| | | @ApiModelProperty("商品主图") |
| | | private String goodsPic; |
| | | |
| | | @ApiModelProperty("商品展示图") |
| | | private String images; |
| | | |
| | | @ApiModelProperty("商品状态(1.上架 2.已下架 3.回收站)") |
| | | private Integer status; |
| | | |
| | | @ApiModelProperty("商品销量") |
| | | private Integer sale; |
| | | |
| | | @ApiModelProperty("商品原价") |
| | | private BigDecimal originalPrice; |
| | | |
| | | @ApiModelProperty("商品现价") |
| | | private BigDecimal price; |
| | | |
| | | @ApiModelProperty("商品单位") |
| | | private String unit; |
| | | |
| | | @ApiModelProperty("商品排序") |
| | | private Integer order; |
| | | |
| | | @ApiModelProperty("商品总库存") |
| | | private Integer stock; |
| | | |
| | | @ApiModelProperty("商品详情") |
| | | private String details; |
| | | |
| | | @ApiModelProperty("商品备注") |
| | | private String remark; |
| | | |
| | | @ApiModelProperty("商品描述") |
| | | private String goodsDescribe; |
| | | |
| | | @ApiModelProperty("配送方式(1.自提 2.快递)") |
| | | private Integer deliveryType; |
| | | |
| | | @ApiModelProperty("删除状态(1.未删除 2.已删除)") |
| | | private Integer deleteStatus; |
| | | |
| | | @ApiModelProperty("创建时间") |
| | | private Date createAt; |
| | | |
| | | @ApiModelProperty("修改时间") |
| | | private Date updateAt; |
| | | |
| | | @ApiModelProperty("规格") |
| | | private List<AddShopFlowerGoodsAttrVO> goodsAttrs; |
| | | } |
| | |
| | | |
| | | @ApiModelProperty("手机号") |
| | | private String phone; |
| | | |
| | | @ApiModelProperty("回复内容") |
| | | private String reply; |
| | | } |
| | |
| | | import java.util.List; |
| | | |
| | | import com.panzhihua.common.model.dtos.PageBaseDTO; |
| | | import com.panzhihua.common.model.dtos.community.ActivityInviteDTO; |
| | | import com.panzhihua.common.model.dtos.community.DiscussVoteOptionDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageActivityInviteDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageVoteSituationDTO; |
| | | import com.panzhihua.common.model.dtos.community.*; |
| | | import com.panzhihua.common.model.dtos.community.acid.*; |
| | | import com.panzhihua.common.model.dtos.community.convenient.*; |
| | | import com.panzhihua.common.model.dtos.community.dpc.AddDpcDTO; |
| | | import com.panzhihua.common.model.dtos.community.dpc.EditDpcDTO; |
| | | import com.panzhihua.common.model.dtos.community.dpc.PageDpcDTO; |
| | |
| | | import com.panzhihua.common.model.dtos.community.reserve.*; |
| | | import com.panzhihua.common.model.dtos.community.sanshuo.*; |
| | | import com.panzhihua.common.model.dtos.community.warehouse.ComActWarehouseApplyDTO; |
| | | import com.panzhihua.common.model.dtos.community.GetIdentityEidTokenDTO; |
| | | import com.panzhihua.common.model.dtos.community.cluster.PageClusterMemberDto; |
| | | import com.panzhihua.common.model.dtos.property.CommonPage; |
| | | import com.panzhihua.common.model.dtos.community.discuss.ComActDiscussDetailDTO; |
| | |
| | | import com.panzhihua.common.model.dtos.neighbor.*; |
| | | import com.panzhihua.common.model.dtos.property.PagePropertyWorkerDTO; |
| | | import com.panzhihua.common.model.dtos.property.PropertyWorkerDTO; |
| | | import com.panzhihua.common.model.dtos.shop.*; |
| | | import com.panzhihua.common.model.vos.civil.ComActSocialWorkerVO; |
| | | import com.panzhihua.common.model.vos.community.acid.ComActAcidCheckRecordVO; |
| | | import com.panzhihua.common.model.vos.community.acid.ComActAcidMemberVO; |
| | |
| | | import com.panzhihua.common.model.vos.community.raffle.ComActRaffleRecordVO; |
| | | import com.panzhihua.common.model.vos.community.raffle.ComActRaffleVO; |
| | | import com.panzhihua.common.model.vos.community.reserve.ComActReserveDangerAreaVO; |
| | | import com.panzhihua.common.model.vos.shop.AddShopFlowerGoodsVO; |
| | | import io.swagger.annotations.ApiParam; |
| | | import org.springframework.cloud.openfeign.FeignClient; |
| | | import org.springframework.scheduling.annotation.Async; |
| | |
| | | import com.panzhihua.common.model.dtos.common.PageComMngVolunteerOrgTeamDto; |
| | | import com.panzhihua.common.model.dtos.common.PageComMngVolunteerServiceTypeDto; |
| | | import com.panzhihua.common.model.dtos.common.PageComMngVolunteerSkillDto; |
| | | import com.panzhihua.common.model.dtos.community.AddComActDynTypeDTO; |
| | | import com.panzhihua.common.model.dtos.community.AddIdentityAuthDTO; |
| | | import com.panzhihua.common.model.dtos.community.CancelRecordDTO; |
| | | import com.panzhihua.common.model.dtos.community.CascadeHouseDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComActDiscussCommentDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComActDiscussCommentUserDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComActDiscussDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComActDiscussOptionUserDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComActDiscussUserDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComActEasyPhotoCommentDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComActEasyPhotoCommentUserDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComCvtBusinessDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComCvtCategoryDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComCvtServeDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComExServicemanDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComMngCarAppletDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComMngCarSaveDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComMngPopulationDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComMngPopulationEditDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComMngPopulationHouseAdminDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComMngPopulationHouseEditAdminDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComMngPopulationHouseInsertAdminDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComMngPopulationHouseUserVO; |
| | | import com.panzhihua.common.model.dtos.community.ComMngPopulationTagDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComMngRealCompanyBelongsDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComOpsHouseDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComPropertyPublicityDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComSwDangerReportEditDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComSwDangerReportHandleDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComSwDangerReportRectifyDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComSwPatrolRecordAddDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComSwPatrolRecordEditDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComSwPatrolRecordPageDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComSwRotaPageDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComSwRotaSaveDTO; |
| | | import com.panzhihua.common.model.dtos.community.ComSwSafetyWorkEditDTO; |
| | | import com.panzhihua.common.model.dtos.community.DisabledPersonsDTO; |
| | | import com.panzhihua.common.model.dtos.community.EditComActDynTypeDTO; |
| | | import com.panzhihua.common.model.dtos.community.EldersAuthAddByFamilyDTO; |
| | | import com.panzhihua.common.model.dtos.community.EldersAuthAddDTO; |
| | | import com.panzhihua.common.model.dtos.community.EldersAuthDeleteDTO; |
| | | import com.panzhihua.common.model.dtos.community.EldersAuthEditDTO; |
| | | import com.panzhihua.common.model.dtos.community.EldersAuthElderlyDTO; |
| | | import com.panzhihua.common.model.dtos.community.EldersAuthFeedbackAddDTO; |
| | | import com.panzhihua.common.model.dtos.community.EldersAuthTypeQueryDTO; |
| | | import com.panzhihua.common.model.dtos.community.ExportComMngCarExcelDTO; |
| | | import com.panzhihua.common.model.dtos.community.ExportRealAssetsExcelDTO; |
| | | import com.panzhihua.common.model.dtos.community.ExportRealCompanyExcelDTO; |
| | | import com.panzhihua.common.model.dtos.community.GrantRewardDTO; |
| | | import com.panzhihua.common.model.dtos.community.KeyPersonInfoDTO; |
| | | import com.panzhihua.common.model.dtos.community.OperationDetailDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageActWorkGuideDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComActDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComActDiscussCommentDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComActDiscussDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComActDynTypeDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComActEasyPhotoCommentDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComCvtBusinessAppletsDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComCvtBusinessDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComCvtCategoryDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComCvtServeDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComEldersRecordsDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComMngCarDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComMngRealAssetsDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComMngRealCompanyDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComMngVillageDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComOpsHouseDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComPropertyPublicityDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComStreetDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageElderAuthRecordsDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageEldersAuthDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageEldersAuthElderlyDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageEldersAuthHistoryDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageEldersAuthRecordDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageIdentityAuthRecordDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageQuestnaireAnswerDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageQuestnaireDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageQuestnaireSubDetailsDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageUserReserveDTO; |
| | | import com.panzhihua.common.model.dtos.community.bigscreen.BigScreenEventDTO; |
| | | import com.panzhihua.common.model.dtos.community.bigscreen.BigScreenEventDetailDTO; |
| | | import com.panzhihua.common.model.dtos.community.bigscreen.BigScreenStatisticAgeGenderDTO; |
| | |
| | | import com.panzhihua.common.model.dtos.community.cluster.admin.EditClusterMemberAdminDto; |
| | | import com.panzhihua.common.model.dtos.community.cluster.admin.PageClusterAdminDto; |
| | | import com.panzhihua.common.model.dtos.community.cluster.admin.PageClusterMemberAdminDto; |
| | | import com.panzhihua.common.model.dtos.community.convenient.ConvenientMerchantDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.ConvenientProductCategoryDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.ConvenientProductDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.ConvenientServiceCategoryDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.DeleteConvenientProductDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.DisableOrEnableConvenientMerchantDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.ExportMerchantDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.OnShelfOrOffShelfProductDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageClassifyMerchantDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageConvenientMerchantDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageConvenientProductCategoryDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageConvenientProductDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageConvenientServiceCategoryDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PagePopularMerchantDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageSearchDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.ResetPasswordConvenientMerchantDTO; |
| | | import com.panzhihua.common.model.dtos.community.easyPhoto.AddEasyPhotoActivityDTO; |
| | | import com.panzhihua.common.model.dtos.community.easyPhoto.AddEasyPhotoClassifyDTO; |
| | | import com.panzhihua.common.model.dtos.community.easyPhoto.EditEasyPhotoActivityDTO; |
| | |
| | | import com.panzhihua.common.model.dtos.neighbor.DeleteNeighborCircleAppDTO; |
| | | import com.panzhihua.common.model.dtos.neighbor.DetailNeighborAllCommentByAdminDTO; |
| | | import com.panzhihua.common.model.dtos.neighbor.DetailNeighborCommentReplyByAdminDTO; |
| | | import com.panzhihua.common.model.dtos.shop.ComShopAddressDTO; |
| | | import com.panzhihua.common.model.dtos.shop.ComShopCartDTO; |
| | | import com.panzhihua.common.model.dtos.shop.ComShopEditNubCartDTO; |
| | | import com.panzhihua.common.model.dtos.shop.ComShopFundsExportDTO; |
| | | import com.panzhihua.common.model.dtos.shop.ComShopGoodsDTO; |
| | | import com.panzhihua.common.model.dtos.shop.ComShopOrderCreateDTO; |
| | | import com.panzhihua.common.model.dtos.shop.ComShopOrderDeliverDTO; |
| | | import com.panzhihua.common.model.dtos.shop.ComShopOrderExportDTO; |
| | | import com.panzhihua.common.model.dtos.shop.ComShopOrderPreviewDTO; |
| | | import com.panzhihua.common.model.dtos.shop.ComShopOrderQueryDTO; |
| | | import com.panzhihua.common.model.dtos.shop.ComShopOrderShipDTO; |
| | | import com.panzhihua.common.model.dtos.shop.ComShopSysConfDTO; |
| | | import com.panzhihua.common.model.dtos.shop.OrderPayDTO; |
| | | import com.panzhihua.common.model.dtos.shop.PageComOrderListDTO; |
| | | import com.panzhihua.common.model.dtos.shop.PageComShopAddressDTO; |
| | | import com.panzhihua.common.model.dtos.shop.PageComShopFundsSearchDTO; |
| | | import com.panzhihua.common.model.dtos.shop.PageComShopGoodsDTO; |
| | | import com.panzhihua.common.model.dtos.shop.PageComShopOrderSearchDTO; |
| | | import com.panzhihua.common.model.dtos.shop.PageComShopStoreDTO; |
| | | import com.panzhihua.common.model.dtos.shop.PageComShopSysConfDTO; |
| | | import com.panzhihua.common.model.dtos.shop.WxPayNotifyOrderDTO; |
| | | import com.panzhihua.common.model.dtos.user.PageInputUserDTO; |
| | | import com.panzhihua.common.model.dtos.vaccines.VaccinesByAdminDTO; |
| | | import com.panzhihua.common.model.dtos.vaccines.VaccinesEnrollByAdminDTO; |
| | |
| | | R detailEasyPhoto(@RequestParam("id") Long id, @RequestParam("userId") Long userId); |
| | | |
| | | /** |
| | | * 随手拍详情 |
| | | * |
| | | * @param id |
| | | * 随手拍主键 |
| | | * @param userId |
| | | * 登录用户id |
| | | * @return 详情内容 |
| | | */ |
| | | @PostMapping("detaileasyphotodesensitize") |
| | | R detailEasyPhotoDesensitize(@RequestParam("id") Long id, @RequestParam("userId") Long userId); |
| | | |
| | | |
| | | /** |
| | | * 随手拍删除 |
| | | * |
| | | * @param id |
| | |
| | | */ |
| | | @PostMapping("pagemicrowish/applets") |
| | | R pageMicroWishApplets(@RequestBody ComActMicroWishVO comActMicroWishVO); |
| | | /** |
| | | * 小程序分页查询微心愿 |
| | | * |
| | | * @param comActMicroWishVO |
| | | * 查询参数 |
| | | * @return 分页集合 |
| | | */ |
| | | @PostMapping("pagemicrowish/appletsDesensitize") |
| | | R pageMicroWishAppletsDesensitize(@RequestBody ComActMicroWishVO comActMicroWishVO); |
| | | |
| | | /** |
| | | * 心愿详情 |
| | |
| | | */ |
| | | @PostMapping("detailmicrowish") |
| | | R detailMicroWish(@RequestParam("id") Long id, @RequestParam("userId") Long userId); |
| | | /** |
| | | * 心愿详情 |
| | | * |
| | | * @param id |
| | | * 查询主键 |
| | | * @param userId |
| | | * 登录用户id |
| | | * @return 心愿内容 |
| | | */ |
| | | @PostMapping("detailmicrowishdesensitize") |
| | | R detailMicroWishDesensitize(@RequestParam("id") Long id, @RequestParam("userId") Long userId); |
| | | |
| | | /** |
| | | * 审核、分配、反馈心愿 |
| | |
| | | R pageEasyPhotoApplets(@RequestBody ComActEasyPhotoVO comActEasyPhotoVO); |
| | | |
| | | /** |
| | | * 小程序分页查询随手拍 |
| | | * |
| | | * @param comActEasyPhotoVO |
| | | * 查询参数 |
| | | * @return 返回结果 |
| | | */ |
| | | @PostMapping("pageeasyphotoappletsdesensitize") |
| | | R pageEasyPhotoAppletsDesensitize(@RequestBody ComActEasyPhotoVO comActEasyPhotoVO); |
| | | |
| | | |
| | | /** |
| | | * 随手拍评论分页查询 |
| | | * |
| | | * @param pageComActEasyPhotoCommentDTO |
| | |
| | | */ |
| | | @PostMapping("pagecomacteasyphotocomment") |
| | | R pageComActEasyPhotoComment(@RequestBody PageComActEasyPhotoCommentDTO pageComActEasyPhotoCommentDTO); |
| | | |
| | | /** |
| | | * 随手拍评论分页查询 - 脱敏 |
| | | * |
| | | * @param pageComActEasyPhotoCommentDTO |
| | | * 查询参数 |
| | | * @return 查询结果 |
| | | */ |
| | | @PostMapping("pagecomacteasyphotocommentdesensitize") |
| | | R pageComActEasyPhotoCommentDesensitize(@RequestBody PageComActEasyPhotoCommentDTO pageComActEasyPhotoCommentDTO); |
| | | |
| | | /** |
| | | * 评论点赞/取消点赞 |
| | |
| | | */ |
| | | @PostMapping("pagediscussapplets") |
| | | R pageDiscussApplets(@RequestBody PageComActDiscussDTO pageComActDiscussDTO); |
| | | /** |
| | | * 议事投票-分页查询 小程序 -脱敏 |
| | | * |
| | | * @param pageComActDiscussDTO |
| | | * 查询参数 |
| | | * @return ComActDiscussVO 分页 |
| | | */ |
| | | @PostMapping("pagediscussappletsdesensitize") |
| | | R pageDiscussAppletsDesensitize(@RequestBody PageComActDiscussDTO pageComActDiscussDTO); |
| | | |
| | | /** |
| | | * 议事投票-点赞、取消点赞 |
| | |
| | | R pageDiscussCommentApplets(@RequestBody PageComActDiscussCommentDTO pageComActDiscussCommentDTO); |
| | | |
| | | /** |
| | | * 议事投票-评论-分页查询 小程序 脱敏 |
| | | * |
| | | * @param pageComActDiscussCommentDTO |
| | | * 分页参数 |
| | | * @return ComActDiscussCommentVO |
| | | */ |
| | | @PostMapping("pagediscusscommentappletsdesensitize") |
| | | R pageDiscussCommentAppletsDesensitize(@RequestBody PageComActDiscussCommentDTO pageComActDiscussCommentDTO); |
| | | |
| | | /** |
| | | * 议事投票-详情 小程序 |
| | | * |
| | | * @param id |
| | |
| | | */ |
| | | @PostMapping("detaildiscussapplets") |
| | | R detailDiscussApplets(@RequestParam("id") Long id, @RequestParam("userId") Long userId); |
| | | /** |
| | | * 议事投票-详情 小程序 |
| | | * |
| | | * @param id |
| | | * 主键 |
| | | * @param userId |
| | | * 登录用户主键 |
| | | * @return ComActDiscussVO |
| | | */ |
| | | @PostMapping("detaildiscussappletsdesensitize") |
| | | R detailDiscussAppletsDesensitize(@RequestParam("id") Long id, @RequestParam("userId") Long userId); |
| | | |
| | | /** |
| | | * 议事投票-投票 |
| | |
| | | */ |
| | | @GetMapping("/shop/changeShopGoodsStatus") |
| | | R changeStatus(@RequestParam("id") Long id, @RequestParam("status") Integer status); |
| | | |
| | | /** |
| | | * 商品列表-分页查询 |
| | | * |
| | | * @param pageComShopGoodsDTO |
| | | * 添加数据 |
| | | */ |
| | | @PostMapping("/shopFlower/pageGoods") |
| | | R pageFlowerGoodsList(@RequestBody PageComShopFlowerGoodsDTO pageComShopGoodsDTO); |
| | | |
| | | /** |
| | | * 商品列表-分页查询 |
| | | * |
| | | * @param comShopFlowerGoodsDTO |
| | | * 添加数据 |
| | | */ |
| | | @PostMapping("/shopFlower/pageShopFlowerGoodsByApp") |
| | | R pageShopFlowerGoodsByApp(@RequestBody ComShopFlowerGoodsDTO comShopFlowerGoodsDTO); |
| | | |
| | | |
| | | /** |
| | | * 新增商品 |
| | | * |
| | | * @param addShopGoodsVO |
| | | * @return |
| | | */ |
| | | @PostMapping("/shopFlower/saveShopGoods") |
| | | R saveFlowerShopGoods(@RequestBody AddShopFlowerGoodsVO addShopGoodsVO); |
| | | |
| | | /** |
| | | * 编辑商品 |
| | | * |
| | | * @param id |
| | | * @param addShopGoodsVO |
| | | * @return |
| | | */ |
| | | @PostMapping("/shopFlower/editShopGoods/{id}") |
| | | R editFlowerShopGoods(@PathVariable("id") Long id, @RequestBody AddShopFlowerGoodsVO addShopGoodsVO); |
| | | |
| | | /** |
| | | * 删除商品 |
| | | * |
| | | * @param id |
| | | * @return |
| | | */ |
| | | @PostMapping("/shopFlower/deleteShopGoods") |
| | | R deleteFlowerShopGoods(@RequestBody Long[] id); |
| | | |
| | | /** |
| | | * 修改商品状态 |
| | | * |
| | | * @param id |
| | | * @return |
| | | */ |
| | | @GetMapping("/shopFlower/changeShopGoodsStatus") |
| | | R changeFlowerStatus(@RequestParam("id") Long id, @RequestParam("status") Integer status); |
| | | |
| | | |
| | | /** |
| | | * 结果 |
| | |
| | | */ |
| | | @GetMapping("selectAutomessageSysUserById") |
| | | R selectAutomessageSysUserById(@RequestParam("id") Long id); |
| | | |
| | | /** |
| | | * 分页查询议事委员会列表 |
| | | * */ |
| | | @GetMapping("/proceedings/list") |
| | | R proceedingsList(@RequestParam(value = "page",required = false) Integer page, |
| | | @RequestParam(value = "size",required = false) Integer size, |
| | | @RequestParam(value = "keyWord",required = false) String keyWord); |
| | | /** |
| | | * 添加或修改议事委员会 |
| | | * */ |
| | | @PostMapping("/proceedings") |
| | | R addOrUpdateProceedings(@RequestBody ComActProceedingsDTO comActProceedingsDTO); |
| | | |
| | | /** |
| | | * 自提点分页查询 |
| | | * @param pageConvenientElevatingPointDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/convenient/point/page") |
| | | R pagePoint(PageConvenientElevatingPointDTO pageConvenientElevatingPointDTO); |
| | | |
| | | /** |
| | | * 新增自提点 |
| | | * @param convenientElevatingPointDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/convenient/point/add") |
| | | R addPoint(ConvenientElevatingPointDTO convenientElevatingPointDTO); |
| | | |
| | | /** |
| | | * 编辑自提点 |
| | | * @param convenientElevatingPointDTO |
| | | * @return |
| | | */ |
| | | @PutMapping("/convenient/point/put") |
| | | R putPoint(ConvenientElevatingPointDTO convenientElevatingPointDTO); |
| | | |
| | | /** |
| | | * 删除便民服务 自提点 |
| | | * @param pointId |
| | | * @param operator |
| | | * @return |
| | | */ |
| | | @DeleteMapping("/point/delete") |
| | | R deletePoint(@RequestParam("pointId") Long pointId, @RequestParam("operator") Long operator); |
| | | |
| | | /** |
| | | * 便民服务详情 自提点 |
| | | * @param pointId |
| | | * @return |
| | | */ |
| | | @GetMapping("/point/detail") |
| | | R detailPoint(@RequestParam("pointId") Long pointId); |
| | | |
| | | /** |
| | | * 新增商品分类 |
| | | * @param convenientGoodsCategoryDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/goodsCategory/add") |
| | | R addGoodsCategory(@RequestBody ConvenientGoodsCategoryDTO convenientGoodsCategoryDTO); |
| | | |
| | | /** |
| | | * 编辑 |
| | | * @param convenientGoodsCategoryDTO |
| | | * @return |
| | | */ |
| | | @PutMapping("/goodsCategory/put") |
| | | R putGoodsCategory(@RequestBody ConvenientGoodsCategoryDTO convenientGoodsCategoryDTO); |
| | | |
| | | /** |
| | | * 删除商品分类 |
| | | * @param categoryId |
| | | * @return |
| | | */ |
| | | @DeleteMapping("/goodsCategory/delete") |
| | | R deleteGoodsCategory(@RequestParam("categoryId") Long categoryId, @RequestParam("operator") Long operator); |
| | | |
| | | /** |
| | | * 获取商品分类详情 |
| | | * @param categoryId |
| | | * @return |
| | | */ |
| | | @GetMapping("/goodsCategory/get") |
| | | R getGoodsCategory(@RequestParam("categoryId") Long categoryId); |
| | | |
| | | /** |
| | | * 分页查询商品分类 |
| | | * @param pageConvenientGoodsCategoryDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/goodsCategory/page") |
| | | R pageGoodsCategory(@RequestBody PageConvenientGoodsCategoryDTO pageConvenientGoodsCategoryDTO); |
| | | |
| | | @GetMapping("/dataCount") |
| | | R dataCount(); |
| | | |
| | | @DeleteMapping("/proceedings/remove") |
| | | R removeProceedings(@RequestParam("id") Long id); |
| | | |
| | | /** |
| | | * 获取物业公司通知公告列表 |
| | | * */ |
| | | @GetMapping("comProperty/noticeList") |
| | | R noticeList(@RequestParam("page")Integer page,@RequestParam("size")Integer size,@RequestParam("propertyId")Long propertyId); |
| | | |
| | | /** |
| | | * 获取社区动态置顶banner |
| | | * @param communityId 社区id |
| | | * */ |
| | | @PostMapping("/easyphoto/getUserRewardsNew") |
| | | R getUserRewardsNew(@RequestParam("userId") Long userId, @RequestParam("communityId") Long communityId); |
| | | } |
| | |
| | | R comPropertyRepairSelectAll(@RequestBody CommonPage commonPage); |
| | | |
| | | /** |
| | | * 分页查询所有数据 脱敏 |
| | | * @return 所有数据 |
| | | */ |
| | | @PostMapping("/comPropertyRepair/queryAllDesensitize") |
| | | R comPropertyRepairSelectAllDesensitize(@RequestBody CommonPage commonPage); |
| | | |
| | | /** |
| | | * 通过主键查询单条数据 |
| | | * |
| | | * @param id 主键 |
| | |
| | | R comPropertyRepairSelectOne(@PathVariable("id") Long id); |
| | | |
| | | /** |
| | | * 通过主键查询单条数据 脱敏 |
| | | * |
| | | * @param id 主键 |
| | | * @return 单条数据 |
| | | */ |
| | | @GetMapping("/comPropertyRepair/desensitize/{id}") |
| | | R comPropertyRepairSelectOneDesensitize(@PathVariable("id") Long id); |
| | | |
| | | /** |
| | | * 新增数据 |
| | | * |
| | | * @param comPropertyRepair 实体对象 |
| | |
| | | R addComPbCheckUser(@RequestBody ComPbCheckUserDTO comPbCheckUserDTO); |
| | | |
| | | |
| | | |
| | | /** |
| | | * 是否为专家登陆小程序 |
| | | * */ |
| | |
| | | * */ |
| | | @GetMapping("/removeExpertRole") |
| | | R removeExpertRole(@RequestParam(value = "phone",required = false) String phone); |
| | | |
| | | /** |
| | | *回复反馈意见或修改返回意见的回复 |
| | | * */ |
| | | @PostMapping("/feedBackReply") |
| | | R updateFeedBack(@RequestBody SysUserFeedbackVO sysUserFeedbackVO); |
| | | |
| | | @GetMapping("/myFeedBack") |
| | | R myFeedBack(@RequestParam("userId") Long userId,@RequestParam(value = "type",required = false)Integer type); |
| | | |
| | | /** |
| | | * 获取所有社区等 |
| | | * @return |
| | | */ |
| | | @GetMapping("/getAllCommunityList") |
| | | R getAllCommunityList(); |
| | | |
| | | @GetMapping("/propertyCheck") |
| | | R propertyCheck(@RequestParam("phone") String phone); |
| | | |
| | | } |
| | |
| | | import java.math.BigDecimal; |
| | | import java.util.*; |
| | | |
| | | import cn.hutool.core.util.StrUtil; |
| | | import com.alibaba.fastjson.JSON; |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.panzhihua.common.constants.WxSubscribeConstants; |
| | |
| | | subscribeDTO.setTemplate_id(templateId); |
| | | subscribeDTO.setPage("packageD/pages/washer/order/index"); |
| | | List<TemplateParam> paras=new ArrayList<TemplateParam>(); |
| | | paras.add(new TemplateParam("thing9", washerName)); |
| | | paras.add(new TemplateParam("phone_number10",washerMobile)); |
| | | paras.add(new TemplateParam("thing9", StrUtil.isBlank(washerName) ? "无":washerName)); |
| | | paras.add(new TemplateParam("phone_number10",StrUtil.isBlank(washerMobile) ? "0":washerMobile)); |
| | | subscribeDTO.setTemplateParamList(paras); |
| | | try { |
| | | sendSubscribe(accessToken,subscribeDTO); |
| | |
| | | subscribeDTO.setTemplate_id(templateId); |
| | | subscribeDTO.setPage("pages/washer/order/index"); |
| | | List<TemplateParam> paras=new ArrayList<TemplateParam>(); |
| | | paras.add(new TemplateParam("thing9", washerName)); |
| | | paras.add(new TemplateParam("phone_number10",washerMobile)); |
| | | paras.add(new TemplateParam("thing9", StrUtil.isBlank(washerName) ? "无":washerName)); |
| | | paras.add(new TemplateParam("phone_number10",StrUtil.isBlank(washerMobile) ? "0" :washerMobile)); |
| | | subscribeDTO.setTemplateParamList(paras); |
| | | try { |
| | | sendSubscribe(accessToken,subscribeDTO); |
| | |
| | | subscribeDTO.setPage("packageD/pages/washer/order/index"); |
| | | List<TemplateParam> paras=new ArrayList<TemplateParam>(); |
| | | paras.add(new TemplateParam("thing4", status)); |
| | | paras.add(new TemplateParam("thing3", washerName)); |
| | | paras.add(new TemplateParam("thing6",washerMobile)); |
| | | paras.add(new TemplateParam("thing3", StrUtil.isBlank(washerName) ? "无":washerName)); |
| | | paras.add(new TemplateParam("thing6",StrUtil.isBlank(washerMobile) ? "无":washerMobile)); |
| | | subscribeDTO.setTemplateParamList(paras); |
| | | try { |
| | | sendSubscribe(accessToken,subscribeDTO); |
| | |
| | | subscribeDTO.setPage("pages/washer/order/index"); |
| | | List<TemplateParam> paras=new ArrayList<TemplateParam>(); |
| | | paras.add(new TemplateParam("thing4", status)); |
| | | paras.add(new TemplateParam("thing3", washerName)); |
| | | paras.add(new TemplateParam("thing6",washerMobile)); |
| | | paras.add(new TemplateParam("thing3", StrUtil.isBlank(washerName) ? "无":washerName)); |
| | | paras.add(new TemplateParam("thing6",StrUtil.isBlank(washerMobile) ? "无":washerMobile)); |
| | | subscribeDTO.setTemplateParamList(paras); |
| | | try { |
| | | sendSubscribe(accessToken,subscribeDTO); |
| | |
| | | subscribeDTO.setPage("packageD/pages/washer/order/index"); |
| | | List<TemplateParam> paras=new ArrayList<TemplateParam>(); |
| | | paras.add(new TemplateParam("phrase14", status)); |
| | | paras.add(new TemplateParam("name3", washerName)); |
| | | paras.add(new TemplateParam("thing5",washerMobile)); |
| | | paras.add(new TemplateParam("name3", StrUtil.isBlank(washerName) ? "无":washerName)); |
| | | paras.add(new TemplateParam("thing5",StrUtil.isBlank(washerMobile) ? "无":washerMobile)); |
| | | subscribeDTO.setTemplateParamList(paras); |
| | | try { |
| | | sendSubscribe(accessToken,subscribeDTO); |
| | |
| | | subscribeDTO.setPage("pages/washer/order/index"); |
| | | List<TemplateParam> paras=new ArrayList<TemplateParam>(); |
| | | paras.add(new TemplateParam("phrase14", status)); |
| | | paras.add(new TemplateParam("name3", washerName)); |
| | | paras.add(new TemplateParam("thing5",washerMobile)); |
| | | paras.add(new TemplateParam("name3", StrUtil.isBlank(washerName) ? "无":washerName)); |
| | | paras.add(new TemplateParam("thing5",StrUtil.isBlank(washerMobile) ? "无":washerMobile)); |
| | | subscribeDTO.setTemplateParamList(paras); |
| | | try { |
| | | sendSubscribe(accessToken,subscribeDTO); |
| | |
| | | package com.panzhihua.common.utlis; |
| | | |
| | | import java.io.*; |
| | | import java.net.HttpURLConnection; |
| | | import java.net.URL; |
| | | import java.nio.charset.StandardCharsets; |
| | | import java.util.Map; |
| | | import java.util.concurrent.TimeUnit; |
| | | |
| | | import cn.hutool.core.util.StrUtil; |
| | | import com.alibaba.fastjson.JSON; |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.panzhihua.common.constants.SecurityConstants; |
| | | import com.panzhihua.common.controller.BaseController; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.user.SysAppConfigVO; |
| | | import com.panzhihua.common.redis.RedisUtils; |
| | | import com.panzhihua.common.service.user.UserService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.apache.commons.fileupload.FileItem; |
| | | import org.apache.commons.fileupload.FileItemFactory; |
| | | import org.apache.commons.fileupload.disk.DiskFileItemFactory; |
| | | import org.apache.http.entity.ContentType; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.data.redis.core.RedisTemplate; |
| | | import org.springframework.data.redis.core.StringRedisTemplate; |
| | | import org.springframework.data.redis.core.ValueOperations; |
| | |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | import org.springframework.web.multipart.commons.CommonsMultipartFile; |
| | | |
| | | import com.alibaba.fastjson.JSON; |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.panzhihua.common.constants.SecurityConstants; |
| | | |
| | | import lombok.extern.slf4j.Slf4j; |
| | | |
| | | import javax.annotation.PostConstruct; |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletRequest; |
| | | import java.io.*; |
| | | import java.net.HttpURLConnection; |
| | | import java.net.URL; |
| | | import java.nio.charset.StandardCharsets; |
| | | import java.text.MessageFormat; |
| | | import java.text.SimpleDateFormat; |
| | | import java.util.Date; |
| | | import java.util.Map; |
| | | import java.util.concurrent.TimeUnit; |
| | | |
| | | @Slf4j |
| | | @Component |
| | |
| | | private RedisUtils redisUtils; |
| | | |
| | | private static WxXCXTempSend wxXCXTempSend; |
| | | |
| | | /** |
| | | * url转变为 MultipartFile对象 |
| | | * |
| | |
| | | private static MultipartFile createFileItem(String url, String fileName) throws Exception { |
| | | FileItem item = null; |
| | | try { |
| | | HttpURLConnection conn = (HttpURLConnection)new URL(url).openConnection(); |
| | | HttpURLConnection conn = (HttpURLConnection) new URL(url).openConnection(); |
| | | conn.setReadTimeout(30000); |
| | | conn.setConnectTimeout(30000); |
| | | // 设置应用程序要从网络连接读取数据 |
| | |
| | | FileItemFactory factory = new DiskFileItemFactory(16, null); |
| | | String textFieldName = "uploadfile"; |
| | | item = |
| | | factory.createItem(textFieldName, ContentType.APPLICATION_OCTET_STREAM.toString(), false, fileName); |
| | | factory.createItem(textFieldName, ContentType.APPLICATION_OCTET_STREAM.toString(), false, fileName); |
| | | OutputStream os = item.getOutputStream(); |
| | | |
| | | int bytesRead = 0; |
| | |
| | | * @return |
| | | */ |
| | | public String getAccessToken() throws Exception { |
| | | String accessToken = ""; |
| | | String accessToken = ""; |
| | | String appId = this.getAppId(); |
| | | accessToken=wxXCXTempSend.stringRedisTemplate.boundValueOps("access_token:access_token:"+ appId).get(); |
| | | if (appId.equals(APP_ID)){ |
| | | accessToken = validAccessToken(accessToken, appId,APP_SECRET); |
| | | } |
| | | |
| | | accessToken = wxXCXTempSend.stringRedisTemplate.boundValueOps("access_token:access_token:" + appId).get(); |
| | | return accessToken; |
| | | } |
| | | |
| | | |
| | | public String getAccessToken(String appId) throws Exception { |
| | | String accessToken = ""; |
| | | accessToken=wxXCXTempSend.stringRedisTemplate.boundValueOps("access_token:access_token:"+appId).get(); |
| | | if (appId.equals(APP_ID)){ |
| | | accessToken = validAccessToken(accessToken, appId,APP_SECRET); |
| | | } |
| | | accessToken = wxXCXTempSend.stringRedisTemplate.boundValueOps("access_token:access_token:" + appId).get(); |
| | | return accessToken; |
| | | } |
| | | |
| | | private String validAccessToken(String accessToken, String appId,String appSecret) throws Exception { |
| | | private String validAccessToken(String accessToken, String appId, String appSecret) throws Exception { |
| | | if (StrUtil.isEmpty(accessToken)) { |
| | | //重新获取并设置到缓存 该方法暂时只用在花城 |
| | | accessToken = getAppAccessToken(appId, appSecret); |
| | | wxXCXTempSend.stringRedisTemplate.opsForValue().set("access_token:access_token:" + appId, accessToken, EXPIRE_TIME,TimeUnit.HOURS); |
| | | wxXCXTempSend.stringRedisTemplate.opsForValue().set("access_token:access_token:" + appId, accessToken, EXPIRE_TIME, TimeUnit.HOURS); |
| | | } else { |
| | | String accessTokenUrl = WX_CALL_BACK + accessToken; |
| | | String result = HttpClientUtil.httpGet(accessTokenUrl, null, null); |
| | |
| | | //如果Access_token过期也重新获取 |
| | | if (resultMap.containsKey("errcode")) { |
| | | accessToken = getAppAccessToken(appId, appSecret); |
| | | wxXCXTempSend.stringRedisTemplate.opsForValue().set("access_token:access_token:" + appId, accessToken, EXPIRE_TIME,TimeUnit.HOURS); |
| | | wxXCXTempSend.stringRedisTemplate.opsForValue().set("access_token:access_token:" + appId, accessToken, EXPIRE_TIME, TimeUnit.HOURS); |
| | | } |
| | | } |
| | | return accessToken; |
| | | } |
| | | |
| | | public String getAppAccessToken(String appId,String appSecret) throws Exception { |
| | | public String getAppAccessToken(String appId, String appSecret) throws Exception { |
| | | String accessToken = "0"; |
| | | try { |
| | | log.info("获取微信token参数:appid=" + appId + ",appSecret=" + appSecret); |
| | | String accessTokenUrl = ACCESS_TOKEN_URL + "&appid=" + appId + "&secret=" + appSecret; |
| | | String result = HttpClientUtil.httpGet(accessTokenUrl, null, null); |
| | | Map<String, Object> resultMap = JSON.parseObject(result, Map.class); |
| | | StringRedisTemplate redisTemplate = wxXCXTempSend.stringRedisTemplate; |
| | | if (resultMap.containsKey("access_token")) { |
| | | accessToken = resultMap.get("access_token").toString(); |
| | | redisTemplate.opsForValue().set("access_token:access_token:" + appId, accessToken); |
| | | } |
| | | HttpServletRequest request = ServletUtils.getRequest(); |
| | | String requestURI = request.getRequestURI(); |
| | | //加上时间戳 |
| | | String datetime = new SimpleDateFormat("yyyyMMdd").format(new Date()); |
| | | //这里是 Redis key的前缀,如: sys:tabieId:表名 如果不需要去掉表名也可以 |
| | | String key = MessageFormat.format("{0}:{1}:{2}", "access_token_request_incr",datetime,requestURI); |
| | | //查询 key 是否存在, 不存在返回 1 ,存在的话则自增加1 |
| | | redisTemplate.opsForValue().increment(key, 1); |
| | | |
| | | } catch (IOException ioe) { |
| | | log.error("小程序http请求异常"); |
| | | ioe.printStackTrace(); |
| | |
| | | return accessToken; |
| | | } |
| | | |
| | | /** |
| | | * 发布消息时重新设置access_token 防止过期 |
| | | * @param appId |
| | | * @param appSecret |
| | | * @throws Exception |
| | | */ |
| | | public void setAppAccessTokenToCache(String appId,String appSecret) throws Exception{ |
| | | String accessToken = "0"; |
| | | try { |
| | | log.info("获取微信token参数:appid=" + appId + ",appSecret=" + appSecret); |
| | | String accessTokenUrl = ACCESS_TOKEN_URL + "&appid=" + appId + "&secret=" + appSecret; |
| | | String result = HttpClientUtil.httpGet(accessTokenUrl, null, null); |
| | | Map<String, Object> resultMap = JSON.parseObject(result, Map.class); |
| | | if (resultMap.containsKey("access_token")) { |
| | | accessToken = resultMap.get("access_token").toString(); |
| | | wxXCXTempSend.stringRedisTemplate.opsForValue().set("access_token:access_token:" + appId, accessToken, EXPIRE_TIME,TimeUnit.HOURS); |
| | | } |
| | | } catch (IOException ioe) { |
| | | log.error("小程序http请求异常"); |
| | | ioe.printStackTrace(); |
| | | } |
| | | } |
| | | |
| | | public String getAccessTokenValid(String appId,Integer index) throws Exception { |
| | | if (index % 100 == 0){ |
| | | return getAccessToken(appId); |
| | | }else { |
| | | return wxXCXTempSend.stringRedisTemplate.boundValueOps("access_token:access_token:"+appId).get(); |
| | | } |
| | | |
| | | } |
| | | public String getWsAccessToken() throws Exception { |
| | | String accessToken = "0"; |
| | | try { |
| | | // log.info("获取微信token参数:appid=" + APP_ID + ",appSecret=" + APP_SECRET); |
| | | String accessTokenUrl = ACCESS_TOKEN_URL + "&appid=wx98d62711dfbd8425"+ "&secret=97a2a10b990c2774ed279724337b5337"; |
| | | String accessTokenUrl = ACCESS_TOKEN_URL + "&appid=wx98d62711dfbd8425" + "&secret=97a2a10b990c2774ed279724337b5337"; |
| | | String result = HttpClientUtil.httpGet(accessTokenUrl, null, null); |
| | | Map<String, Object> resultMap = JSON.parseObject(result, Map.class); |
| | | if (resultMap.containsKey("access_token")) { |
| | |
| | | } |
| | | return accessToken; |
| | | } |
| | | |
| | | /** |
| | | * 获取西区社区通微信token |
| | | * @return 西区社区通微信token |
| | | * |
| | | * @return 西区社区通微信token |
| | | * @throws Exception 异常 |
| | | */ |
| | | public String getXQAppAccessToken() throws Exception { |
| | |
| | | mediaId = getAppMediaId(accessToken); |
| | | valueOperations.set(SecurityConstants.APPLETS_ACCESS_MEDIA_ID, mediaId); |
| | | valueOperations.set(SecurityConstants.APPLETS_ACCESS_MEDIA_ID_TIME, |
| | | System.currentTimeMillis() + 259000000 + ""); |
| | | System.currentTimeMillis() + 259000000 + ""); |
| | | } else { |
| | | mediaId = valueOperations.get(SecurityConstants.APPLETS_ACCESS_MEDIA_ID); |
| | | } |
| | |
| | | mediaId = getAppMediaId(accessToken); |
| | | valueOperations.set(SecurityConstants.APPLETS_ACCESS_MEDIA_ID, mediaId); |
| | | valueOperations.set(SecurityConstants.APPLETS_ACCESS_MEDIA_ID_TIME, |
| | | System.currentTimeMillis() + 259000000 + ""); |
| | | System.currentTimeMillis() + 259000000 + ""); |
| | | } |
| | | return mediaId; |
| | | } |
| | |
| | | * |
| | | * @param file |
| | | * @return |
| | | * @author yixiu |
| | | * @throws Exception |
| | | * @author yixiu |
| | | */ |
| | | public String uploadFile(MultipartFile file, String access_token) throws Exception { |
| | | String url = "https://api.weixin.qq.com/cgi-bin/media/upload?access_token=" + access_token + "&type=image"; |
| | | String result = null; |
| | | String fileName = file.getOriginalFilename(); |
| | | URL urlObj = new URL(url); |
| | | HttpURLConnection con = (HttpURLConnection)urlObj.openConnection(); |
| | | HttpURLConnection con = (HttpURLConnection) urlObj.openConnection(); |
| | | con.setRequestMethod("POST"); |
| | | con.setDoInput(true); |
| | | con.setDoOutput(true); |
| | |
| | | public void init() { |
| | | wxXCXTempSend = this; |
| | | wxXCXTempSend.redisTemplate = this.redisTemplate; |
| | | wxXCXTempSend.stringRedisTemplate=this.stringRedisTemplate; |
| | | wxXCXTempSend.redisUtils=this.redisUtils; |
| | | wxXCXTempSend.stringRedisTemplate = this.stringRedisTemplate; |
| | | wxXCXTempSend.redisUtils = this.redisUtils; |
| | | |
| | | } |
| | | |
| | |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenHatchStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.EquipmentPointMapDataVO; |
| | | import com.panzhihua.common.model.vos.community.social.SocialProjectVO; |
| | | import com.panzhihua.common.model.vos.partybuilding.PartyBuildingComPbDynVO; |
| | | import com.panzhihua.common.service.partybuilding.PartyBuildingWestService; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | | import org.springframework.web.bind.annotation.RequestBody; |
| | |
| | | import com.panzhihua.common.model.vos.community.switchs.StreetAllAppletsVO; |
| | | import com.panzhihua.common.model.vos.neighbor.ComActNeighborCircleAdminVO; |
| | | import com.panzhihua.common.model.vos.partybuilding.PartyBuildingActivityVO; |
| | | import com.panzhihua.common.model.vos.partybuilding.PartyBuildingComPbDynVO; |
| | | import com.panzhihua.common.model.vos.property.ComPropertyAlarmVO; |
| | | import com.panzhihua.common.model.vos.screen.ScreenDrawEventPopulationTotalVO; |
| | | import com.panzhihua.common.model.vos.screen.ScreenDrawEventVO; |
| | |
| | | private UserService userService; |
| | | @Resource |
| | | private PartyBuildingService partyBuildingService; |
| | | @Resource |
| | | private PartyBuildingWestService partyBuildingWestService; |
| | | |
| | | @ApiOperation(value = "大屏测试接口") |
| | | @GetMapping("/test/noToken") |
| | |
| | | @PostMapping("/comprehensive/partydyn") |
| | | public R<BigScreenStatisticPartyOrg> partydyn(@RequestBody PartyBuildingComPbDynVO partyBuildingComPbDynVO) { |
| | | partyBuildingComPbDynVO.setType(1); |
| | | return partyBuildingService.pageYnamic(partyBuildingComPbDynVO); |
| | | partyBuildingComPbDynVO.setAppId(this.getAppId()); |
| | | return partyBuildingWestService.pageYnamic(partyBuildingComPbDynVO); |
| | | } |
| | | /** |
| | | * 首页二级页面-便民商家 |
New file |
| | |
| | | package com.panzhihua.community_backstage.api; |
| | | |
| | | import com.panzhihua.common.controller.BaseController; |
| | | import com.panzhihua.common.model.dtos.user.PageFeedBackDTO; |
| | | import com.panzhihua.common.model.dtos.user.SysUserFeedbackDTO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.user.SysUserFeedbackVO; |
| | | import com.panzhihua.common.service.user.UserService; |
| | | import com.panzhihua.common.validated.PageGroup; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | @RestController |
| | | @RequestMapping("/feedBack") |
| | | @Api(tags = "问题留言和投诉建议") |
| | | public class ComActFeedBackApi extends BaseController { |
| | | @Resource |
| | | private UserService userService; |
| | | |
| | | @ApiOperation(value = "分页查询用户意见反馈", response = SysUserFeedbackVO.class) |
| | | @PostMapping("pagefeedback") |
| | | public R pageFeedback(@RequestBody @Validated(PageGroup.class) PageFeedBackDTO pageFeedBackDTO) { |
| | | pageFeedBackDTO.setAreaCode(this.getAreaCode()); |
| | | return userService.pageFeedback(pageFeedBackDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "反馈意见详情", response = SysUserFeedbackVO.class) |
| | | @GetMapping("feedback") |
| | | public R detailFeedback(@RequestParam("id") Long id) { |
| | | return userService.detailFeedback(id); |
| | | } |
| | | |
| | | @ApiOperation(value = "删除意见反馈") |
| | | @DeleteMapping("feedback") |
| | | public R deleteFeedback(@RequestParam("id") Long id) { |
| | | return userService.deleteFeedback(id); |
| | | } |
| | | |
| | | @ApiOperation("回复意见反馈或修改意见反馈回复") |
| | | @PostMapping("feedback") |
| | | public R replyFeedBack(@RequestBody SysUserFeedbackVO sysUserFeedbackVO){ |
| | | return userService.updateFeedBack(sysUserFeedbackVO); |
| | | } |
| | | } |
New file |
| | |
| | | package com.panzhihua.community_backstage.api; |
| | | |
| | | import com.panzhihua.common.model.dtos.community.ComActProceedingsDTO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.community.ComActProceedingsVO; |
| | | import com.panzhihua.common.service.community.CommunityService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | @RestController |
| | | @RequestMapping("/proceedings") |
| | | @Api(tags = {"议事委员会"}) |
| | | public class ComActPorceedingsApi { |
| | | |
| | | @Resource |
| | | private CommunityService communityService; |
| | | |
| | | @ApiOperation(value = "分页查询议事委员会列表",response = ComActProceedingsVO.class) |
| | | @GetMapping |
| | | public R list(@RequestParam(value = "page",required = false) Integer page, |
| | | @RequestParam(value = "size",required = false) Integer size, |
| | | @RequestParam(value = "keyWord",required = false) String keyWord){ |
| | | return communityService.proceedingsList(page, size, keyWord); |
| | | } |
| | | |
| | | @ApiOperation("新增或修改议事委员会") |
| | | @PostMapping |
| | | public R addOrUpdate(@RequestBody ComActProceedingsDTO comActProceedingsDTO){ |
| | | return communityService.addOrUpdateProceedings(comActProceedingsDTO); |
| | | } |
| | | |
| | | @DeleteMapping("/{id}") |
| | | @ApiOperation("删除议事委员会") |
| | | public R remove(@PathVariable Long id){ |
| | | return communityService.removeProceedings(id); |
| | | } |
| | | |
| | | } |
| | |
| | | package com.panzhihua.community_backstage.api; |
| | | |
| | | import com.panzhihua.common.controller.BaseController; |
| | | import com.panzhihua.common.model.dtos.community.ComActProceedingsDTO; |
| | | import com.panzhihua.common.model.dtos.property.CommonPage; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.community.ComActCommiteeVO; |
| | | import com.panzhihua.common.model.vos.community.ComActProceedingsVO; |
| | | import com.panzhihua.common.model.vos.community.ComPropertyVO; |
| | | import com.panzhihua.common.service.community.CommunityService; |
| | | import io.swagger.annotations.Api; |
| | |
| | | * @param commonPage 查询实体 |
| | | * @return 所有数据 |
| | | */ |
| | | @ApiOperation(value = "物业公司列表",response = ComPropertyVO.class) |
| | | @ApiOperation(value = "物业公司列表", response = ComPropertyVO.class) |
| | | @PostMapping("queryAll") |
| | | public R selectAll(@RequestBody CommonPage commonPage) { |
| | | commonPage.setParamId(this.getCommunityId()); |
| | | return this.communityService.comPropertySelectAll(commonPage); |
| | | } |
| | | |
| | | /** |
| | | * 新增数据 |
| | | * |
| | |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import io.swagger.annotations.ApiOperation; |
| | | |
| | | import static java.util.Objects.nonNull; |
| | | |
| | | /** |
| | | * 物业公司工作人员(ComPropertyWorker)表控制层 |
| | | * |
| | |
| | | @ApiOperation(value = "分页查询物业工作人员", response = ComPropertyWorkerVO.class) |
| | | @PostMapping("/page") |
| | | public R pagePropertyWorker(@RequestBody @Valid PagePropertyWorkerDTO pagePropertyWorkerDTO) { |
| | | if(nonNull(getLoginUserInfo().getPropertyId())){ |
| | | pagePropertyWorkerDTO.setRefId(getLoginUserInfo().getPropertyId()); |
| | | } |
| | | return communityService.pagePropertyWorker(pagePropertyWorkerDTO); |
| | | } |
| | | |
| | |
| | | public R addServiceTeam(@RequestBody @Validated(AddGroup.class) ComPbServiceTeamDTO comPbServiceTeamDTO) { |
| | | comPbServiceTeamDTO.setCommunityId(this.getCommunityId()); |
| | | comPbServiceTeamDTO.setAppid(this.getAppId()); |
| | | LoginUserInfoVO loginUserInfo = this.getLoginUserInfo(); |
| | | if (nonNull(loginUserInfo.getPropertyId())){ |
| | | comPbServiceTeamDTO.setPropertyId(loginUserInfo.getPropertyId()); |
| | | } |
| | | return partyBuildingService.addServiceTeam(comPbServiceTeamDTO); |
| | | } |
| | | |
| | |
| | | } else { |
| | | pageComPbServiceTeamDTO.setCommunityId(this.getCommunityId()); |
| | | } |
| | | LoginUserInfoVO loginUserInfo = this.getLoginUserInfo(); |
| | | if (nonNull(loginUserInfo.getPropertyId())){ |
| | | pageComPbServiceTeamDTO.setPropertyId(loginUserInfo.getPropertyId()); |
| | | } |
| | | log.info("==============物业公司id"+loginUserInfo.getPropertyId()); |
| | | return partyBuildingService.pageServiceTeam(pageComPbServiceTeamDTO); |
| | | } |
| | | |
| | |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.panzhihua.common.interfaces.OperLog; |
| | | import com.panzhihua.common.model.vos.LoginReturnsVO; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientMerchantVO; |
| | | import com.panzhihua.common.service.community.CommunityService; |
| | | import com.panzhihua.common.service.user.UserService; |
| | | import com.panzhihua.community_backstage.util.MyAESUtil; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.util.ObjectUtils; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | |
| | | @RestController |
| | | @RequestMapping("/") |
| | | @Api(tags = {"社区平台登录模块"}) |
| | | @Slf4j |
| | | public class LoginApi extends BaseController { |
| | | @Resource |
| | | private TokenService tokenService; |
| | | @Resource |
| | | private UserService userService; |
| | | @Resource |
| | | private CommunityService communityService; |
| | | |
| | | @OperLog(operModul="用户登录",operType = 1) |
| | | @ApiOperation(value = "社区平台登录", response = LoginReturnVO.class) |
| | |
| | | return r; |
| | | } |
| | | |
| | | @ApiOperation(value = "商家后台登录", response = LoginReturnVO.class) |
| | | @PostMapping("loginShopBackStage") |
| | | public R loginShopBackStage(@RequestBody LoginBody loginBody){ |
| | | String account = loginBody.getAccount(); |
| | | String password = loginBody.getPassword(); |
| | | boolean empty = ObjectUtils.isEmpty(account); |
| | | boolean empty1 = ObjectUtils.isEmpty(password); |
| | | if (empty || empty1) { |
| | | return R.fail("账户密码不能为空"); |
| | | } |
| | | log.info("登录用户信息【{}】", loginBody); |
| | | try { |
| | | R<ConvenientMerchantVO> merchant = communityService.getUserMerchantInfoByAccount(account); |
| | | if (R.isOk(merchant)) { |
| | | ConvenientMerchantVO merchantVO = |
| | | JSONObject.parseObject(JSONObject.toJSONString(merchant.getData()), ConvenientMerchantVO.class); |
| | | Boolean accountValid = merchantVO.getAccountStatus() == 1; |
| | | if (accountValid) { |
| | | R result = tokenService.loginMerchantBackStage(account, loginBody.getPassword(),this.getAppId()); |
| | | return result; |
| | | } else { |
| | | return R.fail("账号被禁用"); |
| | | } |
| | | } |
| | | return R.fail(merchant.getMsg()); |
| | | } catch (Exception e) { |
| | | return R.fail("登陆失败了"); |
| | | } |
| | | } |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.community_backstage.api; |
| | | |
| | | import com.panzhihua.common.controller.BaseController; |
| | | import com.panzhihua.common.model.dtos.community.convenient.ConvenientMerchantDTO; |
| | | import com.panzhihua.common.model.dtos.shop.PageComShopFlowerGoodsDTO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.shop.AddShopFlowerGoodsVO; |
| | | import com.panzhihua.common.model.vos.shop.PageShopGoodsVO; |
| | | import com.panzhihua.common.service.community.CommunityService; |
| | | import com.panzhihua.common.service.user.UserService; |
| | | import com.panzhihua.common.validated.AddGroup; |
| | | import com.panzhihua.common.validated.PutGroup; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import io.swagger.annotations.ApiImplicitParams; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | /** |
| | | * @auther yh |
| | | * @describe 商城管理 |
| | | */ |
| | | @Slf4j |
| | | @Api(tags = {"商城管理模块"}) |
| | | @RestController("/shopFlower") |
| | | public class ShopFlowerApi extends BaseController { |
| | | @Value("${excel.userurl}") |
| | | private String excelUrl; |
| | | // FTP 登录用户名 |
| | | @Value("${ftp.username}") |
| | | private String userName; |
| | | // FTP 登录密码 |
| | | @Value("${ftp.password}") |
| | | private String password; |
| | | // FTP 服务器地址IP地址 |
| | | @Value("${ftp.host}") |
| | | private String host; |
| | | // FTP 端口 |
| | | @Value("${ftp.port}") |
| | | private int port; |
| | | @Resource |
| | | private CommunityService communityService; |
| | | @Resource |
| | | private UserService userService; |
| | | |
| | | |
| | | @ApiOperation(value = "编辑便民服务商家") |
| | | @PutMapping("/merchant/put") |
| | | public R putMerchant(@RequestBody @Validated(PutGroup.class) ConvenientMerchantDTO convenientMerchantDTO) { |
| | | convenientMerchantDTO.setUpdatedBy(this.getUserId()); |
| | | convenientMerchantDTO.setCreatedBy(this.getUserId()); |
| | | return communityService.putMerchant(convenientMerchantDTO); |
| | | } |
| | | |
| | | |
| | | @ApiOperation(value = "分页查询商品", response = PageShopGoodsVO.class) |
| | | @PostMapping("/goods/page") |
| | | public R pageGoodsList(@RequestBody PageComShopFlowerGoodsDTO pageComShopGoodsDTO) { |
| | | return communityService.pageFlowerGoodsList(pageComShopGoodsDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "新增商品") |
| | | @PostMapping("/goods/save") |
| | | public R saveShopGoods(@RequestBody @Validated(AddGroup.class) AddShopFlowerGoodsVO addShopGoodsVO) { |
| | | return communityService.saveFlowerShopGoods(addShopGoodsVO); |
| | | } |
| | | |
| | | @ApiOperation(value = "编辑商品") |
| | | @PostMapping("/goods/edit/{id}") |
| | | public R editShopGoods(@PathVariable("id") Long id, |
| | | @RequestBody @Validated(AddGroup.class) AddShopFlowerGoodsVO addShopGoodsVO) { |
| | | return communityService.editFlowerShopGoods(id, addShopGoodsVO); |
| | | } |
| | | |
| | | @ApiOperation(value = "删除商品") |
| | | @PostMapping("/goods/delete") |
| | | public R deleteShopGoods(@RequestBody Long[] id) { |
| | | return communityService.deleteFlowerShopGoods(id); |
| | | } |
| | | |
| | | @ApiOperation(value = "商品上下架") |
| | | @ApiImplicitParams({@ApiImplicitParam(name = "id", value = "商品Id"), |
| | | @ApiImplicitParam(name = "status", value = "1.上架 2.下架 ")}) |
| | | @GetMapping("/goods/changeStatus") |
| | | public R changeStatus(@RequestParam("id") Long id, @RequestParam("status") Integer status) { |
| | | return communityService.changeFlowerStatus(id, status); |
| | | } |
| | | |
| | | /*@ApiOperation(value = "订单_分页列表", response = ComShopOrderSearchVO.class) |
| | | @PostMapping("/order/page") |
| | | public R page(@RequestBody @Validated PageComShopOrderSearchDTO pageComShopOrderSearchDTO) { |
| | | // pageComShopOrderSearchDTO.setUserId(this.getUserId()); |
| | | ClazzUtils.setIfStringIsEmpty(pageComShopOrderSearchDTO); |
| | | return communityService.pageShopOrder(pageComShopOrderSearchDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "订单_详细", response = ComShopOrderPageVO.class) |
| | | @GetMapping("/order/detail") |
| | | @ShopOperLog(operType = 11) |
| | | public R detail(@RequestParam("orderId") Long orderId) { |
| | | return communityService.orderDetail(orderId); |
| | | } |
| | | |
| | | @ApiOperation(value = "订单_导出表格") |
| | | @PostMapping("/order/export") |
| | | @ShopOperLog(operType = 12) |
| | | public R export(@RequestBody ComShopOrderExportDTO comShopOrderExportDTO) { |
| | | ClazzUtils.setIfStringIsEmpty(comShopOrderExportDTO); |
| | | String url = excelUrl; |
| | | String uuid = UUID.randomUUID().toString().replace("-", ""); |
| | | // String name=uuid+".xlsx"; |
| | | String ftpUrl = "/mnt/data/web/excel/"; |
| | | |
| | | R r = communityService.shopOrderExportData(comShopOrderExportDTO); |
| | | if (R.isOk(r)) { |
| | | List<ExcelShopOrderDTO> excelShopOrderDTO = |
| | | JSONArray.parseArray(JSONArray.toJSONString(r.getData()), ExcelShopOrderDTO.class); |
| | | if (excelShopOrderDTO == null || excelShopOrderDTO.size() == 0) { |
| | | return R.ok("未找到数据"); |
| | | } |
| | | try { |
| | | SFTPUtil sftp = new SFTPUtil(userName, password, host, port); |
| | | sftp.login(); |
| | | String name = "商城订单-" + new SimpleDateFormat("yyyyMMddhhmmss").format(new Date()) + ".xlsx"; |
| | | boolean existDir = sftp.isExistDir(ftpUrl + name); |
| | | if (!existDir) { |
| | | String property = System.getProperty("user.dir"); |
| | | String fileName = property + File.separator + name; |
| | | // 这里 需要指定写用哪个class去写 |
| | | ExcelWriter excelWriter = null; |
| | | InputStream inputStream = null; |
| | | try { |
| | | excelWriter = EasyExcel.write(fileName, ExcelShopOrderDTO.class) |
| | | .registerWriteHandler(new LongestMatchColumnWidthStyleStrategy()) |
| | | .registerWriteHandler(new CustomSheetWriteHandler()).build(); |
| | | WriteSheet writeSheet = EasyExcel.writerSheet("订单").build(); |
| | | excelWriter.write(excelShopOrderDTO, writeSheet); |
| | | excelWriter.finish(); |
| | | File file = new File(fileName); |
| | | inputStream = new FileInputStream(file); |
| | | sftp.uploadMore(ftpUrl, name, inputStream); |
| | | sftp.logout(); |
| | | inputStream.close(); |
| | | String absolutePath = file.getAbsolutePath(); |
| | | boolean delete = file.delete(); |
| | | log.info("删除excel【{}】结果【{}】", absolutePath, delete); |
| | | } finally { |
| | | // 千万别忘记finish 会帮忙关闭流 |
| | | if (inputStream != null) { |
| | | inputStream.close(); |
| | | } |
| | | if (excelWriter != null) { |
| | | excelWriter.finish(); |
| | | } |
| | | } |
| | | } |
| | | return R.ok(url + URLEncoder.encode(name, "UTF-8")); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | log.error("文件传输失败【{}】", e.getMessage()); |
| | | return R.fail(); |
| | | } |
| | | } |
| | | return R.fail("导出数据失败"); |
| | | } |
| | | |
| | | @ApiOperation(value = "资金_统计信息") |
| | | @GetMapping("/capital/stat") |
| | | public R stat() { |
| | | Long userId = 0L; |
| | | return communityService.getFundsStat(userId); |
| | | } |
| | | |
| | | @ApiOperation(value = "资金_分页列表") |
| | | @PostMapping("/capital/page") |
| | | public R page(@RequestBody PageComShopFundsSearchDTO pageComShopFundsSearchDTO) { |
| | | pageComShopFundsSearchDTO.setUserId(getUserId()); |
| | | ClazzUtils.setIfStringIsEmpty(pageComShopFundsSearchDTO); |
| | | return communityService.pageShopFunds(pageComShopFundsSearchDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "资金_详情", response = CapitalDetailVO.class) |
| | | @ApiImplicitParam(name = "orderId", value = "订单Id") |
| | | @GetMapping("/capital/capitalDetailByStore") |
| | | R capitalDetailByStore(@RequestParam("orderId") Long orderId) { |
| | | return communityService.capitalDetailByStore(orderId); |
| | | } |
| | | |
| | | @ApiOperation(value = "资金_导出表格") |
| | | @PostMapping("/capital/export") |
| | | @ShopOperLog(operType = 12) |
| | | public R export(@RequestBody ComShopFundsExportDTO comShopFundsExportDTO) { |
| | | ClazzUtils.setIfStringIsEmpty(comShopFundsExportDTO); |
| | | String url = excelUrl; |
| | | String uuid = UUID.randomUUID().toString().replace("-", ""); |
| | | // String name=uuid+".xlsx"; |
| | | String ftpUrl = "/mnt/data/web/excel/"; |
| | | |
| | | Long userId = this.getUserId(); |
| | | comShopFundsExportDTO.setUserId(userId); |
| | | R r = communityService.shopOrderFundsExportData(comShopFundsExportDTO); |
| | | if (R.isOk(r)) { |
| | | List<ExcelShopFundsDTO> excelShopFundsDTO = |
| | | JSONArray.parseArray(JSONArray.toJSONString(r.getData()), ExcelShopFundsDTO.class); |
| | | if (excelShopFundsDTO == null || excelShopFundsDTO.size() == 0) { |
| | | return R.ok("未找到数据"); |
| | | } |
| | | try { |
| | | SFTPUtil sftp = new SFTPUtil(userName, password, host, port); |
| | | sftp.login(); |
| | | String name = "商家资金流水-" + new SimpleDateFormat("yyyyMMddhhmmss").format(new Date()) + ".xlsx"; |
| | | boolean existDir = sftp.isExistDir(ftpUrl + name); |
| | | if (!existDir) { |
| | | String property = System.getProperty("user.dir"); |
| | | String fileName = property + File.separator + name; |
| | | // 这里 需要指定写用哪个class去写 |
| | | ExcelWriter excelWriter = null; |
| | | InputStream inputStream = null; |
| | | try { |
| | | excelWriter = EasyExcel.write(fileName, ExcelShopFundsDTO.class) |
| | | .registerWriteHandler(new LongestMatchColumnWidthStyleStrategy()) |
| | | .registerWriteHandler(new CustomSheetWriteHandler()).build(); |
| | | WriteSheet writeSheet = EasyExcel.writerSheet("订单").build(); |
| | | excelWriter.write(excelShopFundsDTO, writeSheet); |
| | | excelWriter.finish(); |
| | | File file = new File(fileName); |
| | | inputStream = new FileInputStream(file); |
| | | sftp.uploadMore(ftpUrl, name, inputStream); |
| | | sftp.logout(); |
| | | inputStream.close(); |
| | | String absolutePath = file.getAbsolutePath(); |
| | | boolean delete = file.delete(); |
| | | log.info("删除excel【{}】结果【{}】", absolutePath, delete); |
| | | } finally { |
| | | // 千万别忘记finish 会帮忙关闭流 |
| | | if (inputStream != null) { |
| | | inputStream.close(); |
| | | } |
| | | if (excelWriter != null) { |
| | | excelWriter.finish(); |
| | | } |
| | | } |
| | | } |
| | | return R.ok(url + URLEncoder.encode(name, "UTF-8")); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | log.error("文件传输失败【{}】", e.getMessage()); |
| | | return R.fail(); |
| | | } |
| | | } |
| | | return R.fail("导出数据失败"); |
| | | } |
| | | |
| | | @ApiOperation(value = "商家配置修改") |
| | | @PutMapping("/shop/conf") |
| | | public R editConf(@RequestBody ComShopSysConfDTO comShopSysConfDTO) { |
| | | return communityService.editShopSysConf(comShopSysConfDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "商家配置查询", response = ComShopHiddenConfVO.class) |
| | | @GetMapping("/shop/conf") |
| | | public R getConf() { |
| | | PageComShopSysConfDTO pageComShopSysConfDTO = new PageComShopSysConfDTO(); |
| | | R r = communityService.pageShopSysConf(pageComShopSysConfDTO); |
| | | if (R.isOk(r) && r.getData() != null) { |
| | | ComShopSysConfVO comShopSysConfVO = |
| | | JSONObject.parseObject(JSONObject.toJSONString(r.getData()), ComShopSysConfVO.class); |
| | | if (comShopSysConfVO != null) { |
| | | ComShopHiddenConfVO comShopHiddenConfVO = new ComShopHiddenConfVO(); |
| | | comShopHiddenConfVO.setId(comShopSysConfVO.getId()); |
| | | comShopHiddenConfVO.setHidden(comShopSysConfVO.getVal()); |
| | | return R.ok(comShopHiddenConfVO); |
| | | } |
| | | } |
| | | return r; |
| | | }*/ |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.api; |
| | | |
| | | import com.panzhihua.common.model.dtos.community.ComActProceedingsDTO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.service_community.service.ComActProceedingsService; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | @RestController |
| | | @RequestMapping("/proceedings") |
| | | public class ComActProceedingsApi { |
| | | @Resource |
| | | private ComActProceedingsService comActProceedingsService; |
| | | |
| | | /** |
| | | * description 分页查询议事委员会列表 |
| | | * |
| | | * @param keyWord 搜索关键字 |
| | | * @param page 页数 |
| | | * @param size 每页大小 |
| | | * @return R 查询结果对象 |
| | | * @author zts |
| | | * @date 2022-11-02 |
| | | */ |
| | | @GetMapping("/list") |
| | | public R list(@RequestParam(value = "page",required = false) Integer page, |
| | | @RequestParam(value = "size",required = false) Integer size, |
| | | @RequestParam(value = "keyWord",required = false) String keyWord){ |
| | | return comActProceedingsService.pageProceedings(page,size,keyWord); |
| | | } |
| | | |
| | | /** |
| | | * 修改或新增议事委员会 |
| | | * @param comActProceedingsDTO 对象 |
| | | * @return R 处理结果 |
| | | * @author zts |
| | | * @date 2022-11-02 |
| | | * */ |
| | | @PostMapping |
| | | public R addOrUpdate(@RequestBody ComActProceedingsDTO comActProceedingsDTO){ |
| | | return comActProceedingsService.addOrUpdate(comActProceedingsDTO); |
| | | } |
| | | |
| | | @DeleteMapping("/remove") |
| | | public R removeProceedings(@RequestParam("id") Long id){ |
| | | return R.ok(comActProceedingsService.removeById(id)); |
| | | } |
| | | |
| | | } |
| | |
| | | public R detailProperty(@RequestParam("id") Long id) { |
| | | return comPropertyService.detailProperty(id); |
| | | } |
| | | |
| | | @GetMapping("/noticeList") |
| | | public R noticeList(@RequestParam("page")Integer page,@RequestParam("size")Integer size,@RequestParam("propertyId")Long propertyId){ |
| | | return comPropertyService.noticeList(page,size,propertyId); |
| | | } |
| | | } |
| | |
| | | comEvent.setRequestUserId(loginUser.getUserId()); |
| | | comEvent.setRequestUserName(loginUser.getName()); |
| | | comEvent.setRequestUserTel(loginUser.getPhone()); |
| | | comEvent.setAppId(loginUser.getAppId()); |
| | | return comEventService.insertComEvent(comEvent); |
| | | } |
| | | |
| | |
| | | @PostMapping |
| | | public R add(@RequestBody ComSanshuoExpertDTO comSanshuoExpertDTO){ |
| | | comSanshuoExpertDTO.setCreateBy(this.getLoginUserInfo().getName()); |
| | | comSanshuoExpertDTO.setAppId(getLoginUserInfo().getAppId()); |
| | | return comSanShuoExpertService.addOrUpdateExpert(comSanshuoExpertDTO); |
| | | } |
| | | |
| | |
| | | } |
| | | |
| | | /** |
| | | * 随手拍详情-脱敏 |
| | | * |
| | | * @param id |
| | | * 随手拍主键 |
| | | * @param userId |
| | | * 登录用户 |
| | | * @return 详情内容 |
| | | */ |
| | | @PostMapping("detaileasyphotodesensitize") |
| | | public R detailEasyPhotoDesensitize(@RequestParam("id") Long id, @RequestParam("userId") Long userId) { |
| | | return comActEasyPhotoService.detailEasyPhotoDesensitize(id, userId); |
| | | } |
| | | |
| | | /** |
| | | * 随手拍详情 |
| | | * |
| | | * @param id |
| | |
| | | return comActMicroWishService.pageMicroWishApplets(comActMicroWishVO); |
| | | } |
| | | |
| | | @PostMapping("pagemicrowish/appletsDesensitize") |
| | | public R pageMicroWishAppletsDesensitize(@RequestBody ComActMicroWishVO comActMicroWishVO) { |
| | | return comActMicroWishService.pageMicroWishAppletsDesensitize(comActMicroWishVO); |
| | | } |
| | | |
| | | /** |
| | | * 心愿详情 |
| | | * |
| | |
| | | @PostMapping("detailmicrowish") |
| | | public R detailMicroWish(@RequestParam("id") Long id, @RequestParam("userId") Long userId) { |
| | | return comActMicroWishService.detailMicroWish(id, userId); |
| | | } |
| | | /** |
| | | * 心愿详情 - 脱敏 |
| | | * |
| | | * @param id |
| | | * 查询主键 |
| | | * @param userId |
| | | * 登录用户id |
| | | * @return 心愿内容 |
| | | */ |
| | | @PostMapping("detailmicrowishdesensitize") |
| | | public R detailMicroWishDesensitize(@RequestParam("id") Long id, @RequestParam("userId") Long userId) { |
| | | return comActMicroWishService.detailMicroWishDesensitize(id, userId); |
| | | } |
| | | |
| | | /** |
| | |
| | | return comActEasyPhotoService.pageEasyPhotoApplets(comActEasyPhotoVO); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 小程序分页查询随手拍 脱敏 |
| | | * |
| | | * @param comActEasyPhotoVO |
| | | * 查询参数 |
| | | * @return 返回结果 |
| | | */ |
| | | @PostMapping("pageeasyphotoappletsdesensitize") |
| | | public R pageEasyPhotoAppletsDesensitize(@RequestBody ComActEasyPhotoVO comActEasyPhotoVO) { |
| | | return comActEasyPhotoService.pageEasyPhotoAppletsDesensitize(comActEasyPhotoVO); |
| | | } |
| | | |
| | | /** |
| | | * 随手拍评论分页查询 |
| | | * |
| | |
| | | @PostMapping("pagecomacteasyphotocomment") |
| | | public R pageComActEasyPhotoComment(@RequestBody PageComActEasyPhotoCommentDTO pageComActEasyPhotoCommentDTO) { |
| | | return comActEasyPhotoService.pageComActEasyPhotoComment(pageComActEasyPhotoCommentDTO); |
| | | } |
| | | |
| | | /** |
| | | * 随手拍评论分页查询 - 脱敏 |
| | | * |
| | | * @param pageComActEasyPhotoCommentDTO |
| | | * 查询参数 |
| | | * @return 查询结果 |
| | | */ |
| | | @PostMapping("pagecomacteasyphotocommentdesensitize") |
| | | public R pageComActEasyPhotoCommentDesensitize(@RequestBody PageComActEasyPhotoCommentDTO pageComActEasyPhotoCommentDTO) { |
| | | return comActEasyPhotoService.pageComActEasyPhotoCommentDesensitize(pageComActEasyPhotoCommentDTO); |
| | | } |
| | | |
| | | /** |
| | |
| | | return comActEasyPhotoService.getUserReward(userId, communityId); |
| | | } |
| | | |
| | | @PostMapping("easyphoto/getUserRewardsNew") |
| | | public R getUserRewardsNew(@RequestParam("userId") Long userId, @RequestParam("communityId") Long communityId) { |
| | | return comActEasyPhotoService.getUserRewardNew(userId, communityId); |
| | | } |
| | | /** |
| | | * 读取用户随手拍奖励 |
| | | * |
| | |
| | | public R selectAutomessageSysUserById(@RequestParam("id") Long id){ |
| | | return automessageSysUserService.selectAutomessageSysUserById(id); |
| | | } |
| | | |
| | | } |
| | |
| | | import javax.annotation.Resource; |
| | | import javax.validation.Valid; |
| | | |
| | | import com.panzhihua.common.model.dtos.community.convenient.ExportMerchantDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageClassifyMerchantDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PagePopularMerchantDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageSearchDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.*; |
| | | import com.panzhihua.service_community.service.*; |
| | | import org.springframework.web.bind.annotation.DeleteMapping; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | |
| | | import com.panzhihua.common.model.dtos.community.PageComCvtBusinessDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComCvtCategoryDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageComCvtServeDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.ConvenientMerchantDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.ConvenientProductCategoryDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.ConvenientProductDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.ConvenientServiceCategoryDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.DeleteConvenientProductDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.DisableOrEnableConvenientMerchantDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.OnShelfOrOffShelfProductDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageConvenientMerchantDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageConvenientProductCategoryDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageConvenientProductDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageConvenientServiceCategoryDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.ResetPasswordConvenientMerchantDTO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.community.ComCvtServeExcelVO; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientMerchantVO; |
| | | import com.panzhihua.service_community.service.ComCvtBusinessService; |
| | | import com.panzhihua.service_community.service.ComCvtCategoryService; |
| | | import com.panzhihua.service_community.service.ComCvtServeService; |
| | | import com.panzhihua.service_community.service.ConvenientMerchantService; |
| | | import com.panzhihua.service_community.service.ConvenientProductCategoryService; |
| | | import com.panzhihua.service_community.service.ConvenientProductService; |
| | | import com.panzhihua.service_community.service.ConvenientServiceCategoryService; |
| | | |
| | | import lombok.extern.slf4j.Slf4j; |
| | | |
| | |
| | | |
| | | @Resource |
| | | private ConvenientProductService convenientProductService; |
| | | |
| | | @Resource |
| | | private ConvenientElevatingPointService convenientElevatingPointService; |
| | | |
| | | @Resource |
| | | private ConvenientGoodsCategoryService convenientGoodsCategoryService; |
| | | |
| | | /** |
| | | * 社区后台分页查询便民服务商家 |
| | |
| | | public R getProductShelfNum(@RequestParam("merchantId") Long merchantId) { |
| | | return convenientProductService.getProductShelfNum(merchantId); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 分页查询自提点 运营后台 |
| | | * @param pageConvenientElevatingPointDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/point/page") |
| | | public R pagePoint(@RequestBody PageConvenientElevatingPointDTO pageConvenientElevatingPointDTO) { |
| | | return convenientElevatingPointService.pagePoint(pageConvenientElevatingPointDTO); |
| | | } |
| | | |
| | | /** |
| | | * 便民服务新增 自提点 |
| | | * @param convenientElevatingPointDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/point/add") |
| | | public R addPoint(@RequestBody ConvenientElevatingPointDTO convenientElevatingPointDTO) { |
| | | return convenientElevatingPointService.addPoint(convenientElevatingPointDTO); |
| | | } |
| | | |
| | | /** |
| | | * 编辑便民服务 自提点 |
| | | * @param convenientElevatingPointDTO |
| | | * @return |
| | | */ |
| | | @PutMapping("/point/put") |
| | | public R putPoint(@RequestBody ConvenientElevatingPointDTO convenientElevatingPointDTO) { |
| | | return convenientElevatingPointService.putPoint(convenientElevatingPointDTO); |
| | | } |
| | | |
| | | /** |
| | | * 删除便民服务 自提点 |
| | | * @param pointId |
| | | * @param operator |
| | | * @return |
| | | */ |
| | | @DeleteMapping("/point/delete") |
| | | public R deletePoint(@RequestParam("pointId") Long pointId, @RequestParam("operator") Long operator) { |
| | | return convenientElevatingPointService.deletePoint(pointId,operator); |
| | | } |
| | | |
| | | /** |
| | | * 便民服务详情 自提点 |
| | | * @param pointId |
| | | * @return |
| | | */ |
| | | @GetMapping("/point/detail") |
| | | public R detailPoint(@RequestParam("pointId") Long pointId) { |
| | | return convenientElevatingPointService.detailPoint(pointId); |
| | | } |
| | | |
| | | /** |
| | | * 新增商品分类 |
| | | * @param convenientGoodsCategoryDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/goodsCategory/add") |
| | | public R addGoodsCategory(@RequestBody ConvenientGoodsCategoryDTO convenientGoodsCategoryDTO) { |
| | | return convenientGoodsCategoryService.addGoodsCategory(convenientGoodsCategoryDTO); |
| | | } |
| | | |
| | | /** |
| | | * 编辑 |
| | | * @param convenientGoodsCategoryDTO |
| | | * @return |
| | | */ |
| | | @PutMapping("/goodsCategory/put") |
| | | public R putGoodsCategory(@RequestBody ConvenientGoodsCategoryDTO convenientGoodsCategoryDTO) { |
| | | return convenientGoodsCategoryService.putGoodsCategory(convenientGoodsCategoryDTO); |
| | | } |
| | | |
| | | /** |
| | | * 删除商品分类 |
| | | * @param categoryId |
| | | * @return |
| | | */ |
| | | @DeleteMapping("/goodsCategory/delete") |
| | | public R deleteGoodsCategory(@RequestParam("categoryId") Long categoryId, @RequestParam("operator") Long operator) { |
| | | return convenientGoodsCategoryService.deleteGoodsCategoryById(categoryId, operator); |
| | | } |
| | | |
| | | /** |
| | | * 获取商品分类详情 |
| | | * @param categoryId |
| | | * @return |
| | | */ |
| | | @GetMapping("/goodsCategory/get") |
| | | public R getGoodsCategory(@RequestParam("categoryId") Long categoryId) { |
| | | return convenientGoodsCategoryService.getGoodsCategoryById(categoryId); |
| | | } |
| | | |
| | | /** |
| | | * 分页查询商品分类 |
| | | * @param pageConvenientGoodsCategoryDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/goodsCategory/page") |
| | | public R pageGoodsCategory(@RequestBody PageConvenientGoodsCategoryDTO pageConvenientGoodsCategoryDTO) { |
| | | return convenientGoodsCategoryService.pageGoodsCategory(pageConvenientGoodsCategoryDTO); |
| | | } |
| | | } |
| | |
| | | } |
| | | |
| | | /** |
| | | * 议事投票-详情 脱敏 |
| | | * |
| | | * @param discussDetailDTO |
| | | * 请求参数 |
| | | * @return ComActDiscussVO |
| | | */ |
| | | @PostMapping("detaildiscussdesensitize") |
| | | public R detailDiscussDesensitize(@RequestBody ComActDiscussDetailDTO discussDetailDTO) { |
| | | return comActDiscussService.detailDiscussDesensitize(discussDetailDTO); |
| | | } |
| | | |
| | | /** |
| | | * 分页查询评论下回复列表 |
| | | * @param discussDetailDTO 请求参数 |
| | | * @return 回复列表 |
| | |
| | | |
| | | /** |
| | | * 议事投票-分页查询 小程序 |
| | | * |
| | | * |
| | | * @param pageComActDiscussDTO |
| | | * 查询参数 |
| | | * @return ComActDiscussVO 分页 |
| | |
| | | @PostMapping("pagediscussapplets") |
| | | public R pageDiscussApplets(@RequestBody PageComActDiscussDTO pageComActDiscussDTO) { |
| | | return comActDiscussService.pageDiscussApplets(pageComActDiscussDTO); |
| | | } |
| | | |
| | | /** |
| | | * 议事投票-分页查询 小程序 脱敏 |
| | | * |
| | | * @param pageComActDiscussDTO |
| | | * 查询参数 |
| | | * @return ComActDiscussVO 分页 |
| | | */ |
| | | @PostMapping("pagediscussappletsdesensitize") |
| | | public R pageDiscussAppletsDesensitize(@RequestBody PageComActDiscussDTO pageComActDiscussDTO) { |
| | | return comActDiscussService.pageDiscussAppletsDesensitize(pageComActDiscussDTO); |
| | | } |
| | | |
| | | /** |
| | |
| | | public R pageDiscussCommentApplets(@RequestBody PageComActDiscussCommentDTO pageComActDiscussCommentDTO) { |
| | | return comActDiscussService.pageDiscussCommentApplets(pageComActDiscussCommentDTO); |
| | | } |
| | | /** |
| | | * 议事投票-评论-分页查询 小程序 |
| | | * |
| | | * @param pageComActDiscussCommentDTO |
| | | * 分页参数 |
| | | * @return ComActDiscussCommentVO |
| | | */ |
| | | @PostMapping("pagediscusscommentappletsdesensitize") |
| | | public R pageDiscussCommentAppletsDesensitize(@RequestBody PageComActDiscussCommentDTO pageComActDiscussCommentDTO) { |
| | | return comActDiscussService.pageDiscussCommentAppletsDesensitize(pageComActDiscussCommentDTO); |
| | | } |
| | | |
| | | /** |
| | | * 议事投票-详情 小程序 |
| | |
| | | } |
| | | |
| | | /** |
| | | * 议事投票-详情 小程序 脱敏 |
| | | * |
| | | * @param id |
| | | * 主键 |
| | | * @param userId |
| | | * 用户主键 |
| | | * @return ComActDiscussVO |
| | | */ |
| | | @PostMapping("detaildiscussappletsdesensitize") |
| | | public R detailDiscussAppletsDesensitize(@RequestParam("id") Long id, @RequestParam("userId") Long userId) { |
| | | return comActDiscussService.detailDiscussAppletsDesensitize(id, userId); |
| | | } |
| | | |
| | | /** |
| | | * 议事投票-投票 |
| | | * |
| | | * @param discussVoteOptionDTO |
| | |
| | | public R selectCount(@RequestParam("type")Integer type,@RequestParam(value = "phone",required = false)String phone,@RequestParam("communityId")Long communityId){ |
| | | return this.comActNeighborCircleService.selectCount(type,phone,communityId); |
| | | } |
| | | |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.api; |
| | | |
| | | import com.panzhihua.common.model.dtos.shop.ComShopFlowerGoodsDTO; |
| | | import com.panzhihua.common.model.dtos.shop.PageComShopFlowerGoodsDTO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.shop.AddShopFlowerGoodsVO; |
| | | import com.panzhihua.common.service.user.UserService; |
| | | import com.panzhihua.service_community.service.ComShopFlowerGoodsService; |
| | | import com.panzhihua.service_community.service.ConvenientMerchantService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | @Slf4j |
| | | @RestController |
| | | @RequestMapping("/shopFlower") |
| | | public class ShopFlowerApi { |
| | | |
| | | @Resource |
| | | private ComShopFlowerGoodsService comShopFlowerGoodsService; |
| | | // @Resource |
| | | // private ComShopOperLogService comShopOperLogService; |
| | | // @Resource |
| | | // private ComShopOrderService comShopOrderService; |
| | | // @Resource |
| | | // private ComShopCartService comShopCartService; |
| | | // @Resource |
| | | // private ComShopUserAddressService comShopUserAddressService; |
| | | |
| | | @Resource |
| | | private ConvenientMerchantService convenientMerchantService; |
| | | @Resource |
| | | private UserService userService; |
| | | |
| | | |
| | | /** |
| | | * 商品列表-分页查询 |
| | | * |
| | | * @param pageComShopGoodsDTO 查询参数 |
| | | * @return PageShopStoreVO |
| | | */ |
| | | @PostMapping("pageGoods") |
| | | public R pageFlowerGoodsList(@RequestBody PageComShopFlowerGoodsDTO pageComShopGoodsDTO) { |
| | | return comShopFlowerGoodsService.pageFlowerGoodsList(pageComShopGoodsDTO); |
| | | } |
| | | |
| | | /** |
| | | * 商品列表-APP分页查询 |
| | | * |
| | | * @param comShopFlowerGoodsDTO 查询参数 |
| | | * @return PageShopStoreVO |
| | | */ |
| | | @PostMapping("pageShopFlowerGoodsByApp") |
| | | public R pageShopFlowerGoodsByApp(@RequestBody ComShopFlowerGoodsDTO comShopFlowerGoodsDTO) { |
| | | return comShopFlowerGoodsService.pageShopFlowerGoodsByApp(comShopFlowerGoodsDTO); |
| | | } |
| | | |
| | | /** |
| | | * 新增商品 |
| | | * |
| | | * @param addShopGoodsVO |
| | | * @return |
| | | */ |
| | | @PostMapping("saveShopGoods") |
| | | public R saveFlowerShopGoods(@RequestBody AddShopFlowerGoodsVO addShopGoodsVO) { |
| | | return comShopFlowerGoodsService.saveShopFlowerGoods(addShopGoodsVO); |
| | | } |
| | | |
| | | /** |
| | | * 编辑商品 |
| | | * |
| | | * @param addShopGoodsVO |
| | | * @param id 商铺Id |
| | | * @return |
| | | */ |
| | | @Transactional(rollbackFor = Exception.class) |
| | | @PostMapping("editShopGoods/{id}") |
| | | public R editFlowerShopGoods(@PathVariable("id") Long id, @RequestBody AddShopFlowerGoodsVO addShopGoodsVO) { |
| | | return comShopFlowerGoodsService.editFlowerShopGoods(id, addShopGoodsVO); |
| | | } |
| | | |
| | | /** |
| | | * 删除商品 |
| | | * |
| | | * @param id |
| | | * @return |
| | | */ |
| | | @PostMapping("deleteShopGoods") |
| | | public R deleteFlowerShopGoods(@RequestBody Long[] id) { |
| | | return comShopFlowerGoodsService.deleteShopFlowerGoods(id); |
| | | } |
| | | |
| | | /** |
| | | * 修改商品状态 |
| | | * |
| | | * @param id |
| | | * @return |
| | | */ |
| | | @GetMapping("changeShopGoodsStatus") |
| | | public R changeFlowerStatus(@RequestParam("id") Long id, @RequestParam("status") Integer status) { |
| | | return comShopFlowerGoodsService.changeStatus(id, status); |
| | | } |
| | | |
| | | /* |
| | | *//** |
| | | * 分页查询 商家订单 |
| | | * |
| | | * @param pageComShopOrderSearchDTO |
| | | * 分页数据 |
| | | * @return 分页订单 |
| | | *//* |
| | | @PostMapping("/order/page") |
| | | public R pageShopOrder(@RequestBody PageComShopOrderSearchDTO pageComShopOrderSearchDTO) { |
| | | return comShopOrderService.pageShopOrder(pageComShopOrderSearchDTO); |
| | | } |
| | | |
| | | *//** |
| | | * 根据店铺id查询店铺详情 |
| | | * |
| | | * @param comShopStoreDTO |
| | | * 请求参数 |
| | | * @return 店铺详情 |
| | | *//* |
| | | @PostMapping("shopStoreDetail") |
| | | public R shopStoreDetail(@RequestBody PageComShopStoreDTO comShopStoreDTO) { |
| | | return comShopStoreService.shopStoreDetail(comShopStoreDTO); |
| | | } |
| | | |
| | | *//** |
| | | * 分页查询商品列表 |
| | | * |
| | | * @param comShopGoodsDTO |
| | | * 请求参数 |
| | | * @return 商品列表 |
| | | *//* |
| | | @PostMapping("/pageShopGoods") |
| | | public R pageShopGoods(@RequestBody ComShopGoodsDTO comShopGoodsDTO) { |
| | | |
| | | return comShopFlowerGoodsService.pageShopGoods(comShopGoodsDTO); |
| | | } |
| | | |
| | | *//** |
| | | * 根据商品id查询商品详情 |
| | | * |
| | | * @param goodsId |
| | | * 商品id |
| | | * @return 商品信息 |
| | | *//* |
| | | @PostMapping("shopGoodsDetail") |
| | | public R shopGoodsDetail(@RequestParam("goodsId") Long goodsId) { |
| | | return comShopFlowerGoodsService.shopGoodsDetail(goodsId); |
| | | } |
| | | |
| | | *//** |
| | | * 根据用户id查询购物车列表 |
| | | * |
| | | * @param userId |
| | | * 用户id |
| | | * @return 购物车列表信息 |
| | | *//* |
| | | @PostMapping("shopCartList") |
| | | public R shopCartList(@RequestParam("userId") Long userId) { |
| | | return comShopCartService.shopCartList(userId); |
| | | } |
| | | |
| | | *//** |
| | | * 查询用户收货地址列表 |
| | | * |
| | | * @param comShopAddressDTO |
| | | * 请求参数 |
| | | * @return 用户收获地址列表 |
| | | *//* |
| | | @PostMapping("shopUserAddressList") |
| | | public R shopUserAddressList(@RequestBody PageComShopAddressDTO comShopAddressDTO) { |
| | | return comShopUserAddressService.shopUserAddressList(comShopAddressDTO); |
| | | } |
| | | |
| | | *//** |
| | | * 用户添加书货地址 |
| | | * |
| | | * @param comShopAddressDTO |
| | | * 请求参数 |
| | | * @return 添加结果 |
| | | *//* |
| | | @PostMapping("shopAddUserAddress") |
| | | public R shopAddUserAddress(@RequestBody ComShopAddressDTO comShopAddressDTO) { |
| | | return comShopUserAddressService.shopAddUserAddress(comShopAddressDTO); |
| | | } |
| | | |
| | | *//** |
| | | * 用户修改收货地址 |
| | | * |
| | | * @param comShopAddressDTO |
| | | * 请求参数 |
| | | * @return 修改结果 |
| | | *//* |
| | | @PostMapping("shopEditUserAddress") |
| | | public R shopEditUserAddress(@RequestBody ComShopAddressDTO comShopAddressDTO) { |
| | | return comShopUserAddressService.shopEditUserAddress(comShopAddressDTO); |
| | | } |
| | | |
| | | *//** |
| | | * 用户删除收货地址 |
| | | * |
| | | * @param addressId |
| | | * 收货地址id |
| | | * @return 删除结果 |
| | | *//* |
| | | @PostMapping("shopDelUserAddress") |
| | | public R shopDelUserAddress(@RequestParam("addressId") Long addressId) { |
| | | return comShopUserAddressService.shopDelUserAddress(addressId); |
| | | } |
| | | |
| | | *//** |
| | | * 订单预览 |
| | | * |
| | | * @param orderPreviewDTO |
| | | * 请求参数 |
| | | * @return 订单预览数据 |
| | | *//* |
| | | @PostMapping("orderPreview") |
| | | public R orderPreview(@RequestBody ComShopOrderPreviewDTO orderPreviewDTO) { |
| | | return comShopOrderService.orderPreview(orderPreviewDTO); |
| | | } |
| | | |
| | | *//** |
| | | * 创建订单 |
| | | * |
| | | * @param orderCreateDTO |
| | | * 创建订单请求参数 |
| | | * @return 创建结果 |
| | | *//* |
| | | @PostMapping("orderCreate") |
| | | public R orderCreate(@RequestBody ComShopOrderCreateDTO orderCreateDTO) { |
| | | return comShopOrderService.orderCreate(orderCreateDTO); |
| | | } |
| | | |
| | | *//** |
| | | * 分页查询用户订单列表 |
| | | * |
| | | * @param comOrderListDTO |
| | | * 请求参数 |
| | | * @return 查询结果 |
| | | *//* |
| | | @PostMapping("pageOrderList") |
| | | public R pageOrderList(@RequestBody PageComOrderListDTO comOrderListDTO) { |
| | | return comShopOrderService.pageOrderList(comOrderListDTO); |
| | | } |
| | | |
| | | *//** |
| | | * 根据订单id查询订单详情 |
| | | * |
| | | * @param orderId |
| | | * 订单id |
| | | * @return 订单详情 |
| | | *//* |
| | | @PostMapping("orderDetail") |
| | | public R orderDetail(@RequestParam("orderId") Long orderId) { |
| | | return comShopOrderService.orderDetail(orderId); |
| | | } |
| | | |
| | | *//** |
| | | * 根据订单id取消订单 |
| | | * |
| | | * @param comShopOrderQueryDTO |
| | | * 请求参数 |
| | | * @return 取消结果 |
| | | *//* |
| | | @PostMapping("orderCancel") |
| | | public R orderCancel(@RequestBody ComShopOrderQueryDTO comShopOrderQueryDTO) { |
| | | return comShopOrderService.orderCancel(comShopOrderQueryDTO); |
| | | } |
| | | |
| | | *//** |
| | | * 根据订单id删除订单 |
| | | * |
| | | * @param orderId |
| | | * 订单id |
| | | * @return 删除结果 |
| | | *//* |
| | | @PostMapping("orderDelete") |
| | | public R orderDelete(@RequestParam("orderId") Long orderId) { |
| | | return comShopOrderService.orderDelete(orderId); |
| | | } |
| | | |
| | | *//** |
| | | * 根据订单id确认收货 |
| | | * |
| | | * @param comShopOrderQueryDTO |
| | | * 请求参数 |
| | | * @return 确认结果 |
| | | *//* |
| | | @PostMapping("orderConfirm") |
| | | public R orderConfirm(@RequestBody ComShopOrderQueryDTO comShopOrderQueryDTO) { |
| | | return comShopOrderService.orderConfirm(comShopOrderQueryDTO.getOrderId(), comShopOrderQueryDTO.getPhone()); |
| | | } |
| | | |
| | | *//** |
| | | * 统计用户订单数量 |
| | | * |
| | | * @param userId |
| | | * 用户id |
| | | * @return 统计结果 |
| | | *//* |
| | | @PostMapping("orderStatistics") |
| | | public R orderStatistics(@RequestParam("userId") Long userId) { |
| | | return comShopOrderService.orderStatistics(userId); |
| | | } |
| | | |
| | | |
| | | |
| | | *//** |
| | | * 商家资金的订单详情 |
| | | * |
| | | * @param id |
| | | * @return |
| | | *//* |
| | | @GetMapping("capitalDetailByStore") |
| | | public R capitalDetailByStore(@RequestParam("id") Long id) { |
| | | return comShopOrderService.capitalDetailByStore(id); |
| | | } |
| | | |
| | | *//** |
| | | * 订单发货 |
| | | * |
| | | * @param orderShipDTO |
| | | * 发货信息 |
| | | * @return 发货结果 |
| | | *//* |
| | | @PostMapping("/shipOrder") |
| | | R shipOrder(@RequestBody ComShopOrderShipDTO orderShipDTO) { |
| | | return comShopOrderService.shipOrder(orderShipDTO); |
| | | } |
| | | |
| | | *//** |
| | | * 订单配送 |
| | | * |
| | | * @param deliverDTO |
| | | * 订单ID |
| | | * @return 配送结果 |
| | | *//* |
| | | @PostMapping("/deliverOrder") |
| | | R deliverOrder(@RequestBody ComShopOrderDeliverDTO deliverDTO) { |
| | | return comShopOrderService.deliverOrder(deliverDTO); |
| | | } |
| | | |
| | | *//** |
| | | * 订单配送 |
| | | * |
| | | * @param deliverDTO |
| | | * 订单ID |
| | | * @return 配送完成 |
| | | *//* |
| | | @PostMapping("/finishDeliverOrder") |
| | | R finishDeliverOrder(@RequestBody ComShopOrderDeliverDTO deliverDTO) { |
| | | return comShopOrderService.finishDeliverOrder(deliverDTO); |
| | | } |
| | | |
| | | *//** |
| | | * 订单导出信息 |
| | | * |
| | | * @param comShopOrderExportDTO |
| | | * 订单导出信息 |
| | | * @return 订单导出信息 |
| | | *//* |
| | | @PostMapping("/shopOrderExportData") |
| | | R shopOrderExportData(@RequestBody ComShopOrderExportDTO comShopOrderExportDTO) { |
| | | return comShopOrderService.shopOrderExportData(comShopOrderExportDTO); |
| | | } |
| | | |
| | | *//** |
| | | * 资金管理导出信息 |
| | | * |
| | | * @param comShopFundsExportDTO |
| | | * 资金管理导出信息 |
| | | * @return 资金管理导出信息 |
| | | *//* |
| | | @PostMapping("/shopOrderFundsExportData") |
| | | R shopOrderFundsExportData(@RequestBody ComShopFundsExportDTO comShopFundsExportDTO) { |
| | | return comShopOrderService.shopOrderFundsExportData(comShopFundsExportDTO); |
| | | } |
| | | |
| | | *//** |
| | | * 用户资金统计信息 |
| | | * |
| | | * @param userId |
| | | * 用户ID |
| | | * @return 统计信息 |
| | | *//* |
| | | @GetMapping("/getFundsStat") |
| | | R getFundsStat(@RequestParam("userId") Long userId) { |
| | | return comShopOrderService.getFundsStat(userId); |
| | | } |
| | | |
| | | *//** |
| | | * 店铺资金统计信息 |
| | | * |
| | | * @param pageComShopFundsSearchDTO |
| | | * 店铺资金 |
| | | * @return 店铺资金统计信息 |
| | | *//* |
| | | @PostMapping("/pageShopFunds") |
| | | R pageShopFunds(@RequestBody PageComShopFundsSearchDTO pageComShopFundsSearchDTO) { |
| | | return comShopOrderService.pageShopFunds(pageComShopFundsSearchDTO); |
| | | } |
| | | |
| | | *//** |
| | | * 微信支付订单回调 |
| | | * |
| | | * @param wxPayNotifyOrderDTO |
| | | * 订单支付回调参数 |
| | | *//* |
| | | @PostMapping("/wxOrderPayNotify") |
| | | public void wxOrderPayNotify(@RequestBody WxPayNotifyOrderDTO wxPayNotifyOrderDTO) { |
| | | comShopOrderService.wxOrderPayNotify(wxPayNotifyOrderDTO); |
| | | } |
| | | |
| | | *//** |
| | | * 点击去支付订单 |
| | | * |
| | | * @param orderPayDTO |
| | | * 请求参数 |
| | | * @return 支付对象 |
| | | *//* |
| | | @PostMapping("/wxPay") |
| | | public R wxPay(@RequestBody OrderPayDTO orderPayDTO) { |
| | | return comShopOrderService.wxPay(orderPayDTO); |
| | | } |
| | | |
| | | *//** |
| | | * 商城系统配置 |
| | | * |
| | | * @param comShopSysConfDTO |
| | | * @return |
| | | *//* |
| | | @PostMapping("/conf/edit") |
| | | R editShopSysConf(@RequestBody ComShopSysConfDTO comShopSysConfDTO) { |
| | | ComShopSysConfDO comShopSysConfDO = comShopSysConfService.getBaseMapper().selectById(comShopSysConfDTO.getId()); |
| | | switch (comShopSysConfDTO.getHidden()) { |
| | | case 0: |
| | | comShopSysConfDO.setVal("0"); |
| | | comShopSysConfDO.setEnabled("1"); |
| | | break; |
| | | case 1: |
| | | comShopSysConfDO.setVal("1"); |
| | | comShopSysConfDO.setEnabled("1"); |
| | | break; |
| | | default: |
| | | break; |
| | | } |
| | | int updated = comShopSysConfService.getBaseMapper().updateById(comShopSysConfDO); |
| | | if (updated == 1) { |
| | | return R.ok(); |
| | | } |
| | | return R.fail(); |
| | | } |
| | | |
| | | *//** |
| | | * 商城系统配置查询 |
| | | * |
| | | * @param pageComShopSysConfDTO |
| | | * @return |
| | | *//* |
| | | @PostMapping("/conf/get") |
| | | R pageShopSysConf(@RequestBody PageComShopSysConfDTO pageComShopSysConfDTO) { |
| | | List<ComShopSysConfDO> confList = |
| | | comShopSysConfService.getBaseMapper().selectList(new LambdaQueryWrapper<ComShopSysConfDO>() |
| | | .eq(ComShopSysConfDO::getName, "SHOP_HIDDEN").orderByDesc(ComShopSysConfDO::getCreate_at)); |
| | | ComShopSysConfVO comShopSysConfVO = new ComShopSysConfVO(); |
| | | if (confList != null && confList.size() > 0) { |
| | | ComShopSysConfDO firstConf = confList.get(0); |
| | | BeanUtils.copyProperties(firstConf, comShopSysConfVO); |
| | | return R.ok(comShopSysConfVO); |
| | | } |
| | | return R.ok(); |
| | | } |
| | | |
| | | *//** |
| | | * check商家/店铺是否有效 |
| | | * @param userId |
| | | * @return |
| | | *//* |
| | | @GetMapping("/checkStoreIsValid") |
| | | public R checkStoreIsValid(@RequestParam("userId") Long userId) { |
| | | Boolean isShopValid = comShopStoreService.checkStoreIsValid(userId); |
| | | Boolean isConvenientValid = convenientMerchantService.checkStoreIsValid(userId); |
| | | Boolean isMcsValid = userService.checkUserIsValid(userId, 11); |
| | | return R.ok(isShopValid || isConvenientValid || isMcsValid); |
| | | }*/ |
| | | } |
| | |
| | | this.strictInsertFill(metaObject, "updateAt", () -> new Date(), Date.class); // 起始版本 3.3.3(推荐) |
| | | // 或者 |
| | | // this.fillStrategy(metaObject, "createTime", LocalDateTime.now()); // 也可以使用(3.3.0 该方法有bug) |
| | | this.strictInsertFill(metaObject, "createdAt", () -> new Date(), Date.class); // 起始版本 3.3.3(推荐) |
| | | this.strictInsertFill(metaObject, "updatedAt", () -> new Date(), Date.class); // 起始版本 3.3.3(推荐) |
| | | } |
| | | |
| | | @Override |
| | |
| | | // this.strictUpdateFill(metaObject, "updateTime", LocalDateTime.class, LocalDateTime.now()); // 起始版本 3.3.0(推荐) |
| | | // 或者 |
| | | this.strictUpdateFill(metaObject, "updateAt", () -> new Date(), Date.class); // 起始版本 3.3.3(推荐) |
| | | this.strictUpdateFill(metaObject, "updatedAt", () -> new Date(), Date.class); // 起始版本 3.3.3(推荐) |
| | | // 或者 |
| | | // this.fillStrategy(metaObject, "updateTime", LocalDateTime.now()); // 也可以使用(3.3.0 该方法有bug) |
| | | } |
| | |
| | | * @param id |
| | | * @return |
| | | */ |
| | | @Select("select * from automessage_sys_user where user_id = #{id}") |
| | | @Select("SELECT a.* FROM automessage_sys_user a WHERE a.phonenumber = (SELECT u.phone FROM sys_user u WHERE u.user_id = #{id})") |
| | | AutomessageSysUser selectAutomessageSysUserById(@Param("id") Long id); |
| | | |
| | | } |
| | |
| | | @Select("SELECT " + " count( caa.id ) as totalNum, " |
| | | + " (select count(id) from com_act_activity where `status` IN (1,2,3,4,5) and volunteer_min = 0 and community_id = ${communityId}) as commonNum, " |
| | | + " (select count(id) from com_act_activity where `status` IN (1,2,3,4,5) and volunteer_min > 0 and community_id = ${communityId}) as volunteerNum, " |
| | | + " (select count(caas.user_id) from (select * from com_act_act_sign where `status` = 1) as caas left join com_act_activity as caa on caa.id = caas.activity_id where caa.`status` IN (1,2,3,4,5) and is_volunteer = 0 and caa.community_id = ${communityId}) as commonPeopleNum, " |
| | | + " (select count(caas.user_id) from (select * from com_act_act_sign where `status` = 1) as caas left join com_act_activity as caa on caa.id = caas.activity_id where caa.`status` IN (1,2,3,4,5) and is_volunteer = 1 and caa.community_id = ${communityId}) as volunteerPeopleNum, " |
| | | + " (select count(caas.user_id) from (select * from com_act_act_sign where `status` = 1) as caas left join com_act_activity as caa on caa.id = caas.activity_id where caa.`status` IN (1,2,3,4,5) and caas.sign_identity != 3 and caa.community_id = ${communityId}) as commonPeopleNum, " |
| | | + " (select count(caas.user_id) from (select * from com_act_act_sign where `status` = 1) as caas left join com_act_activity as caa on caa.id = caas.activity_id where caa.`status` IN (1,2,3,4,5) and caas.sign_identity = 3 and caa.community_id = ${communityId}) as volunteerPeopleNum, " |
| | | + " (select count(id) from com_act_activity where `status` IN (1,2,3,4,5) and community_id = ${communityId} and create_at between date_sub(curdate() - day(curdate()) +1,interval 1 month) and now()) as currentNum " |
| | | + "FROM " + " com_act_activity AS caa " + "WHERE " |
| | | + " caa.`status` IN (1,2,3,4,5) and community_id = ${communityId}") |
| | |
| | | import java.util.List; |
| | | |
| | | import com.panzhihua.common.model.vos.community.ComActPasswordVo; |
| | | import com.panzhihua.common.model.vos.community.DataCount; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | import org.apache.ibatis.annotations.Select; |
| | |
| | | * @return |
| | | */ |
| | | BigScreenDpcStatisticsInfo selectDpcBaseData(@Param("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 获取社区动态置顶banner |
| | | * */ |
| | | List<BannerVO> getBanner(@Param("communityId") Long communityId); |
| | | |
| | | } |
| | |
| | | + "UNION ALL " |
| | | + "SELECT COUNT(id) as num,'一起议' as name FROM com_act_discuss WHERE community_id = ${communityId} " |
| | | + "UNION ALL " |
| | | + "SELECT COUNT(id) as num,'邻里圈' as name FROM com_act_neighbor_circle WHERE community_id = ${communityId} AND STATUS = 2 and belong_type = 1" |
| | | + "SELECT COUNT(id) as num,'邻里圈' as name FROM com_act_neighbor_circle WHERE community_id = ${communityId} AND STATUS = 2 and belong_type = 1 " |
| | | + "UNION ALL " |
| | | + "SELECT COUNT( e.id ) AS num,'网格事件' AS name FROM `event` as e left join event_grid_data as egd on egd.id = e.grid_id WHERE egd.grid_community_id = ${communityId} AND e.event_process_status = 2 " |
| | | + "UNION ALL " |
| | |
| | | + "UNION ALL " |
| | | + "SELECT COUNT(id) as num,'一起议' as name FROM com_act_discuss WHERE community_id = ${communityId} " |
| | | + "UNION ALL " |
| | | + "SELECT COUNT(id) as num,'邻里圈' as name FROM com_act_neighbor_circle WHERE community_id = ${communityId} AND STATUS = 1 and belong_type = 1" |
| | | + "SELECT COUNT(id) as num,'邻里圈' as name FROM com_act_neighbor_circle WHERE community_id = ${communityId} AND STATUS = 1 and belong_type = 1 " |
| | | + "UNION ALL " |
| | | + "SELECT COUNT( e.id ) AS num,'网格事件' AS NAME FROM `event` as e left join event_grid_data as egd on egd.id = e.grid_id WHERE egd.grid_community_id = ${communityId} AND e.event_status = 2 and e.event_deal_status in (1,2,3) " |
| | | + "UNION ALL " |
New file |
| | |
| | | package com.panzhihua.service_community.dao; |
| | | |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.panzhihua.service_community.entity.ComActProceedings; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Mapper |
| | | public interface ComActProceedingsDao extends BaseMapper<ComActProceedings> { |
| | | int deleteByPrimaryKey(Long id); |
| | | |
| | | int insert(ComActProceedings record); |
| | | |
| | | int insertSelective(ComActProceedings record); |
| | | |
| | | ComActProceedings selectByPrimaryKey(Long id); |
| | | |
| | | int updateByPrimaryKeySelective(ComActProceedings record); |
| | | |
| | | int updateByPrimaryKey(ComActProceedings record); |
| | | |
| | | /** |
| | | * 分页查询议事委员会 |
| | | * @param keyWord 搜索关键字 |
| | | * @return 处理结果 |
| | | * */ |
| | | List<ComActProceedings> pageProceedings(Page page, @Param("keyWord") String keyWord); |
| | | |
| | | |
| | | } |
| | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.panzhihua.common.model.dtos.property.CommonPage; |
| | | import com.panzhihua.common.model.vos.community.ComActAnnouncementVO; |
| | | import com.panzhihua.common.model.vos.community.ComPropertyVO; |
| | | import com.panzhihua.common.model.vos.community.StatisticsCommVO; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenAlarmStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.property.ComPropertyAlarmVO; |
| | | import com.panzhihua.common.model.vos.property.ComPropertyEquipmentVO; |
| | | import com.panzhihua.service_community.entity.ComActAnnouncement; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import com.panzhihua.service_community.entity.ComProperty; |
| | | import org.apache.ibatis.annotations.Param; |
| | |
| | | * @return |
| | | */ |
| | | List<ComPropertyEquipmentVO> getAlarmPointMapData(@Param("communityId") Long communityId); |
| | | |
| | | IPage<ComActAnnouncementVO> noticeList(Page page, @Param("propertyId") Long propertyId); |
| | | } |
| | |
| | | * @param id 社区或街道或业务中心id |
| | | * @return 处理结果 |
| | | * */ |
| | | IPage<ComSanshuoExpertVO> expertPage(Page page, @Param("keyWord")String keyWord, @Param("range") Integer range, @Param("id")Long id,@Param("level")Integer level); |
| | | IPage<ComSanshuoExpertVO> expertPage(Page page, @Param("keyWord")String keyWord, @Param("range") Integer range, @Param("id")Long id,@Param("level")Integer level,@Param("appId")String appId); |
| | | |
| | | /** |
| | | * 专家风采列表 |
| | |
| | | |
| | | Integer selectExpertVoList(); |
| | | |
| | | IPage<ComSanshuoExpertVO> expertList(Page page, @Param("level") Integer level, @Param("id") Long id); |
| | | IPage<ComSanshuoExpertVO> expertList(Page page, @Param("level") Integer level, @Param("id") Long id,@Param("appId")String appId); |
| | | } |
| | | |
| | | |
New file |
| | |
| | | package com.panzhihua.service_community.dao; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.panzhihua.service_community.model.dos.ComShopFlowerEvaluateDO; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | |
| | | /** |
| | | * @ClassName: ComShopFlowerEvaluateMapper |
| | | * @Author: yh |
| | | * @Date: 2022/11/9 16:46 |
| | | * @Description: TODO |
| | | */ |
| | | @Mapper |
| | | public interface ComShopFlowerEvaluateDAO extends BaseMapper<ComShopFlowerEvaluateDO> { |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.dao; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.panzhihua.common.model.vos.shop.ComShopFlowerGoodsAttrVO; |
| | | import com.panzhihua.service_community.model.dos.ComShopFlowerGoodsAttrDO; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @auther yh |
| | | * @create 2022-10-21 09:36:09 |
| | | * @describe 商品规格表mapper类 |
| | | */ |
| | | @Mapper |
| | | public interface ComShopFlowerGoodsAttrDAO extends BaseMapper<ComShopFlowerGoodsAttrDO> { |
| | | |
| | | List<ComShopFlowerGoodsAttrVO> getGoodsAttr(@Param("goodsId") Long goodsId); |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_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.shop.ComShopFlowerGoodsDTO; |
| | | import com.panzhihua.common.model.dtos.shop.PageComShopFlowerGoodsDTO; |
| | | import com.panzhihua.common.model.dtos.shop.PageComShopFlowerStoreDTO; |
| | | import com.panzhihua.common.model.vos.shop.ComShopFlowerGoodsVO; |
| | | import com.panzhihua.common.model.vos.shop.PageShopFlowerGoodsVO; |
| | | import com.panzhihua.service_community.model.dos.ComShopFlowerGoodsDO; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | /** |
| | | * @auther yh |
| | | * @create 2022-10-21 09:36:09 |
| | | * @describe 商品表mapper类 |
| | | */ |
| | | @Mapper |
| | | public interface ComShopFlowerGoodsDAO extends BaseMapper<ComShopFlowerGoodsDO> { |
| | | |
| | | IPage<PageShopFlowerGoodsVO> pageShopGoods(@Param("page") Page page, @Param("pageComShopFlowerGoodsDTO") PageComShopFlowerGoodsDTO pageComShopFlowerGoodsDTO); |
| | | |
| | | /** |
| | | * 根据店铺id查询商品列表 |
| | | * |
| | | * @param page 分页参数 |
| | | * @param pageComShopFlowerStoreDTO 请求参数 |
| | | * @return 分页商品列表 |
| | | */ |
| | | IPage<ComShopFlowerGoodsVO> pageShopGoodsByStoreId(@Param("page") Page page, @Param("pageComShopFlowerStoreDTO") PageComShopFlowerStoreDTO pageComShopFlowerStoreDTO); |
| | | |
| | | /** |
| | | * 分页查询商品列表 |
| | | * |
| | | * @param page 分页参数 |
| | | * @param comShopFlowerGoodsDTO 请求参数 |
| | | * @return 商品列表 |
| | | */ |
| | | IPage<ComShopFlowerGoodsVO> pageShopGoodByApps(@Param("page") Page page, @Param("comShopFlowerGoodsDTO") ComShopFlowerGoodsDTO comShopFlowerGoodsDTO); |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.dao; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.panzhihua.service_community.model.dos.ComShopFlowerOrderDO; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | |
| | | /** |
| | | * @ClassName: ComShopFlowerOrderMapper |
| | | * @Author: yh |
| | | * @Date: 2022/11/9 16:46 |
| | | * @Description: TODO |
| | | */ |
| | | @Mapper |
| | | public interface ComShopFlowerOrderDAO extends BaseMapper<ComShopFlowerOrderDO> { |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.dao; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.panzhihua.service_community.model.dos.ComShopFlowerOrderGoodsDO; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | |
| | | /** |
| | | * @ClassName: ComShopFlowerOrderGoodsMapper |
| | | * @Author: yh |
| | | * @Date: 2022/11/9 16:46 |
| | | * @Description: TODO |
| | | */ |
| | | @Mapper |
| | | public interface ComShopFlowerOrderGoodsDAO extends BaseMapper<ComShopFlowerOrderGoodsDO> { |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.dao; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.panzhihua.service_community.model.dos.ComShopFlowerOrderOperateDO; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | |
| | | /** |
| | | * @ClassName: ComShopFlowerOrderOperateMapper |
| | | * @Author: yh |
| | | * @Date: 2022/11/9 16:46 |
| | | * @Description: TODO |
| | | */ |
| | | @Mapper |
| | | public interface ComShopFlowerOrderOperateDAO extends BaseMapper<ComShopFlowerOrderOperateDO> { |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.dao; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.panzhihua.service_community.model.dos.ComShopFlowerOrderPayDO; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | |
| | | /** |
| | | * @ClassName: ComShopFlowerOrderPayMapper |
| | | * @Author: yh |
| | | * @Date: 2022/11/9 16:46 |
| | | * @Description: TODO |
| | | */ |
| | | @Mapper |
| | | public interface ComShopFlowerOrderPayDAO extends BaseMapper<ComShopFlowerOrderPayDO> { |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.dao; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.panzhihua.service_community.model.dos.ComShopFlowerRefundOrderDO; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | |
| | | /** |
| | | * @ClassName: ComShopFlowerRefundOrderMapper |
| | | * @Author: yh |
| | | * @Date: 2022/11/9 16:46 |
| | | * @Description: TODO |
| | | */ |
| | | @Mapper |
| | | public interface ComShopFlowerRefundOrderDAO extends BaseMapper<ComShopFlowerRefundOrderDO> { |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.dao; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.panzhihua.service_community.model.dos.ComShopFlowerUserAddressDO; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | |
| | | /** |
| | | * @ClassName: ComShopFlowerUserAddressMapper |
| | | * @Author: yh |
| | | * @Date: 2022/11/9 16:46 |
| | | * @Description: TODO |
| | | */ |
| | | @Mapper |
| | | public interface ComShopFlowerUserAddressDAO extends BaseMapper<ComShopFlowerUserAddressDO> { |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_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.community.convenient.PageConvenientElevatingPointDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageConvenientMerchantDTO; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientElevatingPointVO; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientMerchantVO; |
| | | import com.panzhihua.service_community.model.dos.ConvenientElevatingPointDO; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | /** |
| | | * @title: ConvenientElevatingPointDAO |
| | | * @projectName: 成都呐喊信息技术有限公司-智慧社区项目 |
| | | * @description: 自提点DAO |
| | | * @author: YH |
| | | * @date: 2022-10-21 09:36:09 |
| | | */ |
| | | @Mapper |
| | | public interface ConvenientElevatingPointDAO extends BaseMapper<ConvenientElevatingPointDO> { |
| | | /** |
| | | * 分页查询自提点 运营后台 |
| | | * |
| | | * @param page 分页参数 |
| | | * @param pageConvenientElevatingPointDTO |
| | | * @return |
| | | */ |
| | | IPage<ConvenientElevatingPointVO> page(@Param("page") Page page, |
| | | @Param("pageConvenientElevatingPointDTO") PageConvenientElevatingPointDTO pageConvenientElevatingPointDTO); |
| | | |
| | | /** |
| | | * 删除 |
| | | * @param pointId |
| | | * @param operator |
| | | * @return |
| | | */ |
| | | int deletePointById(@Param("pointId") Long pointId, @Param("operator") Long operator); |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_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.community.convenient.PageConvenientGoodsCategoryDTO; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientGoodsCategoryVO; |
| | | import com.panzhihua.service_community.model.dos.ConvenientGoodsCategoryDO; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @ClassName: ConvenientGoodsCategoryDAO |
| | | * @Author: yh |
| | | * @Date: 2022/11/8 13:20 |
| | | * @Description: 商品分类 |
| | | */ |
| | | @Mapper |
| | | public interface ConvenientGoodsCategoryDAO extends BaseMapper<ConvenientGoodsCategoryDO> { |
| | | |
| | | /** |
| | | * 分页查询便民服务分类 |
| | | * |
| | | * @param page 分页参数 |
| | | * @param pageConvenientGoodsCategoryDTO |
| | | * @return 服务分类详情 |
| | | */ |
| | | IPage<ConvenientGoodsCategoryVO> pageGoodsCategory(@Param("page") Page page, @Param("pageConvenientGoodsCategoryDTO") |
| | | PageConvenientGoodsCategoryDTO pageConvenientGoodsCategoryDTO); |
| | | |
| | | /** |
| | | * 删除商家服务类型关系 |
| | | * @param goodsId |
| | | * @return |
| | | */ |
| | | int deleteGoodsCategoryRelation(@Param("goodsId") Long goodsId); |
| | | |
| | | /** |
| | | * 获取商家服务范围 |
| | | * @param goodsId |
| | | * @return |
| | | */ |
| | | String selectCategoryScopeByGoodsId(@Param("goodsId") Long goodsId); |
| | | |
| | | /** |
| | | * 获取商家服务类型 |
| | | * @param goodsId |
| | | * @return serviceIds |
| | | */ |
| | | List<Long> selectCategoryIdsForGoods(@Param("goodsId") Long goodsId); |
| | | |
| | | /** |
| | | * 查看服务分类是否被引用 |
| | | * @param categoryId |
| | | * @return |
| | | */ |
| | | int checkCategoryIsUsing(@Param("categoryId") Long categoryId); |
| | | } |
| | |
| | | */ |
| | | @ApiModelProperty(value = "社区id") |
| | | private Long communityId; |
| | | /** |
| | | * 物业公司id |
| | | * */ |
| | | private Long propertyId; |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.entity; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * com_act_proceedings |
| | | * @author zts |
| | | */ |
| | | @Data |
| | | public class ComActProceedings implements Serializable { |
| | | /** |
| | | * 主键id |
| | | */ |
| | | private Long id; |
| | | |
| | | /** |
| | | * 姓名 |
| | | */ |
| | | private String name; |
| | | |
| | | /** |
| | | * 所属单位名 |
| | | */ |
| | | private String unitName; |
| | | |
| | | /** |
| | | * 所属单位id |
| | | */ |
| | | private Long unitId; |
| | | |
| | | /** |
| | | * 简介 |
| | | */ |
| | | private String introduce; |
| | | |
| | | /** |
| | | * 是否删除0否1是 |
| | | */ |
| | | private Integer delFlag; |
| | | |
| | | /** |
| | | * 状态0可用1禁用 |
| | | */ |
| | | private Integer status; |
| | | |
| | | /** |
| | | * 创建时间 |
| | | */ |
| | | private Date createTime; |
| | | |
| | | /** |
| | | * 创建人 |
| | | */ |
| | | private String createBy; |
| | | |
| | | /** |
| | | * 修改时间 |
| | | */ |
| | | private Date updateTime; |
| | | |
| | | /** |
| | | * 修改人 |
| | | */ |
| | | private Date updateBy; |
| | | /** |
| | | * 工作时间 |
| | | * */ |
| | | private String workTime; |
| | | private String logo; |
| | | |
| | | |
| | | private static final long serialVersionUID = 1L; |
| | | } |
| | |
| | | //更换专家 |
| | | @TableField(exist = false) |
| | | private Integer changeExpert; |
| | | private String appId; |
| | | |
| | | } |
| | |
| | | @TableField(exist = false) |
| | | private BigDecimal rate; |
| | | private Integer added; |
| | | |
| | | |
| | | private String appId; |
| | | @TableField(exist = false) |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | |
| | | package com.panzhihua.service_community.message; |
| | | |
| | | import static java.util.Objects.nonNull; |
| | | |
| | | import java.util.List; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | import cn.binarywang.wx.miniapp.api.WxMaService; |
| | | import com.alibaba.fastjson.JSONArray; |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.toolkit.CollectionUtils; |
| | | import com.panzhihua.common.model.vos.community.ComActDynVO; |
| | | import com.panzhihua.service_community.dao.ComActDAO; |
| | | import com.panzhihua.service_community.dao.SysUserDao; |
| | | import com.panzhihua.service_community.model.dos.ComActDO; |
| | | import org.springframework.amqp.rabbit.annotation.RabbitListener; |
| | | import org.springframework.stereotype.Component; |
| | | |
| | | import com.alibaba.fastjson.JSONArray; |
| | | import com.panzhihua.common.model.vos.LoginUserInfoVO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.community.ComActDynVO; |
| | | import com.panzhihua.common.model.vos.community.acid.ComActAcidDangerMemberVO; |
| | | import com.panzhihua.common.model.vos.community.acid.ComActAcidMemberVO; |
| | | import com.panzhihua.common.model.vos.community.acid.ComActAcidRecordVO; |
| | |
| | | import com.panzhihua.common.utlis.StringUtils; |
| | | import com.panzhihua.common.utlis.WxUtil; |
| | | import com.panzhihua.common.utlis.WxXCXTempSend; |
| | | import com.panzhihua.service_community.dao.ComActDAO; |
| | | import com.panzhihua.service_community.dao.SysUserDao; |
| | | import com.panzhihua.service_community.model.dos.ComActDO; |
| | | import com.panzhihua.service_community.service.ComActAcidMemberService; |
| | | import com.panzhihua.service_community.util.WxMaConfiguration; |
| | | import org.springframework.amqp.rabbit.annotation.RabbitListener; |
| | | import org.springframework.stereotype.Component; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.util.List; |
| | | |
| | | import static java.util.Objects.nonNull; |
| | | |
| | | /** |
| | | * @author zzj |
| | | */ |
| | | @Component |
| | | public class AcidMessage { |
| | | public static final String DELAYED_QUEUE="huacheng.acid.queue"; |
| | | public static final String DELAYED_QUEUE = "huacheng.acid.queue"; |
| | | public static final String ACID_DANGER_QUEUE = "huacheng.acid.danger.queue"; |
| | | public static final String DIRECT_QUEUE="huacheng.acid.direct.queue"; |
| | | public static final String ACID_MESSAGE_QUEUE="huacheng.acid.message.queue"; |
| | | public static final String DIRECT_QUEUE = "huacheng.acid.direct.queue"; |
| | | public static final String ACID_MESSAGE_QUEUE = "huacheng.acid.message.queue"; |
| | | @Resource |
| | | private UserService userService; |
| | | @Resource |
| | |
| | | private ComActDAO comActDAO; |
| | | @Resource |
| | | private SysUserDao sysUserDao; |
| | | @Resource |
| | | private WxMaConfiguration wxMaConfiguration; |
| | | |
| | | @RabbitListener(queues=DELAYED_QUEUE) |
| | | @RabbitListener(queues = DELAYED_QUEUE) |
| | | public void doTemplate(ComActAcidRecordVO comActAcidRecordVO) { |
| | | R<LoginUserInfoVO> loginUserInfoVOR= userService.getUserInfoByUserId(comActAcidRecordVO.getUserId().toString()); |
| | | LoginUserInfoVO loginUserInfoVO=loginUserInfoVOR.getData(); |
| | | if(loginUserInfoVO!=null&& StringUtils.isNotEmpty(loginUserInfoVO.getOpenid())){ |
| | | WxXCXTempSend util = new WxXCXTempSend(); |
| | | String accessToken = null; |
| | | try { |
| | | accessToken = util.getAccessToken(); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | } |
| | | WxUtil.sendSubscribeTXTZ(loginUserInfoVO.getOpenid(),accessToken,"pov2BTQ_uILduT5OoVKubeS2dibbZ_p79cy5AMb_BGE"); |
| | | } |
| | | R<LoginUserInfoVO> loginUserInfoVOR = userService.getUserInfoByUserId(comActAcidRecordVO.getUserId().toString()); |
| | | LoginUserInfoVO loginUserInfoVO = loginUserInfoVOR.getData(); |
| | | WxMaService maService = wxMaConfiguration.getMaService("wx118de8a734d269f0"); |
| | | if (loginUserInfoVO != null && StringUtils.isNotEmpty(loginUserInfoVO.getOpenid())) { |
| | | try { |
| | | WxUtil.sendSubscribeTXTZ(loginUserInfoVO.getOpenid(), maService.getAccessToken(), "pov2BTQ_uILduT5OoVKubeS2dibbZ_p79cy5AMb_BGE"); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | } |
| | | |
| | | } |
| | | } |
| | | |
| | | @RabbitListener(queues=ACID_DANGER_QUEUE) |
| | | @RabbitListener(queues = ACID_DANGER_QUEUE) |
| | | public void pushMessage(ComActAcidDangerMemberVO dangerMember) { |
| | | R r = comActAcidMemberService.selectPushList(dangerMember.getRelationName()); |
| | | WxMaService maService = wxMaConfiguration.getMaService("wx118de8a734d269f0"); |
| | | if (R.isOk(r) && nonNull(r.getData())) { |
| | | List<ComActAcidMemberVO> members = JSONArray.parseArray(JSONArray.toJSONString(r.getData()), ComActAcidMemberVO.class); |
| | | if (nonNull(members) && !members.isEmpty()) { |
| | | members.forEach(member -> { |
| | | WxXCXTempSend util = new WxXCXTempSend(); |
| | | String accessToken = null; |
| | | try { |
| | | accessToken = util.getAccessToken(); |
| | | WxUtil.sendSubscribeDanger(member.getOpenid(), maService.getAccessToken(), dangerMember, "Yr5idSziLRiRo0t07mcz284sMm41Kr2KsA5UmSc0jWU"); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | } |
| | | WxUtil.sendSubscribeDanger(member.getOpenid(), accessToken, dangerMember, "Yr5idSziLRiRo0t07mcz284sMm41Kr2KsA5UmSc0jWU"); |
| | | |
| | | }); |
| | | } |
| | | } |
| | | } |
| | | |
| | | @RabbitListener(queues = DIRECT_QUEUE) |
| | | public void updateUserInfo(ComActAcidRecordVO comActAcidRecordVO){ |
| | | public void updateUserInfo(ComActAcidRecordVO comActAcidRecordVO) { |
| | | //防疫登记提交默认绑定用户信息 |
| | | R<LoginUserInfoVO> loginUserInfoVOR= userService.getUserInfoByUserId(comActAcidRecordVO.getUserId().toString()); |
| | | if(R.isOk(loginUserInfoVOR)&&loginUserInfoVOR.getData()!=null){ |
| | | LoginUserInfoVO loginUserInfoVO=loginUserInfoVOR.getData(); |
| | | if(StringUtils.isEmpty(loginUserInfoVO.getPhone())||StringUtils.isEmpty(loginUserInfoVO.getIdCard())){ |
| | | R<LoginUserInfoVO> loginUserInfoVOR = userService.getUserInfoByUserId(comActAcidRecordVO.getUserId().toString()); |
| | | if (R.isOk(loginUserInfoVOR) && loginUserInfoVOR.getData() != null) { |
| | | LoginUserInfoVO loginUserInfoVO = loginUserInfoVOR.getData(); |
| | | if (StringUtils.isEmpty(loginUserInfoVO.getPhone()) || StringUtils.isEmpty(loginUserInfoVO.getIdCard())) { |
| | | loginUserInfoVO.setPhone(comActAcidRecordVO.getPhone()); |
| | | loginUserInfoVO.setIdCard(comActAcidRecordVO.getIdCard()); |
| | | loginUserInfoVO.setName(comActAcidRecordVO.getName()); |
| | | if(StringUtils.isNotEmpty(comActAcidRecordVO.getLocalCity())){ |
| | | String town=comActAcidRecordVO.getLocalCity().split(",")[2]; |
| | | String area=comActAcidRecordVO.getLocalCity().split(",")[1]; |
| | | String country=comActAcidRecordVO.getLocalCity().split(",")[0]; |
| | | List<ComActDO> comActDOS=comActDAO.selectList(new QueryWrapper<ComActDO>().lambda().eq(ComActDO::getName,town).eq(ComActDO::getAppId,"wx118de8a734d269f0")); |
| | | if(CollectionUtils.isNotEmpty(comActDOS)){ |
| | | if(comActDOS.size()==1){ |
| | | if (StringUtils.isNotEmpty(comActAcidRecordVO.getLocalCity())) { |
| | | String town = comActAcidRecordVO.getLocalCity().split(",")[2]; |
| | | String area = comActAcidRecordVO.getLocalCity().split(",")[1]; |
| | | String country = comActAcidRecordVO.getLocalCity().split(",")[0]; |
| | | List<ComActDO> comActDOS = comActDAO.selectList(new QueryWrapper<ComActDO>().lambda().eq(ComActDO::getName, town).eq(ComActDO::getAppId, "wx118de8a734d269f0")); |
| | | if (CollectionUtils.isNotEmpty(comActDOS)) { |
| | | if (comActDOS.size() == 1) { |
| | | loginUserInfoVO.setCommunityId(comActDOS.get(0).getCommunityId()); |
| | | } |
| | | else { |
| | | ComActDO comActDO=comActDAO.selectOne(new QueryWrapper<ComActDO>().lambda().eq(ComActDO::getAppId,"wx118de8a734d269f0").eq(ComActDO::getName,town).and(comActDOLambdaQueryWrapper -> comActDOLambdaQueryWrapper.like(ComActDO::getAddress,town).or().like(ComActDO::getAddress,area).or().like(ComActDO::getAddress,country))); |
| | | if(comActDO!=null){ |
| | | } else { |
| | | ComActDO comActDO = comActDAO.selectOne(new QueryWrapper<ComActDO>().lambda().eq(ComActDO::getAppId, "wx118de8a734d269f0").eq(ComActDO::getName, town).and(comActDOLambdaQueryWrapper -> comActDOLambdaQueryWrapper.like(ComActDO::getAddress, town).or().like(ComActDO::getAddress, area).or().like(ComActDO::getAddress, country))); |
| | | if (comActDO != null) { |
| | | loginUserInfoVO.setCommunityId(comActDO.getCommunityId()); |
| | | } |
| | | } |
| | |
| | | } |
| | | } |
| | | } |
| | | |
| | | @RabbitListener(queues = ACID_MESSAGE_QUEUE) |
| | | public void sendMessage(ComActDynVO comActDynVO){ |
| | | try{ |
| | | List<String> openIds=sysUserDao.selectOpenId(); |
| | | String appId = "wx118de8a734d269f0"; |
| | | String appSecret = "0264342daefde5cd70a6adada09ee5b1"; |
| | | WxXCXTempSend wxXCXTempSend=new WxXCXTempSend(); |
| | | // wxXCXTempSend.setAppAccessTokenToCache(appId,appSecret); |
| | | public void sendMessage(ComActDynVO comActDynVO) { |
| | | try { |
| | | List<String> openIds = sysUserDao.selectOpenId(); |
| | | WxMaService maService = wxMaConfiguration.getMaService("wx118de8a734d269f0"); |
| | | for (int i = 0; i < openIds.size(); i++) { |
| | | try { |
| | | WxUtil.sendLongTimeTemplate(openIds.get(i),wxXCXTempSend.getAccessTokenValid(appId,i),"疫情快讯",comActDynVO.getTitle().length()>10?comActDynVO.getTitle().substring(0,10)+"..":comActDynVO.getTitle(),"/pages/community_child/community/detail?id="+comActDynVO.getId()+"&title=疫情快讯详情"); |
| | | WxUtil.sendLongTimeTemplate(openIds.get(i), maService.getAccessToken(), "疫情快讯", comActDynVO.getTitle().length() > 10 ? comActDynVO.getTitle().substring(0, 10) + ".." : comActDynVO.getTitle(), "/pages/community_child/community/detail?id=" + comActDynVO.getId() + "&title=疫情快讯详情"); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | } |
| | | } |
| | | for(String openId:openIds){ |
| | | |
| | | } |
| | | }catch (Exception e){ |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | } |
| | | |
| | |
| | | private Integer readNum; |
| | | |
| | | private Date releaseTime; |
| | | /** |
| | | * 广告是否置顶 |
| | | * */ |
| | | private Integer onTop; |
| | | |
| | | /** |
| | | * 图片链接 |
| | | * */ |
| | | private String imageUrl; |
| | | |
| | | } |
| | |
| | | * 大学名称 |
| | | */ |
| | | private String universityName; |
| | | /** |
| | | * 所属物业公司id |
| | | * */ |
| | | private Long propertyId; |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.model.dos; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @ClassName: ComShopFlowerEvaluate |
| | | * @Author: yh |
| | | * @Date: 2022/11/9 16:46 |
| | | * @Description: 评价表 |
| | | */ |
| | | |
| | | @TableName(value = "com_shop_flower_evaluate") |
| | | @Data |
| | | public class ComShopFlowerEvaluateDO implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | /** |
| | | * ,主键 |
| | | */ |
| | | @TableId(type = IdType.ASSIGN_ID) |
| | | private Long id; |
| | | |
| | | /** |
| | | * 订单号 |
| | | */ |
| | | @TableField(value = "order_no") |
| | | private String orderNo; |
| | | |
| | | /** |
| | | * 商品id |
| | | */ |
| | | @TableField(value = "goods_id") |
| | | private String goodsId; |
| | | |
| | | /** |
| | | * 评价人id |
| | | */ |
| | | @TableField(value = "user_id") |
| | | private Long userId; |
| | | |
| | | /** |
| | | * 评价时间 |
| | | */ |
| | | @TableField(value = "evaluate_time") |
| | | private Date evaluateTime; |
| | | |
| | | /** |
| | | * 评价类型(1.非常满意 2.满意 3.一般 4.不满意 5.糟糕透了) |
| | | */ |
| | | @TableField(value = "evaluate_type") |
| | | private Integer evaluateType; |
| | | |
| | | /** |
| | | * 评价内容 |
| | | */ |
| | | @TableField(value = "evaluate_content") |
| | | private String evaluateContent; |
| | | |
| | | /** |
| | | * 评价图片 |
| | | */ |
| | | @TableField(value = "evaluate_pic") |
| | | private String evaluatePic; |
| | | |
| | | /** |
| | | * 创建时间 |
| | | */ |
| | | @TableField(value = "create_at",fill = FieldFill.INSERT) |
| | | private Date createAt; |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.model.dos; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | import java.math.BigDecimal; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @auther yh |
| | | * @create 2022-10-21 09:36:09 |
| | | * @describe 商品规格表实体类 |
| | | */ |
| | | |
| | | @Data |
| | | @TableName("com_shop_flower_goods_attr") |
| | | public class ComShopFlowerGoodsAttrDO implements Serializable { |
| | | |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 商品规格id |
| | | */ |
| | | @TableId(type = IdType.ASSIGN_ID) |
| | | private Long id; |
| | | |
| | | /** |
| | | * 商品id |
| | | */ |
| | | private Long goodsId; |
| | | |
| | | /** |
| | | * 店铺id |
| | | */ |
| | | private Long storeId; |
| | | |
| | | /** |
| | | * 商品名称 |
| | | */ |
| | | private String goodsName; |
| | | |
| | | /** |
| | | * 规格名称 |
| | | */ |
| | | private String goodsAttrName; |
| | | |
| | | /** |
| | | * 商品规格库存 |
| | | */ |
| | | private Integer stock; |
| | | |
| | | /** |
| | | * 商品规格销量 |
| | | */ |
| | | private Integer sale; |
| | | |
| | | /** |
| | | * 商品规格图 |
| | | */ |
| | | private String attrPic; |
| | | |
| | | /** |
| | | * 是否是默认规格(1.是 2.否) |
| | | */ |
| | | private Integer isDefault; |
| | | |
| | | /** |
| | | * 规格价格 |
| | | */ |
| | | private BigDecimal price; |
| | | |
| | | /** |
| | | * 包邮价 |
| | | */ |
| | | private BigDecimal freeShippingPrice; |
| | | /** |
| | | * 拼单价 |
| | | */ |
| | | private BigDecimal collatePrice; |
| | | |
| | | |
| | | /** |
| | | * 创建时间 |
| | | */ |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Date createAt; |
| | | |
| | | /** |
| | | * 修改时间 |
| | | */ |
| | | @TableField(fill = FieldFill.UPDATE) |
| | | private Date updateAt; |
| | | |
| | | @Override |
| | | public String toString() { |
| | | return "ComShopFlowerGoodsAttrDO{" + |
| | | "id=" + id + |
| | | ", goodsId=" + goodsId + |
| | | ", storeId=" + storeId + |
| | | ", goodsName='" + goodsName + '\'' + |
| | | ", goodsAttrName='" + goodsAttrName + '\'' + |
| | | ", stock=" + stock + |
| | | ", sale=" + sale + |
| | | ", attrPic='" + attrPic + '\'' + |
| | | ", isDefault=" + isDefault + |
| | | ", price=" + price + |
| | | ", freeShippingPrice=" + freeShippingPrice + |
| | | ", collatePrice=" + collatePrice + |
| | | ", createAt=" + createAt + |
| | | ", updateAt=" + updateAt + |
| | | '}'; |
| | | } |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.model.dos; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | import java.math.BigDecimal; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @auther yh |
| | | * @create 2022-10-21 09:36:09 |
| | | * @describe 商品表实体类 |
| | | */ |
| | | |
| | | @Data |
| | | @TableName("com_shop_flower_goods") |
| | | public class ComShopFlowerGoodsDO implements Serializable { |
| | | |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 商品id |
| | | */ |
| | | @TableId(type = IdType.ASSIGN_ID) |
| | | private Long id; |
| | | |
| | | /** |
| | | * 商品分类id |
| | | */ |
| | | private Long typeId; |
| | | |
| | | /** |
| | | * 商品名称 |
| | | */ |
| | | @TableField("`name`") |
| | | private String name; |
| | | |
| | | /** |
| | | * 店铺id |
| | | */ |
| | | private Long storeId; |
| | | |
| | | /** |
| | | * 商品主图 |
| | | */ |
| | | private String goodsPic; |
| | | |
| | | /** |
| | | * 商品展示图 |
| | | */ |
| | | private String images; |
| | | |
| | | /** |
| | | * 商品状态(1.出售中 2.已下架 3.回收站) |
| | | */ |
| | | @TableField("`status`") |
| | | private Integer status; |
| | | |
| | | /** |
| | | * 商品销量 |
| | | */ |
| | | private Integer sale; |
| | | |
| | | /** |
| | | * 商品原价 |
| | | */ |
| | | private BigDecimal originalPrice; |
| | | |
| | | /** |
| | | * 商品现价 |
| | | */ |
| | | private BigDecimal price; |
| | | |
| | | /** |
| | | * 商品单位 |
| | | */ |
| | | private String unit; |
| | | |
| | | /** |
| | | * 商品排序 |
| | | */ |
| | | @TableField("`order`") |
| | | private Integer order; |
| | | |
| | | /** |
| | | * 商品总库存 |
| | | */ |
| | | private Integer stock; |
| | | |
| | | /** |
| | | * 商品详情 |
| | | */ |
| | | private String details; |
| | | |
| | | /** |
| | | * 商品备注 |
| | | */ |
| | | private String remark; |
| | | |
| | | /** |
| | | * 商品描述 |
| | | */ |
| | | private String goodsDescribe; |
| | | |
| | | /** |
| | | * 配送方式(1.自提 2.快递) |
| | | */ |
| | | private Integer deliveryType; |
| | | |
| | | /** |
| | | * 删除状态(1.未删除 2.已删除) |
| | | */ |
| | | private Integer deleteStatus; |
| | | |
| | | /** |
| | | * 创建时间 |
| | | */ |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Date createAt; |
| | | |
| | | /** |
| | | * 修改时间 |
| | | */ |
| | | @TableField(fill = FieldFill.UPDATE) |
| | | private Date updateAt; |
| | | |
| | | @Override |
| | | public String toString() { |
| | | return "ComShopGoodsDO{" + "id=" + id + ", typeId=" + typeId + ", name=" + name + ", storeId=" + storeId |
| | | + ", goodsPic=" + goodsPic + ", images=" + images + ", status=" + status + ", sale=" + sale |
| | | + ", originalPrice=" + originalPrice + ", price=" + price + ", unit=" + unit + ", order=" + order |
| | | + ", stock=" + stock + ", details=" + details + ", remark=" + remark + ", goodsDescribe=" + goodsDescribe |
| | | + ", deliveryType=" + deliveryType + ", deleteStatus=" + deleteStatus + ", createAt=" + createAt |
| | | + ", updateAt=" + updateAt + "}"; |
| | | } |
| | | |
| | | /** |
| | | * 商品状态(1.上架 2.已下架 3.回收站) |
| | | */ |
| | | public interface status { |
| | | int sell = 1; |
| | | int lower = 2; |
| | | int recovery = 3; |
| | | } |
| | | |
| | | /** |
| | | * 删除状态(1.未删除 2.已删除) |
| | | */ |
| | | public interface deleteStatus { |
| | | int no = 1; |
| | | int yes = 2; |
| | | } |
| | | |
| | | /** |
| | | * 配送方式(1.自提 2.快递) |
| | | */ |
| | | public interface deliveryType { |
| | | int store = 1; |
| | | int express = 2; |
| | | } |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.model.dos; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | import java.math.BigDecimal; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @ClassName: ComShopFlowerOrder |
| | | * @Author: yh |
| | | * @Date: 2022/11/9 16:46 |
| | | * @Description: 花城订单表 |
| | | */ |
| | | |
| | | @TableName(value = "com_shop_flower_order") |
| | | @Data |
| | | public class ComShopFlowerOrderDO implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | /** |
| | | * 订单id |
| | | */ |
| | | @TableId(type = IdType.ASSIGN_ID) |
| | | private Long id; |
| | | |
| | | /** |
| | | * 店铺id |
| | | */ |
| | | @TableField(value = "store_id") |
| | | private Long storeId; |
| | | |
| | | /** |
| | | * 用户id |
| | | */ |
| | | @TableField(value = "user_id") |
| | | private Long userId; |
| | | |
| | | /** |
| | | * 订单号 |
| | | */ |
| | | @TableField(value = "order_no") |
| | | private String orderNo; |
| | | |
| | | /** |
| | | * 支付单号 |
| | | */ |
| | | @TableField(value = "pay_no") |
| | | private String payNo; |
| | | |
| | | /** |
| | | * 微信交易单号 |
| | | */ |
| | | @TableField(value = "wx_tarde_no") |
| | | private String wxTardeNo; |
| | | |
| | | /** |
| | | * 订单状态(1.等待配送 2.配送中 3.待收货 4.待评价 5.已完成 6.已取消 7.已退款) |
| | | */ |
| | | @TableField(value = "status") |
| | | private Integer status; |
| | | |
| | | /** |
| | | * 支付状态(1.未支付 2.已支付) |
| | | */ |
| | | @TableField(value = "pay_status") |
| | | private Integer payStatus; |
| | | |
| | | /** |
| | | * 订单收货人id |
| | | */ |
| | | @TableField(value = "receiver_id") |
| | | private Long receiverId; |
| | | |
| | | /** |
| | | * 删除状态(1.未删除 2.已删除) |
| | | */ |
| | | @TableField(value = "delete_status") |
| | | private Integer deleteStatus; |
| | | |
| | | /** |
| | | * 订单总金额 |
| | | */ |
| | | @TableField(value = "total_amount") |
| | | private BigDecimal totalAmount; |
| | | |
| | | /** |
| | | * 优惠总金额 |
| | | */ |
| | | @TableField(value = "discount_amount") |
| | | private BigDecimal discountAmount; |
| | | |
| | | /** |
| | | * 支付总金额 |
| | | */ |
| | | @TableField(value = "pay_amount") |
| | | private BigDecimal payAmount; |
| | | |
| | | /** |
| | | * 支付方式(1.微信支付) |
| | | */ |
| | | @TableField(value = "pay_type") |
| | | private Integer payType; |
| | | |
| | | /** |
| | | * 支付时间 |
| | | */ |
| | | @TableField(value = "pay_time") |
| | | private Date payTime; |
| | | |
| | | /** |
| | | * 配送方式(1.自提 2.快递) |
| | | */ |
| | | @TableField(value = "delivery_type") |
| | | private Integer deliveryType; |
| | | |
| | | /** |
| | | * 订单发货状态(1.未发货 2.已发货) |
| | | */ |
| | | @TableField(value = "delivery_status") |
| | | private Integer deliveryStatus; |
| | | |
| | | /** |
| | | * 订单备注 |
| | | */ |
| | | @TableField(value = "remark") |
| | | private String remark; |
| | | |
| | | /** |
| | | * 物流公司 |
| | | */ |
| | | @TableField(value = "logistics_company") |
| | | private String logisticsCompany; |
| | | |
| | | /** |
| | | * 物流单号 |
| | | */ |
| | | @TableField(value = "logistics_no") |
| | | private String logisticsNo; |
| | | |
| | | /** |
| | | * 下单时间 |
| | | */ |
| | | @TableField(value = "create_at",fill = FieldFill.INSERT) |
| | | private Date createAt; |
| | | |
| | | /** |
| | | * 修改时间 |
| | | */ |
| | | @TableField(value = "update_at",fill = FieldFill.UPDATE) |
| | | private Date updateAt; |
| | | |
| | | /** |
| | | * 配送时间 |
| | | */ |
| | | @TableField(value = "delivery_time") |
| | | private Date deliveryTime; |
| | | |
| | | /** |
| | | * 送达时间 |
| | | */ |
| | | @TableField(value = "service_time") |
| | | private Date serviceTime; |
| | | |
| | | /** |
| | | * 收货时间 |
| | | */ |
| | | @TableField(value = "receiving_time") |
| | | private Date receivingTime; |
| | | |
| | | /** |
| | | * 退款时间 |
| | | */ |
| | | @TableField(value = "refund_time") |
| | | private Date refundTime; |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.model.dos; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | import java.math.BigDecimal; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @ClassName: ComShopFlowerOrderGoods |
| | | * @Author: yh |
| | | * @Date: 2022/11/9 16:46 |
| | | * @Description: 花城订单商品表 |
| | | */ |
| | | @TableName(value = "com_shop_flower_order_goods") |
| | | @Data |
| | | public class ComShopFlowerOrderGoodsDO implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | /** |
| | | * 订单商品id |
| | | */ |
| | | @TableId(type = IdType.ASSIGN_ID) |
| | | private Long id; |
| | | |
| | | /** |
| | | * 店铺id |
| | | */ |
| | | @TableField(value = "store_id") |
| | | private Long storeId; |
| | | |
| | | /** |
| | | * 订单id |
| | | */ |
| | | @TableField(value = "order_id") |
| | | private Long orderId; |
| | | |
| | | /** |
| | | * 用户id |
| | | */ |
| | | @TableField(value = "user_id") |
| | | private Long userId; |
| | | |
| | | /** |
| | | * 订单号 |
| | | */ |
| | | @TableField(value = "order_no") |
| | | private String orderNo; |
| | | |
| | | /** |
| | | * 商品id |
| | | */ |
| | | @TableField(value = "goods_id") |
| | | private Long goodsId; |
| | | |
| | | /** |
| | | * 商品规格id |
| | | */ |
| | | @TableField(value = "goods_attr_id") |
| | | private Long goodsAttrId; |
| | | |
| | | /** |
| | | * 规格名称 |
| | | */ |
| | | @TableField(value = "goods_attr_name") |
| | | private String goodsAttrName; |
| | | |
| | | /** |
| | | * 购买数量 |
| | | */ |
| | | @TableField(value = "amount") |
| | | private Integer amount; |
| | | |
| | | /** |
| | | * 商品规格价格 |
| | | */ |
| | | @TableField(value = "goods_attr_price") |
| | | private BigDecimal goodsAttrPrice; |
| | | |
| | | /** |
| | | * 商品规格图 |
| | | */ |
| | | @TableField(value = "goods_attr_pic") |
| | | private String goodsAttrPic; |
| | | |
| | | /** |
| | | * 原价(划线价) |
| | | */ |
| | | @TableField(value = "price") |
| | | private BigDecimal price; |
| | | |
| | | /** |
| | | * 包邮价 |
| | | */ |
| | | @TableField(value = "free_shipping_price") |
| | | private BigDecimal freeShippingPrice; |
| | | |
| | | /** |
| | | * 拼单价 |
| | | */ |
| | | @TableField(value = "collate_price") |
| | | private BigDecimal collatePrice; |
| | | |
| | | /** |
| | | * 商品名称 |
| | | */ |
| | | @TableField(value = "goods_name") |
| | | private String goodsName; |
| | | |
| | | /** |
| | | * 创建时间 |
| | | */ |
| | | @TableField(value = "create_at") |
| | | private Date createAt; |
| | | |
| | | /** |
| | | * 获取订单商品id |
| | | * |
| | | * @return id - 订单商品id |
| | | */ |
| | | public Long getId() { |
| | | return id; |
| | | } |
| | | |
| | | /** |
| | | * 设置订单商品id |
| | | * |
| | | * @param id 订单商品id |
| | | */ |
| | | public void setId(Long id) { |
| | | this.id = id; |
| | | } |
| | | |
| | | /** |
| | | * 获取店铺id |
| | | * |
| | | * @return store_id - 店铺id |
| | | */ |
| | | public Long getStoreId() { |
| | | return storeId; |
| | | } |
| | | |
| | | /** |
| | | * 设置店铺id |
| | | * |
| | | * @param storeId 店铺id |
| | | */ |
| | | public void setStoreId(Long storeId) { |
| | | this.storeId = storeId; |
| | | } |
| | | |
| | | /** |
| | | * 获取订单id |
| | | * |
| | | * @return order_id - 订单id |
| | | */ |
| | | public Long getOrderId() { |
| | | return orderId; |
| | | } |
| | | |
| | | /** |
| | | * 设置订单id |
| | | * |
| | | * @param orderId 订单id |
| | | */ |
| | | public void setOrderId(Long orderId) { |
| | | this.orderId = orderId; |
| | | } |
| | | |
| | | /** |
| | | * 获取用户id |
| | | * |
| | | * @return user_id - 用户id |
| | | */ |
| | | public Long getUserId() { |
| | | return userId; |
| | | } |
| | | |
| | | /** |
| | | * 设置用户id |
| | | * |
| | | * @param userId 用户id |
| | | */ |
| | | public void setUserId(Long userId) { |
| | | this.userId = userId; |
| | | } |
| | | |
| | | /** |
| | | * 获取订单号 |
| | | * |
| | | * @return order_no - 订单号 |
| | | */ |
| | | public String getOrderNo() { |
| | | return orderNo; |
| | | } |
| | | |
| | | /** |
| | | * 设置订单号 |
| | | * |
| | | * @param orderNo 订单号 |
| | | */ |
| | | public void setOrderNo(String orderNo) { |
| | | this.orderNo = orderNo; |
| | | } |
| | | |
| | | /** |
| | | * 获取商品id |
| | | * |
| | | * @return goods_id - 商品id |
| | | */ |
| | | public Long getGoodsId() { |
| | | return goodsId; |
| | | } |
| | | |
| | | /** |
| | | * 设置商品id |
| | | * |
| | | * @param goodsId 商品id |
| | | */ |
| | | public void setGoodsId(Long goodsId) { |
| | | this.goodsId = goodsId; |
| | | } |
| | | |
| | | /** |
| | | * 获取商品规格id |
| | | * |
| | | * @return goods_attr_id - 商品规格id |
| | | */ |
| | | public Long getGoodsAttrId() { |
| | | return goodsAttrId; |
| | | } |
| | | |
| | | /** |
| | | * 设置商品规格id |
| | | * |
| | | * @param goodsAttrId 商品规格id |
| | | */ |
| | | public void setGoodsAttrId(Long goodsAttrId) { |
| | | this.goodsAttrId = goodsAttrId; |
| | | } |
| | | |
| | | /** |
| | | * 获取规格名称 |
| | | * |
| | | * @return goods_attr_name - 规格名称 |
| | | */ |
| | | public String getGoodsAttrName() { |
| | | return goodsAttrName; |
| | | } |
| | | |
| | | /** |
| | | * 设置规格名称 |
| | | * |
| | | * @param goodsAttrName 规格名称 |
| | | */ |
| | | public void setGoodsAttrName(String goodsAttrName) { |
| | | this.goodsAttrName = goodsAttrName; |
| | | } |
| | | |
| | | /** |
| | | * 获取购买数量 |
| | | * |
| | | * @return amount - 购买数量 |
| | | */ |
| | | public Integer getAmount() { |
| | | return amount; |
| | | } |
| | | |
| | | /** |
| | | * 设置购买数量 |
| | | * |
| | | * @param amount 购买数量 |
| | | */ |
| | | public void setAmount(Integer amount) { |
| | | this.amount = amount; |
| | | } |
| | | |
| | | /** |
| | | * 获取商品规格价格 |
| | | * |
| | | * @return goods_attr_price - 商品规格价格 |
| | | */ |
| | | public BigDecimal getGoodsAttrPrice() { |
| | | return goodsAttrPrice; |
| | | } |
| | | |
| | | /** |
| | | * 设置商品规格价格 |
| | | * |
| | | * @param goodsAttrPrice 商品规格价格 |
| | | */ |
| | | public void setGoodsAttrPrice(BigDecimal goodsAttrPrice) { |
| | | this.goodsAttrPrice = goodsAttrPrice; |
| | | } |
| | | |
| | | /** |
| | | * 获取商品规格图 |
| | | * |
| | | * @return goods_attr_pic - 商品规格图 |
| | | */ |
| | | public String getGoodsAttrPic() { |
| | | return goodsAttrPic; |
| | | } |
| | | |
| | | /** |
| | | * 设置商品规格图 |
| | | * |
| | | * @param goodsAttrPic 商品规格图 |
| | | */ |
| | | public void setGoodsAttrPic(String goodsAttrPic) { |
| | | this.goodsAttrPic = goodsAttrPic; |
| | | } |
| | | |
| | | /** |
| | | * 获取原价(划线价) |
| | | * |
| | | * @return price - 原价(划线价) |
| | | */ |
| | | public BigDecimal getPrice() { |
| | | return price; |
| | | } |
| | | |
| | | /** |
| | | * 设置原价(划线价) |
| | | * |
| | | * @param price 原价(划线价) |
| | | */ |
| | | public void setPrice(BigDecimal price) { |
| | | this.price = price; |
| | | } |
| | | |
| | | /** |
| | | * 获取包邮价 |
| | | * |
| | | * @return free_shipping_price - 包邮价 |
| | | */ |
| | | public BigDecimal getFreeShippingPrice() { |
| | | return freeShippingPrice; |
| | | } |
| | | |
| | | /** |
| | | * 设置包邮价 |
| | | * |
| | | * @param freeShippingPrice 包邮价 |
| | | */ |
| | | public void setFreeShippingPrice(BigDecimal freeShippingPrice) { |
| | | this.freeShippingPrice = freeShippingPrice; |
| | | } |
| | | |
| | | /** |
| | | * 获取拼单价 |
| | | * |
| | | * @return collate_price - 拼单价 |
| | | */ |
| | | public BigDecimal getCollatePrice() { |
| | | return collatePrice; |
| | | } |
| | | |
| | | /** |
| | | * 设置拼单价 |
| | | * |
| | | * @param collatePrice 拼单价 |
| | | */ |
| | | public void setCollatePrice(BigDecimal collatePrice) { |
| | | this.collatePrice = collatePrice; |
| | | } |
| | | |
| | | /** |
| | | * 获取商品名称 |
| | | * |
| | | * @return goods_name - 商品名称 |
| | | */ |
| | | public String getGoodsName() { |
| | | return goodsName; |
| | | } |
| | | |
| | | /** |
| | | * 设置商品名称 |
| | | * |
| | | * @param goodsName 商品名称 |
| | | */ |
| | | public void setGoodsName(String goodsName) { |
| | | this.goodsName = goodsName; |
| | | } |
| | | |
| | | /** |
| | | * 获取创建时间 |
| | | * |
| | | * @return create_at - 创建时间 |
| | | */ |
| | | public Date getCreateAt() { |
| | | return createAt; |
| | | } |
| | | |
| | | /** |
| | | * 设置创建时间 |
| | | * |
| | | * @param createAt 创建时间 |
| | | */ |
| | | public void setCreateAt(Date createAt) { |
| | | this.createAt = createAt; |
| | | } |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.model.dos; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @ClassName: ComShopFlowerOrderOperate |
| | | * @Author: yh |
| | | * @Date: 2022/11/9 16:46 |
| | | * @Description: 花城订单操作记录表 |
| | | */ |
| | | @TableName(value = "com_shop_flower_order_operate") |
| | | @Data |
| | | public class ComShopFlowerOrderOperateDO implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | /** |
| | | * ,主键 |
| | | */ |
| | | @TableId(type = IdType.ASSIGN_ID) |
| | | private Long id; |
| | | |
| | | /** |
| | | * 订单号 |
| | | */ |
| | | @TableField(value = "order_no") |
| | | private String orderNo; |
| | | |
| | | /** |
| | | * 操作人 |
| | | */ |
| | | @TableField(value = "operation_by") |
| | | private String operationBy; |
| | | |
| | | /** |
| | | * 操作时间 |
| | | */ |
| | | @TableField(value = "operation_time") |
| | | private Date operationTime; |
| | | |
| | | /** |
| | | * 操作类型(1.创建订单 2.取消订单 3.订单支付 4.订单发货 5.订单完成) |
| | | */ |
| | | @TableField(value = "operation_type") |
| | | private Integer operationType; |
| | | |
| | | /** |
| | | * 操作内容 |
| | | */ |
| | | @TableField(value = "operation_content") |
| | | private String operationContent; |
| | | |
| | | /** |
| | | * 创建时间 |
| | | */ |
| | | @TableField(value = "create_at",fill = FieldFill.INSERT) |
| | | private Date createAt; |
| | | |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.model.dos; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | import java.math.BigDecimal; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @ClassName: ComShopFlowerOrderPay |
| | | * @Author: yh |
| | | * @Date: 2022/11/9 16:46 |
| | | * @Description: 花城订单支付记录表 |
| | | */ |
| | | @TableName(value = "com_shop_flower_order_pay") |
| | | @Data |
| | | public class ComShopFlowerOrderPayDO implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | /** |
| | | * 主键id |
| | | */ |
| | | @TableId(type = IdType.ASSIGN_ID) |
| | | private Long id; |
| | | |
| | | /** |
| | | * 订单号 |
| | | */ |
| | | @TableField(value = "order_no") |
| | | private String orderNo; |
| | | |
| | | /** |
| | | * 支付单号 |
| | | */ |
| | | @TableField(value = "pay_no") |
| | | private String payNo; |
| | | |
| | | /** |
| | | * 微信交易号 |
| | | */ |
| | | @TableField(value = "wx_trade_no") |
| | | private String wxTradeNo; |
| | | |
| | | /** |
| | | * 支付状态(1.未支付 2.已支付) |
| | | */ |
| | | @TableField(value = "pay_status") |
| | | private Integer payStatus; |
| | | |
| | | /** |
| | | * 订单金额 |
| | | */ |
| | | @TableField(value = "order_amount") |
| | | private BigDecimal orderAmount; |
| | | |
| | | /** |
| | | * 支付金额 |
| | | */ |
| | | @TableField(value = "pay_amount") |
| | | private BigDecimal payAmount; |
| | | |
| | | /** |
| | | * 支付时间 |
| | | */ |
| | | @TableField(value = "pay_time") |
| | | private Date payTime; |
| | | |
| | | /** |
| | | * 创建时间 |
| | | */ |
| | | @TableField(value = "create_at",fill = FieldFill.INSERT) |
| | | private Date createAt; |
| | | |
| | | /** |
| | | * 修改时间 |
| | | */ |
| | | @TableField(value = "update_at",fill = FieldFill.UPDATE) |
| | | private Date updateAt; |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.model.dos; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | import java.math.BigDecimal; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @ClassName: ComShopFlowerRefundOrder |
| | | * @Author: yh |
| | | * @Date: 2022/11/9 16:46 |
| | | * @Description: 花城退款订单表 |
| | | */ |
| | | @TableName(value = "com_shop_flower_refund_order") |
| | | @Data |
| | | public class ComShopFlowerRefundOrderDO implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | /** |
| | | * 订单id |
| | | */ |
| | | @TableId(type = IdType.ASSIGN_ID) |
| | | private Long id; |
| | | |
| | | /** |
| | | * 店铺id |
| | | */ |
| | | @TableField(value = "store_id") |
| | | private Long storeId; |
| | | |
| | | /** |
| | | * 用户id |
| | | */ |
| | | @TableField(value = "user_id") |
| | | private Long userId; |
| | | |
| | | /** |
| | | * 原始订单号 |
| | | */ |
| | | @TableField(value = "order_no") |
| | | private String orderNo; |
| | | |
| | | /** |
| | | * 原始订单id |
| | | */ |
| | | @TableField(value = "order_id") |
| | | private String orderId; |
| | | |
| | | /** |
| | | * 退款订单号 |
| | | */ |
| | | @TableField(value = "refund_order_no") |
| | | private String refundOrderNo; |
| | | |
| | | /** |
| | | * 订单状态(1.处理中 2.退款成功 3.退款失败 4.已取消 5.退款中) |
| | | */ |
| | | @TableField(value = "status") |
| | | private Integer status; |
| | | |
| | | /** |
| | | * 删除状态(1.未删除 2.已删除) |
| | | */ |
| | | @TableField(value = "delete_status") |
| | | private Integer deleteStatus; |
| | | |
| | | /** |
| | | * 支付总金额 |
| | | */ |
| | | @TableField(value = "pay_amount") |
| | | private BigDecimal payAmount; |
| | | |
| | | /** |
| | | * 申请退款金额 |
| | | */ |
| | | @TableField(value = "refund_amount") |
| | | private BigDecimal refundAmount; |
| | | |
| | | /** |
| | | * 退款原因 |
| | | */ |
| | | @TableField(value = "refund_reason") |
| | | private String refundReason; |
| | | |
| | | /** |
| | | * 退款照片 |
| | | */ |
| | | @TableField(value = "refund_pic") |
| | | private String refundPic; |
| | | |
| | | /** |
| | | * 申请时间 |
| | | */ |
| | | @TableField(value = "create_at",fill = FieldFill.INSERT) |
| | | private Date createAt; |
| | | |
| | | /** |
| | | * 修改时间 |
| | | */ |
| | | @TableField(value = "update_at") |
| | | private Date updateAt; |
| | | |
| | | /** |
| | | * 处理时间 |
| | | */ |
| | | @TableField(value = "handle_time") |
| | | private Date handleTime; |
| | | |
| | | /** |
| | | * 退款时间 |
| | | */ |
| | | @TableField(value = "refund_time") |
| | | private Date refundTime; |
| | | |
| | | /** |
| | | * 处理结果 |
| | | */ |
| | | @TableField(value = "handle_result") |
| | | private String handleResult; |
| | | |
| | | /** |
| | | * 商家备注 |
| | | */ |
| | | @TableField(value = "remark") |
| | | private String remark; |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.model.dos; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @ClassName: ComShopFlowerUserAddress |
| | | * @Author: yh |
| | | * @Date: 2022/11/9 16:46 |
| | | * @Description: 花城用户收货地址表 |
| | | */ |
| | | @TableName(value = "com_shop_flower_user_address") |
| | | @Data |
| | | public class ComShopFlowerUserAddressDO implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | /** |
| | | * ,主键 |
| | | */ |
| | | @TableId(type = IdType.ASSIGN_ID) |
| | | private Long id; |
| | | |
| | | /** |
| | | * 用户id |
| | | */ |
| | | @TableField(value = "user_id") |
| | | private Long userId; |
| | | |
| | | /** |
| | | * 收货人名称 |
| | | */ |
| | | @TableField(value = "name") |
| | | private String name; |
| | | |
| | | /** |
| | | * 收货人手机号 |
| | | */ |
| | | @TableField(value = "phone") |
| | | private String phone; |
| | | |
| | | /** |
| | | * 收货人省份编码 |
| | | */ |
| | | @TableField(value = "province_code") |
| | | private String provinceCode; |
| | | |
| | | /** |
| | | * 收货人省份名称 |
| | | */ |
| | | @TableField(value = "province_name") |
| | | private String provinceName; |
| | | |
| | | /** |
| | | * 收货人城市编码 |
| | | */ |
| | | @TableField(value = "city_code") |
| | | private String cityCode; |
| | | |
| | | /** |
| | | * 收货人城市名称 |
| | | */ |
| | | @TableField(value = "city_name") |
| | | private String cityName; |
| | | |
| | | /** |
| | | * 收货人区县编码 |
| | | */ |
| | | @TableField(value = "district_code") |
| | | private String districtCode; |
| | | |
| | | /** |
| | | * 收货人区县名称 |
| | | */ |
| | | @TableField(value = "district_name") |
| | | private String districtName; |
| | | |
| | | /** |
| | | * 收货人详细地址 |
| | | */ |
| | | @TableField(value = "detail_address") |
| | | private String detailAddress; |
| | | |
| | | /** |
| | | * 是否是默认地址(1.是 2.否) |
| | | */ |
| | | @TableField(value = "is_default") |
| | | private Integer isDefault; |
| | | |
| | | /** |
| | | * 创建时间 |
| | | */ |
| | | @TableField(value = "create_at",fill = FieldFill.INSERT) |
| | | private Date createAt; |
| | | |
| | | /** |
| | | * 修改时间 |
| | | */ |
| | | @TableField(value = "update_at",fill = FieldFill.UPDATE) |
| | | private Date updateAt; |
| | | |
| | | /** |
| | | * 是否已删除(1.是 2.否) |
| | | */ |
| | | @TableField(value = "delete_status") |
| | | private Integer deleteStatus; |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.model.dos; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @ClassName: ConvenientElevatingPoint |
| | | * @Author: yh |
| | | * @Date: 2022/11/8 9:27 |
| | | * @Description: 自提点 |
| | | */ |
| | | @Data |
| | | @TableName(value = "com_convenient_elevating_point") |
| | | public class ConvenientElevatingPointDO implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 主键id |
| | | */ |
| | | @TableId(type = IdType.ASSIGN_ID) |
| | | private Long id; |
| | | /** |
| | | * 自提点名称 |
| | | */ |
| | | private String name; |
| | | /** |
| | | * 社区id |
| | | */ |
| | | private String communityId; |
| | | /** |
| | | * 社区名称 |
| | | */ |
| | | private String communityName; |
| | | /** |
| | | * 提货点地址 |
| | | */ |
| | | private String address; |
| | | /** |
| | | * 联系人 |
| | | */ |
| | | private String contacts; |
| | | /** |
| | | * 纬度 |
| | | */ |
| | | private String lat; |
| | | /** |
| | | * 经度 |
| | | */ |
| | | private String lon; |
| | | /** |
| | | * 联系电话 |
| | | */ |
| | | private String phone; |
| | | /** |
| | | * 微信账号 |
| | | */ |
| | | private String wechatAccount; |
| | | /** |
| | | * 状态,1:显示,2:隐藏 |
| | | */ |
| | | private Integer businessStatus; |
| | | /** |
| | | * 累计商品数量 |
| | | */ |
| | | private Long cumulativeGoodsNum; |
| | | /** |
| | | * 待提货数量 |
| | | */ |
| | | private Long prepareGoodsNum; |
| | | /** |
| | | * 已提货数量 |
| | | */ |
| | | private Long alreadyGoodsNum; |
| | | /** |
| | | * 是否删除 |
| | | */ |
| | | private Boolean isDel; |
| | | /** |
| | | * 创建时间 |
| | | */ |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Date createdAt; |
| | | |
| | | /** |
| | | * 创建人 |
| | | */ |
| | | private Long createdBy; |
| | | /** |
| | | * 更新时间 |
| | | */ |
| | | @TableField(fill = FieldFill.UPDATE) |
| | | private Date updatedAt; |
| | | /** |
| | | * 更新人 |
| | | */ |
| | | private Long updatedBy; |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.model.dos; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @title: ConvenientGoodsCategoryDO |
| | | * @projectName: 成都呐喊信息技术有限公司-智慧社区项目 |
| | | * @description: 商品分类DO |
| | | * @author: yh |
| | | * @date: 2022-10-21 09:36:09 |
| | | */ |
| | | @Data |
| | | @TableName(value = "com_convenient_goods_categories") |
| | | public class ConvenientGoodsCategoryDO implements Serializable { |
| | | |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 主键id |
| | | */ |
| | | @TableId(type = IdType.ASSIGN_ID) |
| | | private Long id; |
| | | /** |
| | | * 分类名称 |
| | | */ |
| | | private String name; |
| | | /** |
| | | * 分类图标 |
| | | */ |
| | | private String icon; |
| | | /** |
| | | * 备注 |
| | | */ |
| | | private String remark; |
| | | /** |
| | | * 权重 |
| | | */ |
| | | private Integer weight; |
| | | /** |
| | | * 是否删除 |
| | | */ |
| | | 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; |
| | | } |
| | |
| | | package com.panzhihua.service_community.model.dos; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @title: ConvenientMerchantDO |
| | |
| | | /** |
| | | * 创建时间 |
| | | */ |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Date createdAt; |
| | | |
| | | /** |
| | | * 创建人 |
| | | */ |
| | |
| | | /** |
| | | * 更新时间 |
| | | */ |
| | | @TableField(fill = FieldFill.UPDATE) |
| | | private Date updatedAt; |
| | | /** |
| | | * 更新人 |
| | |
| | | private Long updatedBy; |
| | | |
| | | private String areaCode; |
| | | |
| | | /** |
| | | * 服务范围 |
| | | */ |
| | | private Integer serviceRange; |
| | | } |
| | |
| | | * @return ComActDiscussVO |
| | | */ |
| | | R detailDiscuss(ComActDiscussDetailDTO discussDetailDTO); |
| | | /** |
| | | * 议事投票-详情 脱敏 |
| | | * |
| | | * @param discussDetailDTO |
| | | * 请求参数 |
| | | * @return ComActDiscussVO |
| | | */ |
| | | R detailDiscussDesensitize(ComActDiscussDetailDTO discussDetailDTO); |
| | | |
| | | /** |
| | | * 议事投票-删除 |
| | |
| | | * @return ComActDiscussVO 分页 |
| | | */ |
| | | R pageDiscussApplets(PageComActDiscussDTO pageComActDiscussDTO); |
| | | /** |
| | | * 议事投票-分页查询 小程序 脱敏 |
| | | * |
| | | * @param pageComActDiscussDTO |
| | | * 查询参数 |
| | | * @return ComActDiscussVO 分页 |
| | | */ |
| | | R pageDiscussAppletsDesensitize(PageComActDiscussDTO pageComActDiscussDTO); |
| | | |
| | | /** |
| | | * 议事投票-点赞、取消点赞 |
| | |
| | | * @return ComActDiscussCommentVO |
| | | */ |
| | | R pageDiscussCommentApplets(PageComActDiscussCommentDTO pageComActDiscussCommentDTO); |
| | | /** |
| | | * 议事投票-评论-分页查询 小程序 脱敏 |
| | | * |
| | | * @param pageComActDiscussCommentDTO |
| | | * 分页参数 |
| | | * @return ComActDiscussCommentVO |
| | | */ |
| | | R pageDiscussCommentAppletsDesensitize(PageComActDiscussCommentDTO pageComActDiscussCommentDTO); |
| | | |
| | | /** |
| | | * 议事投票-详情 小程序 |
| | |
| | | * @return ComActDiscussVO |
| | | */ |
| | | R detailDiscussApplets(Long id, Long userId); |
| | | /** |
| | | * 议事投票-详情 小程序 |
| | | * |
| | | * @param id |
| | | * 主键 |
| | | * @param userId |
| | | * 用户主键 |
| | | * @return ComActDiscussVO |
| | | */ |
| | | R detailDiscussAppletsDesensitize(Long id, Long userId); |
| | | |
| | | /** |
| | | * 议事投票-投票 |
| | |
| | | * @return 详情内容 |
| | | */ |
| | | R detailEasyPhoto(Long id, Long userId); |
| | | /** |
| | | * 随手拍详情 - 脱敏 |
| | | * |
| | | * @param id |
| | | * 随手拍主键 |
| | | * @param userId |
| | | * 登录用户id |
| | | * @return 详情内容 |
| | | */ |
| | | R detailEasyPhotoDesensitize(Long id, Long userId); |
| | | |
| | | /** |
| | | * 上传随手拍 |
| | |
| | | R pageEasyPhotoApplets(ComActEasyPhotoVO comActEasyPhotoVO); |
| | | |
| | | /** |
| | | * 小程序分页查询随手拍 |
| | | * |
| | | * @param comActEasyPhotoVO |
| | | * 查询参数 |
| | | * @return 返回结果 |
| | | */ |
| | | R pageEasyPhotoAppletsDesensitize(ComActEasyPhotoVO comActEasyPhotoVO); |
| | | |
| | | /** |
| | | * 随手拍评论分页查询 |
| | | * |
| | | * @param pageComActEasyPhotoCommentDTO |
| | |
| | | * @return 查询结果 |
| | | */ |
| | | R pageComActEasyPhotoComment(PageComActEasyPhotoCommentDTO pageComActEasyPhotoCommentDTO); |
| | | /** |
| | | * 随手拍评论分页查询 - 脱敏 |
| | | * |
| | | * @param pageComActEasyPhotoCommentDTO |
| | | * 查询参数 |
| | | * @return 查询结果 |
| | | */ |
| | | R pageComActEasyPhotoCommentDesensitize(PageComActEasyPhotoCommentDTO pageComActEasyPhotoCommentDTO); |
| | | |
| | | |
| | | /** |
| | | * 评论点赞/取消点赞 |
| | |
| | | * @return |
| | | */ |
| | | R addEasyPhotoFeedbackForDpc(ComActEasyPhotoVO comActEasyPhotoVO); |
| | | |
| | | /** |
| | | * 获取社区置顶动态banner |
| | | * */ |
| | | R getUserRewardNew(Long userId, Long communityId); |
| | | } |
| | |
| | | |
| | | R pageMicroWishApplets(ComActMicroWishVO comActMicroWishVO); |
| | | |
| | | R pageMicroWishAppletsDesensitize(ComActMicroWishVO comActMicroWishVO); |
| | | |
| | | /** |
| | | * 心愿详情 |
| | | * |
| | |
| | | R detailMicroWish(Long id, Long userId); |
| | | |
| | | /** |
| | | * 心愿详情 - 脱敏 |
| | | * |
| | | * @param id |
| | | * 查询主键 |
| | | * @param userId |
| | | * 登录用户id |
| | | * @return 心愿内容 |
| | | */ |
| | | R detailMicroWishDesensitize(Long id, Long userId); |
| | | |
| | | /** |
| | | * 审核、分配、反馈心愿 |
| | | * |
| | | * @param comActMicroWishVO |
New file |
| | |
| | | package com.panzhihua.service_community.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.panzhihua.common.model.dtos.community.ComActProceedingsDTO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.service_community.entity.ComActAcidDangerMember; |
| | | import com.panzhihua.service_community.entity.ComActProceedings; |
| | | |
| | | public interface ComActProceedingsService extends IService<ComActProceedings> { |
| | | |
| | | /** |
| | | * 分页查询议事委员会 |
| | | * @param keyWord 搜索关键字 |
| | | * @return 处理结果 |
| | | * */ |
| | | R pageProceedings(Integer page, Integer size, String keyWord); |
| | | |
| | | /** |
| | | * 新增或修改议事委员会 |
| | | * @param comActProceedingsDTO |
| | | * @return 处理结果 |
| | | * */ |
| | | R addOrUpdate(ComActProceedingsDTO comActProceedingsDTO); |
| | | } |
| | |
| | | * @return |
| | | */ |
| | | R detailProperty(Long id); |
| | | |
| | | /** |
| | | * 物业公司通知公告列表 |
| | | * @param propertyId 物业公司Id |
| | | * */ |
| | | R noticeList(Integer page, Integer size, Long propertyId); |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.panzhihua.service_community.model.dos.ComShopFlowerGoodsAttrDO; |
| | | |
| | | /** |
| | | * @ClassName: ComShopFlowerGoodsAttrService |
| | | * @Author: yh |
| | | * @Date: 2022/11/8 17:19 |
| | | * @Description: 商品规格 |
| | | */ |
| | | public interface ComShopFlowerGoodsAttrService extends IService<ComShopFlowerGoodsAttrDO> { |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.panzhihua.common.model.dtos.shop.ComShopFlowerGoodsDTO; |
| | | import com.panzhihua.common.model.dtos.shop.ComShopGoodsDTO; |
| | | import com.panzhihua.common.model.dtos.shop.PageComShopFlowerGoodsDTO; |
| | | import com.panzhihua.common.model.dtos.shop.PageComShopGoodsDTO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.shop.AddShopFlowerGoodsVO; |
| | | import com.panzhihua.common.model.vos.shop.AddShopGoodsVO; |
| | | import com.panzhihua.service_community.model.dos.ComShopFlowerGoodsDO; |
| | | |
| | | /** |
| | | * @ClassName: ComShopFlowerGoodsService |
| | | * @Author: yh |
| | | * @Date: 2022/11/8 17:16 |
| | | * @Description: 商品 |
| | | */ |
| | | public interface ComShopFlowerGoodsService extends IService<ComShopFlowerGoodsDO> { |
| | | |
| | | /** |
| | | * 添加商品 |
| | | * |
| | | * @param addShopFlowerGoodsVO |
| | | * @return |
| | | */ |
| | | R saveShopFlowerGoods(AddShopFlowerGoodsVO addShopFlowerGoodsVO); |
| | | |
| | | |
| | | /** |
| | | * 商品列表-分页查询 |
| | | * |
| | | * @param pageComShopFlowerGoodsDTO |
| | | * 查询参数 |
| | | * @return PageShopStoreVO |
| | | */ |
| | | R pageFlowerGoodsList(PageComShopFlowerGoodsDTO pageComShopFlowerGoodsDTO); |
| | | |
| | | /** |
| | | * 分页查询商品列表 |
| | | * |
| | | * @param comShopFlowerGoodsDTO |
| | | * 请求参数 |
| | | * @return 商品列表 |
| | | */ |
| | | R pageShopFlowerGoodsByApp(ComShopFlowerGoodsDTO comShopFlowerGoodsDTO); |
| | | |
| | | /** |
| | | * 根据商品id查询商品信息 |
| | | * |
| | | * @param goodsId |
| | | * 商品id |
| | | * @return 商品信息 |
| | | */ |
| | | R shopFlowerGoodsDetail(Long goodsId); |
| | | |
| | | /** |
| | | * 编辑商品 |
| | | * |
| | | * @param id |
| | | * 商铺ID |
| | | * @param addShopFlowerGoodsVO |
| | | * @return |
| | | */ |
| | | R editFlowerShopGoods(Long id, AddShopFlowerGoodsVO addShopFlowerGoodsVO); |
| | | |
| | | /** |
| | | * 删除商品 |
| | | * |
| | | * @param id |
| | | * @return |
| | | */ |
| | | R deleteShopFlowerGoods(Long[] id); |
| | | |
| | | /** |
| | | * 修改商品状态 |
| | | * |
| | | * @param id |
| | | * @return |
| | | */ |
| | | R changeStatus(Long id, Integer status); |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.panzhihua.common.model.dtos.community.convenient.ConvenientElevatingPointDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageConvenientElevatingPointDTO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.service_community.model.dos.ConvenientElevatingPointDO; |
| | | |
| | | /** |
| | | * @ClassName: ConvenientElevatingPointService |
| | | * @Author: yh |
| | | * @Date: 2022/11/8 10:32 |
| | | * @Description: 自提点 |
| | | */ |
| | | public interface ConvenientElevatingPointService extends IService<ConvenientElevatingPointDO> { |
| | | /** |
| | | * 分页查询自提点 |
| | | * |
| | | * @param pageConvenientElevatingPointDTO |
| | | * @return |
| | | */ |
| | | R pagePoint(PageConvenientElevatingPointDTO pageConvenientElevatingPointDTO); |
| | | |
| | | /** |
| | | * 新增 |
| | | * @param convenientElevatingPointDTO |
| | | * @return |
| | | */ |
| | | R addPoint(ConvenientElevatingPointDTO convenientElevatingPointDTO); |
| | | |
| | | /** |
| | | * 修改 |
| | | * @param convenientElevatingPointDTO |
| | | * @return |
| | | */ |
| | | R putPoint(ConvenientElevatingPointDTO convenientElevatingPointDTO); |
| | | |
| | | /** |
| | | * 删除 |
| | | * @param pointId |
| | | * @param operator |
| | | * @return |
| | | */ |
| | | R deletePoint(Long pointId, Long operator); |
| | | |
| | | /** |
| | | * 详情 |
| | | * @param pointId |
| | | * @return |
| | | */ |
| | | R detailPoint(Long pointId); |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.panzhihua.common.model.dtos.community.convenient.ConvenientGoodsCategoryDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageConvenientGoodsCategoryDTO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.service_community.model.dos.ConvenientGoodsCategoryDO; |
| | | |
| | | /** |
| | | * @title: ConvenientGoodsCategoryService |
| | | * @projectName: 成都呐喊信息技术有限公司-智慧社区项目 |
| | | * @description: 便民服务分类服务类 |
| | | * @author: hans |
| | | * @date: 2021/09/16 10:31 |
| | | */ |
| | | public interface ConvenientGoodsCategoryService extends IService<ConvenientGoodsCategoryDO> { |
| | | /** |
| | | * 便民服务新增分类 |
| | | * |
| | | * @param convenientGoodsCategoryDTO |
| | | * @return 新增结果 |
| | | */ |
| | | R addGoodsCategory(ConvenientGoodsCategoryDTO convenientGoodsCategoryDTO); |
| | | |
| | | /** |
| | | * 便民服务分类编辑 |
| | | * |
| | | * @param convenientGoodsCategoryDTO |
| | | * @return 修改结果 |
| | | */ |
| | | R putGoodsCategory(ConvenientGoodsCategoryDTO convenientGoodsCategoryDTO); |
| | | |
| | | /** |
| | | * 便民服务分类删除 |
| | | * |
| | | * @param categoryId 便民服务分类id |
| | | * @param operator 操作人员 |
| | | * @return 删除结果 |
| | | */ |
| | | R deleteGoodsCategoryById(Long categoryId, Long operator); |
| | | |
| | | /** |
| | | * 获取便民服务分类详情 |
| | | * |
| | | * @param categoryId 便民服务分类id |
| | | * @return 分类详情 |
| | | */ |
| | | R getGoodsCategoryById(Long categoryId); |
| | | |
| | | /** |
| | | * 分页查询便民服务分类 |
| | | * |
| | | * @param pageConvenientGoodsCategoryDTO |
| | | * @return 分类详情 |
| | | */ |
| | | R pageGoodsCategory(PageConvenientGoodsCategoryDTO pageConvenientGoodsCategoryDTO); |
| | | |
| | | /** |
| | | * 获取所有便民服务分类 |
| | | * |
| | | * @return |
| | | */ |
| | | R getAllGoodsCategories(String areaCode); |
| | | |
| | | /** |
| | | * 获取该社区商家数量大于0的分类 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | } |
| | |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | import cn.binarywang.wx.miniapp.api.WxMaService; |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import com.panzhihua.common.constants.HttpStatus; |
| | | import com.panzhihua.common.model.dtos.community.ActivityInviteDTO; |
| | |
| | | import com.panzhihua.service_community.entity.ComActActivityInvite; |
| | | import com.panzhihua.service_community.model.dos.ComActNeighborCircleTopicWestDO; |
| | | import com.panzhihua.service_community.service.ComActActivityInviteService; |
| | | import com.panzhihua.service_community.util.WxMaConfiguration; |
| | | import org.apache.commons.lang3.time.DateUtils; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.data.redis.core.StringRedisTemplate; |
| | |
| | | private ComActActivityInviteService comActActivityInviteService; |
| | | @Resource |
| | | private ComActNeighborCircleDAO comActNeighborCircleDAO; |
| | | @Resource |
| | | private WxMaConfiguration wxMaConfiguration; |
| | | |
| | | /** |
| | | * 新增社区活动 |
| | |
| | | List<ActivitySignVO> activitySignVOS = comActActSignDAO.listActivitySigns(activitySignVO); |
| | | if (!activitySignVOS.isEmpty()) { |
| | | try { |
| | | WxXCXTempSend util = new WxXCXTempSend(); |
| | | String accessToken = util.getAccessToken(); |
| | | WxMaService maService = wxMaConfiguration.getMaService("wx118de8a734d269f0"); |
| | | String accessToken = maService.getAccessToken(); |
| | | ComActDO comActDO=comActDAO.selectById(comActActivityDO.getCommunityId()); |
| | | R<SysTemplateConfigVO> r=userService.selectTemplate(comActDO.getAreaCode(),1); |
| | | activitySignVOS.forEach(activitySignVO1 -> { |
| | |
| | | // log.info("定时任务--修改社区活动报名状态活动数量【{}】", num1); |
| | | // 查询已经结束的活动,需要计算积分 |
| | | List<Long> activityEndIds = comActActivityDAO.selectBeginIds(); |
| | | WxMaService maService = wxMaConfiguration.getMaService("wx118de8a734d269f0"); |
| | | if(!CollectionUtils.isEmpty(activityEndIds)){ |
| | | activityEndIds.forEach(activityId->{ |
| | | List<String> openIds=comActActivityDAO.selectOpenIdByActivityId(activityId); |
| | |
| | | openIds.forEach(op->{ |
| | | WxXCXTempSend wxXCXTempSend=new WxXCXTempSend(); |
| | | try { |
| | | WxUtil.sendLongTimeTemplate(op,wxXCXTempSend.getAccessToken("wx118de8a734d269f0"),"活动开始提醒","您参加的活动已开始","packageC/pages/activity/communityActivityDetails/communityActivityDetails?id="+activityId); |
| | | WxUtil.sendLongTimeTemplate(op,maService.getAccessToken(),"活动开始提醒","您参加的活动已开始","packageC/pages/activity/communityActivityDetails/communityActivityDetails?id="+activityId); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | } |
| | |
| | | openIds.forEach(op->{ |
| | | WxXCXTempSend wxXCXTempSend=new WxXCXTempSend(); |
| | | try { |
| | | WxUtil.sendLongTimeTemplate(op,wxXCXTempSend.getAccessToken("wx118de8a734d269f0"),"活动结束提醒","您参加的活动已结束","packageC/pages/activity/communityActivityDetails/communityActivityDetails?id="+id); |
| | | WxUtil.sendLongTimeTemplate(op,maService.getAccessToken(),"活动结束提醒","您参加的活动已结束","packageC/pages/activity/communityActivityDetails/communityActivityDetails?id="+id); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | } |
| | |
| | | .lambda().le(ComActActivityDO::getBeginAt, DateUtils.addDays(new Date(), 1)) |
| | | .ge(ComActActivityDO::getBeginAt, new Date()).notIn(ComActActivityDO::getStatus,5,6)); |
| | | if (!actActivityList.isEmpty()) { |
| | | WxXCXTempSend util = new WxXCXTempSend(); |
| | | WxMaService maService = wxMaConfiguration.getMaService("wx118de8a734d269f0"); |
| | | try { |
| | | String accessToken = util.getAccessToken(); |
| | | String accessToken = maService.getAccessToken(); |
| | | actActivityList.forEach(actActivity -> { |
| | | ComActDO comActDO=comActDAO.selectById(actActivity.getCommunityId()); |
| | | R<SysTemplateConfigVO> r=userService.selectTemplate(comActDO.getAreaCode(),9); |
| | |
| | | import javax.annotation.Resource; |
| | | import javax.validation.constraints.NotEmpty; |
| | | |
| | | import cn.hutool.core.util.DesensitizedUtil; |
| | | import com.panzhihua.common.model.dtos.community.ComActDiscussVoteOptionDTO; |
| | | import com.panzhihua.common.model.dtos.community.DiscussVoteOptionDTO; |
| | | import com.panzhihua.common.model.dtos.community.PageVoteSituationDTO; |
| | |
| | | Long userId = comActDiscussDO.getUserId(); |
| | | LoginUserInfoVO loginUserInfoVO = comActDiscussDAO.selectUserByUserId(userId); |
| | | comActDiscussVO.setUserName(loginUserInfoVO.getName()); |
| | | comActDiscussVO.setUserNickName(loginUserInfoVO.getNickName()); |
| | | comActDiscussVO.setImageUrl(loginUserInfoVO.getImageUrl()); |
| | | |
| | | //分页查询评论列表 |
| | | PageComActDiscussCommentDTO pageComActDiscussCommentDTO = new PageComActDiscussCommentDTO(); |
| | | BeanUtils.copyProperties(discussDetailDTO, pageComActDiscussCommentDTO); |
| | | IPage<ComActDiscussCommentVO> discussComments = comActDiscussDAO.pageDiscussCommentAdmin(new Page<>(pageComActDiscussCommentDTO.getPageNum(), pageComActDiscussCommentDTO.getPageSize()), pageComActDiscussCommentDTO); |
| | | discussComments.getRecords().forEach(comment -> { |
| | | if (comment.getReplyNum() > 0) { |
| | | List<ComActDiscussCommentVO> childList = comActDiscussDAO.getDiscussCommentReplyList(comment.getId()); |
| | | if (!childList.isEmpty()) { |
| | | comment.setComActDiscussCommentVOList(childList); |
| | | } |
| | | } |
| | | }); |
| | | comActDiscussVO.setDiscussCommentList(discussComments.getRecords()); |
| | | String viewNumKey = String.join("_", DISCUSS_VIEW_NUM_PREFIX, id.toString()); |
| | | if (stringRedisTemplate.hasKey(viewNumKey)) { |
| | | ValueOperations<String, String> opsForValue = stringRedisTemplate.opsForValue(); |
| | | comActDiscussVO.setViewsNum(Integer.parseInt(opsForValue.get(viewNumKey))); |
| | | } |
| | | return R.ok(comActDiscussVO); |
| | | } |
| | | |
| | | /** |
| | | * 议事投票-详情 脱敏 |
| | | * |
| | | * @param discussDetailDTO 请求参数 |
| | | * @return ComActDiscussVO |
| | | */ |
| | | @Override |
| | | public R detailDiscussDesensitize(ComActDiscussDetailDTO discussDetailDTO) { |
| | | Long id = discussDetailDTO.getId(); |
| | | ComActDiscussDO comActDiscussDO = comActDiscussDAO.selectById(id); |
| | | if (ObjectUtils.isEmpty(comActDiscussDO)) { |
| | | return R.fail("议事投票不存在"); |
| | | } |
| | | ComActDiscussVO comActDiscussVO = new ComActDiscussVO(); |
| | | BeanUtils.copyProperties(comActDiscussDO, comActDiscussVO); |
| | | comActDiscussVO.setSignNum(comActDiscussDO.getFabulousNum()); |
| | | Integer type = comActDiscussVO.getType(); |
| | | if (type.equals(ComActDiscussVO.type.tp)) { |
| | | //查询选项列表 |
| | | List<ComActDiscussOptionVO> comActDiscussOptionList = comActDiscussOptionDAO.getDiscussOptionList(id); |
| | | comActDiscussVO.setComActDiscussOptionVOS(comActDiscussOptionList); |
| | | } |
| | | Long userId = comActDiscussDO.getUserId(); |
| | | LoginUserInfoVO loginUserInfoVO = comActDiscussDAO.selectUserByUserId(userId); |
| | | comActDiscussVO.setUserName(DesensitizedUtil.chineseName(loginUserInfoVO.getName())); |
| | | comActDiscussVO.setUserNickName(loginUserInfoVO.getNickName()); |
| | | comActDiscussVO.setImageUrl(loginUserInfoVO.getImageUrl()); |
| | | |
| | |
| | | } |
| | | |
| | | /** |
| | | * 议事投票-分页查询 小程序 |
| | | * |
| | | * @param pageComActDiscussDTO 查询参数 |
| | | * @return ComActDiscussVO 分页 |
| | | */ |
| | | @Override |
| | | public R pageDiscussAppletsDesensitize(PageComActDiscussDTO pageComActDiscussDTO) { |
| | | Page page = new Page<>(); |
| | | Long pageNum = pageComActDiscussDTO.getPageNum(); |
| | | Long pageSize = pageComActDiscussDTO.getPageSize(); |
| | | Long loginUserId = pageComActDiscussDTO.getLoginUserId(); |
| | | if (null == pageNum || 0 == pageNum) { |
| | | pageNum = 1l; |
| | | } |
| | | if (null == pageSize || 0 == pageSize) { |
| | | pageSize = 10l; |
| | | } |
| | | page.setSize(pageSize); |
| | | page.setCurrent(pageNum); |
| | | pageComActDiscussDTO.setIsPbMember(0); |
| | | pageComActDiscussDTO.setIsVolunteer(0); |
| | | if (nonNull(loginUserId)) { |
| | | pageComActDiscussDTO.setIsPbMember(pbMemberDAO.checkIsPbMember(loginUserId) > 0 ? 1 : 0); |
| | | pageComActDiscussDTO.setIsVolunteer(pbMemberDAO.checkIsVolunteer(loginUserId) > 0 ? 1 : 0); |
| | | } |
| | | IPage<ComActDiscussVO> iPage = comActDiscussDAO.pageDiscussApplets(page, pageComActDiscussDTO); |
| | | List<ComActDiscussVO> records = iPage.getRecords(); |
| | | if (!ObjectUtils.isEmpty(records)) { |
| | | records.forEach(comActDiscussVO -> { |
| | | Integer type = comActDiscussVO.getType(); |
| | | Long id = comActDiscussVO.getId(); |
| | | String viewNumKey = String.join("_", DISCUSS_VIEW_NUM_PREFIX, id.toString()); |
| | | if (stringRedisTemplate.hasKey(viewNumKey)) { |
| | | ValueOperations<String, String> opsForValue = stringRedisTemplate.opsForValue(); |
| | | comActDiscussVO.setViewsNum(Integer.parseInt(opsForValue.get(viewNumKey))); |
| | | } |
| | | if (type.equals(2)) { |
| | | List<ComActDiscussOptionDO> comActDiscussOptionDOS = comActDiscussOptionDAO.selectList( |
| | | new QueryWrapper<ComActDiscussOptionDO>().lambda().eq(ComActDiscussOptionDO::getDiscussId, id)); |
| | | List<ComActDiscussOptionVO> comActDiscussOptionVOS = new ArrayList<>(); |
| | | List<Integer> votes = new ArrayList<>(); |
| | | comActDiscussOptionDOS.forEach(comActDiscussOptionDO -> { |
| | | Long discussOptionDOId = comActDiscussOptionDO.getId(); |
| | | Integer selectCount = |
| | | comActDiscussOptionUserDAO.selectCount(new QueryWrapper<ComActDiscussOptionUserDO>() |
| | | .lambda().eq(ComActDiscussOptionUserDO::getDiscussOptionId, discussOptionDOId)); |
| | | ComActDiscussOptionVO comActDiscussOptionVO = new ComActDiscussOptionVO(); |
| | | BeanUtils.copyProperties(comActDiscussOptionDO, comActDiscussOptionVO); |
| | | comActDiscussOptionVO.setNum(selectCount); |
| | | |
| | | if (loginUserId != null) { |
| | | // 判断选项是否已投票 |
| | | int haveVote = |
| | | comActDiscussOptionUserDAO.selectHaveVotes(comActDiscussOptionDO.getId(), loginUserId); |
| | | votes.add(haveVote); |
| | | comActDiscussOptionVO.setHaveVote(haveVote > 0 ? 1 : 0); |
| | | } |
| | | comActDiscussOptionVOS.add(comActDiscussOptionVO); |
| | | }); |
| | | fillThePercentAndSort(comActDiscussOptionVOS); |
| | | checkDiscussStatusIsCorrect(comActDiscussVO); |
| | | comActDiscussVO.setComActDiscussOptionVOS(comActDiscussOptionVOS); |
| | | //填充剩余可投票数 |
| | | if (loginUserId != null && !loginUserId.equals(0L)) { |
| | | if (comActDiscussVO.getIsRepeat().intValue() == 1) { |
| | | //可重复投票 |
| | | int votedVotesInToday = comActDiscussOptionUserDAO.selectVotedVotesInToday(id, loginUserId); |
| | | int remainingVotes = comActDiscussVO.getCount().intValue() - votedVotesInToday; |
| | | comActDiscussVO.setRemainingVotes(remainingVotes >= 0 ? remainingVotes : 0); |
| | | } else { |
| | | //不可重复投票 |
| | | int alreadyVotedVotes = votes.stream().mapToInt(Integer::intValue).sum(); |
| | | int remainingVotes = comActDiscussVO.getCount().intValue() - alreadyVotedVotes; |
| | | comActDiscussVO.setRemainingVotes(remainingVotes >= 0 ? remainingVotes : 0); |
| | | } |
| | | } |
| | | comActDiscussVO.setUserName(DesensitizedUtil.chineseName(comActDiscussVO.getUserName())); |
| | | //填充投票记录列表 |
| | | List<ComActDiscussOptionUserVO> comActDiscussOptionUserVOList = comActDiscussOptionUserDAO |
| | | .selectVotedRecords(comActDiscussVO.getId()); |
| | | comActDiscussVO.setComActDiscussOptionUserVOList(comActDiscussOptionUserVOList); |
| | | //填充已参与投票人数 |
| | | int votedPersonNum = comActDiscussOptionUserDAO.selectVotedPersonNum(comActDiscussVO.getId()); |
| | | comActDiscussVO.setVotedPersonNum(votedPersonNum); |
| | | } |
| | | |
| | | if (loginUserId != null) { |
| | | Integer integer = comActDiscussUserDAO.selectCount(new QueryWrapper<ComActDiscussUserDO>().lambda() |
| | | .eq(ComActDiscussUserDO::getDiscussId, comActDiscussVO.getId()) |
| | | .eq(ComActDiscussUserDO::getUserId, loginUserId)); |
| | | if (integer > 0) { |
| | | comActDiscussVO.setHaveSign(1); |
| | | } else { |
| | | comActDiscussVO.setHaveSign(0); |
| | | } |
| | | // 判断是否已经投票 |
| | | int haveVote = comActDiscussOptionUserDAO.selectHaveVote(id, loginUserId); |
| | | comActDiscussVO.setHaveVote(haveVote > 0 ? 1 : 0); |
| | | } |
| | | }); |
| | | } |
| | | return R.ok(iPage); |
| | | } |
| | | |
| | | /** |
| | | * 判断discuss状态是否正确 |
| | | * @param comActDiscussVO |
| | | */ |
| | |
| | | return R.ok(iPage); |
| | | } |
| | | |
| | | /** |
| | | * 议事投票-评论-分页查询 小程序 |
| | | * |
| | | * @param pageComActDiscussCommentDTO 分页参数 |
| | | * @return ComActDiscussCommentVO |
| | | */ |
| | | @Override |
| | | public R pageDiscussCommentAppletsDesensitize(PageComActDiscussCommentDTO pageComActDiscussCommentDTO) { |
| | | Page page = new Page<>(); |
| | | Long pageNum = pageComActDiscussCommentDTO.getPageNum(); |
| | | Long pageSize = pageComActDiscussCommentDTO.getPageSize(); |
| | | if (null == pageNum || 0 == pageNum) { |
| | | pageNum = 1l; |
| | | } |
| | | if (null == pageSize || 0 == pageSize) { |
| | | pageSize = 10l; |
| | | } |
| | | page.setSize(pageSize); |
| | | page.setCurrent(pageNum); |
| | | IPage<ComActDiscussCommentVO> iPage = |
| | | comActDiscussDAO.pageDiscussCommentApplets(page, pageComActDiscussCommentDTO); |
| | | List<ComActDiscussCommentVO> records = iPage.getRecords(); |
| | | if (!ObjectUtils.isEmpty(records)) { |
| | | records.forEach(comActDiscussCommentVO -> { |
| | | List<ComActDiscussCommentVO> comActDiscussCommentVOList = new ArrayList<>(); |
| | | Long id = comActDiscussCommentVO.getId(); |
| | | comActDiscussCommentVO.setPhone(DesensitizedUtil.mobilePhone(comActDiscussCommentVO.getPhone())); |
| | | comActDiscussCommentVO.setUserName(DesensitizedUtil.chineseName(comActDiscussCommentVO.getUserName())); |
| | | comActDiscussCommentVO.setUserNameBack(DesensitizedUtil.chineseName(comActDiscussCommentVO.getUserNameBack())); |
| | | comActDiscussCommentVOList = comActDiscussCommentDAO.selectChilds(id); |
| | | if (!ObjectUtils.isEmpty(comActDiscussCommentVOList)) { |
| | | List<ComActDiscussCommentVO> comActDiscussCommentVOS = comActDiscussCommentVOList; |
| | | comActDiscussCommentVOList.forEach(comActDiscussCommentVO1 -> { |
| | | Long parentId = comActDiscussCommentVO1.getParentId(); |
| | | List<ComActDiscussCommentVO> collect = comActDiscussCommentVOS.stream() |
| | | .filter(comActDiscussCommentVO2 -> comActDiscussCommentVO2.getId().equals(parentId)) |
| | | .collect(Collectors.toList()); |
| | | if (!ObjectUtils.isEmpty(collect)) { |
| | | String userName = collect.get(0).getUserName(); |
| | | String userNickName = collect.get(0).getUserNickName(); |
| | | comActDiscussCommentVO1.setUserNameBack(userName); |
| | | comActDiscussCommentVO1.setUserNickNameBack(userNickName); |
| | | } |
| | | List<ComActDiscussCommentVO> collect1 = records.stream() |
| | | .filter(comActDiscussCommentVO2 -> comActDiscussCommentVO2.getId().equals(parentId)) |
| | | .collect(Collectors.toList()); |
| | | if (!ObjectUtils.isEmpty(collect1)) { |
| | | ComActDiscussCommentVO comActDiscussCommentVOFirst = collect1.get(0); |
| | | String userName = comActDiscussCommentVOFirst.getUserName(); |
| | | String userNickName = comActDiscussCommentVOFirst.getUserNickName(); |
| | | comActDiscussCommentVO1.setUserNameBack(userName); |
| | | comActDiscussCommentVO1.setUserNickNameBack(userNickName); |
| | | } |
| | | comActDiscussCommentVO1.setPhone(DesensitizedUtil.mobilePhone(comActDiscussCommentVO1.getPhone())); |
| | | comActDiscussCommentVO1.setUserName(DesensitizedUtil.chineseName(comActDiscussCommentVO1.getUserName())); |
| | | comActDiscussCommentVO1.setUserNameBack(DesensitizedUtil.chineseName(comActDiscussCommentVO1.getUserNameBack())); |
| | | if (pageComActDiscussCommentDTO.getLoginUserId() != null |
| | | && !pageComActDiscussCommentDTO.getLoginUserId().equals(0L)) { |
| | | Integer integer = comActDiscussCommentUserDAO |
| | | .selectCount(new QueryWrapper<ComActDiscussCommentUserDO>().lambda() |
| | | .eq(ComActDiscussCommentUserDO::getDisscussCommentId, |
| | | comActDiscussCommentVO1.getId()) |
| | | .eq(ComActDiscussCommentUserDO::getUserId, |
| | | pageComActDiscussCommentDTO.getLoginUserId())); |
| | | if (integer > 0) { |
| | | comActDiscussCommentVO1.setHaveSign(1); |
| | | } else { |
| | | comActDiscussCommentVO1.setHaveSign(0); |
| | | } |
| | | } |
| | | // if(StringUtils.isEmpty(comActDiscussCommentVO1.getUserNickNameBack())){ |
| | | // comActDiscussCommentVO1.setUserNickNameBack("社区管理员"); |
| | | // } |
| | | }); |
| | | comActDiscussCommentVO.setComActDiscussCommentVOList(comActDiscussCommentVOList); |
| | | } |
| | | if (pageComActDiscussCommentDTO.getLoginUserId() != null |
| | | && !pageComActDiscussCommentDTO.getLoginUserId().equals(0L)) { |
| | | Integer integer = |
| | | comActDiscussCommentUserDAO.selectCount(new QueryWrapper<ComActDiscussCommentUserDO>().lambda() |
| | | .eq(ComActDiscussCommentUserDO::getDisscussCommentId, comActDiscussCommentVO.getId()) |
| | | .eq(ComActDiscussCommentUserDO::getUserId, pageComActDiscussCommentDTO.getLoginUserId())); |
| | | if (integer > 0) { |
| | | comActDiscussCommentVO.setHaveSign(1); |
| | | } else { |
| | | comActDiscussCommentVO.setHaveSign(0); |
| | | } |
| | | } |
| | | |
| | | // 判断当前评论是否是社区管理员评论 |
| | | if (!comActDiscussCommentVO.getUserType().equals(1)) { |
| | | comActDiscussCommentVO.setUserNickName("社区管理员"); |
| | | } |
| | | }); |
| | | } |
| | | return R.ok(iPage); |
| | | } |
| | | |
| | | /** |
| | | * 议事投票-详情 小程序 |
| | | * |
| | |
| | | } |
| | | return R.ok(comActDiscussVO); |
| | | } |
| | | /** |
| | | * 议事投票-详情 小程序 脱敏 |
| | | * |
| | | * @param id 主键 |
| | | * @param loginUserId 登录用户主键 |
| | | * @return ComActDiscussVO |
| | | */ |
| | | @Override |
| | | public R detailDiscussAppletsDesensitize(Long id, Long loginUserId) { |
| | | ComActDiscussDO comActDiscussDO = comActDiscussDAO.selectById(id); |
| | | if (ObjectUtils.isEmpty(comActDiscussDO)) { |
| | | return R.fail("议事投票不存在"); |
| | | } |
| | | ComActDiscussVO comActDiscussVO = new ComActDiscussVO(); |
| | | BeanUtils.copyProperties(comActDiscussDO, comActDiscussVO); |
| | | comActDiscussVO.setSignNum(comActDiscussDO.getFabulousNum()); |
| | | Integer type = comActDiscussVO.getType(); |
| | | if (type.equals(2)) { |
| | | List<ComActDiscussOptionDO> comActDiscussOptionDOS = comActDiscussOptionDAO.selectList( |
| | | new QueryWrapper<ComActDiscussOptionDO>().lambda().eq(ComActDiscussOptionDO::getDiscussId, id)); |
| | | List<ComActDiscussOptionVO> comActDiscussOptionVOS = new ArrayList<>(); |
| | | ArrayList<Integer> votes = new ArrayList<>(); |
| | | comActDiscussOptionDOS.forEach(comActDiscussOptionDO -> { |
| | | Long discussOptionDOId = comActDiscussOptionDO.getId(); |
| | | Integer selectCount = |
| | | comActDiscussOptionUserDAO.selectCount(new QueryWrapper<ComActDiscussOptionUserDO>().lambda() |
| | | .eq(ComActDiscussOptionUserDO::getDiscussOptionId, discussOptionDOId)); |
| | | ComActDiscussOptionVO comActDiscussOptionVO = new ComActDiscussOptionVO(); |
| | | BeanUtils.copyProperties(comActDiscussOptionDO, comActDiscussOptionVO); |
| | | comActDiscussOptionVO.setNum(selectCount); |
| | | if (loginUserId != null && !loginUserId.equals(0L)) { |
| | | // 判断选项是否已投票 |
| | | int haveVote = |
| | | comActDiscussOptionUserDAO.selectHaveVotes(comActDiscussOptionDO.getId(), loginUserId); |
| | | votes.add(haveVote); |
| | | comActDiscussOptionVO.setHaveVote(haveVote > 0 ? 1 : 0); |
| | | } |
| | | comActDiscussOptionVOS.add(comActDiscussOptionVO); |
| | | }); |
| | | fillThePercentAndSort(comActDiscussOptionVOS); |
| | | comActDiscussVO.setComActDiscussOptionVOS(comActDiscussOptionVOS); |
| | | //填充剩余可投票数 |
| | | if (loginUserId != null && !loginUserId.equals(0L)) { |
| | | if (comActDiscussVO.getIsRepeat().intValue() == 1) { |
| | | //可重复投票 |
| | | int votedVotesInToday = comActDiscussOptionUserDAO.selectVotedVotesInToday(id, loginUserId); |
| | | int remainingVotes = comActDiscussVO.getCount().intValue() - votedVotesInToday; |
| | | comActDiscussVO.setRemainingVotes(remainingVotes >= 0 ? remainingVotes : 0); |
| | | } else { |
| | | //不可重复投票 |
| | | int alreadyVotedVotes = votes.stream().mapToInt(Integer::intValue).sum(); |
| | | int remainingVotes = comActDiscussVO.getCount().intValue() - alreadyVotedVotes; |
| | | comActDiscussVO.setRemainingVotes(remainingVotes >= 0 ? remainingVotes : 0); |
| | | } |
| | | } |
| | | checkDiscussStatusIsCorrect(comActDiscussVO); |
| | | //填充投票记录列表 |
| | | List<ComActDiscussOptionUserVO> comActDiscussOptionUserVOList = comActDiscussOptionUserDAO |
| | | .selectVotedRecords(comActDiscussVO.getId()); |
| | | comActDiscussVO.setComActDiscussOptionUserVOList(comActDiscussOptionUserVOList); |
| | | //填充已参与投票人数 |
| | | int votedPersonNum = comActDiscussOptionUserDAO.selectVotedPersonNum(comActDiscussVO.getId()); |
| | | comActDiscussVO.setVotedPersonNum(votedPersonNum); |
| | | } |
| | | Long userId = comActDiscussDO.getUserId(); |
| | | LoginUserInfoVO loginUserInfoVO = comActDiscussDAO.selectUserByUserId(userId); |
| | | if (loginUserInfoVO != null) { |
| | | comActDiscussVO.setUserName(DesensitizedUtil.chineseName(loginUserInfoVO.getName())); |
| | | if (StringUtils.isEmpty(loginUserInfoVO.getNickName())) { |
| | | comActDiscussVO.setUserNickName(DesensitizedUtil.chineseName(loginUserInfoVO.getName())); |
| | | } else { |
| | | comActDiscussVO.setUserNickName(loginUserInfoVO.getNickName()); |
| | | } |
| | | comActDiscussVO.setImageUrl(loginUserInfoVO.getImageUrl()); |
| | | comActDiscussVO.setUserType(loginUserInfoVO.getType()); |
| | | } |
| | | Long communityId = comActDiscussDO.getCommunityId(); |
| | | Integer type1 = loginUserInfoVO.getType(); |
| | | if (type1.intValue() > 1) { |
| | | ComActVO comActVO = comActDiscussDAO.selectCommunity(communityId); |
| | | comActDiscussVO.setUserName(comActVO.getName()); |
| | | comActDiscussVO.setUserNickName(comActVO.getName()); |
| | | } |
| | | if (loginUserId != null && !loginUserId.equals(0L)) { |
| | | ComActDiscussVO comActDiscussVO1 = comActDiscussDAO.selectHaveSignAndHaveVote(id, loginUserId); |
| | | comActDiscussVO.setHaveSign(comActDiscussVO1.getHaveSign()); |
| | | comActDiscussVO.setHaveVote(comActDiscussVO1.getHaveVote()); |
| | | } |
| | | String viewNumKey = String.join("_", DISCUSS_VIEW_NUM_PREFIX, id.toString()); |
| | | if (stringRedisTemplate.hasKey(viewNumKey)) { |
| | | ValueOperations opsForValue = stringRedisTemplate.opsForValue(); |
| | | int viewNum = Integer.parseInt((String) opsForValue.get(viewNumKey)); |
| | | comActDiscussVO.setViewsNum(viewNum); |
| | | } |
| | | return R.ok(comActDiscussVO); |
| | | } |
| | | |
| | | /** |
| | | * 计算投票占比以及排序 |
| | |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | import com.panzhihua.common.model.vos.community.DataCount; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.util.ObjectUtils; |
| | |
| | | } |
| | | comActDynDAO.updateById(comActDynDO); |
| | | } |
| | | return R.ok(comActDynVO); |
| | | return R.ok(); |
| | | } |
| | | |
| | | /** |
| | |
| | | return R.ok(iPage); |
| | | } |
| | | |
| | | |
| | | } |
| | |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.hutool.core.util.DesensitizedUtil; |
| | | import com.panzhihua.common.model.dtos.common.PageComActEasyPhotoEvaluateDto; |
| | | import com.panzhihua.common.model.vos.common.ComActEasyPhotoHandlerVo; |
| | | import com.panzhihua.common.model.vos.community.easyPhoto.BannerVO; |
| | |
| | | if (comActEasyPhotoVO.getActivityId() != null) { |
| | | ComActEasyPhotoActivityDO photoActivityDO = |
| | | comActEasyPhotoActivityMapper.selectById(comActEasyPhotoVO.getActivityId()); |
| | | if (photoActivityDO != null) { |
| | | ComActEasyPhotoActivityVO easyPhotoActivityVO = new ComActEasyPhotoActivityVO(); |
| | | BeanUtils.copyProperties(photoActivityDO, easyPhotoActivityVO); |
| | | comActEasyPhotoVO.setEasyPhotoActivityVO(easyPhotoActivityVO); |
| | | } |
| | | } |
| | | PageComActEasyPhotoEvaluateDto evaluateDto = new PageComActEasyPhotoEvaluateDto(); |
| | | evaluateDto.setServiceId(id); |
| | | evaluateDto.setServiceType(ComActEasyPhotoEvaluate.ServiceType.SSP); |
| | | comActEasyPhotoVO.setEvaluateList(comActEasyPhotoEvaluateMapper.queryAllByList(evaluateDto)); |
| | | return R.ok(comActEasyPhotoVO); |
| | | } |
| | | /** |
| | | * 随手拍详情 - 脱敏 |
| | | * |
| | | * @param id |
| | | * 随手拍主键 |
| | | * @param userId |
| | | * @return 详情内容 |
| | | */ |
| | | @Override |
| | | public R detailEasyPhotoDesensitize(Long id, Long userId) { |
| | | ComActEasyPhotoVO comActEasyPhotoVO = comActEasyPhotoDAO.detailEasyPhoto(id); |
| | | Integer status = comActEasyPhotoVO.getStatus(); |
| | | if (ObjectUtils.isEmpty(comActEasyPhotoVO) || null == status) { |
| | | return R.fail("随手拍不存在"); |
| | | } |
| | | if (!userId.equals(0L)) { |
| | | ComActEasyPhotoUserDO comActEasyPhotoUserDO = |
| | | comActEasyPhotoUserDAO.selectOne(new QueryWrapper<ComActEasyPhotoUserDO>().lambda() |
| | | .eq(ComActEasyPhotoUserDO::getEasyPhotoId, id).eq(ComActEasyPhotoUserDO::getUserId, userId)); |
| | | if (ObjectUtils.isEmpty(comActEasyPhotoUserDO)) { |
| | | comActEasyPhotoVO.setHaveGiveThumbsUp(0); |
| | | } else { |
| | | comActEasyPhotoVO.setHaveGiveThumbsUp(1); |
| | | } |
| | | } |
| | | comActEasyPhotoVO.setSponsorName(DesensitizedUtil.chineseName(comActEasyPhotoVO.getSponsorName())); |
| | | comActEasyPhotoVO.setHandlerName(DesensitizedUtil.chineseName(comActEasyPhotoVO.getHandlerName())); |
| | | comActEasyPhotoVO.setCompleteName(DesensitizedUtil.chineseName(comActEasyPhotoVO.getCompleteName())); |
| | | comActEasyPhotoVO.setPhone(DesensitizedUtil.mobilePhone(comActEasyPhotoVO.getPhone())); |
| | | |
| | | // 查询反馈信息 |
| | | List<ComActEasyPhotoFeedbackVO> photoFeedbackList = comActEasyPhotoFeedbackMapper.getPhotoFeedbackList(id); |
| | | if (!photoFeedbackList.isEmpty()) { |
| | | if (CollUtil.isNotEmpty(photoFeedbackList)){ |
| | | for (ComActEasyPhotoFeedbackVO comActEasyPhotoFeedbackVO : photoFeedbackList) { |
| | | comActEasyPhotoFeedbackVO.setCreateByName(DesensitizedUtil.chineseName(comActEasyPhotoFeedbackVO.getCreateByName())); |
| | | } |
| | | } |
| | | comActEasyPhotoVO.setPhotoFeedbackList(photoFeedbackList); |
| | | } |
| | | |
| | | if (comActEasyPhotoVO.getAddrRemark() == null) { |
| | | comActEasyPhotoVO.setAddrRemark(""); |
| | | } |
| | | |
| | | if (comActEasyPhotoVO.getActivityId() != null) { |
| | | ComActEasyPhotoActivityDO photoActivityDO = |
| | | comActEasyPhotoActivityMapper.selectById(comActEasyPhotoVO.getActivityId()); |
| | | if (photoActivityDO != null) { |
| | | ComActEasyPhotoActivityVO easyPhotoActivityVO = new ComActEasyPhotoActivityVO(); |
| | | BeanUtils.copyProperties(photoActivityDO, easyPhotoActivityVO); |
| | |
| | | } |
| | | |
| | | /** |
| | | * 小程序分页查询随手拍 脱敏 |
| | | * |
| | | * @param comActEasyPhotoVO |
| | | * 查询参数 |
| | | * @return 返回结果 |
| | | */ |
| | | @Override |
| | | public R pageEasyPhotoAppletsDesensitize(ComActEasyPhotoVO comActEasyPhotoVO) { |
| | | Page page = new Page<>(); |
| | | Long pageNum = comActEasyPhotoVO.getPageNum(); |
| | | Long pageSize = comActEasyPhotoVO.getPageSize(); |
| | | Long userId = comActEasyPhotoVO.getLogInUserId(); |
| | | if (null == pageNum || 0 == pageNum) { |
| | | pageNum = 1l; |
| | | } |
| | | if (null == pageSize || 0 == pageSize) { |
| | | pageSize = 10l; |
| | | } |
| | | page.setSize(pageSize); |
| | | page.setCurrent(pageNum); |
| | | IPage<ComActEasyPhotoVO> iPage = comActEasyPhotoDAO.pageEasyPhotoApplets(page, comActEasyPhotoVO); |
| | | List<ComActEasyPhotoVO> records = iPage.getRecords(); |
| | | if (userId != null) { |
| | | if (!ObjectUtils.isEmpty(records)) { |
| | | records.forEach(comActEasyPhotoVO1 -> { |
| | | Long id = comActEasyPhotoVO1.getId(); |
| | | Integer status = comActEasyPhotoVO1.getStatus(); |
| | | Date feedbackAt = comActEasyPhotoVO1.getFeedbackAt(); |
| | | comActEasyPhotoVO1.setSponsorName(DesensitizedUtil.chineseName(comActEasyPhotoVO1.getSponsorName())); |
| | | comActEasyPhotoVO1.setHandlerName(DesensitizedUtil.chineseName(comActEasyPhotoVO1.getHandlerName())); |
| | | comActEasyPhotoVO1.setCompleteName(DesensitizedUtil.chineseName(comActEasyPhotoVO1.getCompleteName())); |
| | | comActEasyPhotoVO1.setPhone(DesensitizedUtil.mobilePhone(comActEasyPhotoVO1.getPhone())); |
| | | List<ComActEasyPhotoUserDO> comActEasyPhotoUserDO = comActEasyPhotoUserDAO.selectList( |
| | | new QueryWrapper<ComActEasyPhotoUserDO>().lambda().eq(ComActEasyPhotoUserDO::getEasyPhotoId, id) |
| | | .eq(ComActEasyPhotoUserDO::getUserId, userId)); |
| | | if (comActEasyPhotoUserDO == null || comActEasyPhotoUserDO.size() == 0) { |
| | | comActEasyPhotoVO1.setHaveGiveThumbsUp(0); |
| | | } else { |
| | | comActEasyPhotoVO1.setHaveGiveThumbsUp(1); |
| | | } |
| | | if (status.intValue() == 4 && null == feedbackAt) { |
| | | comActEasyPhotoVO1.setFeedbackAt(comActEasyPhotoVO1.getExamineAt()); |
| | | } |
| | | //反馈信息列表 |
| | | List<ComActEasyPhotoFeedbackVO> photoFeedbackList = comActEasyPhotoVO1.getPhotoFeedbackList(); |
| | | if (CollUtil.isNotEmpty(photoFeedbackList)){ |
| | | for (ComActEasyPhotoFeedbackVO comActEasyPhotoFeedbackVO : photoFeedbackList) { |
| | | comActEasyPhotoFeedbackVO.setCreateByName(DesensitizedUtil.chineseName(comActEasyPhotoFeedbackVO.getCreateByName())); |
| | | } |
| | | } |
| | | comActEasyPhotoVO1.setPhotoFeedbackList(photoFeedbackList); |
| | | }); |
| | | iPage.setRecords(records); |
| | | } |
| | | } |
| | | return R.ok(iPage); |
| | | } |
| | | |
| | | /** |
| | | * 随手拍评论分页查询 |
| | | * |
| | | * @param pageComActEasyPhotoCommentDTO |
| | |
| | | comActEasyPhotoCommentDAO.pageComActEasyPhotoComment(page, pageComActEasyPhotoCommentDTO); |
| | | if (!iPage.getRecords().isEmpty()) { |
| | | for (ComActEasyPhotoCommentVO commentVO : iPage.getRecords()) { |
| | | if (StringUtils.isEmpty(commentVO.getName())) { |
| | | commentVO.setName(commentVO.getNickName()); |
| | | } |
| | | } |
| | | } |
| | | return R.ok(iPage); |
| | | } |
| | | |
| | | /** |
| | | * 随手拍评论分页查询 - 脱敏 |
| | | * |
| | | * @param pageComActEasyPhotoCommentDTO |
| | | * 查询参数 |
| | | * @return 查询结果 |
| | | */ |
| | | @Override |
| | | public R pageComActEasyPhotoCommentDesensitize(PageComActEasyPhotoCommentDTO pageComActEasyPhotoCommentDTO) { |
| | | Page page = new Page<>(); |
| | | Long pageNum = pageComActEasyPhotoCommentDTO.getPageNum(); |
| | | Long pageSize = pageComActEasyPhotoCommentDTO.getPageSize(); |
| | | if (null == pageNum || 0 == pageNum) { |
| | | pageNum = 1l; |
| | | } |
| | | if (null == pageSize || 0 == pageSize) { |
| | | pageSize = 10l; |
| | | } |
| | | page.setSize(pageSize); |
| | | page.setCurrent(pageNum); |
| | | IPage<ComActEasyPhotoCommentVO> iPage = |
| | | comActEasyPhotoCommentDAO.pageComActEasyPhotoComment(page, pageComActEasyPhotoCommentDTO); |
| | | if (!iPage.getRecords().isEmpty()) { |
| | | for (ComActEasyPhotoCommentVO commentVO : iPage.getRecords()) { |
| | | commentVO.setNickName(DesensitizedUtil.chineseName(commentVO.getNickName())); |
| | | if (StringUtils.isEmpty(commentVO.getName())) { |
| | | commentVO.setName(commentVO.getNickName()); |
| | | } |
| | |
| | | return R.fail(); |
| | | } |
| | | |
| | | /** |
| | | * 获取社区置顶动态banner |
| | | * @param communityId |
| | | * */ |
| | | @Override |
| | | public R getUserRewardNew(Long userId, Long communityId) { |
| | | ComActEasyPhotoRewardVO easyPhotoRewardVO=new ComActEasyPhotoRewardVO(); |
| | | List<BannerVO> bannerVOS=this.comActEasyPhotoDAO.getBanner(communityId); |
| | | if(!bannerVOS.isEmpty()){ |
| | | easyPhotoRewardVO.setBannerVOS(bannerVOS); |
| | | } |
| | | return R.ok(easyPhotoRewardVO); |
| | | } |
| | | |
| | | } |
| | |
| | | package com.panzhihua.service_community.service.impl; |
| | | |
| | | import cn.hutool.core.date.DateUtil; |
| | | import cn.hutool.core.util.DesensitizedUtil; |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | |
| | | } |
| | | return R.ok(iPage); |
| | | } |
| | | @Override |
| | | public R pageMicroWishAppletsDesensitize(ComActMicroWishVO comActMicroWishVO) { |
| | | Long userId = comActMicroWishVO.getResponsibleId(); |
| | | IPage<ComActMicroWishVO> iPage = comActMicroWishDAO.pageMicroWishApplets(new Page(comActMicroWishVO.getPageNum() |
| | | ,comActMicroWishVO.getPageSize()), comActMicroWishVO); |
| | | List<ComActMicroWishVO> records = iPage.getRecords(); |
| | | if (!ObjectUtils.isEmpty(records)) { |
| | | records.forEach(comActMicroWishVO1 -> { |
| | | if(userId != null){ |
| | | Long id = comActMicroWishVO1.getId(); |
| | | ComActMicroWishUserDO comActMicroWishUserDO = comActMicroWishUserDAO.selectOne(new QueryWrapper<ComActMicroWishUserDO>().lambda().eq(ComActMicroWishUserDO::getMicroWishId, id) |
| | | .eq(ComActMicroWishUserDO::getUserId, userId)); |
| | | if (ObjectUtils.isEmpty(comActMicroWishUserDO)) { |
| | | comActMicroWishVO1.setHaveGiveThumbsUp(0); |
| | | } else { |
| | | comActMicroWishVO1.setHaveGiveThumbsUp(1); |
| | | } |
| | | } |
| | | comActMicroWishVO1.setSponsorPhone(SensitiveUtil.desensitizedPhoneNumber(comActMicroWishVO1.getSponsorPhone())); |
| | | comActMicroWishVO1.setSponsorName(DesensitizedUtil.chineseName(comActMicroWishVO1.getSponsorName())); |
| | | comActMicroWishVO1.setResponsibleName(DesensitizedUtil.chineseName(comActMicroWishVO1.getResponsibleName())); |
| | | }); |
| | | iPage.setRecords(records); |
| | | } |
| | | return R.ok(iPage); |
| | | } |
| | | |
| | | /** |
| | | * 心愿详情 |
| | |
| | | comActMicroWishVO.setResponsibleName(this.getWishHandleName(comActMicroWishVO.getHandleId())); |
| | | return R.ok(comActMicroWishVO); |
| | | } |
| | | /** |
| | | * 心愿详情 - 脱敏 |
| | | * |
| | | * @param id 查询主键 |
| | | * @param userId 登录用户id |
| | | * @return 心愿内容 |
| | | */ |
| | | @Override |
| | | public R detailMicroWishDesensitize(Long id, Long userId) { |
| | | ComActMicroWishVO comActMicroWishVO = comActMicroWishDAO.detailMicroWish(id); |
| | | if (ObjectUtils.isEmpty(comActMicroWishVO)) { |
| | | return R.fail("微心愿不存在"); |
| | | } |
| | | Integer starNum = comActMicroWishVO.getStarNum(); |
| | | if (null==starNum) { |
| | | comActMicroWishVO.setStarNum(0); |
| | | } |
| | | if (ObjectUtils.isEmpty(comActMicroWishVO)) { |
| | | return R.fail("心愿不存在"); |
| | | } |
| | | if(userId != null){ |
| | | ComActMicroWishUserDO comActMicroWishUserDO = comActMicroWishUserDAO.selectOne(new QueryWrapper<ComActMicroWishUserDO>().lambda().eq(ComActMicroWishUserDO::getUserId, userId).eq(ComActMicroWishUserDO::getMicroWishId, id)); |
| | | if (ObjectUtils.isEmpty(comActMicroWishUserDO)) { |
| | | comActMicroWishVO.setHaveGiveThumbsUp(0); |
| | | }else { |
| | | comActMicroWishVO.setHaveGiveThumbsUp(1); |
| | | } |
| | | } |
| | | //查询反馈列表 |
| | | List<ComActMicroWishFeedbackVO> feedList=comActMicroWishFeedbackMapper.selectByWishId(id); |
| | | if(!feedList.isEmpty()){ |
| | | for (ComActMicroWishFeedbackVO comActMicroWishFeedbackVO : feedList) { |
| | | comActMicroWishFeedbackVO.setName(DesensitizedUtil.chineseName(comActMicroWishFeedbackVO.getName())); |
| | | } |
| | | comActMicroWishVO.setFeedbackVOList(feedList); |
| | | } |
| | | //查询操作记录 |
| | | List<ComActMicroWishOperationRecordVO> operationList=comActMicroWishOperationRecordMapper.getByWishId(id); |
| | | if(!operationList.isEmpty()){ |
| | | comActMicroWishVO.setOperationRecordVOList(operationList); |
| | | } |
| | | comActMicroWishVO.setSponsorPhone(SensitiveUtil.desensitizedPhoneNumber(comActMicroWishVO.getSponsorPhone())); |
| | | comActMicroWishVO.setSponsorName(DesensitizedUtil.chineseName(comActMicroWishVO.getSponsorName())); |
| | | comActMicroWishVO.setResponsibleName(DesensitizedUtil.chineseName(comActMicroWishVO.getResponsibleName())); |
| | | //查询同类型id数组 |
| | | List<Long> idList=comActMicroWishOperationRecordMapper.selectId(comActMicroWishVO); |
| | | if(!idList.isEmpty()){ |
| | | comActMicroWishVO.setIdList(idList); |
| | | } |
| | | //查询处理人 |
| | | comActMicroWishVO.setResponsibleName(DesensitizedUtil.chineseName(this.getWishHandleName(comActMicroWishVO.getHandleId()))); |
| | | return R.ok(comActMicroWishVO); |
| | | } |
| | | |
| | | /** |
| | | * 审核、分配、反馈心愿 |
New file |
| | |
| | | package com.panzhihua.service_community.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.panzhihua.common.model.dtos.community.ComActProceedingsDTO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.community.ComActProceedingsVO; |
| | | import com.panzhihua.common.utlis.CopyUtil; |
| | | import com.panzhihua.common.utlis.Snowflake; |
| | | import com.panzhihua.service_community.dao.ComActProceedingsDao; |
| | | import com.panzhihua.service_community.entity.ComActProceedings; |
| | | import com.panzhihua.service_community.service.ComActProceedingsService; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | import java.util.Date; |
| | | |
| | | import static java.util.Objects.isNull; |
| | | |
| | | @Service |
| | | public class ComActProceedingsServiceImpl extends ServiceImpl<ComActProceedingsDao, ComActProceedings> implements ComActProceedingsService { |
| | | |
| | | @Resource |
| | | private ComActProceedingsDao comActProceedingsDao; |
| | | /** |
| | | * 分页查询议事委员会 |
| | | * @param keyWord 搜索关键字 |
| | | * @return 处理结果 |
| | | * */ |
| | | @Override |
| | | public R pageProceedings(Integer page, Integer size, String keyWord) { |
| | | return R.ok(CopyUtil.beanCopyList(comActProceedingsDao.pageProceedings(new Page(page,size),keyWord), ComActProceedingsVO.class)); |
| | | } |
| | | |
| | | /** |
| | | * 新增或修改议事委员会 |
| | | * @param comActProceedingsDTO |
| | | * @return 处理结果 |
| | | * */ |
| | | @Override |
| | | public R addOrUpdate(ComActProceedingsDTO comActProceedingsDTO) { |
| | | if(isNull(comActProceedingsDTO.getId())){ |
| | | //新增 |
| | | ComActProceedings comActProceedings=new ComActProceedings(); |
| | | comActProceedings.setId(Snowflake.getId()); |
| | | comActProceedings.setCreateTime(new Date()); |
| | | comActProceedings.setDelFlag(0); |
| | | comActProceedings.setStatus(0); |
| | | BeanUtils.copyProperties(comActProceedingsDTO, comActProceedings); |
| | | int i = comActProceedingsDao.insert(comActProceedings); |
| | | if (i>0){ |
| | | return R.ok(); |
| | | } |
| | | }else{ |
| | | //修改 |
| | | ComActProceedings comActProceedings=new ComActProceedings(); |
| | | BeanUtils.copyProperties(comActProceedingsDTO, comActProceedings); |
| | | comActProceedings.setUpdateTime(new Date()); |
| | | int i = comActProceedingsDao.updateById(comActProceedings); |
| | | if (i>0){ |
| | | return R.ok(); |
| | | } |
| | | } |
| | | return R.fail("操作失败"); |
| | | } |
| | | } |
| | |
| | | Boolean isExpertCheck=false; |
| | | Long expertId=null; |
| | | Boolean isStretAccount = isStreetAccount(loginUserInfoVO); |
| | | comEvent.setAppId(loginUserInfoVO.getAppId()); |
| | | if (nonNull(comEvent.getUserType())){ |
| | | if (comEvent.getUserType().equals(1)){ |
| | | //个人账号权限 |
| | |
| | | } |
| | | } |
| | | |
| | | |
| | | |
| | | @Override |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public R acceptRequest(Long id, Long specterId) { |
| | |
| | | } |
| | | } |
| | | log.info("当前userType===="+comEvent.getUserType()); |
| | | comEvent.setAppId(loginUserInfoVO.getAppId()); |
| | | List<ComEventCalculateVO> calculateList = baseMapper.calculate(comEvent); |
| | | ComEventCalculateVO comEventCalculateVO =new ComEventCalculateVO(); |
| | | comEventCalculateVO.setStatus("0"); |
| | |
| | | if (isNotBlank(comPropertyVO.getAccount())) { |
| | | AdministratorsUserVO administratorsUserVO=new AdministratorsUserVO(); |
| | | administratorsUserVO.setType(3); |
| | | if (comPropertyVO.getCommunityId().equals(10172)){ |
| | | administratorsUserVO.setType(20); |
| | | } |
| | | administratorsUserVO.setAccount(comPropertyVO.getAccount()); |
| | | administratorsUserVO.setPassword(comPropertyVO.getPassword()); |
| | | administratorsUserVO.setRoleId(comPropertyVO.getRoleId()); |
| | |
| | | comPropertyVO.setPassword(null); |
| | | return R.ok(comPropertyVO); |
| | | } |
| | | |
| | | @Override |
| | | public R noticeList(Integer page, Integer size, Long propertyId) { |
| | | return R.ok(comPropertyDao.noticeList(new Page(page,size),propertyId)); |
| | | } |
| | | } |
| | |
| | | e.printStackTrace(); |
| | | } |
| | | //生成后台账号 |
| | | //如果是普达社区专家则不生成后台账号 |
| | | if (nonNull(expert.getCommunityId()) && !expert.getCommunityId().equals(10172)){ |
| | | return R.ok(); |
| | | } |
| | | AdministratorsUserVO user=new AdministratorsUserVO(); |
| | | user.setUserId(Snowflake.getId()); |
| | | user.setAccount(comSanshuoExpertDTO.getAccount()); |
| | |
| | | user.setType(11); |
| | | user.setImageUrl(comSanshuoExpertDTO.getAvatar()); |
| | | user.setPhone(comSanshuoExpertDTO.getPhone()); |
| | | return R.ok(userService.sanShuoAddUser(user)); |
| | | userService.sanShuoAddUser(user); |
| | | return R.ok(); |
| | | } |
| | | }else { |
| | | ComSanshuoExpert expert=new ComSanshuoExpert(); |
| | |
| | | range=1; |
| | | } |
| | | log.info(""); |
| | | IPage<ComSanshuoExpertVO> comSanshuoExpertVOIPage = comSanshuoExpertDao.expertPage(new Page(page, size), keyWord, range, id, level); |
| | | IPage<ComSanshuoExpertVO> comSanshuoExpertVOIPage = comSanshuoExpertDao.expertPage(new Page(page, size), keyWord, range, id, level,loginUserInfo.getAppId()); |
| | | for (ComSanshuoExpertVO record : comSanshuoExpertVOIPage.getRecords()) { |
| | | //获取调解次数和成功率 |
| | | record.setCount(comEventMapper.selectCount(new QueryWrapper<ComEvent>().lambda().eq(ComEvent::getSpecialistId, record.getId()))); |
| | |
| | | if (nonNull(level)){ |
| | | if (level.equals(1)){ |
| | | //三说会堂权限,查看所有 |
| | | return R.ok(comSanshuoExpertDao.expertList(new Page(page,size),level,null)); |
| | | return R.ok(comSanshuoExpertDao.expertList(new Page(page,size),level,null ,loginUserInfoVO.getAppId())); |
| | | }else if (level.equals(2)){ |
| | | //行业分中心 |
| | | ComSanshuoIndustryCenter center = comSanshuoIndustryCenterDao.selectOne(new QueryWrapper<ComSanshuoIndustryCenter>().lambda().eq(ComSanshuoIndustryCenter::getAccount, loginUserInfoVO.getAccount())); |
| | | return R.ok(comSanshuoExpertDao.expertList(new Page(page,size),level,center.getId())); |
| | | return R.ok(comSanshuoExpertDao.expertList(new Page(page,size),level,center.getId(),loginUserInfoVO.getAppId())); |
| | | }else if (level.equals(3)){ |
| | | //街道 |
| | | return R.ok(comSanshuoExpertDao.expertList(new Page(page,size),level,loginUserInfoVO.getStreetId())); |
| | | return R.ok(comSanshuoExpertDao.expertList(new Page(page,size),level,loginUserInfoVO.getStreetId(),loginUserInfoVO.getAppId())); |
| | | }else if(level.equals(4)){ |
| | | return R.ok(comSanshuoExpertDao.expertList(new Page(page,size),level,loginUserInfoVO.getCommunityId())); |
| | | return R.ok(comSanshuoExpertDao.expertList(new Page(page,size),level,loginUserInfoVO.getCommunityId(),loginUserInfoVO.getAppId())); |
| | | } |
| | | } |
| | | return null; |
New file |
| | |
| | | package com.panzhihua.service_community.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.panzhihua.service_community.dao.ComShopFlowerGoodsAttrDAO; |
| | | import com.panzhihua.service_community.dao.ComShopGoodsAttrDAO; |
| | | import com.panzhihua.service_community.model.dos.ComShopFlowerGoodsAttrDO; |
| | | import com.panzhihua.service_community.model.dos.ComShopGoodsAttrDO; |
| | | import com.panzhihua.service_community.service.ComShopFlowerGoodsAttrService; |
| | | import com.panzhihua.service_community.service.ComShopGoodsAttrService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | /** |
| | | * @auther yh |
| | | * @create 2022-11-08 17:25:45 |
| | | * @describe 商品规格表服务实现类 |
| | | */ |
| | | @Slf4j |
| | | @Service |
| | | public class ComShopFlowerGoodsAttrServiceImpl extends ServiceImpl<ComShopFlowerGoodsAttrDAO, ComShopFlowerGoodsAttrDO> |
| | | implements ComShopFlowerGoodsAttrService { |
| | | |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | 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.google.common.collect.Lists; |
| | | import com.panzhihua.common.exceptions.ServiceException; |
| | | import com.panzhihua.common.model.dtos.shop.ComShopFlowerGoodsDTO; |
| | | import com.panzhihua.common.model.dtos.shop.PageComShopFlowerGoodsDTO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientMerchantVO; |
| | | import com.panzhihua.common.model.vos.shop.*; |
| | | import com.panzhihua.common.utlis.DifferentLongListUtil; |
| | | import com.panzhihua.service_community.dao.ComShopFlowerGoodsAttrDAO; |
| | | import com.panzhihua.service_community.dao.ComShopFlowerGoodsDAO; |
| | | import com.panzhihua.service_community.dao.ConvenientMerchantDAO; |
| | | import com.panzhihua.service_community.model.dos.*; |
| | | import com.panzhihua.service_community.service.ComShopFlowerGoodsAttrService; |
| | | import com.panzhihua.service_community.service.ComShopFlowerGoodsService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.stream.Collectors; |
| | | |
| | | /** |
| | | * @ClassName: ComShopFlowerGoodsServiceImpl |
| | | * @Author: yh |
| | | * @Date: 2022/11/8 17:17 |
| | | * @Description: 商品 |
| | | */ |
| | | @Service |
| | | @Slf4j |
| | | public class ComShopFlowerGoodsServiceImpl extends ServiceImpl<ComShopFlowerGoodsDAO, ComShopFlowerGoodsDO> implements ComShopFlowerGoodsService { |
| | | |
| | | @Resource |
| | | private ComShopFlowerGoodsAttrService comShopFlowerGoodsAttrService; |
| | | @Resource |
| | | private ComShopFlowerGoodsAttrDAO shopFlowerGoodsAttrDAO; |
| | | @Resource |
| | | private ConvenientMerchantDAO convenientMerchantDAO; |
| | | |
| | | @Override |
| | | public R saveShopFlowerGoods(AddShopFlowerGoodsVO addShopFlowerGoodsVO) { |
| | | if (addShopFlowerGoodsVO == null) { |
| | | return R.ok("500", "数据为空!"); |
| | | } |
| | | String[] images = addShopFlowerGoodsVO.getGoodsPic().split(","); |
| | | ComShopFlowerGoodsDO shopGoodsDO = new ComShopFlowerGoodsDO(); |
| | | BeanUtils.copyProperties(addShopFlowerGoodsVO, shopGoodsDO); |
| | | shopGoodsDO.setOriginalPrice(addShopFlowerGoodsVO.getPrice()); |
| | | if (images.length > 1) { |
| | | shopGoodsDO.setGoodsPic(images[0]); |
| | | } |
| | | shopGoodsDO.setImages(addShopFlowerGoodsVO.getGoodsPic()); |
| | | shopGoodsDO.setSale(0); |
| | | shopGoodsDO.setDetails(addShopFlowerGoodsVO.getDetails()); |
| | | int goodsId = this.baseMapper.insert(shopGoodsDO); |
| | | if (goodsId > 0) { |
| | | ArrayList<ComShopFlowerGoodsAttrDO> goodsAttrDOS = Lists.newArrayList(); |
| | | ComShopFlowerGoodsDO goodDO = this.baseMapper.selectById(shopGoodsDO.getId()); |
| | | addShopFlowerGoodsVO.getGoodsAttrVOList().forEach(goodsAttr -> { |
| | | // 维护商品规格表 |
| | | if (goodDO == null) { |
| | | throw new ServiceException("商品id不存在!"); |
| | | } |
| | | ComShopFlowerGoodsAttrDO shopGoodsAttrDO = new ComShopFlowerGoodsAttrDO(); |
| | | shopGoodsAttrDO.setGoodsId(shopGoodsDO.getId()); |
| | | shopGoodsAttrDO.setStoreId(goodDO.getStoreId()); |
| | | shopGoodsAttrDO.setGoodsName(goodDO.getName()); |
| | | shopGoodsAttrDO.setGoodsAttrName(goodsAttr.getGoodsAttrName()); |
| | | shopGoodsAttrDO.setIsDefault(1); |
| | | shopGoodsAttrDO.setPrice(goodsAttr.getPrice()); |
| | | shopGoodsAttrDO.setCollatePrice(goodsAttr.getCollatePrice()); |
| | | shopGoodsAttrDO.setFreeShippingPrice(goodsAttr.getFreeShippingPrice()); |
| | | shopGoodsAttrDO.setAttrPic(goodsAttr.getAttrPic()); |
| | | shopGoodsAttrDO.setStock(goodsAttr.getStock()); |
| | | shopGoodsAttrDO.setSale(0); |
| | | goodsAttrDOS.add(shopGoodsAttrDO); |
| | | }); |
| | | if (goodsAttrDOS.size() > 0) { |
| | | comShopFlowerGoodsAttrService.saveBatch(goodsAttrDOS); |
| | | } |
| | | } |
| | | return R.ok(); |
| | | } |
| | | |
| | | /** |
| | | * 分页查询 |
| | | * |
| | | * @param pageComShopFlowerGoodsDTO 查询参数 |
| | | * @return |
| | | */ |
| | | @Override |
| | | public R pageFlowerGoodsList(PageComShopFlowerGoodsDTO pageComShopFlowerGoodsDTO) { |
| | | long pageNum = pageComShopFlowerGoodsDTO.getPageNum() != null ? pageComShopFlowerGoodsDTO.getPageNum() : 1; |
| | | long pageSize = pageComShopFlowerGoodsDTO.getPageSize() != null ? pageComShopFlowerGoodsDTO.getPageSize() : 10; |
| | | Page page = new Page<>(pageNum, pageSize); |
| | | IPage<PageShopFlowerGoodsVO> comShopStoreVOIPage = this.baseMapper.pageShopGoods(page, pageComShopFlowerGoodsDTO); |
| | | if (!comShopStoreVOIPage.getRecords().isEmpty()) { |
| | | comShopStoreVOIPage.getRecords().forEach(shopGoods -> { |
| | | List<ComShopFlowerGoodsAttrDO> goodsAttrDOs = |
| | | shopFlowerGoodsAttrDAO.selectList(new QueryWrapper<ComShopFlowerGoodsAttrDO>().lambda() |
| | | .eq(ComShopFlowerGoodsAttrDO::getGoodsId, shopGoods.getId())); |
| | | ArrayList<AddShopFlowerGoodsAttrVO> goodsAttrVOList = Lists.newArrayList(); |
| | | for (ComShopFlowerGoodsAttrDO oneGoodsAttrDO : goodsAttrDOs) { |
| | | AddShopFlowerGoodsAttrVO goodsAttrVO = new AddShopFlowerGoodsAttrVO(); |
| | | BeanUtils.copyProperties(oneGoodsAttrDO, goodsAttrVO); |
| | | goodsAttrVOList.add(goodsAttrVO); |
| | | } |
| | | shopGoods.setGoodsAttrs(goodsAttrVOList); |
| | | }); |
| | | } |
| | | return R.ok(comShopStoreVOIPage); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 分页查询商品列表 |
| | | * |
| | | * @param comShopFlowerGoodsDTO 请求参数 |
| | | * @return |
| | | */ |
| | | @Override |
| | | public R pageShopFlowerGoodsByApp(ComShopFlowerGoodsDTO comShopFlowerGoodsDTO) { |
| | | Page page = new Page<>(comShopFlowerGoodsDTO.getPageNum(), comShopFlowerGoodsDTO.getPageSize()); |
| | | IPage<ComShopFlowerGoodsVO> goodsVOIPage = this.baseMapper.pageShopGoodByApps(page, comShopFlowerGoodsDTO); |
| | | if (!goodsVOIPage.getRecords().isEmpty()) { |
| | | goodsVOIPage.getRecords().forEach(goodsVo -> { |
| | | List<ComShopFlowerGoodsAttrVO> goodsAttrList = shopFlowerGoodsAttrDAO.getGoodsAttr(goodsVo.getId()); |
| | | if (!goodsAttrList.isEmpty()) { |
| | | ComShopFlowerGoodsAttrVO comShopFlowerGoodsAttrVO = goodsAttrList.get(0); |
| | | |
| | | goodsVo.setGoodsAttrList(goodsAttrList); |
| | | goodsVo.setGoodsPic(comShopFlowerGoodsAttrVO.getAttrPic()); |
| | | goodsVo.setOriginalPrice(comShopFlowerGoodsAttrVO.getPrice()); |
| | | goodsVo.setPrice(comShopFlowerGoodsAttrVO.getCollatePrice()); |
| | | } |
| | | }); |
| | | } |
| | | return R.ok(goodsVOIPage); |
| | | } |
| | | |
| | | @Override |
| | | public R shopFlowerGoodsDetail(Long goodsId) { |
| | | // 根据id查询商品信息 |
| | | ComShopFlowerGoodsDO goodsDO = this.baseMapper.selectById(goodsId); |
| | | if (goodsDO == null || goodsDO.getDeleteStatus().equals(ComShopFlowerGoodsDO.deleteStatus.yes)) { |
| | | return R.fail(403, "商品不存在"); |
| | | } |
| | | if (!goodsDO.getStatus().equals(ComShopFlowerGoodsDO.status.sell)) { |
| | | return R.fail(405, "商品已下架"); |
| | | } |
| | | |
| | | // 根据商品id查询商品规格信息 |
| | | List<ComShopFlowerGoodsAttrVO> goodsAttrList = new ArrayList<>(); |
| | | List<ComShopFlowerGoodsAttrDO> goodsAttrDOS = |
| | | shopFlowerGoodsAttrDAO.selectList(new QueryWrapper<ComShopFlowerGoodsAttrDO>().eq("goods_id", goodsId)); |
| | | goodsAttrDOS.forEach(attrDO -> { |
| | | ComShopFlowerGoodsAttrVO goodsAttrVO = new ComShopFlowerGoodsAttrVO(); |
| | | BeanUtils.copyProperties(attrDO, goodsAttrVO); |
| | | goodsAttrList.add(goodsAttrVO); |
| | | }); |
| | | |
| | | // 查询商品店铺信息 |
| | | ConvenientMerchantDO convenientMerchantDO = convenientMerchantDAO.selectById(goodsDO.getStoreId()); |
| | | ConvenientMerchantVO convenientMerchantVO = new ConvenientMerchantVO(); |
| | | BeanUtils.copyProperties(convenientMerchantDO, convenientMerchantVO); |
| | | |
| | | // 设置值 |
| | | ComShopFlowerGoodsVO shopGoods = new ComShopFlowerGoodsVO(); |
| | | BeanUtils.copyProperties(goodsDO, shopGoods); |
| | | shopGoods.setGoodsAttrList(goodsAttrList); |
| | | shopGoods.setConvenientMerchantVO(convenientMerchantVO); |
| | | return R.ok(shopGoods); |
| | | } |
| | | |
| | | @Override |
| | | public R editFlowerShopGoods(Long id, AddShopFlowerGoodsVO addShopFlowerGoodsVO) { |
| | | if (addShopFlowerGoodsVO == null) { |
| | | return R.ok("500", "数据为空!"); |
| | | } |
| | | LambdaQueryWrapper<ComShopFlowerGoodsDO> query = |
| | | new LambdaQueryWrapper<ComShopFlowerGoodsDO>().eq(ComShopFlowerGoodsDO::getId, id); |
| | | ComShopFlowerGoodsDO shopGoodsDO = new ComShopFlowerGoodsDO(); |
| | | BeanUtils.copyProperties(addShopFlowerGoodsVO, shopGoodsDO); |
| | | shopGoodsDO.setOriginalPrice(addShopFlowerGoodsVO.getPrice()); |
| | | int update = this.baseMapper.update(shopGoodsDO, query); |
| | | if (update < 1) { |
| | | throw new ServiceException("修改失败"); |
| | | } |
| | | // 修改规格表 |
| | | List<ComShopFlowerGoodsAttrDO> comShopFlowerGoodsAttrDOS = shopFlowerGoodsAttrDAO |
| | | .selectList(new LambdaQueryWrapper<ComShopFlowerGoodsAttrDO>().eq(ComShopFlowerGoodsAttrDO::getGoodsId, id)); |
| | | if (addShopFlowerGoodsVO.getGoodsAttrVOList().size() == 0) { |
| | | shopFlowerGoodsAttrDAO |
| | | .delete(new LambdaQueryWrapper<ComShopFlowerGoodsAttrDO>().eq(ComShopFlowerGoodsAttrDO::getGoodsId, id)); |
| | | ComShopFlowerGoodsAttrDO comShopFlowerGoodsAttrDO = new ComShopFlowerGoodsAttrDO(); |
| | | comShopFlowerGoodsAttrDO.setGoodsId(id); |
| | | comShopFlowerGoodsAttrDO.setStoreId(addShopFlowerGoodsVO.getStoreId()); |
| | | comShopFlowerGoodsAttrDO.setGoodsName(addShopFlowerGoodsVO.getName()); |
| | | comShopFlowerGoodsAttrDO.setGoodsAttrName("默认"); |
| | | comShopFlowerGoodsAttrDO.setAttrPic(addShopFlowerGoodsVO.getGoodsPic()); |
| | | comShopFlowerGoodsAttrDO.setIsDefault(1); |
| | | comShopFlowerGoodsAttrDO.setPrice(addShopFlowerGoodsVO.getPrice()); |
| | | shopFlowerGoodsAttrDAO.insert(comShopFlowerGoodsAttrDO); |
| | | } else { |
| | | List<Long> attrIds = |
| | | comShopFlowerGoodsAttrDOS.stream().map(ComShopFlowerGoodsAttrDO::getId).collect(Collectors.toList()); |
| | | List<Long> voAttrIds = addShopFlowerGoodsVO.getGoodsAttrVOList().stream().map(AddShopFlowerGoodsAttrVO::getGoodsAttrId) |
| | | .collect(Collectors.toList()); |
| | | // 需要删除的规格ID——针对编辑时删除了规格的情况 |
| | | List<Long> deleteIds = DifferentLongListUtil.getDiffrent(attrIds, voAttrIds); |
| | | if (deleteIds.size() != 0) { |
| | | shopFlowerGoodsAttrDAO.deleteBatchIds(deleteIds); |
| | | } |
| | | addShopFlowerGoodsVO.getGoodsAttrVOList().forEach(goodsAttr -> { |
| | | ComShopFlowerGoodsAttrDO comShopGoodsAttrDO = shopFlowerGoodsAttrDAO.selectById(goodsAttr.getGoodsAttrId()); |
| | | if (comShopGoodsAttrDO != null) { |
| | | comShopGoodsAttrDO.setPrice(goodsAttr.getPrice()); |
| | | comShopGoodsAttrDO.setCollatePrice(goodsAttr.getCollatePrice()); |
| | | comShopGoodsAttrDO.setFreeShippingPrice(goodsAttr.getFreeShippingPrice()); |
| | | comShopGoodsAttrDO.setGoodsAttrName(goodsAttr.getGoodsAttrName()); |
| | | comShopGoodsAttrDO.setAttrPic(goodsAttr.getAttrPic()); |
| | | comShopGoodsAttrDO.setStock(goodsAttr.getStock()); |
| | | shopFlowerGoodsAttrDAO.updateById(comShopGoodsAttrDO); |
| | | } else { |
| | | comShopGoodsAttrDO = new ComShopFlowerGoodsAttrDO(); |
| | | comShopGoodsAttrDO.setGoodsId(shopGoodsDO.getId()); |
| | | comShopGoodsAttrDO.setStoreId(shopGoodsDO.getStoreId()); |
| | | comShopGoodsAttrDO.setGoodsName(shopGoodsDO.getName()); |
| | | comShopGoodsAttrDO.setGoodsAttrName(goodsAttr.getGoodsAttrName()); |
| | | comShopGoodsAttrDO.setIsDefault(1); |
| | | comShopGoodsAttrDO.setPrice(goodsAttr.getPrice()); |
| | | comShopGoodsAttrDO.setCollatePrice(goodsAttr.getCollatePrice()); |
| | | comShopGoodsAttrDO.setFreeShippingPrice(goodsAttr.getFreeShippingPrice()); |
| | | comShopGoodsAttrDO.setAttrPic(goodsAttr.getAttrPic()); |
| | | comShopGoodsAttrDO.setStock(goodsAttr.getStock()); |
| | | comShopGoodsAttrDO.setSale(0); |
| | | shopFlowerGoodsAttrDAO.insert(comShopGoodsAttrDO); |
| | | } |
| | | }); |
| | | } |
| | | return R.ok(); |
| | | } |
| | | |
| | | @Override |
| | | public R deleteShopFlowerGoods(Long[] id) { |
| | | LambdaQueryWrapper<ComShopFlowerGoodsDO> query = new LambdaQueryWrapper<ComShopFlowerGoodsDO>().in(ComShopFlowerGoodsDO::getId, id); |
| | | List<ComShopFlowerGoodsDO> comShopGoodsDOS = this.baseMapper.selectList(query); |
| | | for (ComShopFlowerGoodsDO one : comShopGoodsDOS) { |
| | | one.setDeleteStatus(ComShopFlowerGoodsDO.deleteStatus.yes); |
| | | this.baseMapper.updateById(one); |
| | | } |
| | | return R.ok(); |
| | | } |
| | | |
| | | @Override |
| | | public R changeStatus(Long id, Integer status) { |
| | | ComShopFlowerGoodsDO shopGoodsDO = this.baseMapper.selectById(id); |
| | | if (shopGoodsDO == null) { |
| | | return R.fail("id有误!"); |
| | | } |
| | | shopGoodsDO.setStatus(status); |
| | | this.baseMapper.updateById(shopGoodsDO); |
| | | return R.ok(); |
| | | } |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_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.ConvenientElevatingPointDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.ConvenientMerchantDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageConvenientElevatingPointDTO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientElevatingPointVO; |
| | | import com.panzhihua.common.utlis.Snowflake; |
| | | import com.panzhihua.service_community.dao.ComActDAO; |
| | | import com.panzhihua.service_community.dao.ConvenientElevatingPointDAO; |
| | | import com.panzhihua.service_community.model.dos.ComActDO; |
| | | import com.panzhihua.service_community.model.dos.ConvenientElevatingPointDO; |
| | | import com.panzhihua.service_community.model.dos.ConvenientMerchantDO; |
| | | import com.panzhihua.service_community.model.dos.ConvenientServiceCategoryDO; |
| | | import com.panzhihua.service_community.service.ConvenientElevatingPointService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.validation.constraints.NotNull; |
| | | import java.util.List; |
| | | |
| | | import static java.util.Objects.isNull; |
| | | import static java.util.Objects.nonNull; |
| | | import static org.apache.commons.lang3.StringUtils.isNotBlank; |
| | | |
| | | /** |
| | | * @ClassName: ConvenientElevatingPointServiceImpl |
| | | * @Author: yh |
| | | * @Date: 2022/11/8 10:34 |
| | | * @Description: 自提点 |
| | | */ |
| | | @Service |
| | | @Slf4j |
| | | public class ConvenientElevatingPointServiceImpl extends ServiceImpl<ConvenientElevatingPointDAO, ConvenientElevatingPointDO> implements ConvenientElevatingPointService { |
| | | @Resource |
| | | private ComActDAO comActDAO; |
| | | |
| | | /** |
| | | * 分页查询 |
| | | * @param pageConvenientElevatingPointDTO |
| | | * @return |
| | | */ |
| | | @Override |
| | | public R pagePoint(PageConvenientElevatingPointDTO pageConvenientElevatingPointDTO) { |
| | | Page page = new Page<>(); |
| | | page.setSize(pageConvenientElevatingPointDTO.getPageSize()); |
| | | page.setCurrent(pageConvenientElevatingPointDTO.getPageNum()); |
| | | IPage<ConvenientElevatingPointVO> iPage = this.baseMapper.page(page, pageConvenientElevatingPointDTO); |
| | | return R.ok(iPage); |
| | | } |
| | | |
| | | /** |
| | | * 新增 |
| | | * @param convenientElevatingPointDTO |
| | | * @return |
| | | */ |
| | | @Override |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public R addPoint(ConvenientElevatingPointDTO convenientElevatingPointDTO) { |
| | | ConvenientElevatingPointDO convenientElevatingPointDO = new ConvenientElevatingPointDO(); |
| | | BeanUtils.copyProperties(convenientElevatingPointDTO,convenientElevatingPointDO); |
| | | String communityId = convenientElevatingPointDTO.getCommunityId(); |
| | | if (nonNull(communityId)) { |
| | | ComActDO comActDO = comActDAO.selectById(Long.parseLong(communityId.substring(communityId.lastIndexOf(",")+1))); |
| | | if(comActDO!=null){ |
| | | convenientElevatingPointDO.setCommunityName(comActDO.getName()); |
| | | } |
| | | } |
| | | this.baseMapper.insert(convenientElevatingPointDO); |
| | | return R.ok(); |
| | | } |
| | | |
| | | /** |
| | | * 修改 |
| | | * @param convenientElevatingPointDTO |
| | | * @return |
| | | */ |
| | | @Override |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public R putPoint(ConvenientElevatingPointDTO convenientElevatingPointDTO) { |
| | | Long id = convenientElevatingPointDTO.getId(); |
| | | ConvenientElevatingPointDO convenientElevatingPointDO = this.baseMapper.selectById(id); |
| | | if (isNull(convenientElevatingPointDO)) { |
| | | return R.fail("自提点不存在"); |
| | | } |
| | | String communityId = convenientElevatingPointDTO.getCommunityId(); |
| | | if (nonNull(communityId)) { |
| | | ComActDO comActDO = comActDAO.selectById(Long.parseLong(communityId.substring(communityId.lastIndexOf(",")+1))); |
| | | if(comActDO!=null){ |
| | | convenientElevatingPointDO.setCommunityName(comActDO.getName()); |
| | | } |
| | | } |
| | | BeanUtils.copyProperties(convenientElevatingPointDTO, convenientElevatingPointDO); |
| | | this.baseMapper.updateById(convenientElevatingPointDO); |
| | | return R.ok(); |
| | | } |
| | | |
| | | |
| | | @Override |
| | | public R deletePoint(Long pointId, Long operator) { |
| | | ConvenientElevatingPointDO convenientElevatingPointDO = this.baseMapper.selectById(pointId); |
| | | if (convenientElevatingPointDO.getPrepareGoodsNum() > 0){ |
| | | return R.fail("该提货点暂时无法删除!若想删除需保证待提货数量为0"); |
| | | } |
| | | int result = this.baseMapper.deletePointById(pointId, operator); |
| | | if (result > 0) { |
| | | return R.ok(); |
| | | } |
| | | return R.fail("删除失败"); |
| | | } |
| | | |
| | | @Override |
| | | public R detailPoint(Long pointId) { |
| | | ConvenientElevatingPointDO convenientElevatingPointDO = this.baseMapper.selectById(pointId); |
| | | return R.ok(convenientElevatingPointDO); |
| | | } |
| | | } |
New file |
| | |
| | | package com.panzhihua.service_community.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | 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.ConvenientGoodsCategoryDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.ConvenientServiceCategoryDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageConvenientGoodsCategoryDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PageConvenientServiceCategoryDTO; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientGoodsCategoryVO; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientServiceCategoryVO; |
| | | import com.panzhihua.service_community.dao.ConvenientGoodsCategoryDAO; |
| | | import com.panzhihua.service_community.dao.ConvenientServiceCategoryDAO; |
| | | import com.panzhihua.service_community.model.dos.ConvenientGoodsCategoryDO; |
| | | import com.panzhihua.service_community.model.dos.ConvenientServiceCategoryDO; |
| | | import com.panzhihua.service_community.service.ConvenientGoodsCategoryService; |
| | | import com.panzhihua.service_community.service.ConvenientServiceCategoryService; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.util.ObjectUtils; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | |
| | | import static java.util.Objects.isNull; |
| | | |
| | | /** |
| | | * @title: ConvenientGoodsCategoryServiceImpl |
| | | * @projectName: 成都呐喊信息技术有限公司-智慧社区项目 |
| | | * @description: 商品分类服务实现类 |
| | | * @author: yh |
| | | * @date: 2022-10-21 09:36:09 |
| | | */ |
| | | @Service |
| | | public class ConvenientGoodsCategoryServiceImpl extends ServiceImpl<ConvenientGoodsCategoryDAO, ConvenientGoodsCategoryDO> |
| | | implements ConvenientGoodsCategoryService { |
| | | |
| | | @Override |
| | | public R addGoodsCategory(ConvenientGoodsCategoryDTO convenientGoodsCategoryDTO) { |
| | | ConvenientGoodsCategoryDO convenientGoodsCategoryDO = new ConvenientGoodsCategoryDO(); |
| | | BeanUtils.copyProperties(convenientGoodsCategoryDTO, convenientGoodsCategoryDO); |
| | | convenientGoodsCategoryDO.setCreatedAt(new Date()); |
| | | int result = this.baseMapper.insert(convenientGoodsCategoryDO); |
| | | if (result > 0) { |
| | | return R.ok(); |
| | | } |
| | | return R.fail("添加失败"); |
| | | } |
| | | |
| | | @Override |
| | | public R putGoodsCategory(ConvenientGoodsCategoryDTO convenientGoodsCategoryDTO) { |
| | | ConvenientGoodsCategoryDO convenientGoodsCategoryDO = this.baseMapper.selectById(convenientGoodsCategoryDTO.getId()); |
| | | if (isNull(convenientGoodsCategoryDO)) { |
| | | return R.fail("分类id不存在"); |
| | | } |
| | | BeanUtils.copyProperties(convenientGoodsCategoryDTO, convenientGoodsCategoryDO); |
| | | int result = this.baseMapper.updateById(convenientGoodsCategoryDO); |
| | | if (result > 0) { |
| | | return R.ok(); |
| | | } |
| | | return R.fail("更新失败"); |
| | | } |
| | | |
| | | @Override |
| | | public R deleteGoodsCategoryById(Long categoryId, Long operator) { |
| | | if (isNull(categoryId)) { |
| | | return R.fail("分类id不能为空"); |
| | | } |
| | | ConvenientGoodsCategoryDO convenientGoodsCategoryDO = this.baseMapper.selectById(categoryId); |
| | | if (isNull(convenientGoodsCategoryDO)) { |
| | | return R.fail("分类id不存在"); |
| | | } |
| | | int count = this.baseMapper.checkCategoryIsUsing(categoryId); |
| | | if (count > 0) { |
| | | return R.fail("该分类名称已被引用,无法删除!"); |
| | | } |
| | | convenientGoodsCategoryDO.setIsDel(true); |
| | | convenientGoodsCategoryDO.setUpdatedBy(operator); |
| | | int result = this.baseMapper.updateById(convenientGoodsCategoryDO); |
| | | if (result > 0) { |
| | | return R.ok(); |
| | | } |
| | | return R.fail("删除失败"); |
| | | } |
| | | |
| | | @Override |
| | | public R getGoodsCategoryById(Long goodsId) { |
| | | if (isNull(goodsId)) { |
| | | return R.fail("分类id不能为空"); |
| | | } |
| | | ConvenientGoodsCategoryDO convenientGoodsCategoryDO = this.baseMapper.selectById(goodsId); |
| | | if (isNull(convenientGoodsCategoryDO)) { |
| | | return R.fail("分类id不存在"); |
| | | } |
| | | ConvenientGoodsCategoryVO convenientGoodsCategoryVO = new ConvenientGoodsCategoryVO(); |
| | | BeanUtils.copyProperties(convenientGoodsCategoryDO, convenientGoodsCategoryVO); |
| | | return R.ok(convenientGoodsCategoryVO); |
| | | } |
| | | |
| | | @Override |
| | | public R pageGoodsCategory(PageConvenientGoodsCategoryDTO pageConvenientGoodsCategoryDTO) { |
| | | Page page = new Page<>(); |
| | | page.setSize(pageConvenientGoodsCategoryDTO.getPageSize()); |
| | | page.setCurrent(pageConvenientGoodsCategoryDTO.getPageNum()); |
| | | IPage<ConvenientGoodsCategoryVO> iPage = this.baseMapper.pageGoodsCategory(page, pageConvenientGoodsCategoryDTO); |
| | | return R.ok(iPage); |
| | | } |
| | | |
| | | @Override |
| | | public R getAllGoodsCategories(String areaCode) { |
| | | List<ConvenientGoodsCategoryVO> categoryVOList = new ArrayList<>(); |
| | | List<ConvenientGoodsCategoryDO> categoryDOS = this.baseMapper.selectList(new QueryWrapper<ConvenientGoodsCategoryDO>() |
| | | .lambda().eq(ConvenientGoodsCategoryDO::getAreaCode,areaCode).orderByDesc(ConvenientGoodsCategoryDO::getWeight)); |
| | | if (!ObjectUtils.isEmpty(categoryDOS)) { |
| | | categoryDOS.forEach(categoryDO -> { |
| | | ConvenientGoodsCategoryVO categoryVO = new ConvenientGoodsCategoryVO(); |
| | | BeanUtils.copyProperties(categoryDO, categoryVO); |
| | | categoryVOList.add(categoryVO); |
| | | }); |
| | | } |
| | | return R.ok(categoryVOList); |
| | | } |
| | | |
| | | } |
| | |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | import cn.binarywang.wx.miniapp.config.impl.WxMaRedisBetterConfigImpl; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.user.SysAppConfigVO; |
| | | import com.panzhihua.common.service.user.UserService; |
| | | import com.panzhihua.common.utlis.StringUtils; |
| | | import me.chanjar.weixin.common.redis.RedisTemplateWxRedisOps; |
| | | import me.chanjar.weixin.common.redis.WxRedisOps; |
| | | import org.springframework.data.redis.core.StringRedisTemplate; |
| | | import org.springframework.stereotype.Component; |
| | | |
| | | import cn.binarywang.wx.miniapp.api.WxMaService; |
| | |
| | | |
| | | @Resource |
| | | private WxMaProperties properties; |
| | | @Resource |
| | | private StringRedisTemplate stringRedisTemplate; |
| | | |
| | | @Resource |
| | | private UserService userService; |
| | | |
| | | |
| | | public WxMaService getMaService() { |
| | | WxMaDefaultConfigImpl config = new WxMaDefaultConfigImpl(); |
| | |
| | | wxMaService.setWxMaConfig(config); |
| | | return wxMaService; |
| | | } |
| | | |
| | | public WxMaService getMaService(String appid) { |
| | | WxRedisOps redisOps = new RedisTemplateWxRedisOps(stringRedisTemplate); |
| | | WxMaRedisBetterConfigImpl config = new WxMaRedisBetterConfigImpl(redisOps, "access_token"); |
| | | if(StringUtils.isNotEmpty(appid)){ |
| | | R<SysAppConfigVO> r=userService.selectByAppid(appid); |
| | | if(R.isOk(r)){ |
| | | SysAppConfigVO sysAppConfigVO= r.getData(); |
| | | config.setAppid(sysAppConfigVO.getAppId()); |
| | | config.setSecret(sysAppConfigVO.getSecret()); |
| | | config.setMsgDataFormat(properties.getMsgDataFormat()); |
| | | } |
| | | } |
| | | else{ |
| | | config.setAppid(properties.getAppid()); |
| | | config.setSecret(properties.getSecret()); |
| | | config.setMsgDataFormat(properties.getMsgDataFormat()); |
| | | } |
| | | WxMaService wxMaService = new WxMaServiceImpl(); |
| | | wxMaService.setWxMaConfig(config); |
| | | return wxMaService; |
| | | } |
| | | } |
| | |
| | | SELECT |
| | | (select count(id) from com_act_dpc where community_id = ${communityId} AND is_del = 0) AS dpcNum |
| | | </select> |
| | | <select id="getBanner" resultType="com.panzhihua.common.model.vos.community.easyPhoto.BannerVO"> |
| | | select * from com_act_dyn where type=1 AND on_top=1 |
| | | </select> |
| | | |
| | | </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_community.dao.ComActProceedingsDao"> |
| | | <resultMap id="BaseResultMap" type="com.panzhihua.service_community.entity.ComActProceedings"> |
| | | <id column="id" jdbcType="BIGINT" property="id" /> |
| | | <result column="name" jdbcType="VARCHAR" property="name" /> |
| | | <result column="unit_name" jdbcType="VARCHAR" property="unitName" /> |
| | | <result column="unit_id" jdbcType="BIGINT" property="unitId" /> |
| | | <result column="introduce" jdbcType="VARCHAR" property="introduce" /> |
| | | <result column="del_flag" jdbcType="BIT" property="delFlag" /> |
| | | <result column="status" jdbcType="BIT" property="status" /> |
| | | <result column="create_time" jdbcType="TIMESTAMP" property="createTime" /> |
| | | <result column="create_by" jdbcType="VARCHAR" property="createBy" /> |
| | | <result column="update_time" jdbcType="TIMESTAMP" property="updateTime" /> |
| | | <result column="update_by" jdbcType="TIMESTAMP" property="updateBy" /> |
| | | </resultMap> |
| | | <sql id="Base_Column_List"> |
| | | id, `name`, unit_name, unit_id, introduce, del_flag, `status`, create_time, create_by, |
| | | update_time, update_by |
| | | </sql> |
| | | <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap"> |
| | | select |
| | | <include refid="Base_Column_List" /> |
| | | from com_act_proceedings |
| | | where id = #{id,jdbcType=BIGINT} |
| | | </select> |
| | | <delete id="deleteByPrimaryKey" parameterType="java.lang.Long"> |
| | | delete from com_act_proceedings |
| | | where id = #{id,jdbcType=BIGINT} |
| | | </delete> |
| | | <insert id="insert" keyColumn="id" keyProperty="id" parameterType="com.panzhihua.service_community.entity.ComActProceedings" useGeneratedKeys="true"> |
| | | insert into com_act_proceedings (id,`name`, unit_name, unit_id, |
| | | introduce, del_flag, `status`, |
| | | create_time) |
| | | values (#{id},#{name,jdbcType=VARCHAR}, #{unitName,jdbcType=VARCHAR}, #{unitId,jdbcType=BIGINT}, |
| | | #{introduce,jdbcType=VARCHAR}, #{delFlag,jdbcType=BIT}, #{status,jdbcType=BIT}, |
| | | #{createTime,jdbcType=TIMESTAMP}) |
| | | </insert> |
| | | <insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="com.panzhihua.service_community.entity.ComActProceedings" useGeneratedKeys="true"> |
| | | insert into com_act_proceedings |
| | | <trim prefix="(" suffix=")" suffixOverrides=","> |
| | | <if test="id != null"> |
| | | `id`, |
| | | </if> |
| | | <if test="name != null"> |
| | | `name`, |
| | | </if> |
| | | <if test="unitName != null"> |
| | | unit_name, |
| | | </if> |
| | | <if test="unitId != null"> |
| | | unit_id, |
| | | </if> |
| | | <if test="introduce != null"> |
| | | introduce, |
| | | </if> |
| | | <if test="delFlag != null"> |
| | | del_flag, |
| | | </if> |
| | | <if test="status != null"> |
| | | `status`, |
| | | </if> |
| | | <if test="createTime != null"> |
| | | create_time, |
| | | </if> |
| | | <if test="createBy != null"> |
| | | create_by, |
| | | </if> |
| | | <if test="updateTime != null"> |
| | | update_time, |
| | | </if> |
| | | <if test="updateBy != null"> |
| | | update_by, |
| | | </if> |
| | | </trim> |
| | | <trim prefix="values (" suffix=")" suffixOverrides=","> |
| | | <if test="id != null"> |
| | | #{id,jdbcType=BIGINT}, |
| | | </if> |
| | | <if test="name != null"> |
| | | #{name,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="unitName != null"> |
| | | #{unitName,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="unitId != null"> |
| | | #{unitId,jdbcType=BIGINT}, |
| | | </if> |
| | | <if test="introduce != null"> |
| | | #{introduce,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="delFlag != null"> |
| | | #{delFlag,jdbcType=BIT}, |
| | | </if> |
| | | <if test="status != null"> |
| | | #{status,jdbcType=BIT}, |
| | | </if> |
| | | <if test="createTime != null"> |
| | | #{createTime,jdbcType=TIMESTAMP}, |
| | | </if> |
| | | <if test="createBy != null"> |
| | | #{createBy,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="updateTime != null"> |
| | | #{updateTime,jdbcType=TIMESTAMP}, |
| | | </if> |
| | | <if test="updateBy != null"> |
| | | #{updateBy,jdbcType=TIMESTAMP}, |
| | | </if> |
| | | </trim> |
| | | </insert> |
| | | <update id="updateByPrimaryKeySelective" parameterType="com.panzhihua.service_community.entity.ComActProceedings"> |
| | | update com_act_proceedings |
| | | <set> |
| | | <if test="name != null"> |
| | | `name` = #{name,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="unitName != null"> |
| | | unit_name = #{unitName,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="unitId != null"> |
| | | unit_id = #{unitId,jdbcType=BIGINT}, |
| | | </if> |
| | | <if test="introduce != null"> |
| | | introduce = #{introduce,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="delFlag != null"> |
| | | del_flag = #{delFlag,jdbcType=BIT}, |
| | | </if> |
| | | <if test="status != null"> |
| | | `status` = #{status,jdbcType=BIT}, |
| | | </if> |
| | | <if test="createTime != null"> |
| | | create_time = #{createTime,jdbcType=TIMESTAMP}, |
| | | </if> |
| | | <if test="createBy != null"> |
| | | create_by = #{createBy,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="updateTime != null"> |
| | | update_time = #{updateTime,jdbcType=TIMESTAMP}, |
| | | </if> |
| | | <if test="updateBy != null"> |
| | | update_by = #{updateBy,jdbcType=TIMESTAMP}, |
| | | </if> |
| | | </set> |
| | | where id = #{id,jdbcType=BIGINT} |
| | | </update> |
| | | <update id="updateByPrimaryKey" parameterType="com.panzhihua.service_community.entity.ComActProceedings"> |
| | | update com_act_proceedings |
| | | set `name` = #{name,jdbcType=VARCHAR}, |
| | | unit_name = #{unitName,jdbcType=VARCHAR}, |
| | | unit_id = #{unitId,jdbcType=BIGINT}, |
| | | introduce = #{introduce,jdbcType=VARCHAR}, |
| | | del_flag = #{delFlag,jdbcType=BIT}, |
| | | `status` = #{status,jdbcType=BIT}, |
| | | create_time = #{createTime,jdbcType=TIMESTAMP}, |
| | | create_by = #{createBy,jdbcType=VARCHAR}, |
| | | update_time = #{updateTime,jdbcType=TIMESTAMP}, |
| | | update_by = #{updateBy,jdbcType=TIMESTAMP} |
| | | where id = #{id,jdbcType=BIGINT} |
| | | </update> |
| | | <select id="pageProceedings" resultType="com.panzhihua.service_community.entity.ComActProceedings"> |
| | | select * from com_act_proceedings where del_flag=0 |
| | | <if test="keyWord != null and keyWord != ''"> |
| | | AND name like concat("%",#{keyWord},"%") |
| | | </if> |
| | | </select> |
| | | </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_community.dao.ConvenientElevatingPointDAO"> |
| | | <resultMap id="BaseResultMap" type="com.panzhihua.service_community.model.dos.ConvenientElevatingPointDO"> |
| | | <!--@Table com_convenient_elevating_point--> |
| | | <id column="id" jdbcType="BIGINT" property="id"/> |
| | | <result column="name" jdbcType="VARCHAR" property="name"/> |
| | | <result column="community_id" jdbcType="VARCHAR" property="communityId"/> |
| | | <result column="community_name" jdbcType="VARCHAR" property="communityName"/> |
| | | <result column="address" jdbcType="VARCHAR" property="address"/> |
| | | <result column="contacts" jdbcType="VARCHAR" property="contacts"/> |
| | | <result column="phone" jdbcType="VARCHAR" property="phone"/> |
| | | <result column="wechat_account" jdbcType="VARCHAR" property="wechatAccount"/> |
| | | <result column="lat" jdbcType="VARCHAR" property="lat"/> |
| | | <result column="lon" jdbcType="VARCHAR" property="lon"/> |
| | | <result column="business_status" property="businessStatus"/> |
| | | <result column="cumulative_goods_num" jdbcType="BIGINT" property="cumulativeGoodsNum"/> |
| | | <result column="prepare_goods_num" jdbcType="BIGINT" property="prepareGoodsNum"/> |
| | | <result column="already_goods_num" jdbcType="BIGINT" property="alreadyGoodsNum"/> |
| | | <result column="is_del" jdbcType="BIT" property="isDel"/> |
| | | <result column="created_at" jdbcType="TIMESTAMP" property="createdAt"/> |
| | | <result column="created_by" jdbcType="BIGINT" property="createdBy"/> |
| | | <result column="updated_at" jdbcType="TIMESTAMP" property="updatedAt"/> |
| | | <result column="updated_by" jdbcType="BIGINT" property="updatedBy"/> |
| | | </resultMap> |
| | | <sql id="Base_Column_List"> |
| | | id, `name`, community_id, community_name, address, contacts, phone, wechat_account, |
| | | lat, lon, `business_status`, cumulative_goods_num, prepare_goods_num, already_goods_num, is_del, |
| | | created_at, created_by, updated_at, updated_by |
| | | </sql> |
| | | |
| | | <select id="page" resultType="com.panzhihua.common.model.vos.community.convenient.ConvenientElevatingPointVO"> |
| | | SELECT cce.* FROM com_convenient_elevating_point cce WHERE cce.is_del = 0 |
| | | <if test="pageConvenientElevatingPointDTO.businessStatus != null and pageConvenientElevatingPointDTO.businessStatus != ''"> |
| | | AND cce.business_status = #{pageConvenientElevatingPointDTO.businessStatus} |
| | | </if> |
| | | <if test="pageConvenientElevatingPointDTO.communityId != null and pageConvenientElevatingPointDTO.communityId != 0"> |
| | | AND ccm.community_id = ${pageConvenientElevatingPointDTO.communityId} |
| | | </if> |
| | | |
| | | <if test="pageConvenientElevatingPointDTO.keyword != null and pageConvenientElevatingPointDTO.keyword != """> |
| | | AND ( |
| | | cce.name LIKE CONCAT('%', #{pageConvenientElevatingPointDTO.keyword}, '%') |
| | | OR cce.address LIKE CONCAT('%', #{pageConvenientElevatingPointDTO.keyword}, '%') |
| | | OR cce.contacts LIKE CONCAT('%', #{pageConvenientElevatingPointDTO.keyword}, '%') |
| | | ) |
| | | </if> |
| | | ORDER BY cce.prepare_goods_num DESC |
| | | </select> |
| | | |
| | | <update id="deletePointById"> |
| | | UPDATE com_convenient_elevating_point SET is_del = 1, updated_by = #{operator} WHERE id = #{pointId} |
| | | </update> |
| | | </mapper> |
| | |
| | | FROM com_sanshuo_event_info |
| | | <where> |
| | | event_process_status !=9 |
| | | AND app_id=#{comEvent.appId} |
| | | <if test="comEvent.keyword != null and comEvent.keyword!=''" > |
| | | AND ( order_sn = #{comEvent.keyword} or request_user_tel =#{comEvent.keyword} or current_org_name=#{comEvent.keyword}) |
| | | </if> |
| | |
| | | FROM com_sanshuo_event_info |
| | | <where> |
| | | event_process_status !=9 |
| | | AND app_id=#{comEvent.appId} |
| | | <if test="eventIds != null"> |
| | | AND id in |
| | | <foreach collection="eventIds" item="id" separator="," open="(" close=")"> |
| | |
| | | from com_sanshuo_event_info |
| | | <where> |
| | | event_process_status not in (9) |
| | | AND app_id=#{comEvent.appId} |
| | | <if test="comEvent.userType == 1"> |
| | | AND request_user_id=#{comEvent.requestUserId} |
| | | </if> |
| | |
| | | from com_sanshuo_event_info |
| | | <where> |
| | | event_process_status not in (9) |
| | | |
| | | AND app_id=#{comEvent.appId} |
| | | <if test="comEvent.userType == 1"> |
| | | AND request_user_id=#{comEvent.requestUserId} |
| | | </if> |
| | |
| | | (SELECT count(id) FROM com_sanshuo_event_info |
| | | where event_process_status in (2,3,5,6) |
| | | AND user_event_status not in(3,4) |
| | | AND app_id='wx0cef797390444b75' |
| | | <if test="dto.type == 2"> |
| | | AND current_process_type=1 |
| | | <if test="dto.id != null"> |
| | |
| | | (SELECT count(id) FROM com_sanshuo_event_info |
| | | where event_process_status = 5 |
| | | AND user_event_status not in(3,4) |
| | | AND app_id='wx0cef797390444b75' |
| | | <if test="dto.type == 2"> |
| | | AND current_process_type=1 |
| | | <if test="dto.id != null"> |
| | |
| | | (SELECT count(id) FROM com_sanshuo_event_info |
| | | where event_process_status = 6 |
| | | AND user_event_status not in(3) |
| | | AND app_id='wx0cef797390444b75' |
| | | <if test="dto.type == 2"> |
| | | AND current_process_type=1 |
| | | <if test="dto.id != null"> |
| | |
| | | where t.event_process_status in (6,7) |
| | | AND t.user_event_status not in(3,4) |
| | | AND t1.event_status=7 |
| | | AND app_id='wx0cef797390444b75' |
| | | <if test="dto.type == 2"> |
| | | AND t.current_process_type=1 |
| | | <if test="dto.id != null"> |
| | |
| | | (select count(id) FROM com_sanshuo_event_info |
| | | where event_result=2 |
| | | AND user_event_status not in(3,4) |
| | | AND app_id='wx0cef797390444b75' |
| | | <if test="dto.type == 2"> |
| | | AND current_process_type=1 |
| | | <if test="dto.id != null"> |
| | |
| | | (select count(id) FROM com_sanshuo_event_info |
| | | where event_result=1 |
| | | AND user_event_status not in(3,4) |
| | | AND app_id='wx0cef797390444b75' |
| | | <if test="dto.type == 2"> |
| | | AND current_process_type=1 |
| | | <if test="dto.id != null"> |
| | |
| | | (select count(id) from com_sanshuo_event_info WHERE |
| | | create_at BETWEEN DATE_FORMAT(#{beginDate}, '%Y-%m-%d 00:00:00') AND DATE_FORMAT(#{endDate}, '%Y-%m-%d 23:59:59') |
| | | AND event_process_status not in (8) |
| | | AND app_id='wx0cef797390444b75' |
| | | <if test="dto.type == 2"> |
| | | AND current_process_type=1 |
| | | <if test="dto.id != null"> |
| | |
| | | create_at BETWEEN DATE_FORMAT(#{beginDate}, '%Y-%m-%d 00:00:00') AND DATE_FORMAT(#{endDate}, '%Y-%m-%d 23:59:59') |
| | | AND event_process_status not in (8) |
| | | AND event_process_status = 6 |
| | | AND app_id='wx0cef797390444b75' |
| | | <if test="dto.type == 2"> |
| | | AND current_process_type=1 |
| | | <if test="dto.id != null"> |
| | |
| | | SELECT COUNT(id) FROM com_sanshuo_event_info |
| | | WHERE create_at BETWEEN DATE_FORMAT(#{beginDate}, '%Y-%m-%d 00:00:00') AND DATE_FORMAT(#{endDate}, '%Y-%m-%d 23:59:59') |
| | | AND event_process_status not in (9) |
| | | AND app_id='wx0cef797390444b75' |
| | | <if test="dto.type == 2"> |
| | | AND current_process_type=1 |
| | | <if test="dto.id != null"> |
| | |
| | | SELECT COUNT(id) FROM com_sanshuo_event_info |
| | | WHERE create_at BETWEEN DATE_FORMAT(#{beginDate}, '%Y-%m-%d 00:00:00') AND DATE_FORMAT(#{endDate}, '%Y-%m-%d 23:59:59') |
| | | AND event_process_status=6 |
| | | AND app_id='wx0cef797390444b75' |
| | | <if test="dto.type == 2"> |
| | | AND current_process_type=1 |
| | | <if test="dto.id != null"> |
| | |
| | | <select id="eventRate" resultType="com.panzhihua.common.model.vos.sanshuo.EventRateVO"> |
| | | select count(id) as count,current_process_type from com_sanshuo_event_info |
| | | where event_process_status not in(7,8,9) |
| | | AND app_id='wx0cef797390444b75' |
| | | group by current_process_type |
| | | having current_process_type <>5 |
| | | </select> |
| | | <select id="expertRate" resultType="com.panzhihua.common.model.vos.sanshuo.EventRateVO"> |
| | | select count(id) as count,level as type from com_sanshuo_expert |
| | | select count(id) as count,level as type from com_sanshuo_expert where app_id='wx0cef797390444b75' |
| | | group by level |
| | | </select> |
| | | <select id="mediateTypeRate" resultType="com.panzhihua.common.model.vos.sanshuo.EventRateVO"> |
| | | select count(t.id) as count,t1.name from com_sanshuo_event_info t |
| | | left join com_mediate_type t1 on t.event_category=t1.id |
| | | where t.event_process_status not in(7,8,9) |
| | | AND t.app_id='wx0cef797390444b75' |
| | | group by t.event_category |
| | | </select> |
| | | |
| | |
| | | <if test='comMngVolunteerMngVO.phone != null and comMngVolunteerMngVO.phone != ""'> |
| | | AND cmvm.phone like concat(#{comMngVolunteerMngVO.phone},'%') |
| | | </if> |
| | | <if test="comMngVolunteerMngVO.propertyId != null and comMngVolunteerMngVO.propertyId != ''"> |
| | | AND cmvm.property_id=#{comMngVolunteerMngVO.propertyId} |
| | | </if> |
| | | ORDER BY |
| | | integral DESC, |
| | | cmvm.create_at DESC |
| | |
| | | ) |
| | | </select> |
| | | |
| | | <select id="noticeList" resultType="com.panzhihua.common.model.vos.community.ComActAnnouncementVO"> |
| | | select * from com_act_announcement where property_id=#{propertyId} |
| | | </select> |
| | | |
| | | </mapper> |
| | |
| | | introduction,street_id,industry_center_id, |
| | | unit_id,unit from com_sanshuo_expert |
| | | where del_flag=1 |
| | | AND app_id=#{appId} |
| | | <if test="keyWord != null and keyWord != ''"> |
| | | AND unit like concat('%',#{keyWord},'%') |
| | | OR name like concat('%',#{keyWord},'%') |
| | |
| | | introduction,street_id,industry_center_id, |
| | | unit_id,unit from com_sanshuo_expert |
| | | where del_flag=1 |
| | | AND app_id=#{appId} |
| | | <if test="level != null"> |
| | | <if test="level == 2"> |
| | | AND level = 2 |
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_community.dao.ComShopFlowerEvaluateDAO"> |
| | | <resultMap id="BaseResultMap" type="com.panzhihua.service_community.model.dos.ComShopFlowerEvaluateDO"> |
| | | <!--@mbg.generated--> |
| | | <!--@Table com_shop_flower_evaluate--> |
| | | <id column="id" jdbcType="BIGINT" property="id" /> |
| | | <result column="order_no" jdbcType="VARCHAR" property="orderNo" /> |
| | | <result column="goods_id" jdbcType="VARCHAR" property="goodsId" /> |
| | | <result column="user_id" jdbcType="BIGINT" property="userId" /> |
| | | <result column="evaluate_time" jdbcType="TIMESTAMP" property="evaluateTime" /> |
| | | <result column="evaluate_type" jdbcType="TINYINT" property="evaluateType" /> |
| | | <result column="evaluate_content" jdbcType="VARCHAR" property="evaluateContent" /> |
| | | <result column="evaluate_pic" jdbcType="VARCHAR" property="evaluatePic" /> |
| | | <result column="create_at" jdbcType="TIMESTAMP" property="createAt" /> |
| | | </resultMap> |
| | | <sql id="Base_Column_List"> |
| | | <!--@mbg.generated--> |
| | | id, order_no, goods_id, user_id, evaluate_time, evaluate_type, evaluate_content, |
| | | evaluate_pic, create_at |
| | | </sql> |
| | | </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_community.dao.ComShopFlowerGoodsAttrDAO"> |
| | | <resultMap id="BaseResultMap" type="com.panzhihua.service_community.model.dos.ComShopFlowerGoodsAttrDO"> |
| | | <!--@mbg.generated--> |
| | | <!--@Table com_shop_flower_goods_attr--> |
| | | <id column="id" jdbcType="BIGINT" property="id"/> |
| | | <result column="goods_id" jdbcType="BIGINT" property="goodsId"/> |
| | | <result column="store_id" jdbcType="BIGINT" property="storeId"/> |
| | | <result column="goods_name" jdbcType="VARCHAR" property="goodsName"/> |
| | | <result column="goods_attr_name" jdbcType="VARCHAR" property="goodsAttrName"/> |
| | | <result column="stock" jdbcType="INTEGER" property="stock"/> |
| | | <result column="sale" jdbcType="INTEGER" property="sale"/> |
| | | <result column="attr_pic" jdbcType="VARCHAR" property="attrPic"/> |
| | | <result column="is_default" jdbcType="TINYINT" property="isDefault"/> |
| | | <result column="price" jdbcType="DECIMAL" property="price"/> |
| | | <result column="free_shipping_price" jdbcType="DECIMAL" property="freeShippingPrice"/> |
| | | <result column="collate_price" jdbcType="DECIMAL" property="collatePrice"/> |
| | | <result column="create_at" jdbcType="TIMESTAMP" property="createAt"/> |
| | | <result column="update_at" jdbcType="TIMESTAMP" property="updateAt"/> |
| | | </resultMap> |
| | | <sql id="Base_Column_List"> |
| | | <!--@mbg.generated--> |
| | | id, goods_id, store_id, goods_name, goods_attr_name, stock, sale, attr_pic, is_default, |
| | | price, free_shipping_price, collate_price, create_at, update_at |
| | | </sql> |
| | | <select id="getGoodsAttr" resultType="com.panzhihua.common.model.vos.shop.ComShopFlowerGoodsAttrVO"> |
| | | select <include refid="Base_Column_List"/> from com_shop_flower_goods_attr where goods_id = #{goodsId} |
| | | </select> |
| | | </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_community.dao.ComShopFlowerGoodsDAO"> |
| | | <resultMap id="BaseResultMap" type="com.panzhihua.service_community.model.dos.ComShopFlowerGoodsDO"> |
| | | <!--@mbg.generated--> |
| | | <!--@Table com_shop_flower_goods--> |
| | | <id column="id" jdbcType="BIGINT" property="id"/> |
| | | <result column="type_id" jdbcType="BIGINT" property="typeId"/> |
| | | <result column="name" jdbcType="VARCHAR" property="name"/> |
| | | <result column="store_id" jdbcType="BIGINT" property="storeId"/> |
| | | <result column="goods_pic" jdbcType="VARCHAR" property="goodsPic"/> |
| | | <result column="images" jdbcType="VARCHAR" property="images"/> |
| | | <result column="status" jdbcType="TINYINT" property="status"/> |
| | | <result column="sale" jdbcType="INTEGER" property="sale"/> |
| | | <result column="original_price" jdbcType="DECIMAL" property="originalPrice"/> |
| | | <result column="price" jdbcType="DECIMAL" property="price"/> |
| | | <result column="unit" jdbcType="VARCHAR" property="unit"/> |
| | | <result column="order" jdbcType="INTEGER" property="order"/> |
| | | <result column="stock" jdbcType="INTEGER" property="stock"/> |
| | | <result column="details" jdbcType="LONGVARCHAR" property="details"/> |
| | | <result column="remark" jdbcType="VARCHAR" property="remark"/> |
| | | <result column="goods_describe" jdbcType="VARCHAR" property="goodsDescribe"/> |
| | | <result column="delivery_type" jdbcType="TINYINT" property="deliveryType"/> |
| | | <result column="delete_status" jdbcType="TINYINT" property="deleteStatus"/> |
| | | <result column="create_at" jdbcType="TIMESTAMP" property="createAt"/> |
| | | <result column="update_at" jdbcType="TIMESTAMP" property="updateAt"/> |
| | | </resultMap> |
| | | <sql id="Base_Column_List"> |
| | | <!--@mbg.generated--> |
| | | id, type_id, `name`, store_id, goods_pic, images, `status`, sale, original_price, |
| | | price, unit, `order`, stock, details, remark, goods_describe, delivery_type, delete_status, |
| | | create_at, update_at |
| | | </sql> |
| | | <select id="pageShopGoods" resultType="com.panzhihua.common.model.vos.shop.PageShopFlowerGoodsVO"> |
| | | select c.id,c.type_id,ccm.name as |
| | | storeName,c.name,c.store_id,c.goods_pic,c.images,c.status,c.sale,c.original_price,c.price,c.unit,c.order,c.stock,c.details,c.remark,c.goods_describe,c.delivery_type,c.delete_status,c.create_at,c.update_at |
| | | from com_shop_flower_goods c |
| | | left join com_convenient_merchants ccm on c.store_id=ccm.id |
| | | <where>and |
| | | <if test='pageComShopFlowerGoodsDTO.storeName != null and pageComShopFlowerGoodsDTO.storeName.trim() != ""'> |
| | | c.delete_status = 1 and ccm.id_del = 0 |
| | | and ccm.name like concat('%',#{pageComShopFlowerGoodsDTO.storeName},'%') |
| | | </if> |
| | | <if test='pageComShopFlowerGoodsDTO.name != null and pageComShopFlowerGoodsDTO.name.trim() != ""'>and c.name |
| | | like concat('%',#{pageComShopFlowerGoodsDTO.name},'%') |
| | | </if> |
| | | <if test='pageComShopFlowerGoodsDTO.storeId != null'>and ccm.id=#{pageComShopFlowerGoodsDTO.storeId} |
| | | </if> |
| | | <if test='pageComShopFlowerGoodsDTO.status != null'>and c.status like |
| | | concat('%',#{pageComShopFlowerGoodsDTO.status},'%') |
| | | </if> |
| | | </where> |
| | | order by c.create_at desc |
| | | </select> |
| | | <select id="pageShopGoodsByStoreId" resultType="com.panzhihua.common.model.vos.shop.ComShopFlowerGoodsVO"> |
| | | select id,`name`,store_id,goods_pic,images,`status`,sale,original_price,price |
| | | ,unit,`order`,stock,details,delivery_type from com_shop_flower_goods where store_id = |
| | | #{pageComShopFlowerStoreDTO.storeId} |
| | | and delete_status = 1 and status = 1 order by sale desc,create_at desc |
| | | </select> |
| | | <select id="pageShopGoodByApps" resultType="com.panzhihua.common.model.vos.shop.ComShopFlowerGoodsVO"> |
| | | select csg.id,csg.`name`,csg.store_id,csg.goods_pic,csg.images,csg.`status`,csg.sale,csg.original_price |
| | | ,csg.price,csg.unit,csg.`order`,csg.stock,csg.details,csg.delivery_type, csg.create_at from com_shop_flower_goods as |
| | | csg left join com_convenient_merchants as css on css.id = csg.store_id where 1=1 and csg.delete_status = 1 and |
| | | css.`business_status` = 0 |
| | | <if test='comShopFlowerGoodsDTO.name != null and comShopFlowerGoodsDTO.name !=""'> |
| | | AND csg.`name` like concat('%',#{comShopFlowerGoodsDTO.name},'%') |
| | | </if> |
| | | <if test='comShopFlowerGoodsDTO.status != null '>AND csg.`status` = #{comShopFlowerGoodsDTO.status}</if> |
| | | <if test='comShopFlowerGoodsDTO.storeId != null '>AND csg.store_id = #{comShopFlowerGoodsDTO.storeId}</if> |
| | | <if test='comShopFlowerGoodsDTO.status != null '>AND csg.status = #{comShopFlowerGoodsDTO.status}</if> |
| | | <if test='comShopFlowerGoodsDTO.deliveryType != null '>AND csg.delivery_type = #{comShopFlowerGoodsDTO.deliveryType}</if> |
| | | order by sale desc,create_at desc |
| | | </select> |
| | | </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_community.dao.ComShopFlowerOrderDAO"> |
| | | <resultMap id="BaseResultMap" type="com.panzhihua.service_community.model.dos.ComShopFlowerOrderDO"> |
| | | <!--@mbg.generated--> |
| | | <!--@Table com_shop_flower_order--> |
| | | <id column="id" jdbcType="BIGINT" property="id" /> |
| | | <result column="store_id" jdbcType="BIGINT" property="storeId" /> |
| | | <result column="user_id" jdbcType="BIGINT" property="userId" /> |
| | | <result column="order_no" jdbcType="VARCHAR" property="orderNo" /> |
| | | <result column="pay_no" jdbcType="VARCHAR" property="payNo" /> |
| | | <result column="wx_tarde_no" jdbcType="VARCHAR" property="wxTardeNo" /> |
| | | <result column="status" jdbcType="TINYINT" property="status" /> |
| | | <result column="pay_status" jdbcType="TINYINT" property="payStatus" /> |
| | | <result column="receiver_id" jdbcType="BIGINT" property="receiverId" /> |
| | | <result column="delete_status" jdbcType="TINYINT" property="deleteStatus" /> |
| | | <result column="total_amount" jdbcType="DECIMAL" property="totalAmount" /> |
| | | <result column="discount_amount" jdbcType="DECIMAL" property="discountAmount" /> |
| | | <result column="pay_amount" jdbcType="DECIMAL" property="payAmount" /> |
| | | <result column="pay_type" jdbcType="TINYINT" property="payType" /> |
| | | <result column="pay_time" jdbcType="TIMESTAMP" property="payTime" /> |
| | | <result column="delivery_type" jdbcType="TINYINT" property="deliveryType" /> |
| | | <result column="delivery_status" jdbcType="TINYINT" property="deliveryStatus" /> |
| | | <result column="remark" jdbcType="VARCHAR" property="remark" /> |
| | | <result column="logistics_company" jdbcType="VARCHAR" property="logisticsCompany" /> |
| | | <result column="logistics_no" jdbcType="VARCHAR" property="logisticsNo" /> |
| | | <result column="create_at" jdbcType="TIMESTAMP" property="createAt" /> |
| | | <result column="update_at" jdbcType="TIMESTAMP" property="updateAt" /> |
| | | <result column="delivery_time" jdbcType="TIMESTAMP" property="deliveryTime" /> |
| | | <result column="service_time" jdbcType="TIMESTAMP" property="serviceTime" /> |
| | | <result column="receiving_time" jdbcType="TIMESTAMP" property="receivingTime" /> |
| | | <result column="refund_time" jdbcType="TIMESTAMP" property="refundTime" /> |
| | | </resultMap> |
| | | <sql id="Base_Column_List"> |
| | | <!--@mbg.generated--> |
| | | id, store_id, user_id, order_no, pay_no, wx_tarde_no, `status`, pay_status, receiver_id, |
| | | delete_status, total_amount, discount_amount, pay_amount, pay_type, pay_time, delivery_type, |
| | | delivery_status, remark, logistics_company, logistics_no, create_at, update_at, delivery_time, |
| | | service_time, receiving_time, refund_time |
| | | </sql> |
| | | </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_community.dao.ComShopFlowerOrderGoodsDAO"> |
| | | <resultMap id="BaseResultMap" type="com.panzhihua.service_community.model.dos.ComShopFlowerOrderGoodsDO"> |
| | | <!--@mbg.generated--> |
| | | <!--@Table com_shop_flower_order_goods--> |
| | | <id column="id" jdbcType="BIGINT" property="id" /> |
| | | <result column="store_id" jdbcType="BIGINT" property="storeId" /> |
| | | <result column="order_id" jdbcType="BIGINT" property="orderId" /> |
| | | <result column="user_id" jdbcType="BIGINT" property="userId" /> |
| | | <result column="order_no" jdbcType="VARCHAR" property="orderNo" /> |
| | | <result column="goods_id" jdbcType="BIGINT" property="goodsId" /> |
| | | <result column="goods_attr_id" jdbcType="BIGINT" property="goodsAttrId" /> |
| | | <result column="goods_attr_name" jdbcType="VARCHAR" property="goodsAttrName" /> |
| | | <result column="amount" jdbcType="INTEGER" property="amount" /> |
| | | <result column="goods_attr_price" jdbcType="DECIMAL" property="goodsAttrPrice" /> |
| | | <result column="goods_attr_pic" jdbcType="VARCHAR" property="goodsAttrPic" /> |
| | | <result column="price" jdbcType="DECIMAL" property="price" /> |
| | | <result column="free_shipping_price" jdbcType="DECIMAL" property="freeShippingPrice" /> |
| | | <result column="collate_price" jdbcType="DECIMAL" property="collatePrice" /> |
| | | <result column="goods_name" jdbcType="VARCHAR" property="goodsName" /> |
| | | <result column="create_at" jdbcType="TIMESTAMP" property="createAt" /> |
| | | </resultMap> |
| | | <sql id="Base_Column_List"> |
| | | <!--@mbg.generated--> |
| | | id, store_id, order_id, user_id, order_no, goods_id, goods_attr_id, goods_attr_name, |
| | | amount, goods_attr_price, goods_attr_pic, price, free_shipping_price, collate_price, |
| | | goods_name, create_at |
| | | </sql> |
| | | </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_community.dao.ComShopFlowerOrderOperateDAO"> |
| | | <resultMap id="BaseResultMap" type="com.panzhihua.service_community.model.dos.ComShopFlowerOrderOperateDO"> |
| | | <!--@mbg.generated--> |
| | | <!--@Table com_shop_flower_order_operate--> |
| | | <id column="id" jdbcType="BIGINT" property="id" /> |
| | | <result column="order_no" jdbcType="VARCHAR" property="orderNo" /> |
| | | <result column="operation_by" jdbcType="VARCHAR" property="operationBy" /> |
| | | <result column="operation_time" jdbcType="TIMESTAMP" property="operationTime" /> |
| | | <result column="operation_type" jdbcType="TINYINT" property="operationType" /> |
| | | <result column="operation_content" jdbcType="VARCHAR" property="operationContent" /> |
| | | <result column="create_at" jdbcType="TIMESTAMP" property="createAt" /> |
| | | </resultMap> |
| | | <sql id="Base_Column_List"> |
| | | <!--@mbg.generated--> |
| | | id, order_no, operation_by, operation_time, operation_type, operation_content, create_at |
| | | </sql> |
| | | </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_community.dao.ComShopFlowerOrderPayDAO"> |
| | | <resultMap id="BaseResultMap" type="com.panzhihua.service_community.model.dos.ComShopFlowerOrderPayDO"> |
| | | <!--@mbg.generated--> |
| | | <!--@Table com_shop_flower_order_pay--> |
| | | <id column="id" jdbcType="BIGINT" property="id" /> |
| | | <result column="order_no" jdbcType="VARCHAR" property="orderNo" /> |
| | | <result column="pay_no" jdbcType="VARCHAR" property="payNo" /> |
| | | <result column="wx_trade_no" jdbcType="VARCHAR" property="wxTradeNo" /> |
| | | <result column="pay_status" jdbcType="TINYINT" property="payStatus" /> |
| | | <result column="order_amount" jdbcType="DECIMAL" property="orderAmount" /> |
| | | <result column="pay_amount" jdbcType="DECIMAL" property="payAmount" /> |
| | | <result column="pay_time" jdbcType="TIMESTAMP" property="payTime" /> |
| | | <result column="create_at" jdbcType="TIMESTAMP" property="createAt" /> |
| | | <result column="update_at" jdbcType="TIMESTAMP" property="updateAt" /> |
| | | </resultMap> |
| | | <sql id="Base_Column_List"> |
| | | <!--@mbg.generated--> |
| | | id, order_no, pay_no, wx_trade_no, pay_status, order_amount, pay_amount, pay_time, |
| | | create_at, update_at |
| | | </sql> |
| | | </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_community.dao.ComShopFlowerRefundOrderDAO"> |
| | | <resultMap id="BaseResultMap" type="com.panzhihua.service_community.model.dos.ComShopFlowerRefundOrderDO"> |
| | | <!--@mbg.generated--> |
| | | <!--@Table com_shop_flower_refund_order--> |
| | | <id column="id" jdbcType="BIGINT" property="id" /> |
| | | <result column="store_id" jdbcType="BIGINT" property="storeId" /> |
| | | <result column="user_id" jdbcType="BIGINT" property="userId" /> |
| | | <result column="order_no" jdbcType="VARCHAR" property="orderNo" /> |
| | | <result column="order_id" jdbcType="VARCHAR" property="orderId" /> |
| | | <result column="refund_order_no" jdbcType="VARCHAR" property="refundOrderNo" /> |
| | | <result column="status" jdbcType="TINYINT" property="status" /> |
| | | <result column="delete_status" jdbcType="TINYINT" property="deleteStatus" /> |
| | | <result column="pay_amount" jdbcType="DECIMAL" property="payAmount" /> |
| | | <result column="refund_amount" jdbcType="DECIMAL" property="refundAmount" /> |
| | | <result column="refund_reason" jdbcType="VARCHAR" property="refundReason" /> |
| | | <result column="refund_pic" jdbcType="VARCHAR" property="refundPic" /> |
| | | <result column="create_at" jdbcType="TIMESTAMP" property="createAt" /> |
| | | <result column="update_at" jdbcType="TIMESTAMP" property="updateAt" /> |
| | | <result column="handle_time" jdbcType="TIMESTAMP" property="handleTime" /> |
| | | <result column="refund_time" jdbcType="TIMESTAMP" property="refundTime" /> |
| | | <result column="handle_result" jdbcType="VARCHAR" property="handleResult" /> |
| | | <result column="remark" jdbcType="VARCHAR" property="remark" /> |
| | | </resultMap> |
| | | <sql id="Base_Column_List"> |
| | | <!--@mbg.generated--> |
| | | id, store_id, user_id, order_no, order_id, refund_order_no, `status`, delete_status, |
| | | pay_amount, refund_amount, refund_reason, refund_pic, create_at, update_at, handle_time, |
| | | refund_time, handle_result, remark |
| | | </sql> |
| | | </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_community.dao.ComShopFlowerUserAddressDAO"> |
| | | <resultMap id="BaseResultMap" type="com.panzhihua.service_community.model.dos.ComShopFlowerUserAddressDO"> |
| | | <!--@mbg.generated--> |
| | | <!--@Table com_shop_flower_user_address--> |
| | | <id column="id" jdbcType="BIGINT" property="id" /> |
| | | <result column="user_id" jdbcType="BIGINT" property="userId" /> |
| | | <result column="name" jdbcType="VARCHAR" property="name" /> |
| | | <result column="phone" jdbcType="VARCHAR" property="phone" /> |
| | | <result column="province_code" jdbcType="VARCHAR" property="provinceCode" /> |
| | | <result column="province_name" jdbcType="VARCHAR" property="provinceName" /> |
| | | <result column="city_code" jdbcType="VARCHAR" property="cityCode" /> |
| | | <result column="city_name" jdbcType="VARCHAR" property="cityName" /> |
| | | <result column="district_code" jdbcType="VARCHAR" property="districtCode" /> |
| | | <result column="district_name" jdbcType="VARCHAR" property="districtName" /> |
| | | <result column="detail_address" jdbcType="VARCHAR" property="detailAddress" /> |
| | | <result column="is_default" jdbcType="TINYINT" property="isDefault" /> |
| | | <result column="create_at" jdbcType="TIMESTAMP" property="createAt" /> |
| | | <result column="update_at" jdbcType="TIMESTAMP" property="updateAt" /> |
| | | <result column="delete_status" jdbcType="TINYINT" property="deleteStatus" /> |
| | | </resultMap> |
| | | <sql id="Base_Column_List"> |
| | | <!--@mbg.generated--> |
| | | id, user_id, `name`, phone, province_code, province_name, city_code, city_name, district_code, |
| | | district_name, detail_address, is_default, create_at, update_at, delete_status |
| | | </sql> |
| | | </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_community.dao.ConvenientGoodsCategoryDAO"> |
| | | |
| | | <!-- 通用查询映射结果 --> |
| | | <resultMap id="BaseResultMap" type="com.panzhihua.service_community.model.dos.ConvenientGoodsCategoryDO"> |
| | | <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="pageGoodsCategory" |
| | | resultType="com.panzhihua.common.model.vos.community.convenient.ConvenientGoodsCategoryVO"> |
| | | SELECT |
| | | <include refid="Base_Column_List"/> |
| | | FROM com_convenient_service_categories |
| | | WHERE is_del = 0 |
| | | <if test="pageConvenientGoodsCategoryDTO.name != null and pageConvenientGoodsCategoryDTO.name.trim() != """> |
| | | AND `name` LIKE concat('%', #{pageConvenientGoodsCategoryDTO.name}, '%' ) |
| | | </if> |
| | | <if test="pageConvenientGoodsCategoryDTO.areaCode != null and pageConvenientGoodsCategoryDTO.areaCode.trim() != """> |
| | | AND area_code = #{pageConvenientGoodsCategoryDTO.areaCode} |
| | | </if> |
| | | ORDER BY weight DESC |
| | | </select> |
| | | <delete id="deleteGoodsCategoryRelation"> |
| | | DELETE FROM com_convenient_goods_scope WHERE goods_id = #{goodsId} |
| | | </delete> |
| | | <select id="selectCategoryScopeByGoodsId" resultType="java.lang.String"> |
| | | SELECT GROUP_CONCAT(`goods_category_name`) serviceScope FROM com_convenient_goods_scope WHERE goods_id = #{goodsId} |
| | | </select> |
| | | <select id="selectCategoryIdsForGoods" resultType="java.lang.Long"> |
| | | SELECT goods_category_id FROM com_convenient_goods_scope WHERE goods_id = #{goodsId} |
| | | </select> |
| | | <select id="checkCategoryIsUsing" resultType="java.lang.Integer"> |
| | | SELECT COUNT(1) FROM com_convenient_goods_scope WHERE goods_category_id = #{categoryId} |
| | | </select> |
| | | |
| | | </mapper> |
| | |
| | | <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" /> |
| | | </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 |
| | | business_status,user_id,consultation_volume,is_del,created_at,created_by,updated_at,updated_by,area_code,service_range |
| | | </sql> |
| | | <select id="pageMerchant" resultType="com.panzhihua.common.model.vos.community.convenient.ConvenientMerchantVO"> |
| | | SELECT ccm.*, su.account, su.status AS accountStatus, GROUP_CONCAT(ccss.service_name) AS serviceScope |
| | |
| | | |
| | | @Select("SELECT caa.community_id FROM com_act caa WHERE caa.`name` = ( select ca.`name` FROM com_act ca WHERE ca.community_id =#{id})") |
| | | List<Long> selectIds(@Param("id") Long id); |
| | | |
| | | /** |
| | | * 根据区域名称查询社区id |
| | | * @param area |
| | | * @return |
| | | */ |
| | | @Select("select distinct community_id from com_area_town_community where area=#{area}") |
| | | List<Long> selectDistinctCommunityId(@Param("area") String area); |
| | | |
| | | } |
| | |
| | | + " where community_id = ${pageComPbServiceTeamDTO.communityId}" |
| | | + "<if test='pageComPbServiceTeamDTO.name != null and pageComPbServiceTeamDTO.name.trim() != ""'>" |
| | | + " and name LIKE concat( #{pageComPbServiceTeamDTO.name}, '%' ) \n" + " </if> " |
| | | + "<if test='pageComPbServiceTeamDTO.propertyId != null and pageComPbServiceTeamDTO.propertyId != ""'>" |
| | | + " and property_id = #{pageComPbServiceTeamDTO.propertyId} </if> " |
| | | + "<if test='pageComPbServiceTeamDTO.type != null and pageComPbServiceTeamDTO.type != ""'>" |
| | | + " and type = #{pageComPbServiceTeamDTO.type} </if> " |
| | | + "<if test='pageComPbServiceTeamDTO.job != null and pageComPbServiceTeamDTO.job.trim() != ""'>" |
| | | + "AND job LIKE concat(\n" + "#{pageComPbServiceTeamDTO.job},\n" + "'%')" + " </if> " + "</script>") |
| | | IPage<ComPbServiceTeamVO> PageComPbServiceTeamDTO(Page page, |
| | |
| | | * 身份证号码 |
| | | */ |
| | | private String cardNo; |
| | | /** |
| | | * 所属物业公司Id |
| | | * */ |
| | | private Long propertyId; |
| | | private Integer type; |
| | | } |
| | |
| | | communityIds.add(communityId); |
| | | } |
| | | partyBuildingComPbDynVO.setCommunityIds(communityIds); |
| | | }else { |
| | | //西区大屏 |
| | | if (CollUtil.isEmpty(partyBuildingComPbDynVO.getCommunityIds()) || "wx0cef797390444b75".equals(partyBuildingComPbDynVO.getAppId())){ |
| | | List<Long> selectDistinctCommunityId = comPbMemberDAO.selectDistinctCommunityId("西区"); |
| | | partyBuildingComPbDynVO.setCommunityIds(selectDistinctCommunityId); |
| | | } |
| | | } |
| | | IPage<PartyBuildingComPbDynVO> iPage = comPbDynDAO.pageYnamic(page, partyBuildingComPbDynVO); |
| | | List<PartyBuildingComPbDynVO> records = iPage.getRecords(); |
| | |
| | | return this.comPropertyRepairService.pageList(commonPage); |
| | | } |
| | | |
| | | /** |
| | | * 分页查询所有数据 脱敏 |
| | | * @return 所有数据 |
| | | */ |
| | | @PostMapping("queryAllDesensitize") |
| | | public R selectAllDesensitize(@RequestBody CommonPage commonPage) { |
| | | return this.comPropertyRepairService.pageListDesensitize(commonPage); |
| | | } |
| | | |
| | | |
| | | |
| | | /** |
| | |
| | | return this.comPropertyRepairService.selectDetail(id); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 通过主键查询单条数据 脱敏 |
| | | * |
| | | * @param id 主键 |
| | | * @return 单条数据 |
| | | */ |
| | | @GetMapping("desensitize/{id}") |
| | | public R selectOneDesensitize(@PathVariable("id") Long id) { |
| | | return this.comPropertyRepairService.selectDetailDesensitize(id); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 新增数据 |
| | | * |
| | |
| | | dealNewData(message); |
| | | } |
| | | |
| | | @Async |
| | | void dealNewData(String message) { |
| | | comPropertyAlarmDao = SpringUtil.getBean(ComPropertyAlarmDao.class); |
| | | JSONObject deviceMess = JSONObject.parseObject(message); |
| | | boolean checkFlag = |
| | | ("trace_call".equals(deviceMess.getString("cmd")) && (StringUtils.isNotEmpty(deviceMess.getString("userid")))); |
| | | if (checkFlag) { |
| | | logger.info("收到设备报警信息:{}", message); |
| | | for (int i = 1; i < 10; i++) { |
| | | if (org.apache.commons.lang.StringUtils.isNotEmpty(deviceMess.getString("num" + i))) { |
| | | ComPropertyAlarm comPropertyAlarm = new ComPropertyAlarm(); |
| | | comPropertyAlarm.setSerialNo(deviceMess.getString("userid")); |
| | | comPropertyAlarm.setReceiveNo(deviceMess.getString("num" + i)); |
| | | comPropertyAlarm.setStatus(0); |
| | | // 10位的秒级别的时间戳 |
| | | Date createDate = new Date(deviceMess.getLong("ts" + i) * 1000); |
| | | //对应的就是时间戳对应的Date |
| | | comPropertyAlarm.setCreateTime(createDate); |
| | | comPropertyAlarm.setType(1); |
| | | comPropertyAlarmDao.insert(comPropertyAlarm); |
| | | } else { |
| | | break; |
| | | } |
| | | } |
| | | } |
| | | } |
| | | |
| | | @Deprecated |
| | | @Async |
| | | void dealNewData(String message) { |
| | |
| | | * @return |
| | | */ |
| | | R pageList(CommonPage commonPage); |
| | | /** |
| | | * 多条件查询维修列表 |
| | | * @param commonPage |
| | | * @return |
| | | */ |
| | | R pageListDesensitize(CommonPage commonPage); |
| | | |
| | | /** |
| | | * 详情查询 |
| | | */ |
| | | R selectDetail(Long id); |
| | | |
| | | |
| | | /** |
| | | * 详情查询脱敏 |
| | | */ |
| | | R selectDetailDesensitize(Long id); |
| | | } |
| | |
| | | package com.panzhihua.service_property.service.impl; |
| | | |
| | | import cn.hutool.core.util.DesensitizedUtil; |
| | | 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.vos.R; |
| | | import com.panzhihua.common.model.vos.property.ComPropertyRepairVO; |
| | | import com.panzhihua.common.utlis.RSAUtils; |
| | | import com.panzhihua.service_property.entity.ComPropertyRepair; |
| | | import com.panzhihua.service_property.dao.ComPropertyRepairDao; |
| | | import com.panzhihua.service_property.entity.ComPropertyRepair; |
| | | import com.panzhihua.service_property.service.ComPropertyRepairService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * (ComPropertyRepair)表服务实现类 |
| | |
| | | public class ComPropertyRepairServiceImpl extends ServiceImpl<ComPropertyRepairDao, ComPropertyRepair> implements ComPropertyRepairService { |
| | | @Resource |
| | | private ComPropertyRepairDao comPropertyRepairDao; |
| | | |
| | | @Override |
| | | public R pageList(CommonPage commonPage) { |
| | | // try { |
| | | // commonPage.setUsername(RSAUtils.decrypt(commonPage.getUsername(), Constants.PRIVATE_KEY)); |
| | | // commonPage.setPhone(RSAUtils.decrypt(commonPage.getPhone(), Constants.PRIVATE_KEY)); |
| | | // } catch (Exception e) { |
| | | // e.printStackTrace(); |
| | | // } |
| | | IPage<ComPropertyRepairVO> list=comPropertyRepairDao.pageList(new Page(commonPage.getPage(), commonPage.getSize()),commonPage); |
| | | IPage<ComPropertyRepairVO> list = comPropertyRepairDao.pageList(new Page(commonPage.getPage(), commonPage.getSize()), commonPage); |
| | | return R.ok(list); |
| | | } |
| | | |
| | | @Override |
| | | public R pageListDesensitize(CommonPage commonPage) { |
| | | try { |
| | | commonPage.setUsername(RSAUtils.decrypt(commonPage.getUsername(), Constants.PRIVATE_KEY)); |
| | | commonPage.setPhone(RSAUtils.decrypt(commonPage.getPhone(), Constants.PRIVATE_KEY)); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | } |
| | | IPage<ComPropertyRepairVO> list = comPropertyRepairDao.pageList(new Page(commonPage.getPage(), commonPage.getSize()), commonPage); |
| | | for (ComPropertyRepairVO record : list.getRecords()) { |
| | | record.setRepairName(DesensitizedUtil.mobilePhone(record.getRepairPhone())); |
| | | record.setRepairName(DesensitizedUtil.chineseName(record.getRepairName())); |
| | | record.setFeedback(DesensitizedUtil.chineseName(record.getFeedback())); |
| | | } |
| | | return R.ok(list); |
| | | } |
| | | |
| | | @Override |
| | | public R selectDetail(Long id) { |
| | | return R.ok(comPropertyRepairDao.selectDetail(id)); |
| | | ComPropertyRepairVO vo = comPropertyRepairDao.selectDetail(id); |
| | | return R.ok(vo); |
| | | } |
| | | |
| | | @Override |
| | | public R selectDetailDesensitize(Long id) { |
| | | ComPropertyRepairVO vo = comPropertyRepairDao.selectDetail(id); |
| | | vo.setRepairPhone(DesensitizedUtil.mobilePhone(vo.getRepairPhone())); |
| | | vo.setRepairName(DesensitizedUtil.chineseName(vo.getRepairName())); |
| | | vo.setFeedback(DesensitizedUtil.chineseName(vo.getFeedback())); |
| | | return R.ok(vo); |
| | | } |
| | | } |
| | |
| | | return userService.getCommunityList(name,id); |
| | | } |
| | | |
| | | @GetMapping("/getAllCommunityList") |
| | | public R getAllCommunityList(){ |
| | | return userService.getAllCommunityList(); |
| | | } |
| | | |
| | | @GetMapping("/resetPasswordAccount") |
| | | public R resetPasswordAccount(@RequestParam("type")Integer type,@RequestParam("account")String account,@RequestParam("appId")String appId){ |
| | | return userService.resetPassword(type,account,appId); |
| | |
| | | return userService.addComPbCheckUser(comPbCheckUserDTO); |
| | | } |
| | | |
| | | @PostMapping("/feedBackReply") |
| | | public R feedBackReply(@RequestBody SysUserFeedbackVO sysUserFeedbackVO){ |
| | | return userService.feedBackReply(sysUserFeedbackVO); |
| | | } |
| | | |
| | | @GetMapping("/myFeedBack") |
| | | public R myFeedBack(@RequestParam("userId")Long id,@RequestParam(value = "type",required = false)Integer type){ |
| | | return userService.myFeedBack(id,type); |
| | | } |
| | | |
| | | @GetMapping("/propertyCheck") |
| | | public R propertyCheck(@RequestParam String phone){ |
| | | return userService.propertyCheck(phone); |
| | | } |
| | | |
| | | } |
| | |
| | | |
| | | DataKanbanDTO selectCommunityAddUserOrder(@Param("areaCode") String areaCode, @Param("date1") Date date1); |
| | | |
| | | List<UsersStatisticsDTO> selectDailyAdd(@Param("createAt") String createAt, @Param("appId") String appId); |
| | | |
| | | List<UsersStatisticsDTO> selectActive(@Param("lastLoginTime") String lastLoginTime, @Param("appId") String appId); |
| | | |
| | | IndexDataVO indexDataCommunityBackstage(Long communityId); |
| | | |
| | |
| | | |
| | | /** |
| | | * 根据手机号查询社区团队表中用户数量 |
| | | * |
| | | * @param phone 手机号 |
| | | * @return 用户数量 |
| | | * @return 用户数量 |
| | | */ |
| | | Integer getCommunityTeamCount(@Param("phone") String phone); |
| | | |
| | | /** |
| | | * 查询西区所有街道列表以及统计人数 |
| | | * @return 西区所有街道列表以及统计人数 |
| | | * |
| | | * @return 西区所有街道列表以及统计人数 |
| | | */ |
| | | List<IndexUserStreetVo> getUserStreetList(@Param("areaCode") String areaCode); |
| | | |
| | | /** |
| | | * 查询街道下社区列表以及统计人数 |
| | | * @param streetId 街道id |
| | | * @return 社区列表以及统计人数 |
| | | * |
| | | * @param streetId 街道id |
| | | * @return 社区列表以及统计人数 |
| | | */ |
| | | List<IndexUserCommunityVo> getUserCommunityList(@Param("streetId") Long streetId); |
| | | |
| | | /** |
| | | * 查询街道下社区注册人数统计数据导出 |
| | | * @return 社区注册人数统计数据导出 |
| | | * |
| | | * @return 社区注册人数统计数据导出 |
| | | */ |
| | | List<IndexUserStreetExcelExportVo> getUserCommunityExcelExport(String areaCode); |
| | | |
| | | /** |
| | | * 查看是否是社区物业人员 |
| | | * |
| | | * @param userId |
| | | * @param userCommunityId |
| | | * @return |
| | |
| | | |
| | | /** |
| | | * 查看是否社工 |
| | | * |
| | | * @param phone |
| | | * @param communityId |
| | | * @return |
| | |
| | | |
| | | /** |
| | | * 查看是否社会组织 |
| | | * |
| | | * @param userId |
| | | * @return |
| | | */ |
| | |
| | | |
| | | /** |
| | | * 查看是否是微团队成员 |
| | | * |
| | | * @param phone |
| | | * @param userCommunityId |
| | | * @return |
| | |
| | | |
| | | /** |
| | | * 查询街道信息 |
| | | * |
| | | * @param streetId |
| | | * @return |
| | | */ |
| | |
| | | |
| | | /** |
| | | * 查询是否是社会组织成员 |
| | | * |
| | | * @param userId |
| | | * @return |
| | | */ |
| | |
| | | |
| | | /** |
| | | * 查询是否社会组织联系人 |
| | | * |
| | | * @param phone |
| | | * @return |
| | | */ |
| | |
| | | |
| | | /** |
| | | * 查询是否人大代表 |
| | | * |
| | | * @param phone |
| | | * @param userCommunityId |
| | | * @return |
| | | */ |
| | | int selectCountDpc(@Param("phone") String phone, @Param("userCommunityId") Long userCommunityId); |
| | | |
| | | /** |
| | | * 查看是否网格员 |
| | | * |
| | | * @param phone |
| | | * @param userCommunityId |
| | | * @return |
| | |
| | | |
| | | /** |
| | | * 查询防疫工作人员信息 |
| | | * |
| | | * @param phone |
| | | * @return |
| | | */ |
| | |
| | | |
| | | /** |
| | | * 查询单位管理员 |
| | | * |
| | | * @param phone |
| | | * @return |
| | | */ |
| | |
| | | |
| | | /** |
| | | * 查询报道单位id |
| | | * |
| | | * @param phone |
| | | * @return |
| | | */ |
| | |
| | | |
| | | /** |
| | | * 根据社区名称查询区县社区联动关系 |
| | | * |
| | | * @param relationName |
| | | * @return |
| | | */ |
| | |
| | | |
| | | /** |
| | | * 根据街道id查询区域名称 |
| | | * |
| | | * @param streetId |
| | | * @return |
| | | */ |
| | |
| | | |
| | | /** |
| | | * 看板用户统计:用户占比统计 |
| | | * */ |
| | | List<UserProportion> userAnalysis(@Param("type") Integer type,@Param("range") String range,@Param("streetId") Long streetId,@Param("areaCode")Long areaCode,@Param("appId")String appId); |
| | | */ |
| | | List<UserProportion> userAnalysis(@Param("type") Integer type, @Param("range") String range, @Param("streetId") Long streetId, @Param("areaCode") Long areaCode, @Param("appId") String appId); |
| | | |
| | | /** |
| | | * 统计区域实名用户数 |
| | | * */ |
| | | List<RealUser> realUserCount(@Param("type") Integer type,@Param("range") String range,@Param("streetId") Long streetId,@Param("areaCode")Long areaCode,@Param("appId")String appId); |
| | | */ |
| | | List<RealUser> realUserCount(@Param("type") Integer type, @Param("range") String range, @Param("streetId") Long streetId, @Param("areaCode") Long areaCode, @Param("appId") String appId); |
| | | |
| | | /** |
| | | * 统计该街道内的所有用户数 |
| | | * */ |
| | | Integer streetUserCount(@Param("id") Long id,@Param("areaCode")Long areaCode); |
| | | */ |
| | | Integer streetUserCount(@Param("id") Long id, @Param("areaCode") Long areaCode); |
| | | |
| | | /** |
| | | * 街道用户统计 |
| | | * */ |
| | | IndexDataKanbanVO dataKanBanStreet(@Param("streetId") Long streetId,@Param("areaCode") Long areaCode,@Param("range") String range); |
| | | */ |
| | | IndexDataKanbanVO dataKanBanStreet(@Param("streetId") Long streetId, @Param("areaCode") Long areaCode, @Param("range") String range); |
| | | |
| | | /** |
| | | * 获取当天的新增和日活 |
| | | * */ |
| | | Map<String,Long> getDailyAddAndActive(@Param("date") Date date, @Param("id") Long streetId, @Param("areaCode") Long areaCode, @Param("appId") String appId); |
| | | */ |
| | | Map<String, Long> getDailyAddAndActive(@Param("date") Date date, @Param("id") Long streetId, @Param("areaCode") Long areaCode, @Param("appId") String appId); |
| | | |
| | | List<UsersStatisticsDTO> getDailyAdd(@Param("createAt") String createAt, @Param("id") Long streetId, @Param("areaCode") Long areaCode, @Param("appId") String appId); |
| | | |
| | |
| | | |
| | | /** |
| | | * 获取本月的 |
| | | * */ |
| | | Integer getMonthUsers(@Param("streetId") Long streetId,@Param("areaCode") Long areaCode,@Param("range") String range,@Param("appId")String appId); |
| | | */ |
| | | Integer getMonthUsers(@Param("streetId") Long streetId, @Param("areaCode") Long areaCode, @Param("range") String range, @Param("appId") String appId); |
| | | |
| | | /** |
| | | * 获取街道下属村/社区 |
| | | * */ |
| | | List<CommunityVO> selectCommunityByStreetId(@Param("id") Long streetId,@Param("type") Integer type); |
| | | */ |
| | | List<CommunityVO> selectCommunityByStreetId(@Param("id") Long streetId, @Param("type") Integer type); |
| | | |
| | | /** |
| | | * 获取账户id |
| | | * */ |
| | | */ |
| | | List<Integer> selectIdsByAccount(@Param("array") String[] streetList); |
| | | |
| | | List<CommunityVO> selectCommunityByStreetName(String name); |
| | |
| | | |
| | | /** |
| | | * 是否为专家 |
| | | * */ |
| | | */ |
| | | ComSanshuoExpertVO isExpert(String phone); |
| | | |
| | | /** |
| | | * 当前账号是否为专家后台账号 |
| | | * */ |
| | | */ |
| | | int isIndustryCenterAccount(String account); |
| | | |
| | | /** |
| | | * 当前账号是否为专家后台账号 |
| | | * */ |
| | | */ |
| | | int isExpertAccount(String account); |
| | | |
| | | /** |
| | | * 查询两个appid的用户做更新 |
| | | * @param userId |
| | | * @return |
| | | */ |
| | | List<SysUserDO> selectByUserId(@Param("userId") Long userId); |
| | | |
| | | /** |
| | | * 是否为党员 |
| | | * */ |
| | | int isDpcMember(@Param("phone") String phone,@Param("name")String name); |
| | | |
| | | /** |
| | | * 是否为物业公司后台账号 |
| | | * */ |
| | | Long isPropertyAccount(String phone); |
| | | } |
| | |
| | | * 状态 |
| | | */ |
| | | private Integer status; |
| | | |
| | | /** |
| | | * 问题留言或投诉建议 |
| | | * */ |
| | | private Integer type; |
| | | } |
| | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.FieldFill; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | |
| | | import lombok.Data; |
| | | |
| | |
| | | /** |
| | | * id |
| | | */ |
| | | @TableId(type = IdType.ASSIGN_ID) |
| | | private Long id; |
| | | |
| | | /** |
| | |
| | | R getCommunityList(String name,Long id); |
| | | |
| | | /** |
| | | * 获取所有城镇或村落列表 |
| | | * @return |
| | | */ |
| | | R getAllCommunityList(); |
| | | |
| | | /** |
| | | * 重置密码 |
| | | * @param type |
| | | * @param account |
| | |
| | | * 移除专家权限 |
| | | * */ |
| | | R removeExpertRole(String phone); |
| | | |
| | | /** |
| | | * 回复用户反馈 |
| | | * */ |
| | | R feedBackReply(SysUserFeedbackVO sysUserFeedbackVO); |
| | | |
| | | /** |
| | | * 查看我的问题留言或者问题留言记录 |
| | | * */ |
| | | R myFeedBack(Long id,Integer type); |
| | | |
| | | /** |
| | | * 是否为物业公司登录 |
| | | * */ |
| | | R propertyCheck(String phone); |
| | | } |
| | |
| | | Boolean isIndustryOrExpertAccount=(userDao.isIndustryCenterAccount(name)>0 || userDao.isExpertAccount(name)>0); |
| | | if (1 == type) { |
| | | sysUserDO = userDao.selectOne( |
| | | new QueryWrapper<SysUserDO>().lambda().eq(SysUserDO::getType, type).eq(SysUserDO::getOpenid, name)); |
| | | new QueryWrapper<SysUserDO>().lambda().eq(SysUserDO::getType, type).eq(SysUserDO::getOpenid, name).eq(SysUserDO::getAppId, appId)); |
| | | }else if(isIndustryOrExpertAccount) { |
| | | //三说会堂行业分中心或专家后台账号登陆 |
| | | sysUserDO = userDao.selectOne( |
| | |
| | | int i = userDao.isDpcMember(sysUserDO.getPhone(), sysUserDO.getName()); |
| | | if (i>0){ |
| | | loginUserInfoVO.setIsDpcMember(1); |
| | | } |
| | | } |
| | | //是否为物业公司账号 |
| | | if (nonNull(sysUserDO.getPhone())){ |
| | | Long propertyAccount = userDao.isPropertyAccount(sysUserDO.getPhone()); |
| | | if (nonNull(propertyAccount)){ |
| | | loginUserInfoVO.setPropertyId(propertyAccount); |
| | | } |
| | | } |
| | | return R.ok(loginUserInfoVO); |
| | |
| | | int i = userDao.isDpcMember(phone, sysUserDO.getName()); |
| | | if (i>0){ |
| | | loginUserInfoVO.setIsDpcMember(1); |
| | | } |
| | | } |
| | | //是否为物业公司账号 |
| | | if (nonNull(sysUserDO.getPhone())){ |
| | | Long propertyAccount = userDao.isPropertyAccount(sysUserDO.getPhone()); |
| | | if (nonNull(propertyAccount)){ |
| | | loginUserInfoVO.setPropertyId(propertyAccount); |
| | | } |
| | | } |
| | | return R.ok(loginUserInfoVO); |
| | |
| | | //是否是防疫工作人员 |
| | | loginUserInfoVO.setIsAcidMember(0); |
| | | ComActAcidMemberVO acidMember = userDao.selectAcidMemberByPhone(loginUserInfoVO.getPhone()); |
| | | //是否为普达物业公司后台账号 |
| | | if (nonNull(sysUserDO.getPhone())){ |
| | | Long propertyAccount = userDao.isPropertyAccount(sysUserDO.getPhone()); |
| | | if (nonNull(propertyAccount)){ |
| | | loginUserInfoVO.setPropertyId(propertyAccount); |
| | | } |
| | | } |
| | | if (nonNull(acidMember)) { |
| | | if (acidMember.getRelationName().equals("panzhihua") || acidMember.getRelationName().equals("西区") || acidMember.getRelationName().equals("东区") || acidMember.getRelationName().equals("仁和区") || acidMember.getRelationName().equals("米易县") || acidMember.getRelationName().equals("盐边县")) { |
| | | loginUserInfoVO.setIsAcidMember(1); |
| | |
| | | userDao.updateComPbMemberUserId(idCard, sysUserDO.getUserId()); |
| | | } |
| | | |
| | | SysUserDO user = userDao.selectById(loginUserInfoVO.getUserId()); |
| | | /*SysUserDO user = userDao.selectById(loginUserInfoVO.getUserId()); |
| | | if (user != null) { |
| | | // 实名认证成功推送订阅消息给用户 |
| | | try { |
| | |
| | | } catch (Exception e) { |
| | | log.error("推送用户订阅消息失败,失败原因:" + e.getMessage()); |
| | | } |
| | | } |
| | | }*/ |
| | | return R.ok(); |
| | | } |
| | | return R.fail(); |
| | |
| | | this.putMenuRole(menuRoleVO); |
| | | } |
| | | } |
| | | log.info("======================type"+administratorsUserVO.getType()); |
| | | if (administratorsUserVO.getType().equals(20)){ |
| | | roleId=1559112102373756548L; |
| | | administratorsUserVO.setType(3); |
| | | } |
| | | log.info("=======================roleId"+roleId); |
| | | SysRoleDO roleDO = roleDAO.selectById(roleId); |
| | | if (ObjectUtils.isEmpty(roleDO)) { |
| | | return R.fail("角色不存在"); |
| | |
| | | } else if (e.getMessage().contains("23000")) { |
| | | throw new ServiceException("手机号已存在"); |
| | | } |
| | | |
| | | } |
| | | if (insert > 0) { |
| | | SysUserDO sysUserDO1 = userDao |
| | |
| | | } |
| | | |
| | | // 获取最近二十天数据 |
| | | List<Date> serverndays = com.panzhihua.common.utlis.DateUtils.getOldDays(); |
| | | serverndays.forEach(date -> { |
| | | // 查询社区活动数量 |
| | | DataKanbanDTO dataKanbanDTO = userDao.selectCommunityAddUserOrder(dataKanBansDto.getAppId(), date); |
| | | List<Date> activeDate = getTwentyDays(); |
| | | |
| | | String twentyDay = com.panzhihua.common.utlis.DateUtils.getTwentyDay(); |
| | | //获取最近活跃人数 |
| | | List<UsersStatisticsDTO> actives = userDao.selectActive(twentyDay, dataKanBansDto.getAppId()); |
| | | //获取最近注册人数 |
| | | List<UsersStatisticsDTO> dailyAdds = userDao.selectDailyAdd(twentyDay, dataKanBansDto.getAppId()); |
| | | |
| | | Map<String, String> activeMap = actives.stream().collect(Collectors.toMap(UsersStatisticsDTO::getSpecificDate, UsersStatisticsDTO::getTotal)); |
| | | Map<String, String> dailyAddMap = dailyAdds.stream().collect(Collectors.toMap(UsersStatisticsDTO::getSpecificDate, UsersStatisticsDTO::getTotal)); |
| | | |
| | | |
| | | for (Date date : activeDate) { |
| | | String dateStr = DateUtil.format(date, "yyyy-MM-dd"); |
| | | communityActiveUserX.add(DateFormatUtils.format(date, "MM-dd")); |
| | | communityActiveUserY.add(dataKanbanDTO.getNum()); |
| | | communityActiveUserZ.add(dataKanbanDTO.getDayNum()); |
| | | }); |
| | | communityActiveUserY.add(dailyAddMap.containsKey(dateStr) ? Integer.parseInt(dailyAddMap.get(dateStr)) : 0); |
| | | communityActiveUserZ.add(activeMap.containsKey(dateStr) ? Integer.parseInt(activeMap.get(dateStr)) : 0); |
| | | } |
| | | indexDataKanbanVO.setCommunityActiveUserX(communityActiveUserX); |
| | | indexDataKanbanVO.setCommunityAddUserY(communityActiveUserY); |
| | | indexDataKanbanVO.setCommunityActiveUserY(communityActiveUserZ); |
| | |
| | | |
| | | @Override |
| | | public R updateUserPartyStatus(Long userId) { |
| | | SysUserDO sysUserDO = userDao.selectById(userId); |
| | | if (sysUserDO != null) { |
| | | sysUserDO.setIsPartymember(1); |
| | | int updated = userDao.updateById(sysUserDO); |
| | | if (updated > 0) { |
| | | // 删除用户信息缓存 |
| | | String userKey = UserConstants.LOGIN_USER_INFO + sysUserDO.getUserId(); |
| | | stringRedisTemplate.delete(userKey); |
| | | List<SysUserDO> sysUserDOs = userDao.selectByUserId(userId); |
| | | for (SysUserDO sysUserDO : sysUserDOs) { |
| | | if (sysUserDO != null) { |
| | | sysUserDO.setIsPartymember(1); |
| | | int updated = userDao.updateById(sysUserDO); |
| | | if (updated > 0) { |
| | | // 删除用户信息缓存 |
| | | String userKey = UserConstants.LOGIN_USER_INFO + sysUserDO.getUserId(); |
| | | stringRedisTemplate.delete(userKey); |
| | | } |
| | | } |
| | | } |
| | | |
| | | return R.ok(); |
| | | } |
| | | |
| | |
| | | String accessToken = ""; |
| | | WxXCXTempSend util = new WxXCXTempSend(); |
| | | try { |
| | | accessToken = util.getAccessToken(); |
| | | accessToken = util.getAccessToken("wx118de8a734d269f0"); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | } |
| | |
| | | WxUtil.sendUuWash3(sysUserDO.getOpenid(), accessToken, status, washName, washPhone, phone, "sU18zbyzxFldHAdOREaQCR5uq_uMvCKTmGtklO1xw-w"); |
| | | break; |
| | | case 4: |
| | | status = "车美已开始服务"; |
| | | status = "开始服务"; |
| | | WxUtil.sendUuWash4(sysUserDO.getOpenid(), accessToken, status, washName, washPhone, phone, "Eft5ksvsnOQANy2uNOGY43CC3pb33eDGA_lgCEoxuiw"); |
| | | break; |
| | | case 6: |
| | | status = "订单确认完成"; |
| | | status = "订单完成"; |
| | | WxUtil.sendUuWash6(sysUserDO.getOpenid(), accessToken, status, washName, washPhone, phone, "k1aV97H3pDNNcNcDTeZBD9jQemNDADnRE801HhTXweI"); |
| | | break; |
| | | case 9: |
| | | status = "订单已取消"; |
| | | status = "订单取消"; |
| | | WxUtil.sendUuWash(sysUserDO.getOpenid(), accessToken, status, washName, washPhone, phone, "9_2FhQPDxZoUqmAuIZ1L1zjjYXokdNvu7A0gzKfvruI"); |
| | | break; |
| | | } |
| | |
| | | WxUtil.sendWsWash3(sysUserDO.getOpenid(), accessToken, status, washName, washPhone, phone, "sNj6m-JBvW6rOokKGDX9X3-XH1AD0GY5_X0jA9JSLwc"); |
| | | break; |
| | | case 4: |
| | | status = "车美已开始服务"; |
| | | status = "开始服务"; |
| | | WxUtil.sendWsWash4(sysUserDO.getOpenid(), accessToken, status, washName, washPhone, phone, "Eft5ksvsnOQANy2uNOGY43CC3pb33eDGA_lgCEoxuiw"); |
| | | break; |
| | | case 6: |
| | | status = "订单确认完成"; |
| | | status = "订单完成"; |
| | | WxUtil.sendWsWash6(sysUserDO.getOpenid(), accessToken, status, washName, washPhone, phone, "iPS8yrsGDqy76hiP8bIbxkosveoX1xTFhdusSiGp-XM"); |
| | | break; |
| | | case 9: |
| | | status = "订单已取消"; |
| | | status = "订单取消"; |
| | | WxUtil.sendWsWash(sysUserDO.getOpenid(), accessToken, status, washName, washPhone, phone, "z_ysGXz9JWBc2rXuYZzVCXKJTyLf0w0WerrohuNoEng"); |
| | | break; |
| | | } |
| | |
| | | } |
| | | |
| | | @Override |
| | | public R getAllCommunityList() { |
| | | List<Integer> areaList = areaCodeList(); |
| | | List<AreaVOS> areaVOList = new ArrayList<>(); |
| | | for (Integer code : areaList) { |
| | | AreaVOS areaVO = new AreaVOS(); |
| | | areaVO.setId(code); |
| | | areaVO.setName(areaCodeToName(code.longValue())); |
| | | List<StreetVOS> streetVOS = userDao.selectStreetByAreaCode(code); |
| | | Iterator<StreetVOS> iterator = streetVOS.listIterator(); |
| | | while (iterator.hasNext()) { |
| | | StreetVOS vo = iterator.next(); |
| | | List<CommunityVO> communityVOS = userDao.selectCommunityByStreetId(vo.getId(), 3); |
| | | vo.setChildList(communityVOS); |
| | | |
| | | } |
| | | areaVO.setChildList(streetVOS); |
| | | areaVOList.add(areaVO); |
| | | } |
| | | return R.ok(areaVOList); |
| | | } |
| | | @Override |
| | | public R getCommunityList(String name, Long id) { |
| | | //区级账号名 |
| | | String[] streetList = {"bingcaogangjiedao", "donghuajiedao", "nongnongpingjiedao", "dadukoujiedaojiedao", "guazipingjiedao", |
| | |
| | | "jingjiangzhen", "renhezhen", "pingdizhen", "datianzhen", "tongdezhen", "futianzhen", "qianjinzhen", "panlianzhen", "binguzhen", "baimazhen", |
| | | "salianzhen", "puweizhen", "deshizhen", "wanqiuyizuxiang", "caochangzhen", "xinshanlisuzuxiang", "tongzilinzhen", "yongxingzhen", "yumenzhen", |
| | | "honggezhen", "hongguoyizuxiang"}; |
| | | List<Integer> ids = userDao.selectIdsByAccount(streetList); |
| | | // List<Integer> ids = userDao.selectIdsByAccount(streetList); |
| | | //村或社区账号 |
| | | Integer type = isVilliage(name); |
| | | //是否为市级账号 |
| | |
| | | return R.ok(); |
| | | } |
| | | |
| | | @Override |
| | | public R feedBackReply(SysUserFeedbackVO sysUserFeedbackVO) { |
| | | SysUserFeedbackDO sysUserFeedbackDO=new SysUserFeedbackDO(); |
| | | BeanUtils.copyProperties(sysUserFeedbackVO, sysUserFeedbackDO); |
| | | return R.ok(sysUserFeedbackDAO.updateById(sysUserFeedbackDO)); |
| | | } |
| | | |
| | | @Override |
| | | public R myFeedBack(Long id,Integer type) { |
| | | List<SysUserFeedbackDO> sysUserFeedbackDOS = sysUserFeedbackDAO.selectList(new QueryWrapper<SysUserFeedbackDO>().lambda().eq(SysUserFeedbackDO::getType, type).eq(SysUserFeedbackDO::getUserId, id)); |
| | | return R.ok(sysUserFeedbackDOS); |
| | | } |
| | | |
| | | @Override |
| | | public R propertyCheck(String phone) { |
| | | Long propertyAccount = userDao.isPropertyAccount(phone); |
| | | log.info("==============物业公司id"+propertyAccount); |
| | | if (isNull(propertyAccount)){ |
| | | return R.fail(); |
| | | } |
| | | return R.ok(propertyAccount); |
| | | } |
| | | |
| | | |
| | | @Override |
| | | public R getAreaAndStreet() { |
| | |
| | | ORDER BY |
| | | u.user_id DESC |
| | | </select> |
| | | <select id="selectByUserId" resultMap="BaseResultMap"> |
| | | SELECT u1.* FROM sys_user u1 WHERE u1.phone = (SELECT phone FROM sys_user u2 WHERE u2.user_id=#{userId}) AND u1.app_id in ('wx118de8a734d269f0','wx0cef797390444b75') |
| | | </select> |
| | | |
| | | </mapper> |
| | |
| | | and su.type = 1 and su.app_id = #{areaCode} |
| | | </select> |
| | | |
| | | <select id="selectDailyAdd" resultType="com.panzhihua.service_user.model.dtos.UsersStatisticsDTO"> |
| | | SELECT DATE_FORMAT( u.create_at, '%Y-%m-%d' ) as specificDate,count( u.user_id ) total FROM sys_user u |
| | | LEFT JOIN com_act t1 ON u.community_id = t1.community_id WHERE u.type = 1 AND u.app_id = #{appId} AND u.create_at > #{createAt} GROUP BY specificDate; |
| | | </select> |
| | | |
| | | <select id="selectActive" resultType="com.panzhihua.service_user.model.dtos.UsersStatisticsDTO"> |
| | | SELECT DATE_FORMAT( u.last_login_time, '%Y-%m-%d' ) as specificDate,count( u.user_id ) total FROM sys_user u |
| | | LEFT JOIN com_act t1 ON u.community_id = t1.community_id WHERE u.type = 1 AND u.app_id = #{appId} AND u.last_login_time > #{lastLoginTime} GROUP BY specificDate; |
| | | </select> |
| | | |
| | | <update id="gridMemberEditStatus"> |
| | | update sys_user set status = #{gridMemberEditDTO.status} where user_id in |
| | | <foreach item="item" collection="gridMemberEditDTO.ids" separator="," open="(" close=")" index=""> |
| | |
| | | <select id="isDpcMember" resultType="Integer"> |
| | | select count(id) from com_act_dpc where name =#{name} and phone=#{phone} |
| | | </select> |
| | | <select id="isPropertyAccount" resultType="java.lang.Long"> |
| | | select id from com_property where phone=#{phone} |
| | | </select> |
| | | </mapper> |
| | |
| | | noLoginUrl.add("/api/applets/renting/houses/houseList"); |
| | | noLoginUrl.add("/api/applets/renting/houses/getConfig"); |
| | | noLoginUrl.add("/api/applets/comActRaffle/queryAll"); |
| | | noLoginUrl.add("/api/communitybackstage/screen/comprehensive/street/list"); |
| | | noLoginUrl.add("/api/communitybackstage/screen/comprehensive/population"); |
| | | noLoginUrl.add("/api/communitybackstage/screen/getWestScreenStatics"); |
| | | noLoginUrl.add("/api/communitybackstage/screen/comprehensive/governance"); |
| | | noLoginUrl.add("/api/communitybackstage/screen/comprehensive/partydyn"); |
| | | noLoginUrl.add("/api/communitybackstage/screen/comprehensive/pagedynamic"); |
| | | noLoginUrl.add("/api/communitybackstage/screen/get/community/password"); |
| | | noLoginUrl.add("/api/huacheng-communitybackstage/screen/comprehensive/street/list"); |
| | | noLoginUrl.add("/api/huacheng-communitybackstage/screen/comprehensive/population"); |
| | | noLoginUrl.add("/api/huacheng-communitybackstage/screen/getWestScreenStatics"); |
| | | noLoginUrl.add("/api/huacheng-communitybackstage/screen/comprehensive/governance"); |
| | | noLoginUrl.add("/api/huacheng-communitybackstage/screen/comprehensive/partydyn"); |
| | | noLoginUrl.add("/api/huacheng-communitybackstage/screen/comprehensive/pagedynamic"); |
| | | noLoginUrl.add("/api/huacheng-communitybackstage/screen/get/community/password"); |
| | | noLoginUrl.add("/api/shopbackstage/microcommercialstreet/verifyCode"); |
| | | noLoginUrl.add("/api/shopbackstage/mcsOrder/wxNotify"); |
| | | noLoginUrl.add("/api/shopbackstage/microcommercialstreet/bindPhone"); |