🚧 商品包调整
This commit is contained in:
parent
b996ddfa1e
commit
055d204ded
@ -49,6 +49,12 @@
|
||||
<artifactId>mybatis-plus-boot-starter</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>cn.iocoder.mall</groupId>
|
||||
<artifactId>mall-spring-boot-starter-mybatis</artifactId>
|
||||
<version>1.0-SNAPSHOT</version>
|
||||
</dependency>
|
||||
|
||||
<!-- RPC 相关 -->
|
||||
<dependency>
|
||||
<groupId>com.alibaba.cloud</groupId>
|
||||
@ -78,6 +84,12 @@
|
||||
<groupId>com.google.guava</groupId>
|
||||
<artifactId>guava</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>cn.iocoder.mall</groupId>
|
||||
<artifactId>user-biz</artifactId>
|
||||
<version>1.0-SNAPSHOT</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
package cn.iocoder.mall.product.dataobject;
|
||||
|
||||
import cn.iocoder.common.framework.dataobject.DeletableDO;
|
||||
import cn.iocoder.mall.mybatis.dataobject.DeletableDO;
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
package cn.iocoder.mall.product.dataobject;
|
||||
|
||||
import cn.iocoder.common.framework.dataobject.DeletableDO;
|
||||
import cn.iocoder.mall.mybatis.dataobject.DeletableDO;
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
package cn.iocoder.mall.product.dataobject;
|
||||
|
||||
import cn.iocoder.common.framework.dataobject.DeletableDO;
|
||||
import cn.iocoder.mall.mybatis.dataobject.DeletableDO;
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
package cn.iocoder.mall.product.dataobject;
|
||||
|
||||
import cn.iocoder.common.framework.dataobject.DeletableDO;
|
||||
import cn.iocoder.mall.mybatis.dataobject.DeletableDO;
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
package cn.iocoder.mall.product.dataobject;
|
||||
|
||||
import cn.iocoder.common.framework.dataobject.DeletableDO;
|
||||
import cn.iocoder.mall.mybatis.dataobject.DeletableDO;
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
package cn.iocoder.mall.product.dataobject;
|
||||
|
||||
import cn.iocoder.common.framework.dataobject.DeletableDO;
|
||||
import cn.iocoder.mall.mybatis.dataobject.DeletableDO;
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
package cn.iocoder.mall.product.message;
|
||||
|
||||
import cn.iocoder.common.framework.constant.DeletedStatusEnum;
|
||||
import cn.iocoder.common.framework.util.ServiceExceptionUtil;
|
||||
import cn.iocoder.mall.mybatis.enums.DeletedStatusEnum;
|
||||
import cn.iocoder.mall.product.api.UserProductSpuCollectionsService;
|
||||
import cn.iocoder.mall.product.api.bo.UserProductSpuCollectionsBO;
|
||||
import cn.iocoder.mall.product.api.dto.UserProductSpuCollectionsAddDTO;
|
||||
@ -10,7 +10,7 @@ import cn.iocoder.mall.product.api.message.ProductSpuCollectionMessage;
|
||||
import cn.iocoder.mall.product.convert.UserProductSpuCollectionsConvert;
|
||||
import cn.iocoder.mall.user.api.UserService;
|
||||
import cn.iocoder.mall.user.api.bo.UserBO;
|
||||
import cn.iocoder.mall.user.api.constant.UserErrorCodeEnum;
|
||||
import cn.iocoder.mall.user.biz.enums.UserErrorCodeEnum;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.apache.dubbo.config.annotation.Reference;
|
||||
import org.apache.rocketmq.spring.annotation.RocketMQMessageListener;
|
||||
|
@ -1,7 +1,7 @@
|
||||
package cn.iocoder.mall.product.service;
|
||||
|
||||
import cn.iocoder.common.framework.constant.DeletedStatusEnum;
|
||||
import cn.iocoder.common.framework.util.ServiceExceptionUtil;
|
||||
import cn.iocoder.mall.mybatis.enums.DeletedStatusEnum;
|
||||
import cn.iocoder.mall.product.api.ProductAttrService;
|
||||
import cn.iocoder.mall.product.api.bo.*;
|
||||
import cn.iocoder.mall.product.api.constant.ProductAttrConstants;
|
||||
|
@ -1,7 +1,7 @@
|
||||
package cn.iocoder.mall.product.service;
|
||||
|
||||
import cn.iocoder.common.framework.constant.DeletedStatusEnum;
|
||||
import cn.iocoder.common.framework.util.ServiceExceptionUtil;
|
||||
import cn.iocoder.mall.mybatis.enums.DeletedStatusEnum;
|
||||
import cn.iocoder.mall.product.api.ProductCategoryService;
|
||||
import cn.iocoder.mall.product.api.bo.ProductCategoryBO;
|
||||
import cn.iocoder.mall.product.api.constant.ProductCategoryConstants;
|
||||
|
@ -1,9 +1,9 @@
|
||||
package cn.iocoder.mall.product.service;
|
||||
|
||||
import cn.iocoder.common.framework.constant.DeletedStatusEnum;
|
||||
import cn.iocoder.common.framework.util.CollectionUtil;
|
||||
import cn.iocoder.common.framework.util.ServiceExceptionUtil;
|
||||
import cn.iocoder.common.framework.util.StringUtil;
|
||||
import cn.iocoder.mall.mybatis.enums.DeletedStatusEnum;
|
||||
import cn.iocoder.mall.product.api.ProductSpuService;
|
||||
import cn.iocoder.mall.product.api.bo.*;
|
||||
import cn.iocoder.mall.product.api.constant.ProductCategoryConstants;
|
||||
|
@ -1,7 +1,7 @@
|
||||
package cn.iocoder.mall.product.service;
|
||||
|
||||
import cn.iocoder.common.framework.constant.DeletedStatusEnum;
|
||||
import cn.iocoder.common.framework.vo.CommonResult;
|
||||
import cn.iocoder.mall.mybatis.enums.DeletedStatusEnum;
|
||||
import cn.iocoder.mall.product.api.UserProductSpuCollectionsService;
|
||||
import cn.iocoder.mall.product.api.bo.UserProductSpuCollectionsBO;
|
||||
import cn.iocoder.mall.product.api.bo.UserProductSpuCollectionsPageBO;
|
||||
|
@ -33,14 +33,10 @@
|
||||
<artifactId>product-service-impl</artifactId>
|
||||
<version>1.0-SNAPSHOT</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>cn.iocoder.mall</groupId>
|
||||
<artifactId>user-sdk</artifactId>
|
||||
<version>1.0-SNAPSHOT</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>cn.iocoder.mall</groupId>
|
||||
<artifactId>system-sdk</artifactId>
|
||||
<artifactId>mall-spring-boot-starter-mybatis</artifactId>
|
||||
<version>1.0-SNAPSHOT</version>
|
||||
</dependency>
|
||||
|
||||
@ -82,6 +78,12 @@
|
||||
<artifactId>spring-boot-starter-test</artifactId>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>cn.iocoder.mall</groupId>
|
||||
<artifactId>mall-spring-boot-starter-security</artifactId>
|
||||
<version>1.0-SNAPSHOT</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
|
@ -12,12 +12,13 @@ import cn.iocoder.mall.product.application.vo.admins.AdminsProductAttrPageVO;
|
||||
import cn.iocoder.mall.product.application.vo.admins.AdminsProductAttrSimpleVO;
|
||||
import cn.iocoder.mall.product.application.vo.admins.AdminsProductAttrVO;
|
||||
import cn.iocoder.mall.product.application.vo.admins.AdminsProductAttrValueVO;
|
||||
import cn.iocoder.mall.system.sdk.context.AdminSecurityContextHolder;
|
||||
import cn.iocoder.mall.security.core.context.AdminSecurityContextHolder;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.dubbo.config.annotation.Reference;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
@ -10,12 +10,13 @@ import cn.iocoder.mall.product.api.dto.ProductBrandUpdateDTO;
|
||||
import cn.iocoder.mall.product.application.convert.ProductBrandConvert;
|
||||
import cn.iocoder.mall.product.application.vo.admins.AdminsProductBrandVO;
|
||||
import cn.iocoder.mall.product.application.vo.admins.AdminsProductBrangPageVO;
|
||||
import cn.iocoder.mall.system.sdk.context.AdminSecurityContextHolder;
|
||||
import cn.iocoder.mall.security.core.context.AdminSecurityContextHolder;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.dubbo.config.annotation.Reference;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import static cn.iocoder.common.framework.vo.CommonResult.success;
|
||||
|
||||
|
@ -9,12 +9,13 @@ import cn.iocoder.mall.product.api.dto.ProductCategoryUpdateDTO;
|
||||
import cn.iocoder.mall.product.application.convert.ProductCategoryConvert;
|
||||
import cn.iocoder.mall.product.application.vo.admins.AdminsProductCategoryTreeNodeVO;
|
||||
import cn.iocoder.mall.product.application.vo.admins.AdminsProductCategoryVO;
|
||||
import cn.iocoder.mall.system.sdk.context.AdminSecurityContextHolder;
|
||||
import cn.iocoder.mall.security.core.context.AdminSecurityContextHolder;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.dubbo.config.annotation.Reference;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Comparator;
|
||||
|
@ -10,13 +10,14 @@ import cn.iocoder.mall.product.application.convert.ProductSpuConvert;
|
||||
import cn.iocoder.mall.product.application.vo.admins.AdminsProductSpuDetailVO;
|
||||
import cn.iocoder.mall.product.application.vo.admins.AdminsProductSpuPageVO;
|
||||
import cn.iocoder.mall.product.application.vo.admins.AdminsProductSpuVO;
|
||||
import cn.iocoder.mall.system.sdk.context.AdminSecurityContextHolder;
|
||||
import cn.iocoder.mall.security.core.context.AdminSecurityContextHolder;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.dubbo.config.annotation.Reference;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
@ -4,12 +4,12 @@ import cn.iocoder.common.framework.vo.CommonResult;
|
||||
import cn.iocoder.mall.product.api.UserProductSpuCollectionsService;
|
||||
import cn.iocoder.mall.product.api.bo.UserProductSpuCollectionsPageBO;
|
||||
import cn.iocoder.mall.product.api.dto.UserProductSpuCollectionsPageDTO;
|
||||
import cn.iocoder.mall.user.sdk.annotation.RequiresLogin;
|
||||
import cn.iocoder.mall.user.sdk.context.UserSecurityContextHolder;
|
||||
import cn.iocoder.mall.security.core.context.UserSecurityContextHolder;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.dubbo.config.annotation.Reference;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
/**
|
||||
* 用户收藏
|
||||
@ -26,7 +26,6 @@ public class UserFavoriteController {
|
||||
private UserProductSpuCollectionsService userProductSpuCollectionsService;
|
||||
|
||||
@GetMapping("page")
|
||||
@RequiresLogin
|
||||
@ApiOperation("用户商品收藏列表")
|
||||
public CommonResult<UserProductSpuCollectionsPageBO> getUserProductSpuCollectionsPage(
|
||||
@Validated UserProductSpuCollectionsPageDTO userProductSpuCollectionsPageDTO) {
|
||||
@ -36,7 +35,6 @@ public class UserFavoriteController {
|
||||
}
|
||||
|
||||
@DeleteMapping("remove")
|
||||
@RequiresLogin
|
||||
@ApiOperation(value = "用户商品收藏-删除")
|
||||
public CommonResult<Boolean> removeUserFavorite(@RequestParam("spuId") final Integer spuId) {
|
||||
final Integer userId = UserSecurityContextHolder.getContext().getUserId();
|
||||
@ -44,7 +42,6 @@ public class UserFavoriteController {
|
||||
}
|
||||
|
||||
@GetMapping("hasUserFavorite")
|
||||
@RequiresLogin
|
||||
@ApiOperation(value = "用户商品收藏-是否收藏")
|
||||
public CommonResult<Boolean> hasUserSpuFavorite(@RequestParam("spuId") final Integer spuId) {
|
||||
final Integer userId = UserSecurityContextHolder.getContext().getUserId();
|
||||
|
@ -2,8 +2,7 @@ package cn.iocoder.mall.product.application.controller.users;
|
||||
|
||||
import cn.iocoder.common.framework.vo.CommonResult;
|
||||
import cn.iocoder.mall.product.api.ProductSpuCollectionService;
|
||||
import cn.iocoder.mall.user.sdk.annotation.RequiresLogin;
|
||||
import cn.iocoder.mall.user.sdk.context.UserSecurityContextHolder;
|
||||
import cn.iocoder.mall.security.core.context.UserSecurityContextHolder;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.dubbo.config.annotation.Reference;
|
||||
@ -30,7 +29,6 @@ public class UsersProductSpuCollectionController {
|
||||
|
||||
@PostMapping("/collection/{spuId}/{hasCollectionType}")
|
||||
@ApiOperation("商品收藏")
|
||||
@RequiresLogin
|
||||
public CommonResult<Boolean> productSpuCollection(@PathVariable("spuId") Integer spuId,
|
||||
@PathVariable("hasCollectionType") Integer hasCollectionType) {
|
||||
final Integer userId = UserSecurityContextHolder.getContext().getUserId();
|
||||
|
@ -1,9 +1,7 @@
|
||||
package cn.iocoder.mall.system.api;
|
||||
|
||||
import cn.iocoder.mall.system.api.bo.systemlog.AccessLogPageBO;
|
||||
import cn.iocoder.mall.system.api.dto.systemlog.AccessLogAddDTO;
|
||||
import cn.iocoder.mall.system.api.dto.systemlog.AccessLogPageDTO;
|
||||
import cn.iocoder.mall.system.api.dto.systemlog.ExceptionLogAddDTO;
|
||||
|
||||
/**
|
||||
* 系统日志 Service 接口
|
||||
|
@ -13,6 +13,9 @@ public enum UserErrorCodeEnum implements ServiceExceptionUtil.Enumerable {
|
||||
USER_ADDRESS_NOT_EXISTENT(1001004000, "用户地址不存在!"),
|
||||
USER_ADDRESS_IS_DELETED(1001004001, "用户地址已被删除!"),
|
||||
USER_GET_ADDRESS_NOT_EXISTS(1001004002, "获取的地址不存在!"),
|
||||
|
||||
// ========== 用户 ==========
|
||||
USER_NOT_EXISTS(1001004003, "获取的地址不存在!"),
|
||||
;
|
||||
|
||||
private final int code;
|
||||
|
Loading…
Reference in New Issue
Block a user