| | |
| | | @GetMapping("/delete/batch") |
| | | @RequiresPermissions("business:activity:delete") |
| | | public ApiResponse deleteByIdInBatch(@RequestParam String ids) { |
| | | |
| | | String [] idArray = ids.split(","); |
| | | List<Integer> idList = new ArrayList<>(); |
| | | for (String id : idArray) { |
| | |
| | | package com.doumee.api.business; |
| | | |
| | | import com.doumee.api.BaseController; |
| | | import com.doumee.core.annotation.excel.ExcelExporter; |
| | | import com.doumee.core.annotation.pr.PreventRepeat; |
| | | import com.doumee.core.annotation.excel.ExcelExporter; |
| | | import com.doumee.core.model.ApiResponse; |
| | | import com.doumee.core.model.PageWrap; |
| | | import com.doumee.core.model.PageData; |
| | |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | |
| | | |
| | | /** |
| | | * @author 江蹄蹄 |
| | |
| | | # application: |
| | | # name: doumeemes |
| | | profiles: |
| | | active: pro |
| | | active: dev |
| | | |
| | | # JSON返回配置 |
| | | jackson: |
| | |
| | | } |
| | | String openid = member.getOpenId(); |
| | | Integer memberId = getTokenId(token); |
| | | Integer isDeleted = dao.queryForObject(" select COALESCE(ISDELETED,0) from Member where id = ?", Integer.class, memberId); |
| | | Integer isDeleted = dao.queryForObject(" select COALESCE(ISDELETED,0) from member where id = ?", Integer.class, memberId); |
| | | if(isDeleted== Constants.ONE){ |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"用户已删除,请联系管理员"); |
| | | } |
| | | Integer isForbidden = dao.queryForObject(" select COALESCE(STATUS,0) from Member where id = ?", Integer.class, memberId); |
| | | Integer isForbidden = dao.queryForObject(" select COALESCE(STATUS,0) from member where id = ?", Integer.class, memberId); |
| | | if(isForbidden == Constants.ONE){ |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"用户已禁用,请联系管理员"); |
| | | } |
| | | if(isForbidden == Constants.TWO){ |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"用户已注销,请联系管理员"); |
| | | } |
| | | String dbOpenid = dao.queryForObject(" select ifnull(open_id,'') from Member where id = ?", String.class, memberId); |
| | | String dbOpenid = dao.queryForObject(" select ifnull(open_id,'') from member where id = ?", String.class, memberId); |
| | | if(StringUtils.isBlank(dbOpenid)||!openid.equals(dbOpenid)){ |
| | | throw new BusinessException(ResponseStatus.NO_LOGIN.getCode(),"已过期,请重新登录"); |
| | | } |
| | | Integer count = dao.queryForObject("select count(1) from Member where id = ?", Integer.class, memberId); |
| | | Integer count = dao.queryForObject("select count(1) from member where id = ?", Integer.class, memberId); |
| | | if (count != null && count > 0) { |
| | | request.setAttribute(JwtTokenUtil.UserId_Name, memberId); |
| | | return true; |
| | |
| | | @TableField(exist = false) |
| | | private String content; |
| | | |
| | | @ApiModelProperty(value = "最低价" ) |
| | | @TableField(exist = false) |
| | | private BigDecimal minPrice; |
| | | |
| | | |
| | | @ApiModelProperty(value = "社区封面图") |
| | | @TableField(exist = false) |
| | |
| | | private String phone; |
| | | |
| | | @ApiModelProperty(value = "是否完成首单:0否 1是", example = "1") |
| | | @ExcelColumn(name="完成极端" ,index =4,width = 10,valueMapping = "0=已注册;1=完成首单;") |
| | | @ExcelColumn(name="完成阶段" ,index =4,width = 10,valueMapping = "0=已注册;1=完成首单;") |
| | | private Integer firstOrderStatus; |
| | | |
| | | @ApiModelProperty(value = "完成首单时间") |
| | |
| | | @ApiModelProperty(value = "对象编码", example = "1") |
| | | private Integer objId; |
| | | |
| | | @ApiModelProperty(value = "对象类型 0商城订单 1积分流水 2互动评价 3优惠券 4现金流水", example = "1") |
| | | @ApiModelProperty(value = "对象类型 0商城订单 1积分流水 2优惠券发放 3过期提醒 4社区消息", example = "1") |
| | | private Integer objType; |
| | | |
| | | @ApiModelProperty(value = "消息类型 0订单通知 1系统消息 2互动消息 3优惠券提醒 4官方客服 5活动推荐 6我的关注", example = "1") |
| | |
| | | .selectAs(Goods::getName,Collect::getName) |
| | | .selectAs(Goods::getPrice,Collect::getPrice) |
| | | .selectAs(Goods::getImgurl,Collect::getActivityImgurl) |
| | | .select(" ifnull(( select min(gs.PRICE) from goods_sku gs where gs.GOODS_ID = t1.id and gs.ISDELETED = 0 ),0) ",Goods::getMinPrice) |
| | | .select(" ifnull(( select min(gs.SHOW_PRICE) from goods_sku gs where gs.GOODS_ID = t1.id and gs.ISDELETED = 0 ),0) ",Goods::getLinePrice) |
| | | .select(" ifnull(( select min(gs.PRICE) from goods_sku gs where gs.GOODS_ID = t1.id and gs.ISDELETED = 0 ),0) ",Collect::getMinPrice) |
| | | .select(" ifnull(( select min(gs.SHOW_PRICE) from goods_sku gs where gs.GOODS_ID = t1.id and gs.ISDELETED = 0 ),0) ",Collect::getLinePrice) |
| | | .leftJoin(Goods.class,Goods::getId,Collect::getObjId) |
| | | .eq(Collect::getIsdeleted,Constants.ZERO) |
| | | .eq(Collect::getMemberId,memberId) |
| | |
| | | Utils.MP.blankToNull(pageWrap.getModel()); |
| | | replyWrapper.selectAs(Comment::getId,ActivityReplyCommentDTO::getId); |
| | | replyWrapper.selectAs(Comment::getReplyId,ActivityReplyCommentDTO::getReplyId); |
| | | replyWrapper.selectAs(Comment::getIsdeleted,ActivityReplyCommentDTO::getIsdeleted); |
| | | if(Objects.isNull(pageWrap.getModel().getMemberId())){ |
| | | replyWrapper.select(" 0 ",ActivityReplyCommentDTO::getZanStatus); |
| | | }else{ |
| | |
| | | if(Objects.nonNull(replyCommentDTO)){ |
| | | ZanDTO replyZan = MapUtils.getObject(count, replyCommentDTO.getId()); |
| | | replyCommentDTO.setZanCount(replyZan != null ? replyZan.getCount() : 0); |
| | | if(com.github.xiaoymin.knife4j.core.util.CollectionUtils.isNotEmpty(multifileList)){ |
| | | replyCommentDTO.setMultifileList(multifileList.stream().filter(t -> t.getObjId().equals(replyCommentDTO.getId())).collect(Collectors.toList())); |
| | | if(Constants.equalsInteger(replyCommentDTO.getIsdeleted(),Constants.ONE)){ |
| | | replyCommentDTO.setContent("该评论已被原作者删除"); |
| | | }else{ |
| | | if(com.github.xiaoymin.knife4j.core.util.CollectionUtils.isNotEmpty(multifileList)){ |
| | | replyCommentDTO.setMultifileList(multifileList.stream().filter(t -> t.getObjId().equals(replyCommentDTO.getId())).collect(Collectors.toList())); |
| | | } |
| | | } |
| | | replyCommentDTO.setMemberImgUrl(StringUtils.isNotBlank(replyCommentDTO.getMemberImgUrl())?memberFile+replyCommentDTO.getMemberImgUrl():null); |
| | | s.setActivityReplyCommentDTO(replyCommentDTO); |
| | |
| | | .le(pageWrap.getModel().getEndtime() != null,WithdrawRecord::getCreateDate, pageWrap.getModel().getEndtime()) |
| | | .like(pageWrap.getModel().getShopName() != null,Shop::getName, pageWrap.getModel().getShopName()) |
| | | .eq(WithdrawRecord::getIsdeleted,Constants.ZERO) |
| | | .in(WithdrawRecord::getStatus,Constants.ZERO,Constants.ONE) |
| | | .eq(pageWrap.getModel().getStatus()!=null,WithdrawRecord::getStatus,pageWrap.getModel().getStatus()) |
| | | ); |
| | | if(count == null){ |
| | |
| | | @Override |
| | | public PageData<SystemUserListVO> findPage(PageWrap<QuerySystemUserDTO> pageWrap) { |
| | | // 根部门条件处理(需查询根部门下所有部门的用户) |
| | | if (pageWrap.getModel().getRootDeptId() != null) { |
| | | pageWrap.getModel().setDepartmentIds(getAllowedDeptIds(pageWrap.getModel().getRootDeptId())); |
| | | } else { |
| | | pageWrap.getModel().setDepartmentIds(getAllowedDeptIds(null)); |
| | | } |
| | | // if (pageWrap.getModel().getRootDeptId() != null) { |
| | | // pageWrap.getModel().setDepartmentIds(getAllowedDeptIds(pageWrap.getModel().getRootDeptId())); |
| | | // } else { |
| | | // pageWrap.getModel().setDepartmentIds(getAllowedDeptIds(null)); |
| | | // } |
| | | // 执行查询 |
| | | PageHelper.startPage(pageWrap.getPage(), pageWrap.getCapacity()); |
| | | List<SystemUserListVO> userList = systemUserMapper.selectManageList(pageWrap.getModel(), pageWrap.getOrderByClause()); |
| | |
| | | wx: |
| | | pay: |
| | | appId: wx0115b948d647e9b2 |
| | | appSecret: 3462fa186da7cb06c544df8d8664b63a |
| | | mchId: 1229817002 |
| | | appSecret: 4b5b97d6770f1fc6b09a7019804739a7 #3462fa186da7cb06c544df8d8664b63a |
| | | mchId: 1739990831 |
| | | mchKey: u4TSNtv0wFP7WRfnxBgijYOtRhS9FvlM |
| | | notifyUrl: https://mall.myshopify.com/dmmall_interface/web/api/wxPayNotify |
| | | notifyUrl: https://dynj.ahapp.net/dmmall_interface/web/api/wxPayNotify #mall.myshopify.com |
| | | keyPath: /usr/local/jars/apiclient_cert.p12 |
| | | |
| | | tencent: |
| | |
| | | # 项目信息配置 |
| | | project: |
| | | name: 福利商城 |
| | | name: 鼎元农机 |
| | | version: 1.0.0 |
| | | env: development |
| | | # env: production |