.gitignore
@@ -17,4 +17,5 @@ *.yaml *.yml *.log *.log *.iml ruoyi-api/ruoyi-api-account/src/main/java/com/ruoyi/account/api/factory/AppUserClientFallbackFactory.java
@@ -6,6 +6,7 @@ import com.ruoyi.common.core.domain.R; import lombok.extern.slf4j.Slf4j; import org.springframework.cloud.openfeign.FallbackFactory; import org.springframework.web.bind.annotation.PostMapping; import java.util.List; @@ -22,7 +23,8 @@ public AppUserClient create(Throwable cause) { return new AppUserClient() { @Override @PostMapping("/appUser/getAppUserById") @Override public AppUser getAppUserById(Long id) { log.error("根据id获取用户失败:{}", cause.getMessage()); throw new RuntimeException("根据id获取用户失败"); @@ -45,6 +47,19 @@ log.error("获取用户门店信息失败:{}", cause.getMessage()); throw new RuntimeException("获取用户门店信息失败"); } @Override public R<List<AppUser>> getUserAncestorList(Long id) { log.error("获取用户祖籍列表失败:{}", cause.getMessage()); throw new RuntimeException("获取用户祖籍列表失败"); } @Override public R<Long> getVipCount(Long userId, Integer vipId) { log.error("获取直推会员数失败:{}", cause.getMessage()); throw new RuntimeException("获取直推会员数失败"); } }; } } ruoyi-api/ruoyi-api-account/src/main/java/com/ruoyi/account/api/feignClient/AppUserClient.java
@@ -25,16 +25,16 @@ * @param id * @return */ @PostMapping("/appUser/getAppUserById") @PostMapping("/app-user/getAppUserById") AppUser getAppUserById(@RequestParam("id") Long id); /** * 根据id编辑用户 */ @PostMapping("/appUser/editAppUserById") @PostMapping("/app-user/editAppUserById") R<Void> editAppUserById(@RequestParam("appUser") AppUser appUser); @PostMapping("/appUser/getCouponCount") @PostMapping("/app-user/getCouponCount") R<Long> getCouponCount(@RequestParam("userId")Long userId, @RequestParam("couponId") Integer couponId ); /** @@ -43,4 +43,14 @@ @GetMapping("/appUserShop/shop/{userId}") R<List<AppUserShop>> getAppUserShop(@PathVariable("userId") Long userId); /** * 根据用户id获取用户的祖籍列表 */ @GetMapping("/appletLogin/getUserAncestorList") R<List<AppUser>> getUserAncestorList(@RequestParam("id") Long id); @PostMapping("/app-user/getVipCount") R<Long> getVipCount(@RequestParam("userId")Long userId, @RequestParam("vipId") Integer vipId ); } ruoyi-api/ruoyi-api-account/src/main/java/com/ruoyi/account/api/model/AppUser.java
@@ -148,11 +148,8 @@ @ApiModelProperty(value = "分销总金额") @TableField("total_distribution_amount") private BigDecimal totalDistributionAmount; @ApiModelProperty(value = "账户余额") @TableField("balance") private BigDecimal balance; @ApiModelProperty(value = "剩余积分") @TableField("lave_point") private Integer lavePoint; @@ -194,24 +191,31 @@ private String districtCode; @ApiModelProperty("等级1会员数") @TableField(exist = false) private Long count1; @ApiModelProperty("等级2会员数") @TableField(exist = false) private Long count2; @ApiModelProperty("等级3会员数") @TableField(exist = false) private Long count3; @ApiModelProperty("等级4会员数") @TableField(exist = false) private Long count4; @ApiModelProperty("等级5会员数") @TableField(exist = false) private Long count5; @ApiModelProperty("等级6会员数") @TableField(exist = false) private Long count6; @ApiModelProperty("等级7会员数") @TableField(exist = false) private Long count7; ruoyi-api/ruoyi-api-account/src/main/java/com/ruoyi/account/api/model/BalanceChangeRecord.java
@@ -1,6 +1,7 @@ package com.ruoyi.account.api.model; 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 io.swagger.annotations.ApiModel; @@ -47,4 +48,13 @@ @ApiModelProperty("添加时间") private LocalDateTime createTime; @TableField(exist = false) @ApiModelProperty("消费用户名称") private String userName; @TableField(exist = false) @ApiModelProperty("消费金额") private BigDecimal amount; } ruoyi-api/ruoyi-api-order/src/main/java/com/ruoyi/order/factory/RemoteOrderFallbackFactory.java
New file @@ -0,0 +1,19 @@ //package factory; // //import feignClient.RemoteOrderClient; //import org.springframework.cloud.openfeign.FallbackFactory; //import org.springframework.stereotype.Component; // ///** // * 订单服务降级处理 // * @author luofl // */ //@Component //public class RemoteOrderFallbackFactory implements FallbackFactory<RemoteOrderClient> { // // @Override // public RemoteOrderClient create(Throwable cause) { // return new RemoteOrderClient() { // }; // } //} ruoyi-api/ruoyi-api-order/src/main/java/com/ruoyi/order/factory/RemoteOrderGoodsFallbackFactory.java
New file @@ -0,0 +1,31 @@ package com.ruoyi.order.factory; import com.ruoyi.common.core.domain.R; import com.ruoyi.order.feignClient.RemoteOrderGoodsClient; import lombok.extern.slf4j.Slf4j; import com.ruoyi.order.model.Order; import com.ruoyi.order.model.OrderGood; import org.springframework.cloud.openfeign.FallbackFactory; import java.util.List; @Slf4j public class RemoteOrderGoodsFallbackFactory implements FallbackFactory<RemoteOrderGoodsClient> { @Override public RemoteOrderGoodsClient create(Throwable cause) { return new RemoteOrderGoodsClient(){ @Override public R<List<OrderGood>> goodsOrder(List<Long> goodsIds) { log.error("获取订单商品失败:{}", cause.getMessage()); throw new RuntimeException("获取订单商品失败"); } @Override public R<List<Order>> getOrderListByIds(List<Long> orderIds) { log.error("获取订单列表失败:{}", cause.getMessage()); throw new RuntimeException("获取订单列表失败"); } }; } } ruoyi-api/ruoyi-api-order/src/main/java/com/ruoyi/order/feignClient/RemoteOrderClient.java
New file @@ -0,0 +1,24 @@ //package feignClient; // //import com.ruoyi.common.core.constant.ServiceNameConstants; //import com.ruoyi.common.core.domain.R; //import factory.RemoteOrderFallbackFactory; //import model.Order; //import model.OrderGood; //import org.springframework.cloud.openfeign.FeignClient; //import org.springframework.web.bind.annotation.GetMapping; //import org.springframework.web.bind.annotation.PostMapping; //import org.springframework.web.bind.annotation.RequestBody; //import org.springframework.web.bind.annotation.RequestParam; // //import java.util.List; // ///** // * 订单远程调用接口 // * @author luofl // */ //@FeignClient(contextId = "RemoteOrderClient", value = ServiceNameConstants.ORDER_SERVICE, fallbackFactory = RemoteOrderFallbackFactory.class) //public interface RemoteOrderClient { // // //} ruoyi-api/ruoyi-api-order/src/main/java/com/ruoyi/order/feignClient/RemoteOrderGoodsClient.java
File was renamed from ruoyi-api/ruoyi-api-order/src/main/java/feignClient/RemoteOrderGoodsClient.java @@ -1,10 +1,11 @@ package feignClient; package com.ruoyi.order.feignClient; import com.ruoyi.common.core.constant.ServiceNameConstants; import com.ruoyi.common.core.domain.R; import factory.RemoteOrderGoodsFallbackFactory; import model.OrderGood; import com.ruoyi.order.factory.RemoteOrderGoodsFallbackFactory; import com.ruoyi.order.model.Order; import com.ruoyi.order.model.OrderGood; import org.springframework.cloud.openfeign.FeignClient; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestBody; @@ -19,4 +20,10 @@ */ @PostMapping("/order-good/selectGoodsOrder") public R<List<OrderGood>> goodsOrder(@RequestBody List<Long> goodsIds); /** * 根据ids查找订单列表 */ @PostMapping("/order/getOrderListByIds") public R<List<Order>> getOrderListByIds(@RequestBody List<Long> orderIds); } ruoyi-api/ruoyi-api-order/src/main/java/com/ruoyi/order/model/Order.java
File was renamed from ruoyi-api/ruoyi-api-order/src/main/java/model/Order.java @@ -1,4 +1,4 @@ package model; package com.ruoyi.order.model; import com.baomidou.mybatisplus.annotation.TableField; import com.baomidou.mybatisplus.annotation.TableId; @@ -44,10 +44,18 @@ @TableField("order_status") private Integer orderStatus; @ApiModelProperty(value = "是否已分佣: 0-否 1-是") @TableField("is_commission") private Integer isCommission; @ApiModelProperty(value = "核销时间") @TableField("end_time") private LocalDateTime endTime; @ApiModelProperty(value = "售后截止日期") @TableField("after_sale_time") private LocalDateTime afterSaleTime; @ApiModelProperty(value = "技师id") @TableField("technician_id") private Integer technicianId; ruoyi-api/ruoyi-api-order/src/main/java/com/ruoyi/order/model/OrderGood.java
File was renamed from ruoyi-api/ruoyi-api-order/src/main/java/model/OrderGood.java @@ -1,4 +1,4 @@ package model; package com.ruoyi.order.model; import com.baomidou.mybatisplus.annotation.*; import io.swagger.annotations.ApiModel; ruoyi-api/ruoyi-api-order/src/main/java/com/ruoyi/order/model/RefundPass.java
File was renamed from ruoyi-api/ruoyi-api-order/src/main/java/model/RefundPass.java @@ -1,4 +1,4 @@ package model; package com.ruoyi.order.model; import com.baomidou.mybatisplus.annotation.TableField; import com.baomidou.mybatisplus.annotation.TableId; ruoyi-api/ruoyi-api-order/src/main/java/com/ruoyi/order/model/ShoppingCart.java
File was renamed from ruoyi-api/ruoyi-api-order/src/main/java/model/ShoppingCart.java @@ -1,4 +1,4 @@ package model; package com.ruoyi.order.model; import com.baomidou.mybatisplus.annotation.TableField; import com.baomidou.mybatisplus.annotation.TableId; ruoyi-api/ruoyi-api-order/src/main/java/com/ruoyi/order/vo/OrderDetailVO.java
File was renamed from ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/vo/OrderDetailVO.java @@ -18,7 +18,7 @@ private List<OrderGoodsVO> goodsList; @ApiModelProperty(value = "使用积分") private BigDecimal point; private Integer point; @ApiModelProperty(value = "收货地址id") private Long addressId; @@ -54,7 +54,7 @@ private BigDecimal expressAmount; @ApiModelProperty(value = "可获得积分") private BigDecimal pointAmount; private Integer pointAmount; @ApiModelProperty(value = "实际支付价格") private BigDecimal paymentAmount; ruoyi-api/ruoyi-api-order/src/main/java/com/ruoyi/order/vo/OrderGoodsVO.java
File was renamed from ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/vo/OrderGoodsVO.java @@ -10,7 +10,7 @@ @ApiModel(value = "订单商品") public class OrderGoodsVO { @ApiModelProperty(value = "商品id") private Long goodsId; private Integer goodsId; @ApiModelProperty(value = "商品名称") private String goodsName; ruoyi-api/ruoyi-api-order/src/main/java/factory/RemoteOrderFallbackFactory.java
File was deleted ruoyi-api/ruoyi-api-order/src/main/java/factory/RemoteOrderGoodsFallbackFactory.java
File was deleted ruoyi-api/ruoyi-api-order/src/main/java/feignClient/RemoteOrderClient.java
File was deleted ruoyi-api/ruoyi-api-order/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports
@@ -0,0 +1 @@ com.ruoyi.order.factory.RemoteOrderGoodsFallbackFactory ruoyi-api/ruoyi-api-other/src/main/java/com/ruoyi/other/api/domain/BaseSetting.java
@@ -26,7 +26,7 @@ private static final long serialVersionUID = 1L; @ApiModelProperty(value = "1:合伙人积分设置一 2:合伙人积分设置二 3:会员说明设置 4:活动管理-活动设置 1开0关") @ApiModelProperty(value = "1:合伙人积分设置一 2:合伙人积分设置二 3:会员说明设置 4:活动管理-活动设置 1开0关 5:售后设置") @TableId("id") private Integer id; ruoyi-api/ruoyi-api-other/src/main/java/com/ruoyi/other/api/domain/VipSetting.java
@@ -55,6 +55,10 @@ @TableField("vip_withdrawal_min_amount") private BigDecimal vipWithdrawalMinAmount; @ApiModelProperty(value = "提现手续费") @TableField("vip_withdrawal_fee") private BigDecimal vipWithdrawalFee; @ApiModelProperty(value = "积分转赠权限 1开0关") @TableField("vip_gift_role") private Integer vipGiftRole; ruoyi-api/ruoyi-api-other/src/main/java/com/ruoyi/other/api/dto/IndexConfigSetDto.java
@@ -11,8 +11,12 @@ private String pic1; @ApiModelProperty("跳转类型1 - 1无2外部链接3商品详情4秒杀商品详情5领卷中心") private Integer direct1; @ApiModelProperty("跳转内容1") private String content1; @ApiModelProperty("宣传图片2") private String pic2; @ApiModelProperty("跳转内容2") private String content2; @ApiModelProperty("跳转类型2 - 1无2外部链接3商品详情4秒杀商品详情5领卷中心") private String direct2; @ApiModelProperty("公司简介") ruoyi-api/ruoyi-api-other/src/main/java/com/ruoyi/other/api/dto/StartPageSetDto.java
New file @@ -0,0 +1,18 @@ package com.ruoyi.other.api.dto; import io.swagger.annotations.ApiModelProperty; import lombok.Data; @Data public class StartPageSetDto { @ApiModelProperty("启动页倒计时") private Integer waitTime; @ApiModelProperty("1图片2视频") private Integer type; @ApiModelProperty("对应文件地址") private String url; } ruoyi-api/ruoyi-api-other/src/main/java/com/ruoyi/other/api/factory/TechnicianClientFallbackFactory.java
File was deleted ruoyi-api/ruoyi-api-other/src/main/java/com/ruoyi/other/api/feignClient/RemoteVipSettingClient.java
@@ -6,10 +6,11 @@ import com.ruoyi.other.api.factory.RemoteVipSettingFallbackFactory; import org.springframework.cloud.openfeign.FeignClient; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RequestParam; @FeignClient(contextId = "RemoteOrderGoodsClient", value = ServiceNameConstants.ORDER_SERVICE, fallbackFactory = RemoteVipSettingFallbackFactory.class) @FeignClient(contextId = "RemoteVipSettingClient", value = ServiceNameConstants.OTHER_SERVICE, fallbackFactory = RemoteVipSettingFallbackFactory.class) public interface RemoteVipSettingClient { @GetMapping("/vip-setting/getVipSettingById") R<VipSetting> getVipSettingById(Integer id); R<VipSetting> getVipSettingById(@RequestParam(value = "id",required = true) Integer id); } ruoyi-api/ruoyi-api-other/src/main/java/com/ruoyi/other/api/feignClient/TechnicianClient.java
@@ -13,8 +13,8 @@ public interface TechnicianClient { @PostMapping("/technician/shop/detail") R<Technician> shopdetail(@RequestParam Integer techId); R<Technician> shopdetail(@RequestParam("techId") Integer techId); @PutMapping("/technician-subscribe/updateStatus") R<Void> updateStatus(@RequestParam Integer status, @RequestParam Integer subscribeId); R<Void> updateStatus(@RequestParam("status") Integer status, @RequestParam("subscribeId") Integer subscribeId); } ruoyi-api/ruoyi-api-other/src/main/java/com/ruoyi/other/api/vo/GetGoodsShopByGoodsIds.java
File was deleted ruoyi-api/ruoyi-api-other/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports
@@ -11,4 +11,5 @@ com.ruoyi.other.api.factory.CouponInfoClientFallbackFactory com.ruoyi.other.api.factory.SystemConfigClientFallbackFactory com.ruoyi.other.api.factory.StoreFallbackFactory com.ruoyi.other.api.factory.CouponClientFallbackFactory com.ruoyi.other.api.factory.CouponClientFallbackFactory com.ruoyi.other.api.factory.TechnicianClientFallbackFactory ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/annotation/Excel.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/annotation/Excels.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/enums/ApproveConfigEnum.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/enums/AuditStateEnum.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/enums/AuditTypeEnum.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/enums/CarStateEnum.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/enums/DelFlagEnum.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/enums/DisabledEnum.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/enums/HandoverStateEnum.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/enums/ImportTypeEnum.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/enums/InsureTypeEnum.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/enums/ReturnCarTypeEnum.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/enums/ReturnStateEnum.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/enums/UserStatus.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/enums/WarrantyStateEnum.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/enums/status/AdvertisingStatusEnum.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/enums/status/AppUserStatusEnum.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/enums/status/ChargingGunModeEnum.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/enums/status/ChargingGunStatusEnum.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/enums/status/SiteStatusEnum.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/exception/auth/NotLoginException.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/exception/auth/NotPermissionException.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/exception/base/BaseException.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/exception/file/FileException.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/exception/file/FileNameLengthLimitExceededException.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/exception/file/FileSizeLimitExceededException.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/exception/file/FileUploadException.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/exception/file/InvalidExtensionException.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/exception/user/CaptchaExpireException.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/exception/user/UserAppletException.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/exception/user/UserException.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/exception/user/UserPasswordNotMatchException.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/query/TimeRangePageQuery.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/utils/CodeGenerateUtils.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/utils/ExceptionUtil.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/utils/MsgUtil.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/utils/ObsUploadUtil.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/utils/StringUtils.java
File was deleted ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/utils/ip/IpUtils.java
File was deleted ruoyi-common/ruoyi-common-redis/src/main/java/com/ruoyi/common/redis/annotation/DistributedLock.java
File was deleted ruoyi-common/ruoyi-common-redis/src/main/java/com/ruoyi/common/redis/configure/FastJson2JsonRedisSerializer.java
File was deleted ruoyi-common/ruoyi-common-redis/src/main/java/com/ruoyi/common/redis/configure/RedisConfig.java
File was deleted ruoyi-common/ruoyi-common-redis/src/main/java/com/ruoyi/common/redis/service/RedisService.java
File was deleted ruoyi-modules/ruoyi-job/src/main/java/com/ruoyi/job/task/AfterSalesTask.java
New file @@ -0,0 +1,39 @@ package com.ruoyi.job.task; import lombok.extern.log4j.Log4j2; import org.springframework.data.redis.core.RedisTemplate; import org.springframework.stereotype.Component; import javax.annotation.Resource; import java.util.Set; @Component("ryTask") @Log4j2 public class AfterSalesTask { @Resource private RedisTemplate<String, String> redisTemplate; /** * 计算佣金(设置每分钟执行一次) */ public void afterSales() { long now = System.currentTimeMillis() / 1000; // 获取当前时间戳(秒) // 从延迟队列中获取需要处理的订单 Set<String> orderIds = redisTemplate.opsForZSet().rangeByScore("delay_queue:commission", 0, now); if (orderIds != null && !orderIds.isEmpty()) { // 处理完后移除已处理的订单 redisTemplate.opsForZSet().removeRangeByScore("delay_queue:commission", 0, now); } } /** * 佣金补偿(每天执行一次) * redis未配置持久化,为防止数据丢失,每天执行一次,将到期未处理的订单重新放入延迟队列中 */ public void afterSalesCompensation() { // 获取未处理的订单 } } ruoyi-service/ruoyi-account/pom.xml
@@ -121,6 +121,10 @@ <groupId>junit</groupId> <artifactId>junit</artifactId> </dependency> <dependency> <groupId>com.github.pagehelper</groupId> <artifactId>pagehelper-spring-boot-starter</artifactId> </dependency> </dependencies> <build> ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/controller/AppUserBankController.java
@@ -1,10 +1,16 @@ package com.ruoyi.account.controller; import com.ruoyi.account.api.model.AppUserBank; import com.ruoyi.account.service.AppUserBankService; import com.ruoyi.common.core.utils.bean.BeanUtils; import com.ruoyi.common.core.web.domain.AjaxResult; import com.ruoyi.common.security.service.TokenService; import com.ruoyi.system.api.model.LoginUser; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import org.springframework.web.bind.annotation.*; import javax.annotation.Resource; /** * @author zhibing.pu @@ -14,7 +20,11 @@ @RestController @RequestMapping("/appUserBank") public class AppUserBankController { @Resource private AppUserBankService appUserBankService; @Resource private TokenService tokenService; @@ -23,15 +33,25 @@ @PostMapping("/saveAppUserBank") @ApiOperation(value = "保存银行卡") public AjaxResult saveAppUserBank(@RequestBody AppUserBank appUserBank){ LoginUser loginUserApplet = tokenService.getLoginUserApplet(); AppUserBank bank = appUserBankService.getById(loginUserApplet.getUserid()); if (bank == null){ appUserBankService.save(appUserBank); }else { BeanUtils.copyBeanProp(bank,appUserBank); appUserBankService.updateById(bank); } return AjaxResult.success(); } @ResponseBody @GetMapping("/getAppUserBank") @ApiOperation(value = "获取银行卡信息") public AjaxResult<AppUserBank> getAppUserBank(){ return AjaxResult.success(); LoginUser loginUserApplet = tokenService.getLoginUserApplet(); AppUserBank bank = appUserBankService.getById(loginUserApplet.getUserid()); return AjaxResult.success(bank); } } ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/controller/AppUserController.java
@@ -4,8 +4,10 @@ import com.ruoyi.account.api.model.AppUser; import com.ruoyi.account.api.model.UserCancellationLog; import com.ruoyi.account.api.model.UserCoupon; import com.ruoyi.account.service.AppUserService; import com.ruoyi.account.service.UserCancellationLogService; import com.ruoyi.account.service.UserCouponService; import com.ruoyi.common.core.domain.R; import com.ruoyi.common.security.service.TokenService; import com.ruoyi.other.api.domain.Shop; @@ -56,6 +58,19 @@ private AppUserService appUserService; @Resource private StoreClient storeClient; @Resource private UserCouponService userCouponService; @ResponseBody @PostMapping("/mobileLogin") @ApiOperation(value = "手机号登录") public R<LoginVo> mobileLogin(@RequestBody MobileLogin mobileLogin){ return appUserService.mobileLogin(mobileLogin); } @@ -68,12 +83,34 @@ @ResponseBody @PostMapping("/mobileLogin") @ApiOperation(value = "手机号登录") public R<LoginVo> mobileLogin(@RequestBody MobileLogin mobileLogin){ return appUserService.mobileLogin(mobileLogin); @PostMapping("/getAppUserById") public AppUser getAppUserById(@RequestParam("id") Long id){ return appUserService.getById(id); } @ResponseBody @PostMapping("/editAppUserById") public R<Void> editAppUserById(@RequestParam("appUser") AppUser appUser) { appUserService.updateById(appUser); return R.ok(); } @ResponseBody @PostMapping("/getCouponCount") public R<Long> getCouponCount(@RequestParam("userId")Long userId, @RequestParam("couponId") Integer couponId ){ Long count = userCouponService.lambdaQuery().eq(UserCoupon::getAppUserId, userId).eq(UserCoupon::getCouponId, couponId).count(); return R.ok(count); } @ResponseBody @PostMapping("/getVipCount") public R<Long> getVipCount(@RequestParam("userId")Long userId, @RequestParam("vipId") Integer vipId ){ Long count = appUserService.lambdaQuery().eq(AppUser::getInviteUserId, userId).eq(AppUser::getVipId, vipId).count(); return R.ok(count); } @ResponseBody @@ -147,7 +184,9 @@ } @PostMapping("/index") @GetMapping("/index") @ApiOperation(value = "个人中心首页", tags = {"小程序-个人中心首页"}) public R<AppUser> index(){ System.err.println("=-===="); @@ -185,6 +224,15 @@ } /** * 获取用户的祖籍列表 */ @GetMapping("/getUserAncestorList") public R<List<AppUser>> getUserAncestorList(Long id){ List<AppUser> list = appUserService.getUserAncestorList(id,null); return R.ok(list); } } ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/controller/UserCouponController.java
@@ -99,7 +99,7 @@ if (data==null){ return R.fail("当前优惠券不存在,请刷新后重试"); } if (data.getSendType()!=1&&byId.getLavePoint().compareTo(data.getNeedPoint())==-1){ if (data.getSendType()!=1&&byId.getLavePoint().compareTo(data.getNeedPoint().intValue())==-1){ return R.fail("当前积分不足,兑换失败"); } //检验发放时间 @@ -112,12 +112,12 @@ UserPoint userPoint = new UserPoint(); userPoint.setType(4); userPoint.setHistoricalPoint(byId.getLavePoint()); userPoint.setVariablePoint(data.getNeedPoint()); userPoint.setVariablePoint(data.getNeedPoint().intValue()); userPoint.setAppUserId(userid); userPoint.setObjectId(Long.valueOf(data.getId())); userPointService.save(userPoint); //扣除积分 byId.setLavePoint(byId.getLavePoint().subtract(userPoint.getVariablePoint())); byId.setLavePoint(byId.getLavePoint() - userPoint.getVariablePoint()); appUserService.updateById(byId); } //增加优惠券记录,根据时间类型设置开始结束时间 ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/controller/UserPointController.java
@@ -29,7 +29,7 @@ */ @RestController @RequestMapping("/user-point") @Api("用户积分") @Api(tags = "个人积分") public class UserPointController extends BaseController { @Resource private UserPointService userPointService; ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/controller/WalletController.java
@@ -1,25 +1,39 @@ package com.ruoyi.account.controller; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.ruoyi.account.api.model.AppUser; import com.ruoyi.account.api.model.BalanceChangeRecord; import com.ruoyi.account.service.AppUserService; import com.ruoyi.account.service.BalanceChangeRecordService; import com.ruoyi.account.service.VipSettingService; import com.ruoyi.account.service.WalletService; import com.ruoyi.account.vo.WalletVO; import com.ruoyi.common.core.domain.R; import com.ruoyi.common.core.web.controller.BaseController; import com.ruoyi.common.security.service.TokenService; import com.ruoyi.common.security.utils.SecurityUtils; import com.ruoyi.order.feignClient.RemoteOrderGoodsClient; import com.ruoyi.order.model.Order; import com.ruoyi.other.api.domain.VipSetting; import com.ruoyi.system.api.model.LoginUser; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiParam; import org.springframework.format.annotation.DateTimeFormat; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestParam; import org.springframework.web.bind.annotation.RestController; import javax.annotation.Resource; import java.time.LocalDate; import java.time.LocalDateTime; import java.time.LocalTime; import java.time.YearMonth; import java.util.List; import java.util.stream.Collectors; @Api("钱包") @Api(tags = "小程序-个人中心-我的钱包") @RestController @RequestMapping("wallet") public class WalletController extends BaseController { @@ -29,27 +43,73 @@ private TokenService tokenService; @Resource private WalletService walletService; @Resource private RemoteOrderGoodsClient remoteOrderGoodsClient; @Resource private AppUserService appUserService; @Resource private VipSettingService vipSettingService; /** * 钱包详情 */ @GetMapping("detail") @ApiOperation(value = "钱包详情", notes = "钱包详情", tags = {"小程序-个人中心-我的钱包-钱包详情"}) @ApiOperation(value = "钱包详情", notes = "钱包详情") public R<WalletVO> detail() { LoginUser loginUserApplet = tokenService.getLoginUserApplet(); VipSetting vipSetting = vipSettingService.getVipSettingByUserId(loginUserApplet.getUserid()); WalletVO walletVO = walletService.getWalletByUserId(loginUserApplet.getUserid()); walletVO.setVipWithdrawalFee(vipSetting.getVipWithdrawalFee()); return R.ok(walletVO); } /** * 变更明细 */ @ApiOperation(value = "变更明细", notes = "变更明细", tags = {"小程序-个人中心-我的钱包-变更记录"}) @ApiOperation(value = "变更明细", notes = "变更明细") @GetMapping("change") public R<List<BalanceChangeRecord>> change() { public R<List<BalanceChangeRecord>> change(@ApiParam(value = "变更类型") @RequestParam(required = false) Integer changeType, @ApiParam(value = "创建时间") @RequestParam(required = false) @DateTimeFormat(pattern = "yyyy-MM-dd") LocalDate createTime) { Long userId = SecurityUtils.getUserId(); return R.ok(balanceChangeRecordService.list(new LambdaQueryWrapper<BalanceChangeRecord>() .eq(BalanceChangeRecord::getAppUserId, userId))); LocalDateTime startTime = null; LocalDateTime endTime = null; if (createTime != null) { // 将 createTime 设置为当天的开始时间 (00:00) startTime = createTime.atStartOfDay(); // 使用 YearMonth 来获取该月的最后一天 YearMonth yearMonth = YearMonth.from(createTime); LocalDate lastDayOfMonth = yearMonth.atEndOfMonth(); // 将最后一天转换为 LocalDateTime,并设置为当天的最后一秒 (23:59:59.999) endTime = lastDayOfMonth.atTime(LocalTime.MAX); } List<BalanceChangeRecord> list = balanceChangeRecordService.list(new LambdaQueryWrapper<BalanceChangeRecord>() .eq(changeType != null, BalanceChangeRecord::getChangeType, changeType) .between(startTime != null, BalanceChangeRecord::getCreateTime, startTime, endTime) .eq(BalanceChangeRecord::getAppUserId, userId)); List<Long> orderIds = list.stream().map(BalanceChangeRecord::getOrderId).collect(Collectors.toList()); R<List<Order>> r = remoteOrderGoodsClient.getOrderListByIds(orderIds); if (!R.isSuccess(r)){ return R.fail(r.getMsg()); } List<Order> orderList = r.getData(); list.forEach(bc -> { orderList.stream().filter(o -> o.getId().equals(bc.getOrderId())).findFirst().ifPresent(o -> { Long appUserId = o.getAppUserId(); AppUser appUser = appUserService.getById(appUserId); bc.setUserName(appUser.getName()); bc.setAmount(o.getPaymentAmount()); }); }); return R.ok(list); } // /** ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/mapper/AppUserBankMapper.java
New file @@ -0,0 +1,7 @@ package com.ruoyi.account.mapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.ruoyi.account.api.model.AppUserBank; public interface AppUserBankMapper extends BaseMapper<AppUserBank> { } ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/service/AppUserBankService.java
New file @@ -0,0 +1,7 @@ package com.ruoyi.account.service; import com.baomidou.mybatisplus.extension.service.IService; import com.ruoyi.account.api.model.AppUserBank; public interface AppUserBankService extends IService<AppUserBank> { } ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/service/AppUserService.java
@@ -57,4 +57,9 @@ * @return */ List<NearbyReferrerVo> getNearbyReferrer(NearbyReferrer nearbyReferrer); /** * 获取用户的祖籍列表 */ List<AppUser> getUserAncestorList(Long id,List<AppUser> list); } ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/service/VipSettingService.java
New file @@ -0,0 +1,10 @@ package com.ruoyi.account.service; import com.ruoyi.other.api.domain.VipSetting; public interface VipSettingService { VipSetting getVipSettingById(Integer id); VipSetting getVipSettingByUserId(Long appUserId); } ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/service/impl/AppUserBankServiceImpl.java
New file @@ -0,0 +1,11 @@ package com.ruoyi.account.service.impl; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.ruoyi.account.api.model.AppUserBank; import com.ruoyi.account.mapper.AppUserBankMapper; import com.ruoyi.account.service.AppUserBankService; import org.springframework.stereotype.Service; @Service public class AppUserBankServiceImpl extends ServiceImpl<AppUserBankMapper, AppUserBank> implements AppUserBankService { } ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/service/impl/AppUserServiceImpl.java
@@ -18,14 +18,13 @@ import com.ruoyi.system.api.domain.SysUser; import com.ruoyi.system.api.feignClient.SysUserClient; import com.ruoyi.system.api.model.LoginUser; import org.checkerframework.checker.units.qual.A; import org.springframework.stereotype.Service; import javax.annotation.Resource; import java.math.BigDecimal; import java.time.LocalDateTime; import java.util.HashMap; import java.util.List; import java.util.Map; import java.util.*; /** * <p> @@ -308,11 +307,11 @@ } public AppUser getTopAppUser(List<AppUser> list, Long id){ AppUser appUser = list.stream().filter(s -> s.getInviteUserId().equals(id)).findFirst().get(); AppUser appUser = list.stream().filter(s -> s.getId().equals(id)).findFirst().get(); if(null == appUser.getInviteUserId()){ return appUser; } return getTopAppUser(list, appUser.getId()); return getTopAppUser(list, appUser.getInviteUserId()); } @@ -330,4 +329,38 @@ List<NearbyReferrerVo> list = this.baseMapper.getNearbyReferrer(cityCode, nearbyReferrer); return list; } @Override public List<AppUser> getUserAncestorList(Long id, List<AppUser> list) { if (list == null) { list = new ArrayList<>(); } Set<Long> visitedIds = new HashSet<>(); Long currentId = id; while (currentId != null && !visitedIds.contains(currentId)) { AppUser appUser = getById(currentId); if (appUser == null) { break; // 如果用户不存在,终止循环 } Long inviteUserId = appUser.getInviteUserId(); if (inviteUserId != null) { AppUser invitedUser = getById(inviteUserId); if (invitedUser != null) { list.add(invitedUser); visitedIds.add(currentId); currentId = inviteUserId; } else { break; // 如果邀请用户不存在,终止循环 } } else { break; // 如果没有邀请用户,终止循环 } } return list; } } ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/service/impl/UserPointServiceImpl.java
@@ -40,10 +40,10 @@ List<UserPoint> userPointList = list(new LambdaQueryWrapper<UserPoint>() .eq(UserPoint::getAppUserId, userId)); Map<Integer, BigDecimal> userBalanceMap = userPointList.stream() Map<Integer, Integer> userBalanceMap = userPointList.stream() .collect(Collectors.toMap(UserPoint::getType, UserPoint::getBalance)); BigDecimal lavePoint = appUser.getLavePoint(); Integer lavePoint = appUser.getLavePoint(); UserPointVO userPointVO = new UserPointVO(); userPointVO.setTotalPoint(lavePoint); userPointVO.setShopPoint(userBalanceMap.get(PointChangeType.CONSUME.getCode())); ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/service/impl/VipSettingServiceImpl.java
New file @@ -0,0 +1,40 @@ package com.ruoyi.account.service.impl; import com.ruoyi.account.api.feignClient.AppUserClient; import com.ruoyi.account.api.model.AppUser; import com.ruoyi.account.service.VipSettingService; import com.ruoyi.common.core.domain.R; import com.ruoyi.common.core.exception.ServiceException; import com.ruoyi.other.api.domain.VipSetting; import com.ruoyi.other.api.feignClient.RemoteVipSettingClient; import org.springframework.stereotype.Service; import javax.annotation.Resource; @Service public class VipSettingServiceImpl implements VipSettingService { @Resource private RemoteVipSettingClient remoteVipSettingClient; @Resource private AppUserClient appUserClient; @Override public VipSetting getVipSettingById(Integer id) { R<VipSetting> vipSettingById = remoteVipSettingClient.getVipSettingById(id); if (!R.isSuccess(vipSettingById)){ throw new ServiceException("会员等级获取失败"); } return vipSettingById.getData(); } @Override public VipSetting getVipSettingByUserId(Long appUserId) { AppUser appUser = appUserClient.getAppUserById(appUserId); if(null == appUser){ throw new ServiceException("用户不存在"); } return getVipSettingById(appUser.getVipId()); } } ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/service/impl/WalletServiceImpl.java
@@ -34,9 +34,6 @@ } Integer vipId = appUser.getVipId(); R<VipSetting> r = remoteVipSettingClient.getVipSettingById(vipId); if (r == null || r.getCode() != R.SUCCESS) { throw new RuntimeException("获取会员设置信息失败"); } VipSetting data = r.getData(); if (data == null) { throw new RuntimeException("会员设置信息为空"); ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/service/impl/WithdrawalRequestsServiceImpl.java
@@ -1,13 +1,25 @@ package com.ruoyi.account.service.impl; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.ruoyi.account.api.feignClient.AppUserClient; import com.ruoyi.account.api.model.AppUser; import com.ruoyi.account.api.model.WithdrawalRequests; import com.ruoyi.account.dto.WithdrawalRequestsDTO; import com.ruoyi.account.mapper.WithdrawalRequestsMapper; import com.ruoyi.account.api.model.WithdrawalRequests; import com.ruoyi.account.service.VipSettingService; import com.ruoyi.account.service.WithdrawalRequestsService; import com.ruoyi.common.core.domain.R; import com.ruoyi.common.core.exception.ServiceException; import com.ruoyi.common.core.utils.bean.BeanUtils; import com.ruoyi.common.security.service.TokenService; import com.ruoyi.common.security.utils.SecurityUtils; import com.ruoyi.other.api.domain.VipSetting; import com.ruoyi.system.api.model.LoginUser; import org.springframework.stereotype.Service; import javax.annotation.Resource; import java.math.BigDecimal; import java.math.RoundingMode; /** * <p> @@ -19,9 +31,45 @@ */ @Service public class WithdrawalRequestsServiceImpl extends ServiceImpl<WithdrawalRequestsMapper, WithdrawalRequests> implements WithdrawalRequestsService { @Resource private TokenService tokenService; @Resource private AppUserClient appUserClient; @Resource private VipSettingService vipSettingService; public static final BigDecimal MAX_WITHDRAWAL_AMOUNT = new BigDecimal("200"); public static final BigDecimal VIP_WITHDRAWAL_FEE_DENOMINATOR = new BigDecimal("100"); @Override public void withdrawalApply(WithdrawalRequestsDTO params) { if (params.getWithdrawalAmount().compareTo(MAX_WITHDRAWAL_AMOUNT) > 0) { throw new ServiceException("提现失败,单次提现金额不能超过200元!"); } LoginUser loginUserApplet = tokenService.getLoginUserApplet(); AppUser appUser = appUserClient.getAppUserById(loginUserApplet.getUserid()); if (appUser.getWithdrawableAmount().compareTo(params.getWithdrawalAmount()) < 0) { throw new ServiceException("提现失败,可提现金额不足!"); } Integer vipId = appUser.getVipId(); VipSetting vipSetting = vipSettingService.getVipSettingById(vipId); if (vipSetting.getVipWithdrawalRole() == 0) { throw new ServiceException("提现失败,当前会员等级不允许提现!"); } BigDecimal vipWithdrawalMinAmount = vipSetting.getVipWithdrawalMinAmount(); if (params.getWithdrawalAmount().compareTo(vipWithdrawalMinAmount) < 0) { throw new ServiceException("提现失败,提现金额不能小于" + vipWithdrawalMinAmount + "元!"); } // 提现手续费 BigDecimal vipWithdrawalFee = vipSetting.getVipWithdrawalFee() .divide(VIP_WITHDRAWAL_FEE_DENOMINATOR, 2, RoundingMode.HALF_UP); // 减去手续费 params.setWithdrawalAmount(params.getWithdrawalAmount() .subtract(params.getWithdrawalAmount().multiply(vipWithdrawalFee))); WithdrawalRequests withdrawalRequests = new WithdrawalRequests(); BeanUtils.copyBeanProp(withdrawalRequests, params); withdrawalRequests.setDelFlag(0); @@ -29,4 +77,5 @@ withdrawalRequests.setAuditStatus(1); save(withdrawalRequests); } } ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/util/weChat/TaskUtil.java
File was renamed from ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/util/TaskUtil.java @@ -1,4 +1,4 @@ package com.ruoyi.account.util; package com.ruoyi.account.util.weChat; import org.springframework.scheduling.annotation.Scheduled; ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/util/weChat/weChat/AES.java
ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/util/weChat/weChat/WXCore.java
ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/util/weChat/weChat/WeChatUtil.java
ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/util/weChat/weChat/WxPKCS7Encoder.java
ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/vo/UserPointDetailVO.java
@@ -16,7 +16,7 @@ private Integer type; @ApiModelProperty(value = "变动金额") private BigDecimal variablePoint; private Integer variablePoint; @ApiModelProperty(value = "变动时间") private LocalDateTime createTime; ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/vo/UserPointVO.java
@@ -1,31 +1,28 @@ package com.ruoyi.account.vo; import com.baomidou.mybatisplus.annotation.TableField; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import lombok.Data; import java.math.BigDecimal; @Data @ApiModel(value="UserPoint对象", description="") public class UserPointVO { @ApiModelProperty(value = "总积分") private BigDecimal totalPoint; private Integer totalPoint; @ApiModelProperty(value = "消费积分数") private BigDecimal shopPoint; private Integer shopPoint; @ApiModelProperty(value = "返佣积分数") private BigDecimal sharePoint; private Integer sharePoint; @ApiModelProperty(value = "拉新积分") private BigDecimal pullNewPoint; private Integer pullNewPoint; @ApiModelProperty(value = "门店业绩积分") private BigDecimal shopAchievementPoint; private Integer shopAchievementPoint; @ApiModelProperty(value = "门店返佣积分") private BigDecimal shopSharePoint; private Integer shopSharePoint; } ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/vo/WalletVO.java
@@ -33,4 +33,7 @@ @ApiModelProperty(value = "分销总金额") private BigDecimal totalDistributionAmount; @ApiModelProperty(value = "提现手续费") private BigDecimal vipWithdrawalFee; } ruoyi-service/ruoyi-account/src/test/java/com/ruoyi/order/account/RuoYiAccountApplicationTests.java
ruoyi-service/ruoyi-order/pom.xml
@@ -124,7 +124,7 @@ <dependency> <groupId>com.baomidou</groupId> <artifactId>mybatis-plus-boot-starter</artifactId> <version>3.5.2</version> <version>3.5.4</version> </dependency> <dependency> @@ -145,6 +145,11 @@ </exclusions> </dependency> <dependency> <groupId>com.github.pagehelper</groupId> <artifactId>pagehelper-spring-boot-starter</artifactId> </dependency> </dependencies> <build> ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/controller/OrderController.java
@@ -5,6 +5,7 @@ import com.ruoyi.common.core.domain.R; import com.ruoyi.common.security.service.TokenService; import com.ruoyi.order.service.OrderService; import org.springframework.web.bind.annotation.*; import com.ruoyi.order.vo.OrderDetailVO; import com.ruoyi.order.vo.OrderVO; import com.ruoyi.system.api.model.LoginUser; @@ -12,11 +13,7 @@ import io.swagger.annotations.ApiImplicitParam; import io.swagger.annotations.ApiImplicitParams; import io.swagger.annotations.ApiOperation; import model.Order; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; import com.ruoyi.order.model.Order; import javax.annotation.Resource; import java.util.List; @@ -53,6 +50,14 @@ } /** * 通过订单ids获取订单列表 */ @PostMapping("/getOrderListByIds") public R<List<Order>> getOrderListByIds(@RequestBody List<Long> ids){ return R.ok(orderService.listByIds(ids)); } /** * 订单详情 */ @ApiOperation(value = "订单详情", tags = {"小程序-订单详情"}) ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/controller/OrderGoodController.java
File was deleted ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/controller/ShoppingCartController.java
@@ -2,7 +2,6 @@ import com.ruoyi.common.core.domain.R; import com.ruoyi.common.core.web.controller.BaseController; import com.ruoyi.common.core.web.domain.AjaxResult; import com.ruoyi.common.core.web.page.TableDataInfo; import com.ruoyi.common.security.service.TokenService; import com.ruoyi.order.service.ShoppingCartService; @@ -11,7 +10,7 @@ import io.swagger.annotations.ApiImplicitParam; import io.swagger.annotations.ApiImplicitParams; import io.swagger.annotations.ApiOperation; import model.ShoppingCart; import com.ruoyi.order.model.ShoppingCart; import org.springframework.web.bind.annotation.*; import javax.annotation.Resource; ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/enums/OrderStatus.java
File was deleted ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/enums/OrderType.java
File was deleted ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/mapper/OrderGoodMapper.java
File was deleted ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/mapper/OrderMapper.java
@@ -2,7 +2,7 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.ruoyi.order.vo.OrderVO; import model.Order; import com.ruoyi.order.model.Order; import java.util.List; ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/mapper/RefundPassMapper.java
@@ -1,7 +1,7 @@ package com.ruoyi.order.mapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper; import model.RefundPass; import com.ruoyi.order.model.RefundPass; /** * <p> ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/mapper/ShoppingCartMapper.java
@@ -1,7 +1,7 @@ package com.ruoyi.order.mapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper; import model.ShoppingCart; import com.ruoyi.order.model.ShoppingCart; public interface ShoppingCartMapper extends BaseMapper<ShoppingCart> { ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/service/CommissionService.java
New file @@ -0,0 +1,12 @@ package com.ruoyi.order.service; import java.time.LocalDateTime; import java.util.List; public interface CommissionService { // 计算佣金 void calculationCommission(List<Long> orderIds); void addToCommissionDelayQueue(Long orderId, LocalDateTime afterSalesDeadline); } ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/service/OrderGoodService.java
File was deleted ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/service/OrderService.java
File was deleted ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/service/RefundPassService.java
File was deleted ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/service/ShoppingCartService.java
File was deleted ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/service/impl/CommissionServiceImpl.java
New file @@ -0,0 +1,111 @@ package com.ruoyi.order.service.impl; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.ruoyi.account.api.feignClient.AppUserClient; import com.ruoyi.account.api.model.AppUser; import com.ruoyi.common.core.domain.R; import com.ruoyi.order.service.CommissionService; import com.ruoyi.order.service.OrderGoodService; import com.ruoyi.order.service.OrderService; import com.ruoyi.other.api.domain.Shop; import com.ruoyi.other.api.feignClient.ShopClient; import com.ruoyi.order.model.Order; import com.ruoyi.order.model.OrderGood; import org.springframework.data.redis.core.RedisTemplate; import org.springframework.stereotype.Service; import javax.annotation.Resource; import java.math.BigDecimal; import java.time.LocalDateTime; import java.time.ZoneId; import java.util.List; import java.util.Map; import java.util.stream.Collectors; @Service public class CommissionServiceImpl implements CommissionService { @Resource private OrderService orderService; @Resource private OrderGoodService orderGoodService; @Resource private AppUserClient appUserClient; @Resource private ShopClient shopClient; @Resource private RedisTemplate<String, String> redisTemplate; /** * 返佣延迟队列(redis有序集合) * * @param orderId 订单ID * @param afterSalesDeadline 售后截止日期(计算日期) */ @Override public void addToCommissionDelayQueue(Long orderId, LocalDateTime afterSalesDeadline) { // 获取订单售后截止日期时间戳(秒) long deadlineTimestamp = afterSalesDeadline.atZone(ZoneId.systemDefault()).toEpochSecond(); redisTemplate.opsForZSet().add("delay_queue:commission", orderId.toString(), deadlineTimestamp); } @Override public void calculationCommission(List<Long> orderIds) { List<OrderGood> orderGoods = orderGoodService.list(new LambdaQueryWrapper<OrderGood>() .in(OrderGood::getOrderId, orderIds)); Map<Long, List<OrderGood>> ogMap = orderGoods.stream().collect(Collectors.groupingBy(OrderGood::getOrderId)); for (Map.Entry<Long, List<OrderGood>> entry : ogMap.entrySet()) { Long k = entry.getKey(); List<OrderGood> v = entry.getValue(); Order order = orderService.getById(k); if (order.getIsCommission() == 1) { continue; } R<Shop> r = shopClient.getShopById(order.getShopId()); if (!R.isSuccess(r)) { throw new RuntimeException("获取门店信息失败"); } Shop shop = r.getData(); if (shop == null) { throw new RuntimeException("获取门店信息失败"); } Long appUserId = order.getAppUserId(); AppUser appUser = appUserClient.getAppUserById(appUserId); if (appUser == null) { throw new RuntimeException("获取用户信息失败"); } Long inviteUserId = appUser.getInviteUserId(); AppUser inviteUser = appUserClient.getAppUserById(inviteUserId); for (OrderGood og : v) {// 累计分销金额 // 上级分销金额 if (inviteUser != null){ BigDecimal superiorSubcommission = og.getSuperiorSubcommission(); BigDecimal totalDistributionAmount = inviteUser.getTotalDistributionAmount(); totalDistributionAmount = totalDistributionAmount.add(superiorSubcommission); // Integer superiorType = og.getSuperiorType(); Integer sharePoint = inviteUser.getSharePoint(); if (superiorType == 1) { Integer superiorRebatePoints = og.getSuperiorRebatePoints(); sharePoint = sharePoint + superiorRebatePoints; } else if (superiorType == 2) { } else { continue; } inviteUser.setTotalDistributionAmount(totalDistributionAmount); inviteUser.setSharePoint(sharePoint); } // 门店分销金额 og.getBoundShopCharges(); } } } } ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/service/impl/OrderGoodServiceImpl.java
File was deleted ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/service/impl/OrderServiceImpl.java
File was deleted ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/service/impl/RefundPassServiceImpl.java
File was deleted ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/service/impl/ShoppingCartServiceImpl.java
File was deleted ruoyi-service/ruoyi-order/src/test/java/com/ruoyi/order/RuoYiOrderApplicationTests.java
File was deleted ruoyi-service/ruoyi-other/pom.xml
@@ -114,7 +114,7 @@ <dependency> <groupId>com.baomidou</groupId> <artifactId>mybatis-plus-boot-starter</artifactId> <version>3.5.2</version> <version>3.5.4</version> </dependency> <dependency> @@ -132,6 +132,10 @@ <version>RELEASE</version> <scope>compile</scope> </dependency> <dependency> <groupId>com.github.pagehelper</groupId> <artifactId>pagehelper-spring-boot-starter</artifactId> </dependency> </dependencies> <build> ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/RuoYiOtherApplication.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/config/DataUpdateHandlerConfig.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/config/HttpConfig.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/config/MybatisPlusConfig.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/BannerController.java
@@ -32,8 +32,8 @@ @ApiOperation(value = "banner列表", tags = {"小程序-banner"}) public R<List<Banner>> list(String name, Integer jumpType, Integer position){ List<Banner> list = bannerService.lambdaQuery().like(StringUtils.isNotEmpty(name), Banner::getName, name) .eq(Banner::getJumpType, jumpType) .eq(Banner::getPosition, position) .eq(jumpType!=null,Banner::getJumpType, jumpType) .eq(position!=null,Banner::getPosition, position) .list(); return R.ok(list); } ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/GoodsCategoryController.java
@@ -34,7 +34,7 @@ @Resource private GoodsCategoryService goodsCategoryService; @PostMapping("/index/list") @GetMapping("/index/list") @ApiOperation(value = "商品分类", tags = {"小程序-首页"}) public R<List<GoodsCategory>> indexlist(){ List<GoodsCategory> indexlist = goodsCategoryService.lambdaQuery() ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/ShopController.java
@@ -10,16 +10,10 @@ import com.ruoyi.common.security.utils.SecurityUtils; import com.ruoyi.other.api.domain.Shop; import com.ruoyi.other.api.domain.Technician; import com.ruoyi.other.enums.ShopStatus; import com.ruoyi.other.service.ShopService; import com.ruoyi.other.service.TechnicianService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiParam; import org.springframework.web.bind.annotation.*; import com.ruoyi.other.vo.NearbyShopVO; import com.ruoyi.other.vo.ShopDetailVO; import com.ruoyi.other.vo.VerifiableShopVo; import io.swagger.annotations.*; import org.springframework.web.bind.annotation.*; ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/SystemConfigController.java
@@ -6,6 +6,7 @@ import com.ruoyi.common.core.domain.R; import com.ruoyi.other.api.domain.SystemConfig; import com.ruoyi.other.api.dto.IndexConfigSetDto; import com.ruoyi.other.api.dto.StartPageSetDto; import com.ruoyi.other.service.SystemConfigService; import org.springframework.web.bind.annotation.*; import io.swagger.annotations.Api; @@ -40,7 +41,7 @@ systemConfigService.save(systemConfig); return R.ok(); } @PostMapping("/index/detail") @GetMapping("/index/detail") @ApiOperation(value = "宣传图片-公司简介", tags = {"后台-广告管理-首页配置","小程序-首页"}) public R<IndexConfigSetDto> detail(){ SystemConfig one = systemConfigService.lambdaQuery().eq(SystemConfig::getType, 2).one(); @@ -65,5 +66,31 @@ return R.ok(one); } @PostMapping("/index/start") @ApiOperation(value = "宣传图片-公司简介", tags = {"小程序-启动页"}) public R<StartPageSetDto> indexstart(){ SystemConfig one = systemConfigService.lambdaQuery().eq(SystemConfig::getType, 1).one(); if (one==null){ return R.ok(); } StartPageSetDto indexConfigSetDto = JSONObject.parseObject(one.getContent(), StartPageSetDto.class); return R.ok(indexConfigSetDto); } @PostMapping("/startPage/add") @ApiOperation(value = "添加", tags = {"后台-广告管理-启动页管理"}) public R startPageadd(@RequestBody StartPageSetDto startPageSetDto){ //先删除type=1的数据 List<SystemConfig> list = systemConfigService.lambdaQuery().eq(SystemConfig::getType, 1).list(); systemConfigService.removeBatchByIds(list); SystemConfig systemConfig = new SystemConfig(); systemConfig.setType(1); systemConfig.setContent(JSON.toJSONString(startPageSetDto)); systemConfigService.save(systemConfig); return R.ok(); } } ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/TechnicianController.java
@@ -54,62 +54,61 @@ private TechnicianSubscribeService technicianSubscribeService; @Resource private TokenService tokenService; @PostMapping("/shop/list") @ApiOperation(value = "获取门店的技师列表", tags = {"小程序-门店详情-技师预约"}) public R<Page<Technician>> shoplist(@RequestParam Integer shopId,@RequestParam Integer pageNum,@RequestParam Integer pageSize){ //查出技师列表 Page<Technician> page = technicianService.lambdaQuery().eq(Technician::getShopId, shopId).eq(Technician::getStatus, 2).page(Page.of(pageNum, pageSize)); for (Technician technician : page.getRecords()) { //查出技师订单 R<List<Long>> orderIdsByTechId = orderClient.getOrderIdsByTechId(technician.getId()); if (orderIdsByTechId.getData().isEmpty()){ technician.setGrade(new BigDecimal(0)); technician.setServeCount(0); continue; } //查出技师评价 List<GoodsEvaluate> list = goodsEvaluateService.lambdaQuery().in(GoodsEvaluate::getOrderId, orderIdsByTechId.getData()).list(); // @PostMapping("/shop/list") // @ApiOperation(value = "获取门店的技师列表", tags = {"小程序-门店详情-技师预约"}) // public R<Page<Technician>> shoplist(@RequestParam Integer shopId,@RequestParam Integer pageNum,@RequestParam Integer pageSize){ // //查出技师列表 // Page<Technician> page = technicianService.lambdaQuery().eq(Technician::getShopId, shopId).eq(Technician::getStatus, 2).page(Page.of(pageNum, pageSize)); // for (Technician technician : page.getRecords()) { // //查出技师订单 // R<List<Long>> orderIdsByTechId = orderClient.getOrderIdsByTechId(technician.getId()); // if (orderIdsByTechId.getData().isEmpty()){ // technician.setGrade(new BigDecimal(0)); // technician.setServeCount(0); // continue; // } // //查出技师评价 // List<GoodsEvaluate> list = goodsEvaluateService.lambdaQuery().in(GoodsEvaluate::getOrderId, orderIdsByTechId.getData()).list(); // // //算出平均分并保留一位小数 // BigDecimal avg = list.stream().map(GoodsEvaluate::getGrade).reduce(BigDecimal.ZERO, BigDecimal::add).divide(new BigDecimal(list.size()), 1, BigDecimal.ROUND_HALF_UP); // technician.setGrade(avg); // technician.setServeCount(orderIdsByTechId.getData().size()); // // } // return R.ok(page); // } //算出平均分并保留一位小数 BigDecimal avg = list.stream().map(GoodsEvaluate::getGrade).reduce(BigDecimal.ZERO, BigDecimal::add).divide(new BigDecimal(list.size()), 1, BigDecimal.ROUND_HALF_UP); technician.setGrade(avg); technician.setServeCount(orderIdsByTechId.getData().size()); } return R.ok(page); } @PostMapping("/shop/detail") @ApiOperation(value = "获取门店的技师详情", tags = {"小程序-门店详情-技师预约"}) public R<Technician> shopdetail(@RequestParam Integer techId) { //查出技师列表 Technician technician = technicianService.getById(techId); //查出技师订单 R<List<Long>> orderIdsByTechId = orderClient.getOrderIdsByTechId(technician.getId()); if (orderIdsByTechId.getData().isEmpty()) { technician.setGrade(new BigDecimal(0)); technician.setServeCount(0); return R.ok(technician); } //查出技师评价 List<GoodsEvaluate> list = goodsEvaluateService.lambdaQuery().in(GoodsEvaluate::getOrderId, orderIdsByTechId.getData()).list(); //算出平均分并保留一位小数 BigDecimal avg = list.stream().map(GoodsEvaluate::getGrade).reduce(BigDecimal.ZERO, BigDecimal::add).divide(new BigDecimal(list.size()), 1, BigDecimal.ROUND_HALF_UP); technician.setGrade(avg); technician.setServeCount(orderIdsByTechId.getData().size()); return R.ok(technician); } @PostMapping("/shop/tech") @ApiOperation(value = "预约操作", tags = {"小程序-门店详情-技师预约"}) public R<Technician> shoptech(@RequestBody TechnicianSubscribe subscribe) { Long userId = tokenService.getLoginUserApplet().getUserid(); subscribe.setAppUserId(userId); technicianSubscribeService.save(subscribe); return R.ok(); } // @PostMapping("/shop/detail") // @ApiOperation(value = "获取门店的技师详情", tags = {"小程序-门店详情-技师预约"}) // public R<Technician> shopdetail(@RequestParam Integer techId){ // //查出技师列表 // Technician technician = technicianService.getById(techId); // // //查出技师订单 // R<List<Long>> orderIdsByTechId = orderClient.getOrderIdsByTechId(technician.getId()); // if (orderIdsByTechId.getData().isEmpty()){ // technician.setGrade(new BigDecimal(0)); // technician.setServeCount(0); // return R.ok(technician); // } // //查出技师评价 // List<GoodsEvaluate> list = goodsEvaluateService.lambdaQuery().in(GoodsEvaluate::getOrderId, orderIdsByTechId.getData()).list(); // // //算出平均分并保留一位小数 // BigDecimal avg = list.stream().map(GoodsEvaluate::getGrade).reduce(BigDecimal.ZERO, BigDecimal::add).divide(new BigDecimal(list.size()), 1, BigDecimal.ROUND_HALF_UP); // technician.setGrade(avg); // technician.setServeCount(orderIdsByTechId.getData().size()); // return R.ok(technician); // } // @PostMapping("/shop/tech") // @ApiOperation(value = "预约操作", tags = {"小程序-门店详情-技师预约"}) // public R<Technician> shoptech(@RequestBody TechnicianSubscribe subscribe){ // Long userId = tokenService.getLoginUserApplet().getUserid(); // subscribe.setAppUserId(userId); // technicianSubscribeService.save(subscribe); // return R.ok(); // } /** ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/TechnicianSubscribeController.java
@@ -75,12 +75,12 @@ } /** * 跟新技师预约状态 * 更新技师预约状态 * * @param status */ @PutMapping("/updateStatus") @ApiOperation(value = "跟新技师预约状态", notes = "跟新技师预约状态", tags = {"后台-技师预约管理-跟新技师预约状态"}) @ApiOperation(value = "更新技师预约状态", notes = "更新技师预约状态", tags = {"后台-技师预约管理-更新技师预约状态"}) public R<Void> updateStatus(@ApiParam @RequestParam Integer status, @ApiParam @RequestParam Long subscribeId) { boolean update = technicianSubscribeService.update(new LambdaUpdateWrapper<TechnicianSubscribe>() .eq(TechnicianSubscribe::getId, subscribeId) ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/VipSettingController.java
@@ -1,21 +1,22 @@ package com.ruoyi.other.controller; import com.ruoyi.account.api.feignClient.AppUserClient; import com.ruoyi.account.api.model.AppUser; import com.ruoyi.common.core.domain.R; import com.ruoyi.common.security.service.TokenService; import com.ruoyi.other.api.domain.VipGood; import com.ruoyi.other.api.domain.VipSetting; import com.ruoyi.other.service.VipGoodService; import com.ruoyi.other.service.VipSettingService; import io.swagger.annotations.ApiOperation; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.*; import com.ruoyi.common.core.domain.R; import com.ruoyi.other.api.domain.VipSetting; import com.ruoyi.other.service.VipSettingService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiParam; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; import javax.annotation.Resource; import java.util.List; @@ -36,18 +37,74 @@ public class VipSettingController { @Resource private VipSettingService vipSettingService; @Resource private AppUserClient appUserClient; @Resource private TokenService tokenService; @Resource private VipGoodService vipGoodService; @PostMapping("/info") @ApiOperation(value = "获取各级会员信息", tags = {"小程序-个人中心首页"}) public R<List<VipSetting>> info(){ @ApiOperation(value = "获取各级会员信息", tags = {"小程序-个人中心首页", "小程序-会员中心"}) public R<List<VipSetting>> info() { List<VipSetting> list = vipSettingService.list(); return R.ok(list); } // @PostMapping("/button/agent/check") // @ApiOperation(value = "准代理,代理按钮是否展示", tags = {"小程序-个人中心首页","小程序-会员中心"}) // public R<Boolean> buttoncheck(@ApiParam("4准代理,5代理")Integer id) { // Long userid = tokenService.getLoginUserApplet().getUserid(); // AppUser appUserById = appUserClient.getAppUserById(userid); // Boolean back = true; // VipSetting byId = vipSettingService.getById(id); // //第一种判断 // if (byId == null) { // back = false; // } else { // if (byId.getVipAgentLevelUpRole() == null || byId.getVipAgentLevelUpRole() == 0) { // back = false; // } // if (byId.getVipLevelUpShop() == null || byId.getVipLevelUpShare() == null) { // back = false; // } else { // if (back && appUserById.getShopPoint().compareTo(byId.getVipLevelUpShop()) > 0 && appUserById.getSharePoint().compareTo(byId.getVipLevelUpShare()) > 0) { // back = true; // } // } // if (back) { // return R.ok(true); // } // //第二种判断 // if (byId.getVipDirectVipRole() == null || byId.getVipDirectVipRole() == 0 || byId.getVipDirectVipNum() == null) { // back = false; // } else { // //拿到当前用户直推钻石会员人数 // Long data = appUserClient.getVipCount(userid, 3).getData(); // if (data >= byId.getVipDirectVipNum()) { // return R.ok(true); // } // } // //第三种判断 // List<VipGood> list = vipGoodService.lambdaQuery().eq(VipGood::getVipId, id).list(); // for (VipGood vipGood : list) { // //挨个判断是否购买商品 // // // } // } // // return R.ok(); // } @GetMapping("getVipSettingById") @ApiOperation(value = "获取会员设置") public R<VipSetting> getVipSettingById(@ApiParam(value = "会员id") Integer id){ public R<VipSetting> getVipSettingById(@ApiParam(value = "会员id") @RequestParam Integer id) { return R.ok(vipSettingService.getById(id)); } } ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/enums/GoodsStatus.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/enums/PhoneType.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/enums/ShareAddType.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/enums/ShareAuditStatus.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/enums/ShopStatus.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/enums/TechnicianErrorCode.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/enums/TechnicianStatus.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/filter/AuthFilter.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/AgreementMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/BannerMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/BaseSettingMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/CouponInfoMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/GoodsAppUserMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/GoodsAreaMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/GoodsBargainPriceDetailMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/GoodsBargainPriceMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/GoodsCategoryMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/GoodsEvaluateMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/GoodsMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/GoodsSeckillMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/GoodsShopMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/GoodsVipMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/OrderActivityInfoMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/PhoneMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/PointSettingMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/RechargeSetMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/RedPackegeSetMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/RegionMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/SeckillActivityInfoMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/ShareMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/ShopBalanceStatementMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/ShopMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/ShopPointMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/ShopWithdrawMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/SystemConfigMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/TechnicianMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/TechnicianSubscribeMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/VipGoodMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/mapper/VipSettingMapper.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/AgreementService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/BannerService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/BaseSettingService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/CouponInfoService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/GoodsAppUserService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/GoodsAreaService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/GoodsBargainPriceDetailService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/GoodsBargainPriceService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/GoodsCategoryService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/GoodsEvaluateService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/GoodsSeckillService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/GoodsService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/GoodsShopService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/GoodsVipService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/IAgreementService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/OrderActivityInfoService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/PhoneService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/PointSettingService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/RechargeSetService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/RedPackegeSetService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/RegionService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/SeckillActivityInfoService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/ShareService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/ShopBalanceStatementService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/ShopPointService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/ShopService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/ShopWithdrawService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/SystemConfigService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/TechnicianService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/TechnicianSubscribeService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/VipGoodService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/VipSettingService.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/AgreementServiceImpl.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/BaseSettingServiceImpl.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/GoodsAppUserServiceImpl.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/GoodsAreaServiceImpl.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/GoodsBargainPriceServiceImpl.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/GoodsEvaluateServiceImpl.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/GoodsSeckillServiceImpl.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/GoodsServiceImpl.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/GoodsShopServiceImpl.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/GoodsVipServiceImpl.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/PhoneServiceImpl.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/RechargeSetServiceImpl.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/RedPackegeSetServiceImpl.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/SeckillActivityInfoServiceImpl.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/ShareServiceImpl.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/ShopPointServiceImpl.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/ShopServiceImpl.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/TechnicianServiceImpl.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/TechnicianSubscribeServiceImpl.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/VipGoodServiceImpl.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/vo/GoodsVO.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/vo/Home.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/vo/NearbyShopVO.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/vo/SeckillActivityDetailVO.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/vo/SeckillActivityVO.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/vo/ShopDetailVO.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/vo/TechnicianDetailVO.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/vo/TechnicianSubscribeVO.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/vo/TechnicianVO.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/vo/VerifiableShopVo.java
File was deleted ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/vo/WalletChangeVO.java
File was deleted ruoyi-service/ruoyi-other/src/main/resources/mapper/other/SeckillActivityInfoMapper.xml
@@ -15,9 +15,9 @@ FROM t_seckill_activity_info tsai LEFT JOIN t_goods tg ON tsai.good_id = tg.id LEFT JOIN t_goods_seckill tgs ON tgs.goods_id = tg.id LEFT JOIN t_goods_seckill tgs ON tgs.seckill_activity_info_id = tsai.id WHERE tsai.end_time >= NOW() <if test="goodsName != null and goodsName != ''"> <if test="name != null and name != ''"> AND tg.`name` LIKE concat('%',#{goodsName},'%') </if> <if test="goodsCategoryId != null"> @@ -43,7 +43,7 @@ FROM t_seckill_activity_info tsai LEFT JOIN t_goods tg ON tsai.good_id = tg.id LEFT JOIN t_goods_seckill tgs ON tgs.goods_id = tg.id LEFT JOIN t_goods_seckill tgs ON tgs.seckill_activity_info_id = tsai.id WHERE tsai.id = #{seckillActivityId} </select> </mapper> ruoyi-service/ruoyi-other/src/test/java/com/ruoyi/other/RuoYiOtherApplicationTests.java
File was deleted