zhangyuewww 2 jaren geleden
bovenliggende
commit
0eae7a92a1
100 gewijzigde bestanden met toevoegingen van 0 en 10608 verwijderingen
  1. 0 4
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/advertisement/AdminAdvertisementService.java
  2. 0 3
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/advertisement/AdminAdvertisementServiceImpl.java
  3. 0 40
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/appraise/AdminAppraise.java
  4. 0 46
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/appraise/AdminAppraiseImpl.java
  5. 0 61
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICardClassifyInfoService.java
  6. 0 64
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICardExchangeInfoService.java
  7. 0 61
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICardHolderInfoService.java
  8. 0 75
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICardManagementInfoService.java
  9. 0 63
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICardNewsInfoService.java
  10. 0 67
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICertificateManagementInfoService.java
  11. 0 57
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICircleCardInfoService.java
  12. 0 65
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICircleFriendsDetailService.java
  13. 0 67
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICircleFriendsInfoService.java
  14. 0 73
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICircleManagementInfoService.java
  15. 0 67
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICommonUserInfoService.java
  16. 0 69
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/IPersonalHomepageInfoService.java
  17. 0 57
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ISearchRecordsInfoService.java
  18. 0 149
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CardClassifyInfoServiceImpl.java
  19. 0 206
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CardExchangeInfoServiceImpl.java
  20. 0 164
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CardHolderInfoServiceImpl.java
  21. 0 241
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CardManagementInfoServiceImpl.java
  22. 0 181
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CardNewsInfoServiceImpl.java
  23. 0 305
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CertificateManagementInfoServiceImpl.java
  24. 0 132
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CircleCardInfoServiceImpl.java
  25. 0 142
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CircleFriendsDetailServiceImpl.java
  26. 0 148
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CircleFriendsInfoServiceImpl.java
  27. 0 214
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CircleManagementInfoServiceImpl.java
  28. 0 151
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CommonUserInfoServiceImpl.java
  29. 0 157
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/PersonalHomepageInfoServiceImpl.java
  30. 0 138
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/SearchRecordsInfoServiceImpl.java
  31. 0 62
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/category/AdminCategoryService.java
  32. 0 304
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/category/AdminCategoryServiceImpl.java
  33. 0 82
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/coupon/AdminCouponService.java
  34. 0 123
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/coupon/AdminCouponServiceImpl.java
  35. 0 20
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/dashboard/DashboardService.java
  36. 0 86
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/dashboard/DashboardServiceImpl.java
  37. 0 62
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/freight/AdminFreightTemplateService.java
  38. 0 147
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/freight/AdminFreightTemplateServiceImpl.java
  39. 0 64
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/goods/AdminGoodsService.java
  40. 0 414
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/goods/AdminGoodsServiceImpl.java
  41. 0 55
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/goods/AdminGroupShopGoodsService.java
  42. 0 290
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/goods/AdminGroupShopGoodsServiceImpl.java
  43. 0 66
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/IMarketAdvertisementInfoService.java
  44. 0 50
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/IMarketCaseService.java
  45. 0 67
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/IMarketCircleInfoService.java
  46. 0 70
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/IMarketOrderDetailService.java
  47. 0 68
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/IMarketOrderInfoService.java
  48. 0 74
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/IMarketProdectInfoService.java
  49. 0 71
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/IMarketReceivingAddressService.java
  50. 0 74
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/IMarketShopInfoService.java
  51. 0 140
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/impl/MarketAdvertisementInfoServiceImpl.java
  52. 0 96
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/impl/MarketCaseServiceImpl.java
  53. 0 150
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/impl/MarketCircleInfoServiceImpl.java
  54. 0 149
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/impl/MarketOrderDetailServiceImpl.java
  55. 0 146
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/impl/MarketOrderInfoServiceImpl.java
  56. 0 164
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/impl/MarketProdectInfoServiceImpl.java
  57. 0 158
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/impl/MarketReceivingAddressServiceImpl.java
  58. 0 167
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/impl/MarketShopInfoServiceImpl.java
  59. 0 57
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/order/AdminOrderService.java
  60. 0 198
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/order/AdminOrderServiceImpl.java
  61. 0 54
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/recommend/AdminRecommendService.java
  62. 0 99
      unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/recommend/AdminRecommendServiceImpl.java
  63. 0 67
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/address/AddressService.java
  64. 0 142
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/address/AddressServiceImpl.java
  65. 0 51
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/appraise/AppraiseService.java
  66. 0 166
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/appraise/AppraiseServiceImpl.java
  67. 0 61
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/cart/CartService.java
  68. 0 146
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/cart/CartServiceImpl.java
  69. 0 47
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/collect/CollectService.java
  70. 0 96
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/collect/CollectServiceImpl.java
  71. 0 3
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/commonUser/CommonUserService.java
  72. 0 45
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/commonUser/CommonUserServiceImpl.java
  73. 0 34
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/coupon/CouponService.java
  74. 0 157
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/coupon/CouponServiceImpl.java
  75. 0 27
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/freight/FreightTemplateService.java
  76. 0 26
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/freight/FreightTemplateServiceImpl.java
  77. 0 33
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/goods/GoodsService.java
  78. 0 41
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/goods/GoodsServiceImpl.java
  79. 0 30
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/groupshop/GroupShopService.java
  80. 0 36
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/groupshop/GroupShopServiceImpl.java
  81. 0 18
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/integral/IntegralService.java
  82. 0 79
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/integral/IntegralServiceImpl.java
  83. 0 66
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/IMarketAdvertisementInfoAppService.java
  84. 0 49
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/IMarketCaseAppService.java
  85. 0 57
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/IMarketCircleInfoAppService.java
  86. 0 70
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/IMarketOrderDetailAppService.java
  87. 0 68
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/IMarketOrderInfoAppService.java
  88. 0 74
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/IMarketProdectInfoAppService.java
  89. 0 72
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/IMarketReceivingAddressAppService.java
  90. 0 74
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/IMarketShopInfoAppService.java
  91. 0 136
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/MarketAdvertisementInfoAppServiceImpl.java
  92. 0 93
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/MarketCaseAppServiceImpl.java
  93. 0 150
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/MarketCircleInfoAppServiceImpl.java
  94. 0 148
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/MarketOrderDetailAppServiceImpl.java
  95. 0 142
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/MarketOrderInfoAppServiceImpl.java
  96. 0 160
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/MarketProdectInfoAppServiceImpl.java
  97. 0 154
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/MarketReceivingAddressAppServiceImpl.java
  98. 0 150
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/MarketShopInfoAppServiceImpl.java
  99. 0 71
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/order/OrderService.java
  100. 0 475
      unimall-app-api/src/main/java/com/iotechn/unimall/app/api/order/OrderServiceImpl.java

+ 0 - 4
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/advertisement/AdminAdvertisementService.java

@@ -8,12 +8,8 @@ import com.iotechn.unimall.core.annotation.param.NotNull;
 import com.iotechn.unimall.core.annotation.param.Range;
 import com.iotechn.unimall.core.exception.ServiceException;
 import com.iotechn.unimall.data.domain.AdvertisementDO;
-import com.iotechn.unimall.data.dto.RecommendDTO;
-import com.iotechn.unimall.data.enums.StatusType;
 import com.iotechn.unimall.data.model.Page;
 
-import java.util.List;
-
 /**
  * Created with IntelliJ IDEA.
  * Description:

+ 0 - 3
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/advertisement/AdminAdvertisementServiceImpl.java

@@ -7,15 +7,12 @@ import com.iotechn.unimall.core.exception.ExceptionDefinition;
 import com.iotechn.unimall.core.exception.ServiceException;
 import com.iotechn.unimall.data.component.CacheComponent;
 import com.iotechn.unimall.data.domain.AdvertisementDO;
-import com.iotechn.unimall.data.domain.OrderDO;
-import com.iotechn.unimall.data.enums.AdvertisementType;
 import com.iotechn.unimall.data.mapper.AdvertisementMapper;
 import com.iotechn.unimall.data.model.Page;
 import org.apache.ibatis.session.RowBounds;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.StringUtils;
 
 import java.util.Date;
 import java.util.List;

+ 0 - 40
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/appraise/AdminAppraise.java

@@ -1,40 +0,0 @@
-package com.iotechn.unimall.admin.api.appraise;
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.dto.appraise.AppraiseResponseDTO;
-import com.iotechn.unimall.data.model.Page;
-
-/**
- * Created with IntelliJ IDEA.
- * Description:
- * User: kbq
- * Date: 2019-07-15
- * Time: 下午3:41
- */
-@HttpOpenApi(group = "admin.appraise", description = "评论")
-public interface AdminAppraise {
-
-    @HttpMethod(description = "删除", permission = "operation:appraise:delete", permissionParentName = "运营管理", permissionName = "评论管理")
-    public boolean deleteAppraise(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId,
-            @NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "评论id") Long id) throws ServiceException;
-
-
-    @HttpMethod(description = "查询", permission = "operation:appraise:query", permissionParentName = "运营管理", permissionName = "评论管理")
-    public Page<AppraiseResponseDTO> getAppraiseList(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId,
-            @HttpParam(name = "id", type = HttpParamType.COMMON, description = "评论id") Long id,
-            @HttpParam(name = "userName", type = HttpParamType.COMMON, description = "用户姓名") String userName,
-            @HttpParam(name = "spuName", type = HttpParamType.COMMON, description = "商品名字") String spuName,
-            @HttpParam(name = "orderId", type = HttpParamType.COMMON, description = "订单ID") Long orderId,
-            @HttpParam(name = "score", type = HttpParamType.COMMON, description = "评论id") Integer score,
-            @HttpParam(name = "content", type = HttpParamType.COMMON, description = "评论id") String content,
-            @HttpParam(name = "pageNo", type = HttpParamType.COMMON, description = "页码") Integer pageNo,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度") Integer limit) throws ServiceException;
-
-}

+ 0 - 46
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/appraise/AdminAppraiseImpl.java

@@ -1,46 +0,0 @@
-package com.iotechn.unimall.admin.api.appraise;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.dto.appraise.AppraiseResponseDTO;
-import com.iotechn.unimall.data.mapper.AppraiseMapper;
-import com.iotechn.unimall.data.model.Page;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.StringUtils;
-
-import java.util.List;
-
-/**
- * Created with IntelliJ IDEA.
- * Description:
- * User: kbq
- * Date: 2019-07-15
- * Time: 下午3:56
- */
-@Service
-public class AdminAppraiseImpl implements  AdminAppraise {
-
-    @Autowired
-    private AppraiseMapper appraiseMapper;
-
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public boolean deleteAppraise(Long adminId, Long id) throws ServiceException {
-        return appraiseMapper.deleteById(id) > 0;
-    }
-
-    @Override
-    public Page<AppraiseResponseDTO> getAppraiseList(Long adminId, Long id, String userName, String spuName, Long orderId, Integer score, String content,Integer pageNo,Integer limit) throws ServiceException {
-
-        Integer count = appraiseMapper.countAppraiseCondition(id,userName ,spuName , orderId, score, content);
-
-        List<AppraiseResponseDTO> appraiseResponseDTOList = appraiseMapper.selectAppraiseCondition(id,userName ,spuName , orderId, score, content,(pageNo-1)*limit,limit);
-
-        Page<AppraiseResponseDTO> page = new Page<AppraiseResponseDTO>(appraiseResponseDTOList,pageNo,limit,count);
-
-        return page;
-    }
-}

+ 0 - 61
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICardClassifyInfoService.java

@@ -1,61 +0,0 @@
-package com.iotechn.unimall.admin.api.card;
-
-
-import com.iotechn.unimall.data.domain.CardClassifyInfo;
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.CardManagementInfo;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-
-/**
- * 名片分类Service接口
- * 
- * @author jlb
- * @date 2023-04-10
- */
-@HttpOpenApi(group = "admin.unimall.cardClassifyInfo", description = "名片分类")
-public interface ICardClassifyInfoService{
-	@HttpMethod(description = "新增",  permissionName = "名片分类管理")
-	public Boolean add(@NotNull @HttpParam(name = "cardClassifyInfo", type = HttpParamType.COMMON, description = "名片分类") CardClassifyInfo cardClassifyInfo)throws ServiceException;
-
-	@HttpMethod(description = "列表", permissionName = "名片分类管理")
-	public Page<CardClassifyInfo> list(
-								@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "个人id") Long commonId,
-							@HttpParam(name = "circleName", type = HttpParamType.COMMON, description = "分类名称") String circleName,
-							@HttpParam(name = "topMarking", type = HttpParamType.COMMON, description = "置顶标识") Long topMarking,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-					@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-		@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-		throws ServiceException;
-
-	@HttpMethod(description = "删除",  permissionName = "名片分类管理")
-	public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")String id)throws ServiceException;
-
-	@HttpMethod(description = "置顶",  permissionName = "名片分类管理")
-	public Boolean top(@NotNull @HttpParam(name = "cardClassifyInfo", type = HttpParamType.COMMON, description = "名片分类") CardClassifyInfo cardClassifyInfo)throws ServiceException;
-
-	@HttpMethod(description = "修改",  permissionName = "名片分类管理")
-	public Boolean update(@NotNull @HttpParam(name = "cardClassifyInfo", type = HttpParamType.COMMON, description = "名片分类") CardClassifyInfo cardClassifyInfo)throws ServiceException;
-
-	@HttpMethod(description = "查询",  permissionName = "名片分类管理")
-	public CardClassifyInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")Long id)throws ServiceException;
-	
-	@HttpMethod(description = "导出excl表", permissionName = "名片分类管理")
-	public String export(
-								@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "个人id") Long commonId,
-							@HttpParam(name = "circleName", type = HttpParamType.COMMON, description = "分类名称") String circleName,
-							@HttpParam(name = "topMarking", type = HttpParamType.COMMON, description = "置顶标识") Long topMarking,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-				@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-	@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)throws ServiceException;
-	
-}

+ 0 - 64
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICardExchangeInfoService.java

@@ -1,64 +0,0 @@
-package com.iotechn.unimall.admin.api.card;
-
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.CardExchangeInfo;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-
-/**
- * 名片交换Service接口
- * 
- * @author jlb
- * @date 2023-04-12
- */
-@HttpOpenApi(group = "admin.unimall.cardExchangeInfo", description = "名片交换")
-public interface ICardExchangeInfoService{
-	@HttpMethod(description = "新增", permissionName = "名片交换管理")
-	public Boolean add(@NotNull @HttpParam(name = "cardExchangeInfo", type = HttpParamType.COMMON, description = "名片交换") CardExchangeInfo cardExchangeInfo)throws ServiceException;
-
-	@HttpMethod(description = "列表", permissionName = "名片交换管理")
-	public Page<CardExchangeInfo> list(
-								@HttpParam(name = "sendId", type = HttpParamType.COMMON, description = "发起人id") Long sendId,
-							@HttpParam(name = "receiveId", type = HttpParamType.COMMON, description = "接收人id") Long receiveId,
-							@HttpParam(name = "sendCardId", type = HttpParamType.COMMON, description = "发起人名片id") Long sendCardId,
-							@HttpParam(name = "receiveCardId", type = HttpParamType.COMMON, description = "接收人名片id") Long receiveCardId,
-							@HttpParam(name = "circleName", type = HttpParamType.COMMON, description = "圈子名称") String circleName,
-							@HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态(1已接受3已拒绝5已过期)") String status,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-					@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-		@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-		throws ServiceException;
-
-	@HttpMethod(description = "删除", permissionName = "名片交换管理")
-	public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")String id)throws ServiceException;
-
-	@HttpMethod(description = "修改", permissionName = "名片交换管理")
-	public Boolean update(@NotNull @HttpParam(name = "cardExchangeInfo", type = HttpParamType.COMMON, description = "名片交换") CardExchangeInfo cardExchangeInfo,
-						  @HttpParam(name = "updateFlag", type = HttpParamType.COMMON, description = "updateFlag") String updateFlag)throws ServiceException;
-
-	@HttpMethod(description = "查询", permissionName = "名片交换管理")
-	public CardExchangeInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")Long id)throws ServiceException;
-	
-	@HttpMethod(description = "导出excl表", permissionName = "名片交换管理")
-	public String export(
-								@HttpParam(name = "sendId", type = HttpParamType.COMMON, description = "发起人id") Long sendId,
-							@HttpParam(name = "receiveId", type = HttpParamType.COMMON, description = "接收人id") Long receiveId,
-							@HttpParam(name = "sendCardId", type = HttpParamType.COMMON, description = "发起人名片id") Long sendCardId,
-							@HttpParam(name = "receiveCardId", type = HttpParamType.COMMON, description = "接收人名片id") Long receiveCardId,
-							@HttpParam(name = "circleName", type = HttpParamType.COMMON, description = "圈子名称") String circleName,
-							@HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态(1已接受3已拒绝5已过期)") String status,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-				@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-	@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)throws ServiceException;
-	
-}

+ 0 - 61
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICardHolderInfoService.java

@@ -1,61 +0,0 @@
-package com.iotechn.unimall.admin.api.card;
-
-
-import com.iotechn.unimall.data.domain.CardHolderInfo;
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-
-/**
- * 名片夹Service接口
- * 
- * @author jlb
- * @date 2023-04-10
- */
-@HttpOpenApi(group = "admin.unimall.cardHolderInfo", description = "名片夹")
-public interface ICardHolderInfoService{
-	@HttpMethod(description = "新增",  permissionName = "名片夹管理")
-	public Boolean add(@NotNull @HttpParam(name = "cardHolderInfo", type = HttpParamType.COMMON, description = "名片夹") CardHolderInfo cardHolderInfo)throws ServiceException;
-
-	@HttpMethod(description = "列表",  permissionName = "名片夹管理")
-	public Page<CardHolderInfo> list(
-								@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "个人id") Long commonId,
-							@HttpParam(name = "searchContent", type = HttpParamType.COMMON, description = "搜索内容") String searchContent,
-										@HttpParam(name = "classify", type = HttpParamType.COMMON, description = "客户分类") String classify,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-					@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-		@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-		throws ServiceException;
-
-	@HttpMethod(description = "删除", permissionName = "名片夹管理")
-	public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")String id)throws ServiceException;
-
-	@HttpMethod(description = "修改",  permissionName = "名片夹管理")
-	public Boolean update(@NotNull @HttpParam(name = "cardHolderInfo", type = HttpParamType.COMMON, description = "名片夹") CardHolderInfo cardHolderInfo)throws ServiceException;
-
-	@HttpMethod(description = "查询", permissionName = "名片夹管理")
-	public CardHolderInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")Long id)throws ServiceException;
-
-	@HttpMethod(description = "查看是否添加", permissionName = "名片夹管理")
-	public CardHolderInfo getAdded(@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "个人id") Long commonId,
-								   @HttpParam(name = "cardId", type = HttpParamType.COMMON, description = "名片ID") String cardId)throws ServiceException;
-	
-	@HttpMethod(description = "导出excl表", permissionName = "名片夹管理")
-	public String export(
-								@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "个人id") Long commonId,
-							@HttpParam(name = "cardId", type = HttpParamType.COMMON, description = "名片id") String cardId,
-										@HttpParam(name = "classify", type = HttpParamType.COMMON, description = "客户分类") String classify,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-				@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-	@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)throws ServiceException;
-	
-}

+ 0 - 75
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICardManagementInfoService.java

@@ -1,75 +0,0 @@
-package com.iotechn.unimall.admin.api.card;
-
-
-import com.iotechn.unimall.data.domain.CardManagementInfo;
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-
-/**
- * 名片管理Service接口
- * 
- * @author jlb
- * @date 2023-04-10
- */
-@HttpOpenApi(group = "admin.unimall.cardManagementInfo", description = "名片管理")
-public interface ICardManagementInfoService{
-	@HttpMethod(description = "新增",  permissionName = "名片管理管理")
-	public Boolean add(@NotNull @HttpParam(name = "cardManagementInfo", type = HttpParamType.COMMON, description = "名片管理") CardManagementInfo cardManagementInfo)throws ServiceException;
-
-	@HttpMethod(description = "列表",  permissionName = "名片管理管理")
-	public Page<CardManagementInfo> list(
-								@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "个人id") Long commonId,
-							@HttpParam(name = "cardBusiness", type = HttpParamType.COMMON, description = "名片标识") String cardBusiness,
-							@HttpParam(name = "name", type = HttpParamType.COMMON, description = "姓名") String name,
-							@HttpParam(name = "post", type = HttpParamType.COMMON, description = "职务") String post,
-							@HttpParam(name = "companyName", type = HttpParamType.COMMON, description = "公司名") String companyName,
-							@HttpParam(name = "location", type = HttpParamType.COMMON, description = "定位") String location,
-							@HttpParam(name = "detailedAddress", type = HttpParamType.COMMON, description = "详细地址") String detailedAddress,
-							@HttpParam(name = "phone", type = HttpParamType.COMMON, description = "联系电话") String phone,
-							@HttpParam(name = "headSculpture", type = HttpParamType.COMMON, description = "头像") String headSculpture,
-							@HttpParam(name = "qrCode", type = HttpParamType.COMMON, description = "二维码") String qrCode,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-					@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-		@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-		throws ServiceException;
-
-	@HttpMethod(description = "删除",  permissionName = "名片管理管理")
-	public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")String id,
-						@HttpParam(name = "deleteCondition", type = HttpParamType.COMMON, description = "删除条件") String deleteCondition)throws ServiceException;
-
-	@HttpMethod(description = "修改",  permissionName = "名片管理管理")
-	public Boolean update(@NotNull @HttpParam(name = "cardManagementInfo", type = HttpParamType.COMMON, description = "名片管理") CardManagementInfo cardManagementInfo)throws ServiceException;
-
-	@HttpMethod(description = "置顶",  permissionName = "名片管理管理")
-	public Boolean top(@NotNull @HttpParam(name = "cardManagementInfo", type = HttpParamType.COMMON, description = "名片管理") CardManagementInfo cardManagementInfo)throws ServiceException;
-
-	@HttpMethod(description = "查询", permissionName = "名片管理管理")
-	public CardManagementInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")Long id)throws ServiceException;
-	
-	@HttpMethod(description = "导出excl表", permissionName = "名片管理管理")
-	public String export(
-								@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "个人id") Long commonId,
-							@HttpParam(name = "cardBusiness", type = HttpParamType.COMMON, description = "名片标识") String cardBusiness,
-							@HttpParam(name = "name", type = HttpParamType.COMMON, description = "姓名") String name,
-							@HttpParam(name = "post", type = HttpParamType.COMMON, description = "职务") String post,
-							@HttpParam(name = "companyName", type = HttpParamType.COMMON, description = "公司名") String companyName,
-							@HttpParam(name = "location", type = HttpParamType.COMMON, description = "定位") String location,
-							@HttpParam(name = "detailedAddress", type = HttpParamType.COMMON, description = "详细地址") String detailedAddress,
-							@HttpParam(name = "phone", type = HttpParamType.COMMON, description = "联系电话") String phone,
-							@HttpParam(name = "headSculpture", type = HttpParamType.COMMON, description = "头像") String headSculpture,
-							@HttpParam(name = "qrCode", type = HttpParamType.COMMON, description = "二维码") String qrCode,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-				@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-	@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)throws ServiceException;
-	
-}

+ 0 - 63
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICardNewsInfoService.java

@@ -1,63 +0,0 @@
-package com.iotechn.unimall.admin.api.card;
-
-
-import com.iotechn.unimall.data.domain.CardNewsInfo;
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-
-/**
- * 记录消息信息Service接口
- * 
- * @author jlb
- * @date 2023-04-20
- */
-@HttpOpenApi(group = "admin.unimall.cardNewsInfo", description = "记录消息信息")
-public interface ICardNewsInfoService{
-	@HttpMethod(description = "新增", permissionName = "记录消息信息管理")
-	public String add(@NotNull @HttpParam(name = "cardNewsInfo", type = HttpParamType.COMMON, description = "记录消息信息") CardNewsInfo cardNewsInfo)throws ServiceException;
-
-	@HttpMethod(description = "列表", permissionName = "记录消息信息管理")
-	public Page<CardNewsInfo> list(
-								@HttpParam(name = "sendId", type = HttpParamType.COMMON, description = "发送消息用户id") Long sendId,
-							@HttpParam(name = "receiveId", type = HttpParamType.COMMON, description = "接收消息用户id") Long receiveId,
-							@HttpParam(name = "newsTitle", type = HttpParamType.COMMON, description = "消息标题") String newsTitle,
-							@HttpParam(name = "newsContent", type = HttpParamType.COMMON, description = "消息内容") String newsContent,
-							@HttpParam(name = "newsType", type = HttpParamType.COMMON, description = "消息类型") String newsType,
-							@HttpParam(name = "newsFlag", type = HttpParamType.COMMON, description = "已读标识(1已读)") String newsFlag,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-					@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-		@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-		throws ServiceException;
-
-	@HttpMethod(description = "删除",permissionName = "记录消息信息管理")
-	public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")String id)throws ServiceException;
-
-	@HttpMethod(description = "修改", permissionName = "记录消息信息管理")
-	public Boolean update(@NotNull @HttpParam(name = "cardNewsInfo", type = HttpParamType.COMMON, description = "记录消息信息") CardNewsInfo cardNewsInfo)throws ServiceException;
-
-	@HttpMethod(description = "查询",  permissionName = "记录消息信息管理")
-	public CardNewsInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")Long id)throws ServiceException;
-	
-	@HttpMethod(description = "导出excl表",permissionName = "记录消息信息管理")
-	public String export(
-								@HttpParam(name = "sendId", type = HttpParamType.COMMON, description = "发送消息用户id") Long sendId,
-							@HttpParam(name = "receiveId", type = HttpParamType.COMMON, description = "接收消息用户id") Long receiveId,
-							@HttpParam(name = "newsTitle", type = HttpParamType.COMMON, description = "消息标题") String newsTitle,
-							@HttpParam(name = "newsContent", type = HttpParamType.COMMON, description = "消息内容") String newsContent,
-							@HttpParam(name = "newsType", type = HttpParamType.COMMON, description = "消息类型") String newsType,
-							@HttpParam(name = "newsFlag", type = HttpParamType.COMMON, description = "已读标识(1已读)") String newsFlag,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-				@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-	@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)throws ServiceException;
-	
-}

+ 0 - 67
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICertificateManagementInfoService.java

@@ -1,67 +0,0 @@
-package com.iotechn.unimall.admin.api.card;
-
-
-import com.iotechn.unimall.data.domain.CertificateManagementInfo;
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.dto.DistinguishView;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-
-/**
- * 证件管理Service接口
- * 
- * @author jlb
- * @date 2023-04-10
- */
-@HttpOpenApi(group = "admin.unimall.certificateManagementInfo", description = "证件管理")
-public interface ICertificateManagementInfoService{
-	@HttpMethod(description = "新增", permissionName = "证件管理管理")
-	public Boolean add(@NotNull @HttpParam(name = "certificateManagementInfo", type = HttpParamType.COMMON, description = "证件管理") CertificateManagementInfo certificateManagementInfo)throws ServiceException;
-
-	@HttpMethod(description = "列表",  permissionName = "证件管理管理")
-	public Page<CertificateManagementInfo> list(
-								@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "个人id") Long commonId,
-							@HttpParam(name = "certificateName", type = HttpParamType.COMMON, description = "证件名称") String certificateName,
-							@HttpParam(name = "certificateImage", type = HttpParamType.COMMON, description = "证件图") String certificateImage,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-					@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-		@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-		throws ServiceException;
-
-	@HttpMethod(description = "删除", permissionName = "证件管理管理")
-	public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")String id)throws ServiceException;
-
-	@HttpMethod(description = "修改",  permissionName = "证件管理管理")
-	public Boolean update(@NotNull @HttpParam(name = "certificateManagementInfo", type = HttpParamType.COMMON, description = "证件管理") CertificateManagementInfo certificateManagementInfo)throws ServiceException;
-
-	@HttpMethod(description = "查询",  permissionName = "证件管理管理")
-	public CertificateManagementInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")Long id)throws ServiceException;
-
-	@HttpMethod(description = "识别身份证",  permissionName = "证件管理管理")
-	public DistinguishView personShibie(@HttpParam(name = "certificateImage", type = HttpParamType.COMMON, description = "证件图") String certificateImage)throws ServiceException;
-
-	@HttpMethod(description = "识别银行卡",  permissionName = "证件管理管理")
-	public DistinguishView bankShibie(@HttpParam(name = "certificateImage", type = HttpParamType.COMMON, description = "证件图") String certificateImage)throws ServiceException;
-
-	@HttpMethod(description = "语音识别",  permissionName = "证件管理管理")
-	public DistinguishView speechRecognition(@HttpParam(name = "voiceMessage", type = HttpParamType.COMMON, description = "语音") String voiceMessage)throws ServiceException;
-
-	@HttpMethod(description = "导出excl表", permissionName = "证件管理管理")
-	public String export(
-								@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "个人id") Long commonId,
-							@HttpParam(name = "certificateName", type = HttpParamType.COMMON, description = "证件名称") String certificateName,
-							@HttpParam(name = "certificateImage", type = HttpParamType.COMMON, description = "证件图") String certificateImage,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-				@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-	@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)throws ServiceException;
-	
-}

+ 0 - 57
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICircleCardInfoService.java

@@ -1,57 +0,0 @@
-package com.iotechn.unimall.admin.api.card;
-
-
-import com.iotechn.unimall.data.domain.CircleCardInfo;
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-
-/**
- * 圈子个人关系Service接口
- * 
- * @author jlb
- * @date 2023-04-10
- */
-@HttpOpenApi(group = "admin.unimall.circleCardInfo", description = "圈子个人关系")
-public interface ICircleCardInfoService{
-	@HttpMethod(description = "新增",  permissionName = "圈子个人关系管理")
-	public Boolean add(@NotNull @HttpParam(name = "circleCardInfo", type = HttpParamType.COMMON, description = "圈子个人关系") CircleCardInfo circleCardInfo)throws ServiceException;
-
-	@HttpMethod(description = "列表", permissionName = "圈子个人关系管理")
-	public Page<CircleCardInfo> list(
-					@HttpParam(name = "circleId", type = HttpParamType.COMMON, description = "圈子id") Long circleId,
-							@HttpParam(name = "cardId", type = HttpParamType.COMMON, description = "名片id") Long cardId,
-							@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "个人id") Long commonId,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-					@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-		@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-		throws ServiceException;
-
-	@HttpMethod(description = "删除", permissionName = "圈子个人关系管理")
-	public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = " ")String id)throws ServiceException;
-
-	@HttpMethod(description = "修改",  permissionName = "圈子个人关系管理")
-	public Boolean update(@NotNull @HttpParam(name = "circleCardInfo", type = HttpParamType.COMMON, description = "圈子个人关系") CircleCardInfo circleCardInfo)throws ServiceException;
-
-	@HttpMethod(description = "查询",  permissionName = "圈子个人关系管理")
-	public CircleCardInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")Long id)throws ServiceException;
-	
-	@HttpMethod(description = "导出excl表", permissionName = "圈子个人关系管理")
-	public String export(
-					@HttpParam(name = "circleId", type = HttpParamType.COMMON, description = "圈子id") Long circleId,
-							@HttpParam(name = "cardId", type = HttpParamType.COMMON, description = "名片id") Long cardId,
-							@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "个人id") Long commonId,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-				@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-	@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)throws ServiceException;
-	
-}

+ 0 - 65
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICircleFriendsDetailService.java

@@ -1,65 +0,0 @@
-package com.iotechn.unimall.admin.api.card;
-
-
-import com.iotechn.unimall.data.domain.CircleFriendsDetail;
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-
-/**
- * 记录朋友圈互动信息Service接口
- * 
- * @author jlb
- * @date 2023-05-22
- */
-@HttpOpenApi(group = "admin.unimall.circleFriendsDetail", description = "记录朋友圈互动信息")
-public interface ICircleFriendsDetailService{
-	@HttpMethod(description = "新增",  permissionName = "记录朋友圈互动信息管理")
-	public Boolean add(@NotNull @HttpParam(name = "circleFriendsDetail", type = HttpParamType.COMMON, description = "记录朋友圈互动信息") CircleFriendsDetail circleFriendsDetail)throws ServiceException;
-
-	@HttpMethod(description = "列表",  permissionName = "记录朋友圈互动信息管理")
-	public Page<CircleFriendsDetail> list(
-								@HttpParam(name = "circleFriendsId", type = HttpParamType.COMMON, description = "朋友圈id") Long circleFriendsId,
-							@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "发表人id") Long commonId,
-							@HttpParam(name = "head", type = HttpParamType.COMMON, description = "头像") String head,
-							@HttpParam(name = "nickname", type = HttpParamType.COMMON, description = "昵称") String nickname,
-							@HttpParam(name = "commentContent", type = HttpParamType.COMMON, description = "评论内容") String commentContent,
-							@HttpParam(name = "commentId", type = HttpParamType.COMMON, description = "回复的评论id") Long commentId,
-							@HttpParam(name = "interactionFlag", type = HttpParamType.COMMON, description = "标识(1点赞2评论)") String interactionFlag,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-					@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-		@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-		throws ServiceException;
-
-	@HttpMethod(description = "删除",permissionName = "记录朋友圈互动信息管理")
-	public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")String id)throws ServiceException;
-
-	@HttpMethod(description = "修改",  permissionName = "记录朋友圈互动信息管理")
-	public Boolean update(@NotNull @HttpParam(name = "circleFriendsDetail", type = HttpParamType.COMMON, description = "记录朋友圈互动信息") CircleFriendsDetail circleFriendsDetail)throws ServiceException;
-
-	@HttpMethod(description = "查询",  permissionName = "记录朋友圈互动信息管理")
-	public CircleFriendsDetail get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")Long id)throws ServiceException;
-	
-	@HttpMethod(description = "导出excl表", permissionName = "记录朋友圈互动信息管理")
-	public String export(
-								@HttpParam(name = "circleFriendsId", type = HttpParamType.COMMON, description = "朋友圈id") Long circleFriendsId,
-							@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "发表人id") Long commonId,
-							@HttpParam(name = "head", type = HttpParamType.COMMON, description = "头像") String head,
-							@HttpParam(name = "nickname", type = HttpParamType.COMMON, description = "昵称") String nickname,
-							@HttpParam(name = "commentContent", type = HttpParamType.COMMON, description = "评论内容") String commentContent,
-							@HttpParam(name = "commentId", type = HttpParamType.COMMON, description = "回复的评论id") Long commentId,
-							@HttpParam(name = "interactionFlag", type = HttpParamType.COMMON, description = "标识(1点赞2评论)") String interactionFlag,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-				@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-	@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)throws ServiceException;
-	
-}

+ 0 - 67
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICircleFriendsInfoService.java

@@ -1,67 +0,0 @@
-package com.iotechn.unimall.admin.api.card;
-
-
-import com.iotechn.unimall.data.domain.CircleFriendsInfo;
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-
-/**
- * 记录朋友圈信息Service接口
- * 
- * @author jlb
- * @date 2023-05-22
- */
-@HttpOpenApi(group = "admin.unimall.circleFriendsInfo", description = "记录朋友圈信息")
-public interface ICircleFriendsInfoService{
-	@HttpMethod(description = "新增", permissionName = "记录朋友圈信息管理")
-	public Boolean add(@NotNull @HttpParam(name = "circleFriendsInfo", type = HttpParamType.COMMON, description = "记录朋友圈信息") CircleFriendsInfo circleFriendsInfo)throws ServiceException;
-
-	@HttpMethod(description = "列表",  permissionName = "记录朋友圈信息管理")
-	public Page<CircleFriendsInfo> list(
-								@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "朋友圈发布人id") Long commonId,
-							@HttpParam(name = "head", type = HttpParamType.COMMON, description = "头像") String head,
-							@HttpParam(name = "nickname", type = HttpParamType.COMMON, description = "昵称") String nickname,
-							@HttpParam(name = "content", type = HttpParamType.COMMON, description = "朋友圈内容") String content,
-							@HttpParam(name = "image", type = HttpParamType.COMMON, description = "图片") String image,
-							@HttpParam(name = "location", type = HttpParamType.COMMON, description = "位置") String location,
-							@HttpParam(name = "positioning", type = HttpParamType.COMMON, description = "定位") String positioning,
-							@HttpParam(name = "commentFlag", type = HttpParamType.COMMON, description = "允许评论(1允许)") String commentFlag,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-					@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-		@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-		throws ServiceException;
-
-	@HttpMethod(description = "删除",  permissionName = "记录朋友圈信息管理")
-	public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")String id)throws ServiceException;
-
-	@HttpMethod(description = "修改", permissionName = "记录朋友圈信息管理")
-	public Boolean update(@NotNull @HttpParam(name = "circleFriendsInfo", type = HttpParamType.COMMON, description = "记录朋友圈信息") CircleFriendsInfo circleFriendsInfo)throws ServiceException;
-
-	@HttpMethod(description = "查询", permissionName = "记录朋友圈信息管理")
-	public CircleFriendsInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")Long id)throws ServiceException;
-	
-	@HttpMethod(description = "导出excl表",  permissionName = "记录朋友圈信息管理")
-	public String export(
-								@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "朋友圈发布人id") Long commonId,
-							@HttpParam(name = "head", type = HttpParamType.COMMON, description = "头像") String head,
-							@HttpParam(name = "nickname", type = HttpParamType.COMMON, description = "昵称") String nickname,
-							@HttpParam(name = "content", type = HttpParamType.COMMON, description = "朋友圈内容") String content,
-							@HttpParam(name = "image", type = HttpParamType.COMMON, description = "图片") String image,
-							@HttpParam(name = "location", type = HttpParamType.COMMON, description = "位置") String location,
-							@HttpParam(name = "positioning", type = HttpParamType.COMMON, description = "定位") String positioning,
-							@HttpParam(name = "commentFlag", type = HttpParamType.COMMON, description = "允许评论(1允许)") String commentFlag,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-				@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-	@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)throws ServiceException;
-	
-}

+ 0 - 73
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICircleManagementInfoService.java

@@ -1,73 +0,0 @@
-package com.iotechn.unimall.admin.api.card;
-
-
-import com.iotechn.unimall.data.domain.CardManagementInfo;
-import com.iotechn.unimall.data.domain.CircleManagementInfo;
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-
-/**
- * 圈子管理Service接口
- * 
- * @author jlb
- * @date 2023-04-10
- */
-@HttpOpenApi(group = "admin.unimall.circleManagementInfo", description = "圈子管理")
-public interface ICircleManagementInfoService{
-	@HttpMethod(description = "新增",  permissionName = "圈子管理管理")
-	public Boolean add(@NotNull @HttpParam(name = "circleManagementInfo", type = HttpParamType.COMMON, description = "圈子管理") CircleManagementInfo circleManagementInfo)throws ServiceException;
-
-	@HttpMethod(description = "列表",  permissionName = "圈子管理管理")
-	public Page<CircleManagementInfo> list(
-								@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "个人id") Long commonId,
-							@HttpParam(name = "circleName", type = HttpParamType.COMMON, description = "圈子名称") String circleName,
-							@HttpParam(name = "circleLabel", type = HttpParamType.COMMON, description = "圈子标签") String circleLabel,
-							@HttpParam(name = "status", type = HttpParamType.COMMON, description = "0未审核 1已通过") Long status,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-					@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-		@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-		throws ServiceException;
-
-	@HttpMethod(description = "删除",  permissionName = "圈子管理管理")
-	public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")String id)throws ServiceException;
-
-	@HttpMethod(description = "修改",  permissionName = "圈子管理管理")
-	public Boolean update(@NotNull @HttpParam(name = "circleManagementInfo", type = HttpParamType.COMMON, description = "圈子管理") CircleManagementInfo circleManagementInfo)throws ServiceException;
-
-	@HttpMethod(description = "圈子审核",  permissionName = "圈子管理管理")
-	public Boolean handle(@NotNull @HttpParam(name = "circleManagementInfo", type = HttpParamType.COMMON, description = "圈子管理") CircleManagementInfo circleManagementInfo)throws ServiceException;
-
-	@HttpMethod(description = "查询",  permissionName = "圈子管理管理")
-	public CircleManagementInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")Long id,
-									@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "个人id") Long commonId)throws ServiceException;
-
-	@HttpMethod(description = "圈子详情名片列表",  permissionName = "圈子管理管理")
-	public Page<CardManagementInfo> circleCardlist(
-			@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "个人id") Long commonId,
-			@HttpParam(name = "id", type = HttpParamType.COMMON, description = "")Long id,
-			@HttpParam(name = "status", type = HttpParamType.COMMON, description = " 1已交换 2未交换") String status,
-			@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-			@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-			throws ServiceException;
-
-	@HttpMethod(description = "导出excl表",  permissionName = "圈子管理管理")
-	public String export(
-								@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "个人id") Long commonId,
-							@HttpParam(name = "circleName", type = HttpParamType.COMMON, description = "圈子名称") String circleName,
-							@HttpParam(name = "circleLabel", type = HttpParamType.COMMON, description = "圈子标签") String circleLabel,
-							@HttpParam(name = "status", type = HttpParamType.COMMON, description = "0未审核 1已通过") Long status,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-				@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-	@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)throws ServiceException;
-	
-}

+ 0 - 67
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ICommonUserInfoService.java

@@ -1,67 +0,0 @@
-package com.iotechn.unimall.admin.api.card;
-
-
-import com.iotechn.unimall.data.domain.CommonUserInfo;
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-
-/**
- * 用户管理Service接口
- * 
- * @author jlb
- * @date 2023-04-10
- */
-@HttpOpenApi(group = "admin.unimall.commonUserInfo", description = "用户管理")
-public interface ICommonUserInfoService{
-	@HttpMethod(description = "新增",  permissionName = "用户管理管理")
-	public Boolean add(@NotNull @HttpParam(name = "commonUserInfo", type = HttpParamType.COMMON, description = "用户管理") CommonUserInfo commonUserInfo)throws ServiceException;
-
-	@HttpMethod(description = "列表",  permissionName = "用户管理管理")
-	public Page<CommonUserInfo> list(
-								@HttpParam(name = "nickname", type = HttpParamType.COMMON, description = "昵称") String nickname,
-							@HttpParam(name = "password", type = HttpParamType.COMMON, description = "密码") String password,
-							@HttpParam(name = "phone", type = HttpParamType.COMMON, description = "手机号") String phone,
-							@HttpParam(name = "realname", type = HttpParamType.COMMON, description = "真实姓名") String realname,
-							@HttpParam(name = "shareCard", type = HttpParamType.COMMON, description = "允许他人分享名片(1允许)") Long shareCard,
-							@HttpParam(name = "lookPage", type = HttpParamType.COMMON, description = "允许圈子成员查看主页(1允许)") Long lookPage,
-							@HttpParam(name = "autoAccept", type = HttpParamType.COMMON, description = "自动接受邀请(1是)") Long autoAccept,
-							@HttpParam(name = "status", type = HttpParamType.COMMON, description = "0.冻结 1.激活") Long status,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-					@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-		@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-		throws ServiceException;
-
-	@HttpMethod(description = "删除", permissionName = "用户管理管理")
-	public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")String id)throws ServiceException;
-
-	@HttpMethod(description = "修改",  permissionName = "用户管理管理")
-	public Boolean update(@NotNull @HttpParam(name = "commonUserInfo", type = HttpParamType.COMMON, description = "用户管理") CommonUserInfo commonUserInfo)throws ServiceException;
-
-	@HttpMethod(description = "查询", permissionName = "用户管理管理")
-	public CommonUserInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")Long id)throws ServiceException;
-	
-	@HttpMethod(description = "导出excl表",  permissionName = "用户管理管理")
-	public String export(
-								@HttpParam(name = "nickname", type = HttpParamType.COMMON, description = "昵称") String nickname,
-							@HttpParam(name = "password", type = HttpParamType.COMMON, description = "密码") String password,
-							@HttpParam(name = "phone", type = HttpParamType.COMMON, description = "手机号") String phone,
-							@HttpParam(name = "realname", type = HttpParamType.COMMON, description = "真实姓名") String realname,
-							@HttpParam(name = "shareCard", type = HttpParamType.COMMON, description = "允许他人分享名片(1允许)") Long shareCard,
-							@HttpParam(name = "lookPage", type = HttpParamType.COMMON, description = "允许圈子成员查看主页(1允许)") Long lookPage,
-							@HttpParam(name = "autoAccept", type = HttpParamType.COMMON, description = "自动接受邀请(1是)") Long autoAccept,
-							@HttpParam(name = "status", type = HttpParamType.COMMON, description = "0.冻结 1.激活") Long status,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-				@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-	@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)throws ServiceException;
-	
-}

+ 0 - 69
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/IPersonalHomepageInfoService.java

@@ -1,69 +0,0 @@
-package com.iotechn.unimall.admin.api.card;
-
-
-import com.iotechn.unimall.data.domain.PersonalHomepageInfo;
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-
-/**
- * 个人主页Service接口
- * 
- * @author jlb
- * @date 2023-04-10
- */
-@HttpOpenApi(group = "admin.unimall.personalHomepageInfo", description = "个人主页")
-public interface IPersonalHomepageInfoService{
-	@HttpMethod(description = "新增",  permissionName = "个人主页管理")
-	public Boolean add(@NotNull @HttpParam(name = "personalHomepageInfo", type = HttpParamType.COMMON, description = "个人主页") PersonalHomepageInfo personalHomepageInfo)throws ServiceException;
-
-	@HttpMethod(description = "列表",  permissionName = "个人主页管理")
-	public Page<PersonalHomepageInfo> list(
-								@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "个人id") Long commonId,
-							@HttpParam(name = "companyName", type = HttpParamType.COMMON, description = "公司名") String companyName,
-							@HttpParam(name = "companyIntroduction", type = HttpParamType.COMMON, description = "公司简介") String companyIntroduction,
-							@HttpParam(name = "scopeOfBusiness", type = HttpParamType.COMMON, description = "业务范围") String scopeOfBusiness,
-							@HttpParam(name = "companyAddress", type = HttpParamType.COMMON, description = "公司地址") String companyAddress,
-							@HttpParam(name = "phone", type = HttpParamType.COMMON, description = "联系电话") String phone,
-							@HttpParam(name = "portraiture", type = HttpParamType.COMMON, description = "传真") String portraiture,
-							@HttpParam(name = "postbox", type = HttpParamType.COMMON, description = "邮箱") String postbox,
-							@HttpParam(name = "addressUrl", type = HttpParamType.COMMON, description = "企业风采") String addressUrl,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-					@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-		@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-		throws ServiceException;
-
-	@HttpMethod(description = "删除",  permissionName = "个人主页管理")
-	public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")String id)throws ServiceException;
-
-	@HttpMethod(description = "修改", permissionName = "个人主页管理")
-	public Boolean update(@NotNull @HttpParam(name = "personalHomepageInfo", type = HttpParamType.COMMON, description = "个人主页") PersonalHomepageInfo personalHomepageInfo)throws ServiceException;
-
-	@HttpMethod(description = "查询",  permissionName = "个人主页管理")
-	public PersonalHomepageInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")Long id)throws ServiceException;
-	
-	@HttpMethod(description = "导出excl表",  permissionName = "个人主页管理")
-	public String export(
-								@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "个人id") Long commonId,
-							@HttpParam(name = "companyName", type = HttpParamType.COMMON, description = "公司名") String companyName,
-							@HttpParam(name = "companyIntroduction", type = HttpParamType.COMMON, description = "公司简介") String companyIntroduction,
-							@HttpParam(name = "scopeOfBusiness", type = HttpParamType.COMMON, description = "业务范围") String scopeOfBusiness,
-							@HttpParam(name = "companyAddress", type = HttpParamType.COMMON, description = "公司地址") String companyAddress,
-							@HttpParam(name = "phone", type = HttpParamType.COMMON, description = "联系电话") String phone,
-							@HttpParam(name = "portraiture", type = HttpParamType.COMMON, description = "传真") String portraiture,
-							@HttpParam(name = "postbox", type = HttpParamType.COMMON, description = "邮箱") String postbox,
-							@HttpParam(name = "addressUrl", type = HttpParamType.COMMON, description = "企业风采") String addressUrl,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-				@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-	@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)throws ServiceException;
-	
-}

+ 0 - 57
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/ISearchRecordsInfoService.java

@@ -1,57 +0,0 @@
-package com.iotechn.unimall.admin.api.card;
-
-
-import com.iotechn.unimall.data.domain.SearchRecordsInfo;
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-
-/**
- * 搜索记录Service接口
- * 
- * @author searchRecordsInfo
- * @date 2023-04-10
- */
-@HttpOpenApi(group = "admin.unimall.searchRecordsInfo", description = "搜索记录")
-public interface ISearchRecordsInfoService{
-	@HttpMethod(description = "新增", permissionName = "搜索记录管理")
-	public Boolean add(@NotNull @HttpParam(name = "searchRecordsInfo", type = HttpParamType.COMMON, description = "搜索记录") SearchRecordsInfo searchRecordsInfo)throws ServiceException;
-
-	@HttpMethod(description = "列表", permissionName = "搜索记录管理")
-	public Page<SearchRecordsInfo> list(
-								@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "个人id") Long commonId,
-							@HttpParam(name = "searchContent", type = HttpParamType.COMMON, description = "搜索内容") String searchContent,
-							@HttpParam(name = "functionType", type = HttpParamType.COMMON, description = "功能类型") String functionType,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-					@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-		@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-		throws ServiceException;
-
-	@HttpMethod(description = "清空搜索记录",  permissionName = "搜索记录管理")
-	public Boolean delete(@NotNull @HttpParam(name = "searchRecordsInfo", type = HttpParamType.COMMON, description = "搜索记录") SearchRecordsInfo searchRecordsInfo)throws ServiceException;
-
-	@HttpMethod(description = "修改",  permissionName = "搜索记录管理")
-	public Boolean update(@NotNull @HttpParam(name = "searchRecordsInfo", type = HttpParamType.COMMON, description = "搜索记录") SearchRecordsInfo searchRecordsInfo)throws ServiceException;
-
-	@HttpMethod(description = "查询", permissionName = "搜索记录管理")
-	public SearchRecordsInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")Long id)throws ServiceException;
-	
-	@HttpMethod(description = "导出excl表",  permissionName = "搜索记录管理")
-	public String export(
-								@HttpParam(name = "commonId", type = HttpParamType.COMMON, description = "个人id") Long commonId,
-							@HttpParam(name = "searchContent", type = HttpParamType.COMMON, description = "搜索内容") String searchContent,
-							@HttpParam(name = "functionType", type = HttpParamType.COMMON, description = "功能类型") String functionType,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "删除标识") Long deleteFlag,
-				@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-	@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)throws ServiceException;
-	
-}

+ 0 - 149
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CardClassifyInfoServiceImpl.java

@@ -1,149 +0,0 @@
-package com.iotechn.unimall.admin.api.card.impl;
-
-import java.util.List;
-
-import com.iotechn.unimall.core.exception.AdminServiceException;
-import com.iotechn.unimall.core.exception.AppServiceException;
-import com.iotechn.unimall.core.exception.ExceptionDefinition;
-import com.iotechn.unimall.data.domain.CardManagementInfo;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.CollectionUtils;
-import org.springframework.util.StringUtils;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import com.iotechn.unimall.data.mapper.CardClassifyInfoMapper;
-import com.iotechn.unimall.data.domain.CardClassifyInfo;
-import com.iotechn.unimall.admin.api.card.ICardClassifyInfoService;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 名片分类Service业务层处理
- *
- * @author jlb
- * @date 2023-04-10
- */
-@Service
-public class CardClassifyInfoServiceImpl implements ICardClassifyInfoService {
-    @Autowired
-    private CardClassifyInfoMapper cardClassifyInfoMapper;
-
-    @Override
-    public Boolean add(CardClassifyInfo cardClassifyInfo) throws ServiceException {
-        Date now = new Date();
-        cardClassifyInfo.setGmtCreate(now);
-        cardClassifyInfo.setGmtUpdate(now);
-        List<CardClassifyInfo> cardClassifyInfoList = cardClassifyInfoMapper.selectList(new EntityWrapper<CardClassifyInfo>()
-                .eq("common_id", cardClassifyInfo.getCommonId())
-                .eq("delete_flag", 0)
-                .eq("circle_name", cardClassifyInfo.getCircleName()));
-        if (cardClassifyInfoList.size() > 0) {
-            throw new AppServiceException(ExceptionDefinition.CLASSIFY_REPEAT_ERROR);
-        }
-        return cardClassifyInfoMapper.insert(cardClassifyInfo) > 0;
-    }
-
-    @Override
-    public Page<CardClassifyInfo> list(Long commonId, String circleName, Long topMarking, Date gmtCreate, Date gmtUpdate, Long deleteFlag, Integer page, Integer limit) throws ServiceException {
-        Wrapper<CardClassifyInfo> wrapper = new EntityWrapper<CardClassifyInfo>();
-        if (!StringUtils.isEmpty(commonId)) {
-            wrapper.eq("common_id", commonId);
-        }
-        if (!StringUtils.isEmpty(circleName)) {
-            wrapper.eq("circle_name", circleName);
-        }
-        if (!StringUtils.isEmpty(topMarking)) {
-            wrapper.eq("top_marking", topMarking);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        wrapper.eq("delete_flag", 0).orderBy("top_marking", false).orderBy("gmt_create", true);
-        List<CardClassifyInfo> list = cardClassifyInfoMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-        Integer count = cardClassifyInfoMapper.selectCount(wrapper);
-        return new Page<CardClassifyInfo>(list, page, limit, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt : ids) {
-            CardClassifyInfo tmp = cardClassifyInfoMapper.selectById(Long.parseLong(tt));
-            if (tmp != null) {
-                tmp.setDeleteFlag(1l);
-                tmp.setGmtUpdate(new Date());
-                cardClassifyInfoMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean top(CardClassifyInfo cardClassifyInfo) throws ServiceException {
-        CardClassifyInfo cardClassifyInfo1 = cardClassifyInfoMapper.selectById(cardClassifyInfo.getId());
-        List<CardClassifyInfo> cardClassifyInfoList = cardClassifyInfoMapper.selectList(new EntityWrapper<CardClassifyInfo>()
-                .eq("common_id", cardClassifyInfo1.getCommonId())
-                .orderBy("top_marking", false)
-                .eq("delete_flag", 0));
-        Integer sort=0;
-        if (!CollectionUtils.isEmpty(cardClassifyInfoList)) {
-            sort=cardClassifyInfoList.get(0).getTopMarking()+1;
-        }
-        cardClassifyInfo1.setTopMarking(sort);
-        cardClassifyInfo1.setGmtUpdate(new Date());
-        return cardClassifyInfoMapper.updateById(cardClassifyInfo1) > 0;
-    }
-
-    @Override
-    public Boolean update(CardClassifyInfo cardClassifyInfo) throws ServiceException {
-        Date now = new Date();
-        cardClassifyInfo.setGmtUpdate(now);
-        return cardClassifyInfoMapper.updateById(cardClassifyInfo) > 0;
-    }
-
-    @Override
-    public CardClassifyInfo get(Long id) throws ServiceException {
-        return cardClassifyInfoMapper.selectById(id);
-    }
-
-    @Override
-    public String export(Long commonId, String circleName, Long topMarking, Date gmtCreate, Date gmtUpdate, Long deleteFlag, Integer page, Integer limit) throws ServiceException {
-        Wrapper<CardClassifyInfo> wrapper = new EntityWrapper<CardClassifyInfo>();
-        if (!StringUtils.isEmpty(commonId)) {
-            wrapper.eq("common_id", commonId);
-        }
-        if (!StringUtils.isEmpty(circleName)) {
-            wrapper.eq("circle_name", circleName);
-        }
-        if (!StringUtils.isEmpty(topMarking)) {
-            wrapper.eq("top_marking", topMarking);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        List<CardClassifyInfo> list = cardClassifyInfoMapper.selectList(wrapper);
-        ExcelUtil<CardClassifyInfo> util = new ExcelUtil<CardClassifyInfo>(CardClassifyInfo.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 206
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CardExchangeInfoServiceImpl.java

@@ -1,206 +0,0 @@
-package com.iotechn.unimall.admin.api.card.impl;
-
-import java.util.List;
-
-import com.iotechn.unimall.admin.api.card.ICardExchangeInfoService;
-import com.iotechn.unimall.core.exception.AppServiceException;
-import com.iotechn.unimall.core.exception.ExceptionDefinition;
-import com.iotechn.unimall.data.domain.*;
-import com.iotechn.unimall.data.dto.goods.GroupShopDTO;
-import com.iotechn.unimall.data.dto.order.OrderDTO;
-import com.iotechn.unimall.data.mapper.CardExchangeInfoMapper;
-import com.iotechn.unimall.data.mapper.CardHolderInfoMapper;
-import com.iotechn.unimall.data.mapper.CardManagementInfoMapper;
-import com.iotechn.unimall.data.mapper.CommonUserInfoMapper;
-import com.iotechn.unimall.data.model.Page;
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.CollectionUtils;
-import org.springframework.util.StringUtils;
-
-import com.iotechn.unimall.core.exception.ServiceException;
-
-import java.util.Date;
-
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 名片交换Service业务层处理
- *
- * @author jlb
- * @date 2023-04-12
- */
-@Service
-public class CardExchangeInfoServiceImpl implements ICardExchangeInfoService {
-    @Autowired
-    private CardExchangeInfoMapper cardExchangeInfoMapper;
-    @Autowired
-    private CardHolderInfoMapper cardHolderInfoMapper;
-    @Autowired
-    private CardManagementInfoMapper cardManagementInfoMapper;
-    @Autowired
-    private CommonUserInfoMapper commonUserInfoMapper;
-
-    @Override
-    public Boolean add(CardExchangeInfo cardExchangeInfo) throws ServiceException {
-        Date now = new Date();
-        cardExchangeInfo.setGmtCreate(now);
-        cardExchangeInfo.setGmtUpdate(now);
-        CommonUserInfo commonUserInfo=commonUserInfoMapper.selectById(cardExchangeInfo.getReceiveId());
-        //接收人设置自动接受邀请情况
-        if (commonUserInfo!=null&&commonUserInfo.getAutoAccept()==1){
-            cardExchangeInfo.setStatus("1");
-            CardHolderInfo CardHolderInfo1 = new CardHolderInfo();
-            CardHolderInfo1.setCommonId(cardExchangeInfo.getReceiveId());
-            CardHolderInfo1.setCardId(String.valueOf(cardExchangeInfo.getSendCardId()));
-            CardHolderInfo1.setDeleteFlag(0l);
-            CardHolderInfo cardHolderInfo2 = cardHolderInfoMapper.selectOne(CardHolderInfo1);
-            //查看接收人名片夹是否存有该名片
-            if (cardHolderInfo2==null){
-                //接收人名片夹添加数据
-                CardHolderInfo cardHolderInfo = new CardHolderInfo();
-                cardHolderInfo.setCardId(String.valueOf(cardExchangeInfo.getSendCardId()));
-                CardManagementInfo cardManagementInfo = cardManagementInfoMapper.selectById(cardExchangeInfo.getSendCardId());
-                //查看发起人名片是否删除
-                if (cardManagementInfo.getCommonId() == -1) {
-                    throw new AppServiceException(ExceptionDefinition.ACCEPT_CARD_ERROR);
-                }
-                cardHolderInfo.setCommonId(cardExchangeInfo.getReceiveId());
-                cardHolderInfo.setGmtCreate(now);
-                cardHolderInfo.setGmtUpdate(now);
-                cardHolderInfoMapper.insert(cardHolderInfo);
-            }
-            //发起人名片夹添加数据
-            CardHolderInfo cardHolderInfo = new CardHolderInfo();
-            cardHolderInfo.setCardId(String.valueOf(cardExchangeInfo.getReceiveCardId()));
-            cardHolderInfo.setCommonId(cardExchangeInfo.getSendId());
-            cardHolderInfo.setGmtCreate(now);
-            cardHolderInfo.setGmtUpdate(now);
-            cardHolderInfoMapper.insert(cardHolderInfo);
-        }
-        return cardExchangeInfoMapper.insert(cardExchangeInfo) > 0;
-    }
-
-    @Override
-    public Page<CardExchangeInfo> list(Long sendId, Long receiveId, Long sendCardId, Long receiveCardId, String circleName, String status, Date gmtCreate, Date gmtUpdate, Long deleteFlag, Integer page, Integer limit) throws ServiceException {
-        Integer count = cardExchangeInfoMapper.getCardExchangeCount(status,(page - 1) * limit, limit, receiveId);
-        List<CardExchangeInfo> list = cardExchangeInfoMapper.getCardExchangeInfoPage(status,(page - 1) * limit, limit, receiveId);
-        if (!CollectionUtils.isEmpty(list)){
-            for (CardExchangeInfo cardExchangeInfo:list){
-                CardManagementInfo cardManagementInfo = cardManagementInfoMapper.selectById(cardExchangeInfo.getSendCardId());
-                if (cardManagementInfo != null) {
-                    cardExchangeInfo.setCardManagementInfo(cardManagementInfo);
-                }
-            }
-        }
-        return new Page<CardExchangeInfo>(list, page, limit, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt : ids) {
-            CardExchangeInfo tmp = cardExchangeInfoMapper.selectById(Long.parseLong(tt));
-            if (tmp != null) {
-                tmp.setDeleteFlag(1L);
-                cardExchangeInfoMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(CardExchangeInfo cardExchangeInfo, String updateFlag) throws ServiceException {
-        Date now = new Date();
-        cardExchangeInfo.setGmtUpdate(now);
-        //拉黑
-        if ("1".equals(updateFlag)) {
-            cardExchangeInfo.setStatus("7");
-        }
-        //拒绝
-        else if ("2".equals(updateFlag)) {
-            cardExchangeInfo.setStatus("3");
-        }
-        //接受
-        else if ("3".equals(updateFlag)) {
-            cardExchangeInfo.setStatus("1");
-            CardHolderInfo CardHolderInfo1 = new CardHolderInfo();
-            CardHolderInfo1.setCommonId(cardExchangeInfo.getReceiveId());
-            CardHolderInfo1.setCardId(String.valueOf(cardExchangeInfo.getSendCardId()));
-            CardHolderInfo1.setDeleteFlag(0l);
-            CardHolderInfo cardHolderInfo2 = cardHolderInfoMapper.selectOne(CardHolderInfo1);
-            //查看接收人名片夹是否存有该名片
-            if (cardHolderInfo2==null) {
-                //接收人名片夹添加数据
-                CardHolderInfo cardHolderInfo = new CardHolderInfo();
-                cardHolderInfo.setCardId(String.valueOf(cardExchangeInfo.getSendCardId()));
-                CardManagementInfo cardManagementInfo = cardManagementInfoMapper.selectById(cardExchangeInfo.getSendCardId());
-                //查看发起人名片是否删除
-                if (cardManagementInfo.getCommonId() == -1) {
-                    throw new AppServiceException(ExceptionDefinition.ACCEPT_CARD_ERROR);
-                }
-                cardHolderInfo.setCommonId(cardExchangeInfo.getReceiveId());
-                cardHolderInfo.setGmtCreate(now);
-                cardHolderInfo.setGmtUpdate(now);
-                cardHolderInfoMapper.insert(cardHolderInfo);
-            }
-            //发起人名片夹添加数据
-            CardHolderInfo cardHolderInfo = new CardHolderInfo();
-            cardHolderInfo.setCardId(String.valueOf(cardExchangeInfo.getReceiveCardId()));
-            cardHolderInfo.setCommonId(cardExchangeInfo.getSendId());
-            cardHolderInfo.setGmtCreate(now);
-            cardHolderInfo.setGmtUpdate(now);
-            cardHolderInfoMapper.insert(cardHolderInfo);
-        }
-        //移除还原成未交换过
-        else {
-            cardExchangeInfo.setDeleteFlag(1l);
-        }
-        return cardExchangeInfoMapper.updateById(cardExchangeInfo) > 0;
-    }
-
-    @Override
-    public CardExchangeInfo get(Long id) throws ServiceException {
-        return cardExchangeInfoMapper.selectById(id);
-    }
-
-    @Override
-    public String export(Long sendId, Long receiveId, Long sendCardId, Long receiveCardId, String circleName, String status, Date gmtCreate, Date gmtUpdate, Long deleteFlag, Integer page, Integer limit) throws ServiceException {
-        Wrapper<CardExchangeInfo> wrapper = new EntityWrapper<CardExchangeInfo>();
-        if (!StringUtils.isEmpty(sendId)) {
-            wrapper.eq("send_id", sendId);
-        }
-        if (!StringUtils.isEmpty(receiveId)) {
-            wrapper.eq("receive_id", receiveId);
-        }
-        if (!StringUtils.isEmpty(sendCardId)) {
-            wrapper.eq("send_card_id", sendCardId);
-        }
-        if (!StringUtils.isEmpty(receiveCardId)) {
-            wrapper.eq("receive_card_id", receiveCardId);
-        }
-        if (!StringUtils.isEmpty(circleName)) {
-            wrapper.eq("circle_name", circleName);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        List<CardExchangeInfo> list = cardExchangeInfoMapper.selectList(wrapper);
-        ExcelUtil<CardExchangeInfo> util = new ExcelUtil<CardExchangeInfo>(CardExchangeInfo.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 164
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CardHolderInfoServiceImpl.java

@@ -1,164 +0,0 @@
-package com.iotechn.unimall.admin.api.card.impl;
-
-import java.util.List;
-
-import com.iotechn.unimall.core.exception.AppServiceException;
-import com.iotechn.unimall.core.exception.ExceptionDefinition;
-import com.iotechn.unimall.data.domain.*;
-import com.iotechn.unimall.data.mapper.CardExchangeInfoMapper;
-import com.iotechn.unimall.data.mapper.CardManagementInfoMapper;
-import com.iotechn.unimall.data.mapper.CommonUserInfoMapper;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.CollectionUtils;
-import org.springframework.util.StringUtils;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import com.iotechn.unimall.data.mapper.CardHolderInfoMapper;
-import com.iotechn.unimall.admin.api.card.ICardHolderInfoService;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 名片夹Service业务层处理
- *
- * @author jlb
- * @date 2023-04-10
- */
-@Service
-public class CardHolderInfoServiceImpl implements ICardHolderInfoService {
-    @Autowired
-    private CardHolderInfoMapper cardHolderInfoMapper;
-    @Autowired
-    private CardManagementInfoMapper cardManagementInfoMapper;
-    @Autowired
-    private CommonUserInfoMapper commonUserInfoMapper;
-    @Autowired
-    private CardExchangeInfoMapper cardExchangeInfoMapper;
-
-    @Override
-    public Boolean add(CardHolderInfo cardHolderInfo) throws ServiceException {
-        Date now = new Date();
-        cardHolderInfo.setGmtCreate(now);
-        cardHolderInfo.setGmtUpdate(now);
-        //对方个人展示的二维码并且当前账号有名片情况 在对方名片夹添加我的名片 实现相互交换
-        if (cardHolderInfo.getCardCommonId() != null&&cardHolderInfo.getMyCardId()!=null) {
-            CardHolderInfo cardHolderInfo1 = new CardHolderInfo();
-            cardHolderInfo1.setCardId(cardHolderInfo.getMyCardId());
-            cardHolderInfo1.setCommonId(cardHolderInfo.getCardCommonId());
-            cardHolderInfo1.setGmtCreate(now);
-            cardHolderInfo1.setGmtUpdate(now);
-            cardHolderInfoMapper.insert(cardHolderInfo1);
-        }
-        return cardHolderInfoMapper.insert(cardHolderInfo) > 0;
-    }
-
-    @Override
-    public Page<CardHolderInfo> list(Long commonId, String searchContent, String classify, Date gmtCreate, Date gmtUpdate, Long deleteFlag, Integer page, Integer limit) throws ServiceException {
-        List<CardHolderInfo> list = cardHolderInfoMapper.getCardHolderInfoPage(searchContent,classify,(page - 1) * limit, limit, commonId);
-        Integer count = cardHolderInfoMapper.getCardHolderCount(searchContent,classify,(page - 1) * limit, limit, commonId);
-        return new Page<CardHolderInfo>(list, page, limit, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt : ids) {
-            CardHolderInfo tmp = cardHolderInfoMapper.selectById(Long.parseLong(tt));
-            if (tmp != null) {
-                CardExchangeInfo cardExchangeInfo = new CardExchangeInfo();
-                //发送人删除名片夹内名片
-                cardExchangeInfo.setSendId(tmp.getCommonId());
-                cardExchangeInfo.setReceiveCardId(Long.parseLong(tmp.getCardId()));
-                cardExchangeInfo.setDeleteFlag(0l);
-                CardExchangeInfo cardExchangeInfo1=cardExchangeInfoMapper.selectOne(cardExchangeInfo);
-                //删除交换记录,可以重新交换
-                if (cardExchangeInfo1!=null){
-                    cardExchangeInfo1.setDeleteFlag(1l);
-                    cardExchangeInfo1.setGmtUpdate(new Date());
-                    cardExchangeInfoMapper.updateById(cardExchangeInfo1);
-                }
-                //接收人删除名片夹内名片
-                cardExchangeInfo.setReceiveId(tmp.getCommonId());
-                cardExchangeInfo.setSendCardId(Long.parseLong(tmp.getCardId()));
-                cardExchangeInfo.setDeleteFlag(0l);
-                CardExchangeInfo cardExchangeInfo2=cardExchangeInfoMapper.selectOne(cardExchangeInfo);
-                //删除交换记录,可以重新交换
-                if (cardExchangeInfo2!=null){
-                    cardExchangeInfo2.setDeleteFlag(1l);
-                    cardExchangeInfo2.setGmtUpdate(new Date());
-                    cardExchangeInfoMapper.updateById(cardExchangeInfo2);
-                }
-                tmp.setDeleteFlag(1l);
-                tmp.setGmtUpdate(new Date());
-                cardHolderInfoMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(CardHolderInfo cardHolderInfo) throws ServiceException {
-        Date now = new Date();
-        cardHolderInfo.setGmtUpdate(now);
-        return cardHolderInfoMapper.updateById(cardHolderInfo) > 0;
-    }
-
-    @Override
-    public CardHolderInfo get(Long id) throws ServiceException {
-        return cardHolderInfoMapper.selectById(id);
-    }
-
-    @Override
-    public CardHolderInfo getAdded(Long commonId, String cardId) throws ServiceException {
-        CardHolderInfo CardHolderInfo1 = new CardHolderInfo();
-        CardHolderInfo1.setCommonId(commonId);
-        CardHolderInfo1.setCardId(cardId);
-        CardHolderInfo1.setDeleteFlag(0l);
-        CardHolderInfo cardHolderInfo = cardHolderInfoMapper.selectOne(CardHolderInfo1);
-        //查看名片夹是否存有该名片
-        if (cardHolderInfo!=null){
-            throw new AppServiceException(ExceptionDefinition.ALREADY_ADDED_ERROR);
-        }
-        CardManagementInfo cardManagementInfo=cardManagementInfoMapper.selectById(cardId);
-        //查询名片所属id
-        if (commonId.equals(cardManagementInfo.getCommonId())){
-            throw new AppServiceException(ExceptionDefinition.ADD_ONESELF_ERROR);
-        }
-        return null;
-    }
-
-    @Override
-    public String export(Long commonId, String cardId, String classify, Date gmtCreate, Date gmtUpdate, Long deleteFlag, Integer page, Integer limit) throws ServiceException {
-        Wrapper<CardHolderInfo> wrapper = new EntityWrapper<CardHolderInfo>();
-        if (!StringUtils.isEmpty(commonId)) {
-            wrapper.eq("common_id", commonId);
-        }
-        if (!StringUtils.isEmpty(cardId)) {
-            wrapper.eq("card_id", cardId);
-        }
-        if (!StringUtils.isEmpty(classify)) {
-            wrapper.eq("classify", classify);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        List<CardHolderInfo> list = cardHolderInfoMapper.selectList(wrapper);
-        ExcelUtil<CardHolderInfo> util = new ExcelUtil<CardHolderInfo>(CardHolderInfo.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 241
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CardManagementInfoServiceImpl.java

@@ -1,241 +0,0 @@
-package com.iotechn.unimall.admin.api.card.impl;
-
-import java.util.List;
-
-import com.iotechn.unimall.core.util.GeneratorUtil;
-import com.iotechn.unimall.data.mapper.*;
-import com.iotechn.unimall.data.util.QRCodeUtil;
-import com.iotechn.unimall.data.domain.*;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.CollectionUtils;
-import org.springframework.util.StringUtils;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import com.iotechn.unimall.admin.api.card.ICardManagementInfoService;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 名片管理Service业务层处理
- *
- * @author jlb
- * @date 2023-04-10
- */
-@Service
-public class CardManagementInfoServiceImpl implements ICardManagementInfoService {
-    @Autowired
-    private CardManagementInfoMapper cardManagementInfoMapper;
-    @Autowired
-    private QRCodeUtil qrCodeUtil;
-    @Autowired
-    private CircleCardInfoMapper circleCardInfoMapper;
-    @Autowired
-    private CardHolderInfoMapper cardHolderInfoMapper;
-    @Autowired
-    private PersonalHomepageInfoMapper personalHomepageInfoMapper;
-    @Autowired
-    private CommonUserInfoMapper commonUserInfoMapper;
-
-    @Override
-    public Boolean add(CardManagementInfo cardManagementInfo) throws ServiceException {
-        Date now = new Date();
-        cardManagementInfo.setGmtCreate(now);
-        cardManagementInfo.setGmtUpdate(now);
-        cardManagementInfoMapper.insert(cardManagementInfo);
-        //更新数据库默认值
-        cardManagementInfo = cardManagementInfoMapper.selectById(cardManagementInfo.getId());
-        //二维码
-        String str = qrCodeUtil.getQRCodeImage("http://liangxin.zthymaoyi.com/id="+cardManagementInfo.getId(), false, cardManagementInfo.getName(), GeneratorUtil.genUUId());
-        String str1 = qrCodeUtil.getQRCodeImage("http://liangxin.zthymaoyi.com/id="+cardManagementInfo.getId() + "," + cardManagementInfo.getCommonId(), false, cardManagementInfo.getName(), GeneratorUtil.genUUId());
-        cardManagementInfo.setQrCode(str);
-        cardManagementInfo.setQrCodeMyself(str1);
-        return cardManagementInfoMapper.updateById(cardManagementInfo) > 0;
-    }
-
-    @Override
-    public Page<CardManagementInfo> list(Long commonId, String cardBusiness, String name, String post, String companyName, String location, String detailedAddress, String phone, String headSculpture, String qrCode, Date gmtCreate, Date gmtUpdate, Long deleteFlag, Integer page, Integer limit) throws ServiceException {
-        Wrapper<CardManagementInfo> wrapper = new EntityWrapper<CardManagementInfo>();
-        if (!StringUtils.isEmpty(commonId)) {
-            wrapper.eq("common_id", commonId);
-        }
-        if (!StringUtils.isEmpty(cardBusiness)) {
-            wrapper.eq("card_business", cardBusiness);
-        }
-        if (!StringUtils.isEmpty(name)) {
-            wrapper.eq("name", name);
-        }
-        if (!StringUtils.isEmpty(post)) {
-            wrapper.eq("post", post);
-        }
-        if (!StringUtils.isEmpty(companyName)) {
-            wrapper.eq("company_name", companyName);
-        }
-        if (!StringUtils.isEmpty(location)) {
-            wrapper.eq("location", location);
-        }
-        if (!StringUtils.isEmpty(detailedAddress)) {
-            wrapper.eq("detailed_address", detailedAddress);
-        }
-        if (!StringUtils.isEmpty(phone)) {
-            wrapper.eq("phone", phone);
-        }
-        if (!StringUtils.isEmpty(headSculpture)) {
-            wrapper.eq("head_sculpture", headSculpture);
-        }
-        if (!StringUtils.isEmpty(qrCode)) {
-            wrapper.eq("qr_code", qrCode);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        wrapper.eq("delete_flag", 0).orderBy("top_marking", false);
-        List<CardManagementInfo> list = cardManagementInfoMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-        if (!CollectionUtils.isEmpty(list)) {
-            for (CardManagementInfo cardManagementInfo : list) {
-                PersonalHomepageInfo personalHomepageInfo = new PersonalHomepageInfo();
-                personalHomepageInfo.setCommonId(cardManagementInfo.getCommonId());
-                personalHomepageInfo.setDeleteFlag(0l);
-                PersonalHomepageInfo personalHomepageInfo1 = personalHomepageInfoMapper.selectOne(personalHomepageInfo);
-                if (personalHomepageInfo1 != null) {
-                    cardManagementInfo.setPersonalHomeId(personalHomepageInfo1.getId());
-                }
-                CommonUserInfo commonUserInfo=commonUserInfoMapper.selectById(cardManagementInfo.getCommonId());
-                if (commonUserInfo!=null){
-                    cardManagementInfo.setNickname(commonUserInfo.getNickname());
-                    cardManagementInfo.setAccount(commonUserInfo.getPhone());
-                }
-            }
-        }
-        Integer count = cardManagementInfoMapper.selectCount(wrapper);
-        return new Page<CardManagementInfo>(list, page, limit, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id, String deleteCondition) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt : ids) {
-            CardManagementInfo tmp = cardManagementInfoMapper.selectById(Long.parseLong(tt));
-            if (tmp != null) {
-                //退出关联的圈子
-                List<CircleCardInfo> list = circleCardInfoMapper.selectList(new EntityWrapper<CircleCardInfo>()
-                        .eq("card_id", tmp.getId())
-                        .eq("delete_flag", 0));
-                if (!CollectionUtils.isEmpty(list)) {
-                    for (CircleCardInfo aa : list) {
-                        aa.setDeleteFlag(1l);
-                        aa.setGmtUpdate(new Date());
-                        circleCardInfoMapper.updateById(aa);
-                    }
-                }
-                //从所有拥有此名片用户列表删除
-                if ("1".equals(deleteCondition)) {
-                    List<CardHolderInfo> cardHolderInfoList = cardHolderInfoMapper.selectList(new EntityWrapper<CardHolderInfo>()
-                            .eq("card_id", tmp.getId())
-                            .eq("delete_flag", 0));
-                    if (!CollectionUtils.isEmpty(cardHolderInfoList)) {
-                        for (CardHolderInfo aa : cardHolderInfoList) {
-                            aa.setDeleteFlag(1l);
-                            aa.setGmtUpdate(new Date());
-                            cardHolderInfoMapper.updateById(aa);
-                        }
-                    }
-                }
-                tmp.setCommonId(-1l);
-                tmp.setGmtUpdate(new Date());
-                cardManagementInfoMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(CardManagementInfo cardManagementInfo) throws ServiceException {
-        Date now = new Date();
-        cardManagementInfo.setGmtUpdate(now);
-        return cardManagementInfoMapper.updateById(cardManagementInfo) > 0;
-    }
-
-    @Override
-    public Boolean top(CardManagementInfo cardManagementInfo) throws ServiceException {
-        CardManagementInfo cardManagementInfo1 = cardManagementInfoMapper.selectById(cardManagementInfo.getId());
-        List<CardManagementInfo> cardManagementInfoList = cardManagementInfoMapper.selectList(new EntityWrapper<CardManagementInfo>()
-                .eq("common_id", cardManagementInfo1.getCommonId())
-                .eq("delete_flag", 0));
-        if (!CollectionUtils.isEmpty(cardManagementInfoList)) {
-            for (CardManagementInfo aa : cardManagementInfoList) {
-                aa.setTopMarking(0l);
-                cardManagementInfoMapper.updateById(aa);
-            }
-        }
-        cardManagementInfo1.setTopMarking(1l);
-        cardManagementInfo1.setGmtUpdate(new Date());
-        return cardManagementInfoMapper.updateById(cardManagementInfo1) > 0;
-    }
-
-    @Override
-    public CardManagementInfo get(Long id) throws ServiceException {
-        return cardManagementInfoMapper.selectById(id);
-    }
-
-    @Override
-    public String export(Long commonId, String cardBusiness, String name, String post, String companyName, String location, String detailedAddress, String phone, String headSculpture, String qrCode, Date gmtCreate, Date gmtUpdate, Long deleteFlag, Integer page, Integer limit) throws ServiceException {
-        Wrapper<CardManagementInfo> wrapper = new EntityWrapper<CardManagementInfo>();
-        if (!StringUtils.isEmpty(commonId)) {
-            wrapper.eq("common_id", commonId);
-        }
-        if (!StringUtils.isEmpty(cardBusiness)) {
-            wrapper.eq("card_business", cardBusiness);
-        }
-        if (!StringUtils.isEmpty(name)) {
-            wrapper.eq("name", name);
-        }
-        if (!StringUtils.isEmpty(post)) {
-            wrapper.eq("post", post);
-        }
-        if (!StringUtils.isEmpty(companyName)) {
-            wrapper.eq("company_name", companyName);
-        }
-        if (!StringUtils.isEmpty(location)) {
-            wrapper.eq("location", location);
-        }
-        if (!StringUtils.isEmpty(detailedAddress)) {
-            wrapper.eq("detailed_address", detailedAddress);
-        }
-        if (!StringUtils.isEmpty(phone)) {
-            wrapper.eq("phone", phone);
-        }
-        if (!StringUtils.isEmpty(headSculpture)) {
-            wrapper.eq("head_sculpture", headSculpture);
-        }
-        if (!StringUtils.isEmpty(qrCode)) {
-            wrapper.eq("qr_code", qrCode);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        List<CardManagementInfo> list = cardManagementInfoMapper.selectList(wrapper);
-        ExcelUtil<CardManagementInfo> util = new ExcelUtil<CardManagementInfo>(CardManagementInfo.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 181
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CardNewsInfoServiceImpl.java

@@ -1,181 +0,0 @@
-package com.iotechn.unimall.admin.api.card.impl;
-
-import java.util.List;
-
-import com.iotechn.unimall.admin.api.card.ICardNewsInfoService;
-import com.iotechn.unimall.data.domain.CardNewsInfo;
-import com.iotechn.unimall.data.domain.CommonUserInfo;
-import com.iotechn.unimall.data.mapper.CardNewsInfoMapper;
-import com.iotechn.unimall.data.mapper.CommonUserInfoMapper;
-import org.apache.commons.collections.CollectionUtils;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.StringUtils;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 记录消息信息Service业务层处理
- * 
- * @author jlb
- * @date 2023-04-20
- */
-@Service
-public class CardNewsInfoServiceImpl implements ICardNewsInfoService {
-	@Autowired
-	private CardNewsInfoMapper cardNewsInfoMapper;
-	@Autowired
-	private CommonUserInfoMapper commonUserInfoMapper;
-	
-	@Override
-	public String add(CardNewsInfo cardNewsInfo) throws ServiceException {
-		Date now = new Date();
-		//全部发送
-		if (cardNewsInfo.getAllFlag()!=null){
-			List<CommonUserInfo> commonUserInfoList=commonUserInfoMapper.selectList(new EntityWrapper<CommonUserInfo>()
-			.eq("delete_flag","0"));
-			if (CollectionUtils.isNotEmpty(commonUserInfoList)) {
-				for (CommonUserInfo commonUserInfo : commonUserInfoList) {
-					cardNewsInfo.setNewsTitle(cardNewsInfo.getNewsTitle());
-					cardNewsInfo.setNewsContent(cardNewsInfo.getNewsContent());
-					cardNewsInfo.setReceiveId(commonUserInfo.getId());
-					cardNewsInfo.setGmtCreate(now);
-					cardNewsInfo.setGmtUpdate(now);
-					cardNewsInfoMapper.insert(cardNewsInfo);
-//				//个推
-//				geTuiUtils.initGeTui(cardNewsInfo1.getReceiveId());
-//				geTuiUtils.pushByCid(cardNewsInfo1.getNewsTitle(),cardNewsInfo1.getNewsContent(),cardNewsInfo1.getReceiveId());
-				}
-			}
-		}
-		//选择发送
-		else {
-			List<CardNewsInfo> cardNewsInfoList = cardNewsInfo.getCardNewsInfoList();
-			if (CollectionUtils.isNotEmpty(cardNewsInfoList)) {
-				for (CardNewsInfo cardNewsInfo1 : cardNewsInfoList) {
-					cardNewsInfo1.setNewsTitle(cardNewsInfo.getNewsTitle());
-					cardNewsInfo1.setNewsContent(cardNewsInfo.getNewsContent());
-					cardNewsInfo1.setGmtCreate(now);
-					cardNewsInfo1.setGmtUpdate(now);
-					cardNewsInfoMapper.insert(cardNewsInfo1);
-//				//个推
-//				geTuiUtils.initGeTui(cardNewsInfo1.getReceiveId());
-//				geTuiUtils.pushByCid(cardNewsInfo1.getNewsTitle(),cardNewsInfo1.getNewsContent(),cardNewsInfo1.getReceiveId());
-				}
-			}
-		}
-		return "ok";
-	}
-
-	@Override
-	public Page<CardNewsInfo> list(Long sendId,Long receiveId,String newsTitle,String newsContent,String newsType,String newsFlag,Date gmtCreate,Date gmtUpdate,Long deleteFlag, Integer page, Integer limit)throws ServiceException {
-		Wrapper<CardNewsInfo> wrapper = new EntityWrapper<CardNewsInfo>();
-														if (!StringUtils.isEmpty(sendId)) {
-					wrapper.eq("send_id", sendId);
-				}
-												if (!StringUtils.isEmpty(receiveId)) {
-					wrapper.eq("receive_id", receiveId);
-				}
-												if (!StringUtils.isEmpty(newsTitle)) {
-					wrapper.eq("news_title", newsTitle);
-				}
-												if (!StringUtils.isEmpty(newsContent)) {
-					wrapper.eq("news_content", newsContent);
-				}
-												if (!StringUtils.isEmpty(newsType)) {
-					wrapper.eq("news_type", newsType);
-				}
-												if (!StringUtils.isEmpty(newsFlag)) {
-					wrapper.eq("news_flag", newsFlag);
-				}
-												if (!StringUtils.isEmpty(gmtCreate)) {
-					wrapper.eq("gmt_create", gmtCreate);
-				}
-												if (!StringUtils.isEmpty(gmtUpdate)) {
-					wrapper.eq("gmt_update", gmtUpdate);
-				}
-												if (!StringUtils.isEmpty(deleteFlag)) {
-					wrapper.eq("delete_flag", deleteFlag);
-				}
-							wrapper.eq("delete_flag", 0).orderBy("gmt_update",false);
-		List<CardNewsInfo> list = cardNewsInfoMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-		if (CollectionUtils.isNotEmpty(list)){
-			for (CardNewsInfo cardNewsInfo:list){
-				CommonUserInfo commonUserInfo=commonUserInfoMapper.selectById(cardNewsInfo.getReceiveId());
-				if (commonUserInfo!=null){
-					cardNewsInfo.setReceiveName(commonUserInfo.getNickname());
-				}
-			}
-		}
-		Integer count = cardNewsInfoMapper.selectCount(wrapper);
-		return new Page<CardNewsInfo>(list, page, limit, count);
-	}
-
-	@Override
-	@Transactional(rollbackFor = Exception.class)
-	public Boolean delete(String id) {
-		String[] ids = String.valueOf(id).split(",");
-		for (String tt:ids) {
-			CardNewsInfo tmp =  cardNewsInfoMapper.selectById(Long.parseLong(tt));
-			if(tmp != null){
-				tmp.setDeleteFlag(1l);
-				cardNewsInfoMapper.updateById(tmp);
-			}
-		}
-		return true;
-	}
-
-	@Override
-	public Boolean update(CardNewsInfo cardNewsInfo) throws ServiceException {
-		Date now = new Date();
-		cardNewsInfo.setGmtUpdate(now);
-		return cardNewsInfoMapper.updateById(cardNewsInfo)>0;
-	}
-
-	@Override
-	public CardNewsInfo get(Long id) throws ServiceException {
-		return cardNewsInfoMapper.selectById(id);
-	}
-	
-	@Override
-	public String export(Long sendId,Long receiveId,String newsTitle,String newsContent,String newsType,String newsFlag,Date gmtCreate,Date gmtUpdate,Long deleteFlag, Integer page, Integer limit)throws ServiceException {
-		Wrapper<CardNewsInfo> wrapper = new EntityWrapper<CardNewsInfo>();
-														if (!StringUtils.isEmpty(sendId)) {
-					wrapper.eq("send_id", sendId);
-				}
-												if (!StringUtils.isEmpty(receiveId)) {
-					wrapper.eq("receive_id", receiveId);
-				}
-												if (!StringUtils.isEmpty(newsTitle)) {
-					wrapper.eq("news_title", newsTitle);
-				}
-												if (!StringUtils.isEmpty(newsContent)) {
-					wrapper.eq("news_content", newsContent);
-				}
-												if (!StringUtils.isEmpty(newsType)) {
-					wrapper.eq("news_type", newsType);
-				}
-												if (!StringUtils.isEmpty(newsFlag)) {
-					wrapper.eq("news_flag", newsFlag);
-				}
-												if (!StringUtils.isEmpty(gmtCreate)) {
-					wrapper.eq("gmt_create", gmtCreate);
-				}
-												if (!StringUtils.isEmpty(gmtUpdate)) {
-					wrapper.eq("gmt_update", gmtUpdate);
-				}
-												if (!StringUtils.isEmpty(deleteFlag)) {
-					wrapper.eq("delete_flag", deleteFlag);
-				}
-							List<CardNewsInfo> list = cardNewsInfoMapper.selectList(wrapper);
-		ExcelUtil<CardNewsInfo> util = new ExcelUtil<CardNewsInfo>(CardNewsInfo.class);
-		return util.exportExcel(list, "操作日志");
-	}
-}

+ 0 - 305
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CertificateManagementInfoServiceImpl.java

@@ -1,305 +0,0 @@
-package com.iotechn.unimall.admin.api.card.impl;
-
-import java.util.*;
-
-import com.alibaba.fastjson.JSONArray;
-import com.alibaba.fastjson.JSONObject;
-import com.iotechn.unimall.data.dto.DistinguishView;
-import com.iotechn.unimall.data.util.HttpUtils;
-import org.apache.http.HttpEntity;
-import org.apache.http.HttpResponse;
-import org.apache.http.NameValuePair;
-import org.apache.http.client.entity.UrlEncodedFormEntity;
-import org.apache.http.client.methods.HttpPost;
-import org.apache.http.impl.client.CloseableHttpClient;
-import org.apache.http.impl.client.HttpClients;
-import org.apache.http.message.BasicNameValuePair;
-import org.apache.http.util.EntityUtils;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.StringUtils;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import com.iotechn.unimall.data.mapper.CertificateManagementInfoMapper;
-import com.iotechn.unimall.data.domain.CertificateManagementInfo;
-import com.iotechn.unimall.admin.api.card.ICertificateManagementInfoService;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 证件管理Service业务层处理
- *
- * @author jlb
- * @date 2023-04-10
- */
-@Service
-public class CertificateManagementInfoServiceImpl implements ICertificateManagementInfoService {
-	@Autowired
-	private CertificateManagementInfoMapper certificateManagementInfoMapper;
-
-	@Override
-	public Boolean add(CertificateManagementInfo certificateManagementInfo) throws ServiceException {
-		Date now = new Date();
-		certificateManagementInfo.setGmtCreate(now);
-		certificateManagementInfo.setGmtUpdate(now);
-		return certificateManagementInfoMapper.insert(certificateManagementInfo) > 0;
-	}
-
-	@Override
-	public Page<CertificateManagementInfo> list(Long commonId, String certificateName, String certificateImage, Date gmtCreate, Date gmtUpdate, Long deleteFlag, Integer page, Integer limit) throws ServiceException {
-		Wrapper<CertificateManagementInfo> wrapper = new EntityWrapper<CertificateManagementInfo>();
-		if (!StringUtils.isEmpty(commonId)) {
-			wrapper.eq("common_id", commonId);
-		}
-		if (!StringUtils.isEmpty(certificateName)) {
-			wrapper.eq("certificate_name", certificateName);
-		}
-		if (!StringUtils.isEmpty(certificateImage)) {
-			wrapper.eq("certificate_image", certificateImage);
-		}
-		if (!StringUtils.isEmpty(gmtCreate)) {
-			wrapper.eq("gmt_create", gmtCreate);
-		}
-		if (!StringUtils.isEmpty(gmtUpdate)) {
-			wrapper.eq("gmt_update", gmtUpdate);
-		}
-		if (!StringUtils.isEmpty(deleteFlag)) {
-			wrapper.eq("delete_flag", deleteFlag);
-		}
-		wrapper.eq("delete_flag", 0);
-		List<CertificateManagementInfo> list = certificateManagementInfoMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-		Integer count = certificateManagementInfoMapper.selectCount(wrapper);
-		return new Page<CertificateManagementInfo>(list, page, limit, count);
-	}
-
-	@Override
-	@Transactional(rollbackFor = Exception.class)
-	public Boolean delete(String id) {
-		String[] ids = String.valueOf(id).split(",");
-		for (String tt : ids) {
-			CertificateManagementInfo tmp = certificateManagementInfoMapper.selectById(Long.parseLong(tt));
-			if (tmp != null) {
-				tmp.setDeleteFlag(1l);
-				tmp.setGmtUpdate(new Date());
-				certificateManagementInfoMapper.updateById(tmp);
-			}
-		}
-		return true;
-	}
-
-	@Override
-	public Boolean update(CertificateManagementInfo certificateManagementInfo) throws ServiceException {
-		Date now = new Date();
-		certificateManagementInfo.setGmtUpdate(now);
-		return certificateManagementInfoMapper.updateById(certificateManagementInfo) > 0;
-	}
-
-	@Override
-	public CertificateManagementInfo get(Long id) throws ServiceException {
-		return certificateManagementInfoMapper.selectById(id);
-	}
-
-	@Override
-	public String export(Long commonId, String certificateName, String certificateImage, Date gmtCreate, Date gmtUpdate, Long deleteFlag, Integer page, Integer limit) throws ServiceException {
-		Wrapper<CertificateManagementInfo> wrapper = new EntityWrapper<CertificateManagementInfo>();
-		if (!StringUtils.isEmpty(commonId)) {
-			wrapper.eq("common_id", commonId);
-		}
-		if (!StringUtils.isEmpty(certificateName)) {
-			wrapper.eq("certificate_name", certificateName);
-		}
-		if (!StringUtils.isEmpty(certificateImage)) {
-			wrapper.eq("certificate_image", certificateImage);
-		}
-		if (!StringUtils.isEmpty(gmtCreate)) {
-			wrapper.eq("gmt_create", gmtCreate);
-		}
-		if (!StringUtils.isEmpty(gmtUpdate)) {
-			wrapper.eq("gmt_update", gmtUpdate);
-		}
-		if (!StringUtils.isEmpty(deleteFlag)) {
-			wrapper.eq("delete_flag", deleteFlag);
-		}
-		List<CertificateManagementInfo> list = certificateManagementInfoMapper.selectList(wrapper);
-		ExcelUtil<CertificateManagementInfo> util = new ExcelUtil<CertificateManagementInfo>(CertificateManagementInfo.class);
-		return util.exportExcel(list, "操作日志");
-	}
-
-	@Override
-	public DistinguishView personShibie(String certificateImage) throws ServiceException {
-		String appcode = "2d59bfa794994f5f94d1d98b7b5bd102";
-		//API产品路径
-		String requestUrl = "https://personcard.market.alicloudapi.com/ai_market/ai_ocr_universal/shen_fen_zheng/ch/v1";
-		//阿里云APPCODE
-		DistinguishView distinguishView = new DistinguishView();
-		CloseableHttpClient httpClient = null;
-		try {
-			httpClient = HttpClients.createDefault();
-			List<NameValuePair> params = new ArrayList<NameValuePair>();
-			//启用URL方式进行识别
-			//内容数据类型是图像文件URL链接
-			params.add(new BasicNameValuePair("IMAGE", certificateImage));
-			params.add(new BasicNameValuePair("IMAGE_TYPE", "1"));
-
-			// 创建一个HttpPost实例
-			HttpPost httpPost = new HttpPost(requestUrl);
-			httpPost.addHeader("Authorization", "APPCODE " + appcode);
-			httpPost.addHeader("Content-Type", "application/x-www-form-urlencoded; charset=UTF-8");
-
-			// 设置请求参数
-			httpPost.setEntity(new UrlEncodedFormEntity(params, "utf-8"));
-
-			// 发送POST请求
-			HttpResponse execute = httpClient.execute(httpPost);
-
-			// 获取状态码
-			int statusCode = execute.getStatusLine().getStatusCode();
-			System.out.println(statusCode);
-
-			// 获取结果
-			HttpEntity entity = execute.getEntity();
-			String body = EntityUtils.toString(entity);
-			System.out.println(body);
-			JSONObject jsonObject = JSONObject.parseObject(body);
-			distinguishView.setRecPersonNo(jsonObject.getJSONObject("身份证识别实体信息").getJSONObject("身份证人像面实体信息").getString("身份证号"));
-			return distinguishView;
-		} catch (Exception e) {
-			e.printStackTrace();
-		}
-		return null;
-	}
-
-	@Override
-	public DistinguishView bankShibie(String certificateImage) throws ServiceException {
-		String appcode = "2d59bfa794994f5f94d1d98b7b5bd102";
-		String host = "https://api06.aliyun.venuscn.com";
-		String path = "/ocr/bank-card";
-		String method = "POST";
-		Map<String, String> headers = new HashMap<String, String>();
-		//最后在header中的格式(中间是英文空格)为Authorization:APPCODE 83359fd73fe94948385f570e3c139105
-		headers.put("Authorization", "APPCODE " + appcode);
-		//根据API的要求,定义相对应的Content-Type
-		headers.put("Content-Type", "application/x-www-form-urlencoded; charset=UTF-8");
-		Map<String, String> querys = new HashMap<String, String>();
-		Map<String, String> bodys = new HashMap<String, String>();
-		bodys.put("pic", certificateImage);
-		try {
-			HttpResponse response = HttpUtils.doPost(host, path, method, headers, querys, bodys);
-			String body = EntityUtils.toString(response.getEntity());
-			System.out.println(body);
-			JSONObject jsonObject = JSONObject.parseObject(body);
-			if ("200".equals(jsonObject.getString("ret"))) {
-				JSONObject data = JSONObject.parseObject(jsonObject.getString("data"));
-				DistinguishView distinguishView = new DistinguishView();
-				distinguishView.setBankNo(data.getString("number"));
-
-				host = "https://yhkgsd.market.alicloudapi.com";
-				path = "/bankcard/region";
-				method = "GET";
-				headers = new HashMap<String, String>();
-				//最后在header中的格式(中间是英文空格)为Authorization:APPCODE 83359fd73fe94948385f570e3c139105
-				headers.put("Authorization", "APPCODE " + appcode);
-				querys = new HashMap<String, String>();
-				querys.put("bankcard", distinguishView.getBankNo());
-				try {
-					response = HttpUtils.doGet(host, path, method, headers, querys);
-					body = EntityUtils.toString(response.getEntity());
-					System.out.println(body);
-					jsonObject = JSONObject.parseObject(body);
-					if ("0".equals(jsonObject.getString("code"))) {
-						data = JSONObject.parseObject(jsonObject.getString("data"));
-						JSONObject detail = JSONObject.parseObject(data.getString("detail"));
-						String[] area = detail.getString("area").split(" - ");
-						String province = "";
-						String city = "";
-						if (area.length > 1) {
-							province = area[0];
-							city = area[1];
-						}
-
-						host = "https://cnaps.market.alicloudapi.com";
-						path = "/lianzhuo/querybankaps";
-						method = "GET";
-						headers = new HashMap<String, String>();
-						//最后在header中的格式(中间是英文空格)为Authorization:APPCODE 83359fd73fe94948385f570e3c139105
-						headers.put("Authorization", "APPCODE " + appcode);
-						querys = new HashMap<String, String>();
-						querys.put("card", distinguishView.getBankNo());
-						querys.put("province", province);
-						querys.put("city", city);
-						try {
-							response = HttpUtils.doGet(host, path, method, headers, querys);
-							System.out.println(response.toString());
-							body = EntityUtils.toString(response.getEntity());
-							System.out.println(body);
-							jsonObject = JSONObject.parseObject(body);
-							JSONObject jsonData = jsonObject.getJSONObject("data");
-							JSONObject res = jsonObject.getJSONObject("resp");
-							if ("200".equals(res.get("RespCode"))) {
-								JSONArray jsonArray = jsonData.getJSONArray("record");
-								List<String> bankList = new ArrayList<>();
-								for (int i = 0; i < jsonArray.size(); i++) {
-									bankList.add(jsonArray.getJSONObject(i).get("lName").toString());
-								}
-							}
-						} catch (Exception e) {
-							e.printStackTrace();
-						}
-					}
-				} catch (Exception e) {
-					e.printStackTrace();
-				}
-				return distinguishView;
-			} else {
-				System.out.println(jsonObject.getString("msg"));
-			}
-		} catch (Exception e) {
-			e.printStackTrace();
-		}
-		return null;
-	}
-
-	@Override
-	public DistinguishView speechRecognition(String voiceMessage) throws ServiceException {
-		String host = "https://audio.market.alicloudapi.com";
-		String path = "/audioshort";
-		String method = "POST";
-		String appcode = "2d59bfa794994f5f94d1d98b7b5bd102";
-		Map<String, String> headers = new HashMap<String, String>();
-		//最后在header中的格式(中间是英文空格)为Authorization:APPCODE 83359fd73fe94948385f570e3c139105
-		headers.put("Authorization", "APPCODE " + appcode);
-		//根据API的要求,定义相对应的Content-Type
-		headers.put("Content-Type", "application/x-www-form-urlencoded; charset=UTF-8");
-		Map<String, String> querys = new HashMap<String, String>();
-		Map<String, String> bodys = new HashMap<String, String>();
-		bodys.put("format", "m4a");
-		bodys.put("src", voiceMessage);
-		bodys.put("type", "zh-fast");
-		try {
-			HttpResponse response = HttpUtils.doPost(host, path, method, headers, querys, bodys);
-			String body = EntityUtils.toString(response.getEntity());
-			System.out.println(body);
-			JSONObject jsonObject = JSONObject.parseObject(body);
-			JSONArray jsonArray = jsonObject.getJSONArray("msg");
-			DistinguishView distinguishView = new DistinguishView();
-			if(jsonArray!= null && jsonArray.size() >0){
-				String text = jsonArray.getString(0).replace("。","");
-				distinguishView.setText(text);
-				System.out.println(text);
-			}
-			else{
-				distinguishView.setText("未识别成功!");
-			}
-			return distinguishView;
-		} catch (Exception e) {
-			e.printStackTrace();
-		}
-		return null;
-	}
-}
-

+ 0 - 132
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CircleCardInfoServiceImpl.java

@@ -1,132 +0,0 @@
-package com.iotechn.unimall.admin.api.card.impl;
-
-import java.util.List;
-
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.StringUtils;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import com.iotechn.unimall.data.mapper.CircleCardInfoMapper;
-import com.iotechn.unimall.data.domain.CircleCardInfo;
-import com.iotechn.unimall.admin.api.card.ICircleCardInfoService;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 圈子个人关系Service业务层处理
- *
- * @author jlb
- * @date 2023-04-10
- */
-@Service
-public class CircleCardInfoServiceImpl implements ICircleCardInfoService {
-    @Autowired
-    private CircleCardInfoMapper circleCardInfoMapper;
-
-    @Override
-    public Boolean add(CircleCardInfo circleCardInfo) throws ServiceException {
-        Date now = new Date();
-        circleCardInfo.setGmtCreate(now);
-        circleCardInfo.setGmtUpdate(now);
-        return circleCardInfoMapper.insert(circleCardInfo) > 0;
-    }
-
-    @Override
-    public Page<CircleCardInfo> list(Long circleId, Long cardId, Long commonId, Date gmtCreate, Date gmtUpdate, Long deleteFlag, Integer page, Integer limit) throws ServiceException {
-        Wrapper<CircleCardInfo> wrapper = new EntityWrapper<CircleCardInfo>();
-        if (!StringUtils.isEmpty(circleId)) {
-            wrapper.eq("circle_id", circleId);
-        }
-        if (!StringUtils.isEmpty(cardId)) {
-            wrapper.eq("card_id", cardId);
-        }
-        if (!StringUtils.isEmpty(commonId)) {
-            wrapper.eq("common_id", commonId);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        wrapper.eq("delete_flag", 0);
-        List<CircleCardInfo> list = circleCardInfoMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-        Integer count = circleCardInfoMapper.selectCount(wrapper);
-        return new Page<CircleCardInfo>(list, page, limit, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt : ids) {
-            CircleCardInfo tmp = circleCardInfoMapper.selectById(Long.parseLong(tt));
-            if (tmp != null) {
-                tmp.setDeleteFlag(1l);
-                tmp.setGmtUpdate(new Date());
-                circleCardInfoMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(CircleCardInfo circleCardInfo) throws ServiceException {
-        Date now = new Date();
-        //更换圈子内名片
-        CircleCardInfo circleCardInfo1 = new CircleCardInfo();
-        circleCardInfo1.setCommonId(circleCardInfo.getCommonId());
-        circleCardInfo1.setCircleId(circleCardInfo.getCircleId());
-        circleCardInfo1.setDeleteFlag(0l);
-        CircleCardInfo circleCardInfo2 = circleCardInfoMapper.selectOne(circleCardInfo1);
-        //我加入该圈子的名片
-        if (circleCardInfo2 != null) {
-            circleCardInfo2.setCardId(circleCardInfo.getCardId());
-            circleCardInfo2.setGmtUpdate(now);
-            circleCardInfoMapper.updateById(circleCardInfo2);
-        }
-        return circleCardInfoMapper.updateById(circleCardInfo) > 0;
-    }
-
-    @Override
-    public CircleCardInfo get(Long id) throws ServiceException {
-        return circleCardInfoMapper.selectById(id);
-    }
-
-    @Override
-    public String export(Long circleId, Long cardId, Long commonId, Date gmtCreate, Date gmtUpdate, Long deleteFlag, Integer page, Integer limit) throws ServiceException {
-        Wrapper<CircleCardInfo> wrapper = new EntityWrapper<CircleCardInfo>();
-        if (!StringUtils.isEmpty(circleId)) {
-            wrapper.eq("circle_id", circleId);
-        }
-        if (!StringUtils.isEmpty(cardId)) {
-            wrapper.eq("card_id", cardId);
-        }
-        if (!StringUtils.isEmpty(commonId)) {
-            wrapper.eq("common_id", commonId);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        List<CircleCardInfo> list = circleCardInfoMapper.selectList(wrapper);
-        ExcelUtil<CircleCardInfo> util = new ExcelUtil<CircleCardInfo>(CircleCardInfo.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 142
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CircleFriendsDetailServiceImpl.java

@@ -1,142 +0,0 @@
-package com.iotechn.unimall.admin.api.card.impl;
-
-import java.util.List;
-
-import com.iotechn.unimall.admin.api.card.ICircleFriendsDetailService;
-import com.iotechn.unimall.data.domain.CircleFriendsDetail;
-import com.iotechn.unimall.data.mapper.CircleFriendsDetailMapper;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.StringUtils;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 记录朋友圈互动信息Service业务层处理
- * 
- * @author jlb
- * @date 2023-05-22
- */
-@Service
-public class CircleFriendsDetailServiceImpl implements ICircleFriendsDetailService {
-	@Autowired
-	private CircleFriendsDetailMapper circleFriendsDetailMapper;
-	
-	@Override
-	public Boolean add(CircleFriendsDetail circleFriendsDetail) throws ServiceException {
-		Date now = new Date();
-		circleFriendsDetail.setGmtCreate(now);
-		circleFriendsDetail.setGmtUpdate(now);
-		return circleFriendsDetailMapper.insert(circleFriendsDetail)>0;
-	}
-
-	@Override
-	public Page<CircleFriendsDetail> list(Long circleFriendsId,Long commonId,String head,String nickname,String commentContent,Long commentId,String interactionFlag,Date gmtCreate,Date gmtUpdate,Long deleteFlag, Integer page, Integer limit)throws ServiceException {
-		Wrapper<CircleFriendsDetail> wrapper = new EntityWrapper<CircleFriendsDetail>();
-														if (!StringUtils.isEmpty(circleFriendsId)) {
-					wrapper.eq("circle_friends_id", circleFriendsId);
-				}
-												if (!StringUtils.isEmpty(commonId)) {
-					wrapper.eq("common_id", commonId);
-				}
-												if (!StringUtils.isEmpty(head)) {
-					wrapper.eq("head", head);
-				}
-												if (!StringUtils.isEmpty(nickname)) {
-					wrapper.eq("nickname", nickname);
-				}
-												if (!StringUtils.isEmpty(commentContent)) {
-					wrapper.eq("comment_content", commentContent);
-				}
-												if (!StringUtils.isEmpty(commentId)) {
-					wrapper.eq("comment_id", commentId);
-				}
-												if (!StringUtils.isEmpty(interactionFlag)) {
-					wrapper.eq("interaction_flag", interactionFlag);
-				}
-												if (!StringUtils.isEmpty(gmtCreate)) {
-					wrapper.eq("gmt_create", gmtCreate);
-				}
-												if (!StringUtils.isEmpty(gmtUpdate)) {
-					wrapper.eq("gmt_update", gmtUpdate);
-				}
-												if (!StringUtils.isEmpty(deleteFlag)) {
-					wrapper.eq("delete_flag", deleteFlag);
-				}
-							wrapper.eq("delete_flag", 0);
-		List<CircleFriendsDetail> list = circleFriendsDetailMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-		Integer count = circleFriendsDetailMapper.selectCount(wrapper);
-		return new Page<CircleFriendsDetail>(list, page, limit, count);
-	}
-
-	@Override
-	@Transactional(rollbackFor = Exception.class)
-	public Boolean delete(String id) {
-		String[] ids = String.valueOf(id).split(",");
-		for (String tt:ids) {
-			CircleFriendsDetail tmp =  circleFriendsDetailMapper.selectById(Long.parseLong(tt));
-			if(tmp != null){
-				tmp.setDeleteFlag(1l);
-				circleFriendsDetailMapper.updateById(tmp);
-			}
-		}
-		return true;
-	}
-
-	@Override
-	public Boolean update(CircleFriendsDetail circleFriendsDetail) throws ServiceException {
-		Date now = new Date();
-		circleFriendsDetail.setGmtUpdate(now);
-		return circleFriendsDetailMapper.updateById(circleFriendsDetail)>0;
-	}
-
-	@Override
-	public CircleFriendsDetail get(Long id) throws ServiceException {
-		return circleFriendsDetailMapper.selectById(id);
-	}
-	
-	@Override
-	public String export(Long circleFriendsId,Long commonId,String head,String nickname,String commentContent,Long commentId,String interactionFlag,Date gmtCreate,Date gmtUpdate,Long deleteFlag, Integer page, Integer limit)throws ServiceException {
-		Wrapper<CircleFriendsDetail> wrapper = new EntityWrapper<CircleFriendsDetail>();
-														if (!StringUtils.isEmpty(circleFriendsId)) {
-					wrapper.eq("circle_friends_id", circleFriendsId);
-				}
-												if (!StringUtils.isEmpty(commonId)) {
-					wrapper.eq("common_id", commonId);
-				}
-												if (!StringUtils.isEmpty(head)) {
-					wrapper.eq("head", head);
-				}
-												if (!StringUtils.isEmpty(nickname)) {
-					wrapper.eq("nickname", nickname);
-				}
-												if (!StringUtils.isEmpty(commentContent)) {
-					wrapper.eq("comment_content", commentContent);
-				}
-												if (!StringUtils.isEmpty(commentId)) {
-					wrapper.eq("comment_id", commentId);
-				}
-												if (!StringUtils.isEmpty(interactionFlag)) {
-					wrapper.eq("interaction_flag", interactionFlag);
-				}
-												if (!StringUtils.isEmpty(gmtCreate)) {
-					wrapper.eq("gmt_create", gmtCreate);
-				}
-												if (!StringUtils.isEmpty(gmtUpdate)) {
-					wrapper.eq("gmt_update", gmtUpdate);
-				}
-												if (!StringUtils.isEmpty(deleteFlag)) {
-					wrapper.eq("delete_flag", deleteFlag);
-				}
-							List<CircleFriendsDetail> list = circleFriendsDetailMapper.selectList(wrapper);
-		ExcelUtil<CircleFriendsDetail> util = new ExcelUtil<CircleFriendsDetail>(CircleFriendsDetail.class);
-		return util.exportExcel(list, "操作日志");
-	}
-}

+ 0 - 148
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CircleFriendsInfoServiceImpl.java

@@ -1,148 +0,0 @@
-package com.iotechn.unimall.admin.api.card.impl;
-
-import java.util.List;
-
-import com.iotechn.unimall.admin.api.card.ICircleFriendsInfoService;
-import com.iotechn.unimall.data.domain.CircleFriendsInfo;
-import com.iotechn.unimall.data.mapper.CircleFriendsInfoMapper;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.StringUtils;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 记录朋友圈信息Service业务层处理
- * 
- * @author jlb
- * @date 2023-05-22
- */
-@Service
-public class CircleFriendsInfoServiceImpl implements ICircleFriendsInfoService {
-	@Autowired
-	private CircleFriendsInfoMapper circleFriendsInfoMapper;
-	
-	@Override
-	public Boolean add(CircleFriendsInfo circleFriendsInfo) throws ServiceException {
-		Date now = new Date();
-		circleFriendsInfo.setGmtCreate(now);
-		circleFriendsInfo.setGmtUpdate(now);
-		return circleFriendsInfoMapper.insert(circleFriendsInfo)>0;
-	}
-
-	@Override
-	public Page<CircleFriendsInfo> list(Long commonId,String head,String nickname,String content,String image,String location,String positioning,String commentFlag,Date gmtCreate,Date gmtUpdate,Long deleteFlag, Integer page, Integer limit)throws ServiceException {
-		Wrapper<CircleFriendsInfo> wrapper = new EntityWrapper<CircleFriendsInfo>();
-														if (!StringUtils.isEmpty(commonId)) {
-					wrapper.eq("common_id", commonId);
-				}
-												if (!StringUtils.isEmpty(head)) {
-					wrapper.eq("head", head);
-				}
-												if (!StringUtils.isEmpty(nickname)) {
-					wrapper.eq("nickname", nickname);
-				}
-												if (!StringUtils.isEmpty(content)) {
-					wrapper.eq("content", content);
-				}
-												if (!StringUtils.isEmpty(image)) {
-					wrapper.eq("image", image);
-				}
-												if (!StringUtils.isEmpty(location)) {
-					wrapper.eq("location", location);
-				}
-												if (!StringUtils.isEmpty(positioning)) {
-					wrapper.eq("positioning", positioning);
-				}
-												if (!StringUtils.isEmpty(commentFlag)) {
-					wrapper.eq("comment_flag", commentFlag);
-				}
-												if (!StringUtils.isEmpty(gmtCreate)) {
-					wrapper.eq("gmt_create", gmtCreate);
-				}
-												if (!StringUtils.isEmpty(gmtUpdate)) {
-					wrapper.eq("gmt_update", gmtUpdate);
-				}
-												if (!StringUtils.isEmpty(deleteFlag)) {
-					wrapper.eq("delete_flag", deleteFlag);
-				}
-							wrapper.eq("delete_flag", 0);
-		List<CircleFriendsInfo> list = circleFriendsInfoMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-		Integer count = circleFriendsInfoMapper.selectCount(wrapper);
-		return new Page<CircleFriendsInfo>(list, page, limit, count);
-	}
-
-	@Override
-	@Transactional(rollbackFor = Exception.class)
-	public Boolean delete(String id) {
-		String[] ids = String.valueOf(id).split(",");
-		for (String tt:ids) {
-			CircleFriendsInfo tmp =  circleFriendsInfoMapper.selectById(Long.parseLong(tt));
-			if(tmp != null){
-				tmp.setDeleteFlag(1l);
-				circleFriendsInfoMapper.updateById(tmp);
-			}
-		}
-		return true;
-	}
-
-	@Override
-	public Boolean update(CircleFriendsInfo circleFriendsInfo) throws ServiceException {
-		Date now = new Date();
-		circleFriendsInfo.setGmtUpdate(now);
-		return circleFriendsInfoMapper.updateById(circleFriendsInfo)>0;
-	}
-
-	@Override
-	public CircleFriendsInfo get(Long id) throws ServiceException {
-		return circleFriendsInfoMapper.selectById(id);
-	}
-	
-	@Override
-	public String export(Long commonId,String head,String nickname,String content,String image,String location,String positioning,String commentFlag,Date gmtCreate,Date gmtUpdate,Long deleteFlag, Integer page, Integer limit)throws ServiceException {
-		Wrapper<CircleFriendsInfo> wrapper = new EntityWrapper<CircleFriendsInfo>();
-														if (!StringUtils.isEmpty(commonId)) {
-					wrapper.eq("common_id", commonId);
-				}
-												if (!StringUtils.isEmpty(head)) {
-					wrapper.eq("head", head);
-				}
-												if (!StringUtils.isEmpty(nickname)) {
-					wrapper.eq("nickname", nickname);
-				}
-												if (!StringUtils.isEmpty(content)) {
-					wrapper.eq("content", content);
-				}
-												if (!StringUtils.isEmpty(image)) {
-					wrapper.eq("image", image);
-				}
-												if (!StringUtils.isEmpty(location)) {
-					wrapper.eq("location", location);
-				}
-												if (!StringUtils.isEmpty(positioning)) {
-					wrapper.eq("positioning", positioning);
-				}
-												if (!StringUtils.isEmpty(commentFlag)) {
-					wrapper.eq("comment_flag", commentFlag);
-				}
-												if (!StringUtils.isEmpty(gmtCreate)) {
-					wrapper.eq("gmt_create", gmtCreate);
-				}
-												if (!StringUtils.isEmpty(gmtUpdate)) {
-					wrapper.eq("gmt_update", gmtUpdate);
-				}
-												if (!StringUtils.isEmpty(deleteFlag)) {
-					wrapper.eq("delete_flag", deleteFlag);
-				}
-							List<CircleFriendsInfo> list = circleFriendsInfoMapper.selectList(wrapper);
-		ExcelUtil<CircleFriendsInfo> util = new ExcelUtil<CircleFriendsInfo>(CircleFriendsInfo.class);
-		return util.exportExcel(list, "操作日志");
-	}
-}

+ 0 - 214
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CircleManagementInfoServiceImpl.java

@@ -1,214 +0,0 @@
-package com.iotechn.unimall.admin.api.card.impl;
-
-import java.util.*;
-
-import com.iotechn.unimall.data.domain.*;
-import com.iotechn.unimall.data.mapper.*;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.CollectionUtils;
-import org.springframework.util.StringUtils;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import com.iotechn.unimall.admin.api.card.ICircleManagementInfoService;
-import com.iotechn.unimall.data.model.Page;
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 圈子管理Service业务层处理
- *
- * @author jlb
- * @date 2023-04-10
- */
-@Service
-public class CircleManagementInfoServiceImpl implements ICircleManagementInfoService {
-    @Autowired
-    private CircleManagementInfoMapper circleManagementInfoMapper;
-    @Autowired
-    private CircleCardInfoMapper circleCardInfoMapper;
-    @Autowired
-    private CardNewsInfoMapper cardNewsInfoMapper;
-    @Autowired
-    private CardManagementInfoMapper cardManagementInfoMapper;
-
-    @Override
-    public Boolean add(CircleManagementInfo circleManagementInfo) throws ServiceException {
-        Date now = new Date();
-        circleManagementInfo.setGmtCreate(now);
-        circleManagementInfo.setGmtUpdate(now);
-        //添加圈子状态默认未审核
-        circleManagementInfo.setStatus(0l);
-        return circleManagementInfoMapper.insert(circleManagementInfo) > 0;
-    }
-
-    @Override
-    public Page<CircleManagementInfo> list(Long commonId, String circleName, String circleLabel, Long status, Date gmtCreate, Date gmtUpdate, Long deleteFlag, Integer page, Integer limit) throws ServiceException {
-        Wrapper<CircleManagementInfo> wrapper = new EntityWrapper<CircleManagementInfo>();
-        if (!StringUtils.isEmpty(circleName)) {
-            wrapper.like("circle_name", circleName);
-        }
-        if (!StringUtils.isEmpty(circleLabel)) {
-            wrapper.eq("circle_label", circleLabel);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        wrapper.eq("delete_flag", 0);
-        List<CircleManagementInfo> list = circleManagementInfoMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-        if (!CollectionUtils.isEmpty(list)) {
-            for (CircleManagementInfo circleManagementInfo : list) {
-                List<CircleCardInfo> circleCardInfoList = circleCardInfoMapper.selectList(new EntityWrapper<CircleCardInfo>()
-                        .eq("circle_id", circleManagementInfo.getId())
-                        .eq("delete_flag", 0));
-                circleManagementInfo.setCardNum(circleCardInfoList.size());
-                List<CircleCardInfo> circleCardInfoList1 = circleCardInfoMapper.selectList(new EntityWrapper<CircleCardInfo>()
-                        .eq("circle_id", circleManagementInfo.getId())
-                        .eq("common_id",commonId)
-                        .eq("delete_flag", 0));
-                if (circleCardInfoList1.size()>0){
-                    circleManagementInfo.setAddedFlag(1l);
-                } else {
-                    circleManagementInfo.setAddedFlag(0l);
-                }
-            }
-        }
-        Collections.sort(list, new Comparator<CircleManagementInfo>() {
-            @Override
-            public int compare(CircleManagementInfo o1, CircleManagementInfo o2) {
-                return o1.getAddedFlag() > o2.getAddedFlag() ? -1 : (o1.getAddedFlag() == o2.getAddedFlag()) ? 0 : 1;
-            }
-        });
-        Integer count = circleManagementInfoMapper.selectCount(wrapper);
-        return new Page<CircleManagementInfo>(list, page, limit, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt : ids) {
-            CircleManagementInfo tmp = circleManagementInfoMapper.selectById(Long.parseLong(tt));
-            if (tmp != null) {
-                tmp.setDeleteFlag(1l);
-                tmp.setGmtUpdate(new Date());
-                circleManagementInfoMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(CircleManagementInfo circleManagementInfo) throws ServiceException {
-        Date now = new Date();
-        circleManagementInfo.setGmtUpdate(now);
-        return circleManagementInfoMapper.updateById(circleManagementInfo) > 0;
-    }
-
-    @Override
-    public Boolean handle(CircleManagementInfo circleManagementInfo) throws ServiceException {
-        Date now = new Date();
-        //驳回
-        if (circleManagementInfo.getStatus()==3){
-            CardNewsInfo cardNewsInfo=new CardNewsInfo();
-            cardNewsInfo.setNewsTitle("系统消息");
-            cardNewsInfo.setNewsContent("您创建的圈子”"+circleManagementInfo.getCircleName()+"”未通过审核,驳回原因:"+circleManagementInfo.getReason()+"。");
-            cardNewsInfo.setReceiveId(circleManagementInfo.getCommonId());
-            cardNewsInfo.setGmtCreate(now);
-            cardNewsInfo.setGmtUpdate(now);
-            cardNewsInfoMapper.insert(cardNewsInfo);
-        }
-        else{
-            circleManagementInfo.setStatus(1l);
-            if (circleManagementInfo.getCardId() != null) {
-                //圈子审核通过,创建圈子人自动加入圈子
-                CircleCardInfo circleCardInfo=new CircleCardInfo();
-                circleCardInfo.setCircleId(circleManagementInfo.getId());
-                circleCardInfo.setCommonId(circleManagementInfo.getCommonId());
-                circleCardInfo.setCardId(circleManagementInfo.getCardId());
-                circleCardInfo.setGmtCreate(now);
-                circleCardInfo.setGmtUpdate(now);
-                circleCardInfoMapper.insert(circleCardInfo);
-            }
-            CardNewsInfo cardNewsInfo=new CardNewsInfo();
-            cardNewsInfo.setNewsTitle("系统消息");
-            cardNewsInfo.setNewsContent("您创建的圈子”"+circleManagementInfo.getCircleName()+"“已通过审核,快去邀请好友一起加入吧。");
-            cardNewsInfo.setReceiveId(circleManagementInfo.getCommonId());
-            cardNewsInfo.setGmtCreate(now);
-            cardNewsInfo.setGmtUpdate(now);
-            cardNewsInfoMapper.insert(cardNewsInfo);
-        }
-        return circleManagementInfoMapper.updateById(circleManagementInfo) > 0;
-    }
-
-    @Override
-    public CircleManagementInfo get(Long id, Long commonId) throws ServiceException {
-        CircleManagementInfo circleManagementInfo = circleManagementInfoMapper.selectById(id);
-        if (commonId!=null) {
-            CircleCardInfo circleCardInfo = new CircleCardInfo();
-            circleCardInfo.setCommonId(commonId);
-            circleCardInfo.setCircleId(circleManagementInfo.getId());
-            circleCardInfo.setDeleteFlag(0l);
-            CircleCardInfo circleCardInfo1 = circleCardInfoMapper.selectOne(circleCardInfo);
-            //我加入该圈子的名片
-            if (circleCardInfo1 != null) {
-                circleManagementInfo.setCircleCardInfo(circleCardInfo1);
-            }
-        }
-        List<CircleCardInfo> circleCardInfoList = circleCardInfoMapper.selectList(new EntityWrapper<CircleCardInfo>()
-                .eq("circle_id", circleManagementInfo.getId())
-                .eq("delete_flag", 0));
-        circleManagementInfo.setCardNum(circleCardInfoList.size());
-        return circleManagementInfo;
-    }
-
-    @Override
-    public Page<CardManagementInfo> circleCardlist(Long commonId, Long id, String status, Integer page, Integer limit) throws ServiceException {
-        Wrapper<CardManagementInfo> wrapper = new EntityWrapper<CardManagementInfo>();
-        wrapper.eq("delete_flag", 0);
-        Integer count = cardManagementInfoMapper.getCardManagementCount(status,(page - 1) * limit, limit, commonId,id);
-        List<CardManagementInfo> list = cardManagementInfoMapper.getCardManagementPage(status,(page - 1) * limit, limit, commonId,id);
-        return new Page<CardManagementInfo>(list, page, limit, count);
-    }
-
-    @Override
-    public String export(Long commonId, String circleName, String circleLabel, Long status, Date gmtCreate, Date gmtUpdate, Long deleteFlag, Integer page, Integer limit) throws ServiceException {
-        Wrapper<CircleManagementInfo> wrapper = new EntityWrapper<CircleManagementInfo>();
-        if (!StringUtils.isEmpty(commonId)) {
-            wrapper.eq("common_id", commonId);
-        }
-        if (!StringUtils.isEmpty(circleName)) {
-            wrapper.eq("circle_name", circleName);
-        }
-        if (!StringUtils.isEmpty(circleLabel)) {
-            wrapper.eq("circle_label", circleLabel);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        List<CircleManagementInfo> list = circleManagementInfoMapper.selectList(wrapper);
-        ExcelUtil<CircleManagementInfo> util = new ExcelUtil<CircleManagementInfo>(CircleManagementInfo.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 151
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/CommonUserInfoServiceImpl.java

@@ -1,151 +0,0 @@
-package com.iotechn.unimall.admin.api.card.impl;
-
-import java.util.List;
-
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.StringUtils;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import com.iotechn.unimall.data.mapper.CommonUserInfoMapper;
-import com.iotechn.unimall.data.domain.CommonUserInfo;
-import com.iotechn.unimall.admin.api.card.ICommonUserInfoService;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 用户管理Service业务层处理
- *
- * @author jlb
- * @date 2023-04-10
- */
-@Service
-public class CommonUserInfoServiceImpl implements ICommonUserInfoService {
-    @Autowired
-    private CommonUserInfoMapper commonUserInfoMapper;
-
-    @Override
-    public Boolean add(CommonUserInfo commonUserInfo) throws ServiceException {
-        Date now = new Date();
-        commonUserInfo.setGmtCreate(now);
-        commonUserInfo.setGmtUpdate(now);
-        return commonUserInfoMapper.insert(commonUserInfo) > 0;
-    }
-
-    @Override
-    public Page<CommonUserInfo> list(String nickname, String password, String phone, String realname, Long shareCard, Long lookPage, Long autoAccept, Long status, Date gmtCreate, Date gmtUpdate, Long deleteFlag, Integer page, Integer limit) throws ServiceException {
-        Wrapper<CommonUserInfo> wrapper = new EntityWrapper<CommonUserInfo>();
-        if (!StringUtils.isEmpty(nickname)) {
-            wrapper.eq("nickname", nickname);
-        }
-        if (!StringUtils.isEmpty(password)) {
-            wrapper.eq("password", password);
-        }
-        if (!StringUtils.isEmpty(phone)) {
-            wrapper.eq("phone", phone);
-        }
-        if (!StringUtils.isEmpty(realname)) {
-            wrapper.eq("realname", realname);
-        }
-        if (!StringUtils.isEmpty(shareCard)) {
-            wrapper.eq("share_card", shareCard);
-        }
-        if (!StringUtils.isEmpty(lookPage)) {
-            wrapper.eq("look_page", lookPage);
-        }
-        if (!StringUtils.isEmpty(autoAccept)) {
-            wrapper.eq("auto_accept", autoAccept);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        wrapper.eq("delete_flag", 0);
-        List<CommonUserInfo> list = commonUserInfoMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-        Integer count = commonUserInfoMapper.selectCount(wrapper);
-        return new Page<CommonUserInfo>(list, page, limit, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt : ids) {
-            CommonUserInfo tmp = commonUserInfoMapper.selectById(Long.parseLong(tt));
-            if (tmp != null) {
-                tmp.setDeleteFlag(1L);
-                tmp.setGmtUpdate(new Date());
-                commonUserInfoMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(CommonUserInfo commonUserInfo) throws ServiceException {
-        Date now = new Date();
-        commonUserInfo.setGmtUpdate(now);
-        return commonUserInfoMapper.updateById(commonUserInfo) > 0;
-    }
-
-    @Override
-    public CommonUserInfo get(Long id) throws ServiceException {
-        return commonUserInfoMapper.selectById(id);
-    }
-
-    @Override
-    public String export(String nickname, String password, String phone, String realname, Long shareCard, Long lookPage, Long autoAccept, Long status, Date gmtCreate, Date gmtUpdate, Long deleteFlag, Integer page, Integer limit) throws ServiceException {
-        Wrapper<CommonUserInfo> wrapper = new EntityWrapper<CommonUserInfo>();
-        if (!StringUtils.isEmpty(nickname)) {
-            wrapper.eq("nickname", nickname);
-        }
-        if (!StringUtils.isEmpty(password)) {
-            wrapper.eq("password", password);
-        }
-        if (!StringUtils.isEmpty(phone)) {
-            wrapper.eq("phone", phone);
-        }
-        if (!StringUtils.isEmpty(realname)) {
-            wrapper.eq("realname", realname);
-        }
-        if (!StringUtils.isEmpty(shareCard)) {
-            wrapper.eq("share_card", shareCard);
-        }
-        if (!StringUtils.isEmpty(lookPage)) {
-            wrapper.eq("look_page", lookPage);
-        }
-        if (!StringUtils.isEmpty(autoAccept)) {
-            wrapper.eq("auto_accept", autoAccept);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        List<CommonUserInfo> list = commonUserInfoMapper.selectList(wrapper);
-        ExcelUtil<CommonUserInfo> util = new ExcelUtil<CommonUserInfo>(CommonUserInfo.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 157
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/PersonalHomepageInfoServiceImpl.java

@@ -1,157 +0,0 @@
-package com.iotechn.unimall.admin.api.card.impl;
-
-import java.util.List;
-
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.StringUtils;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import com.iotechn.unimall.data.mapper.PersonalHomepageInfoMapper;
-import com.iotechn.unimall.data.domain.PersonalHomepageInfo;
-import com.iotechn.unimall.admin.api.card.IPersonalHomepageInfoService;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 个人主页Service业务层处理
- *
- * @author jlb
- * @date 2023-04-10
- */
-@Service
-public class PersonalHomepageInfoServiceImpl implements IPersonalHomepageInfoService {
-    @Autowired
-    private PersonalHomepageInfoMapper personalHomepageInfoMapper;
-
-    @Override
-    public Boolean add(PersonalHomepageInfo personalHomepageInfo) throws ServiceException {
-        Date now = new Date();
-        personalHomepageInfo.setGmtCreate(now);
-        personalHomepageInfo.setGmtUpdate(now);
-        return personalHomepageInfoMapper.insert(personalHomepageInfo) > 0;
-    }
-
-    @Override
-    public Page<PersonalHomepageInfo> list(Long commonId, String companyName, String companyIntroduction, String scopeOfBusiness, String companyAddress, String phone, String portraiture, String postbox, String addressUrl, Date gmtCreate, Date gmtUpdate, Long deleteFlag, Integer page, Integer limit) throws ServiceException {
-        Wrapper<PersonalHomepageInfo> wrapper = new EntityWrapper<PersonalHomepageInfo>();
-        if (!StringUtils.isEmpty(commonId)) {
-            wrapper.eq("common_id", commonId);
-        }
-        if (!StringUtils.isEmpty(companyName)) {
-            wrapper.eq("company_name", companyName);
-        }
-        if (!StringUtils.isEmpty(companyIntroduction)) {
-            wrapper.eq("company_introduction", companyIntroduction);
-        }
-        if (!StringUtils.isEmpty(scopeOfBusiness)) {
-            wrapper.eq("scope_of_business", scopeOfBusiness);
-        }
-        if (!StringUtils.isEmpty(companyAddress)) {
-            wrapper.eq("company_address", companyAddress);
-        }
-        if (!StringUtils.isEmpty(phone)) {
-            wrapper.eq("phone", phone);
-        }
-        if (!StringUtils.isEmpty(portraiture)) {
-            wrapper.eq("portraiture", portraiture);
-        }
-        if (!StringUtils.isEmpty(postbox)) {
-            wrapper.eq("postbox", postbox);
-        }
-        if (!StringUtils.isEmpty(addressUrl)) {
-            wrapper.eq("address_url", addressUrl);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        wrapper.eq("delete_flag", 0);
-        List<PersonalHomepageInfo> list = personalHomepageInfoMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-        Integer count = personalHomepageInfoMapper.selectCount(wrapper);
-        return new Page<PersonalHomepageInfo>(list, page, limit, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt : ids) {
-            PersonalHomepageInfo tmp = personalHomepageInfoMapper.selectById(Long.parseLong(tt));
-            if (tmp != null) {
-                tmp.setDeleteFlag(1l);
-                tmp.setGmtUpdate(new Date());
-                personalHomepageInfoMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(PersonalHomepageInfo personalHomepageInfo) throws ServiceException {
-        Date now = new Date();
-        personalHomepageInfo.setGmtUpdate(now);
-        return personalHomepageInfoMapper.updateById(personalHomepageInfo) > 0;
-    }
-
-    @Override
-    public PersonalHomepageInfo get(Long id) throws ServiceException {
-        return personalHomepageInfoMapper.selectById(id);
-    }
-
-    @Override
-    public String export(Long commonId, String companyName, String companyIntroduction, String scopeOfBusiness, String companyAddress, String phone, String portraiture, String postbox, String addressUrl, Date gmtCreate, Date gmtUpdate, Long deleteFlag, Integer page, Integer limit) throws ServiceException {
-        Wrapper<PersonalHomepageInfo> wrapper = new EntityWrapper<PersonalHomepageInfo>();
-        if (!StringUtils.isEmpty(commonId)) {
-            wrapper.eq("common_id", commonId);
-        }
-        if (!StringUtils.isEmpty(companyName)) {
-            wrapper.eq("company_name", companyName);
-        }
-        if (!StringUtils.isEmpty(companyIntroduction)) {
-            wrapper.eq("company_introduction", companyIntroduction);
-        }
-        if (!StringUtils.isEmpty(scopeOfBusiness)) {
-            wrapper.eq("scope_of_business", scopeOfBusiness);
-        }
-        if (!StringUtils.isEmpty(companyAddress)) {
-            wrapper.eq("company_address", companyAddress);
-        }
-        if (!StringUtils.isEmpty(phone)) {
-            wrapper.eq("phone", phone);
-        }
-        if (!StringUtils.isEmpty(portraiture)) {
-            wrapper.eq("portraiture", portraiture);
-        }
-        if (!StringUtils.isEmpty(postbox)) {
-            wrapper.eq("postbox", postbox);
-        }
-        if (!StringUtils.isEmpty(addressUrl)) {
-            wrapper.eq("address_url", addressUrl);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        List<PersonalHomepageInfo> list = personalHomepageInfoMapper.selectList(wrapper);
-        ExcelUtil<PersonalHomepageInfo> util = new ExcelUtil<PersonalHomepageInfo>(PersonalHomepageInfo.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 138
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/card/impl/SearchRecordsInfoServiceImpl.java

@@ -1,138 +0,0 @@
-package com.iotechn.unimall.admin.api.card.impl;
-
-import java.util.List;
-
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.CollectionUtils;
-import org.springframework.util.StringUtils;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import com.iotechn.unimall.data.mapper.SearchRecordsInfoMapper;
-import com.iotechn.unimall.data.domain.SearchRecordsInfo;
-import com.iotechn.unimall.admin.api.card.ISearchRecordsInfoService;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 搜索记录Service业务层处理
- *
- * @author searchRecordsInfo
- * @date 2023-04-10
- */
-@Service
-public class SearchRecordsInfoServiceImpl implements ISearchRecordsInfoService {
-    @Autowired
-    private SearchRecordsInfoMapper searchRecordsInfoMapper;
-
-    @Override
-    public Boolean add(SearchRecordsInfo searchRecordsInfo) throws ServiceException {
-        Date now = new Date();
-        searchRecordsInfo.setGmtCreate(now);
-        searchRecordsInfo.setGmtUpdate(now);
-        List<SearchRecordsInfo> searchRecordsInfos=searchRecordsInfoMapper.selectList(new EntityWrapper<SearchRecordsInfo>()
-                .eq("common_id",searchRecordsInfo.getCommonId())
-                .eq("function_type",searchRecordsInfo.getFunctionType())
-                .eq("search_content",searchRecordsInfo.getSearchContent())
-                .eq("delete_flag",0));
-        //已有搜索记录不新增
-        if (searchRecordsInfos.size()>0){
-            searchRecordsInfos.get(0).setGmtUpdate(now);
-            return searchRecordsInfoMapper.updateById(searchRecordsInfo) > 0;
-        }
-        else {
-            return searchRecordsInfoMapper.insert(searchRecordsInfo) > 0;
-        }
-    }
-
-    @Override
-    public Page<SearchRecordsInfo> list(Long commonId, String searchContent, String functionType, Date gmtCreate, Date gmtUpdate, Long deleteFlag, Integer page, Integer limit) throws ServiceException {
-        Wrapper<SearchRecordsInfo> wrapper = new EntityWrapper<SearchRecordsInfo>();
-        if (!StringUtils.isEmpty(commonId)) {
-            wrapper.eq("common_id", commonId);
-        }
-        if (!StringUtils.isEmpty(searchContent)) {
-            wrapper.eq("search_content", searchContent);
-        }
-        if (!StringUtils.isEmpty(functionType)) {
-            wrapper.eq("function_type", functionType);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        wrapper.eq("delete_flag", 0);
-        wrapper.orderBy("gmt_update", false);
-        List<SearchRecordsInfo> list = searchRecordsInfoMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-        Integer count = searchRecordsInfoMapper.selectCount(wrapper);
-        return new Page<SearchRecordsInfo>(list, page, limit, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(SearchRecordsInfo searchRecordsInfo) {
-        List<SearchRecordsInfo> searchRecordsInfos=searchRecordsInfoMapper.selectList(new EntityWrapper<SearchRecordsInfo>()
-                .eq("common_id",searchRecordsInfo.getCommonId())
-                .eq("function_type",searchRecordsInfo.getFunctionType())
-                .eq("delete_flag",0));
-        //清空搜索记录
-        if (!CollectionUtils.isEmpty(searchRecordsInfos)){
-            for (SearchRecordsInfo searchRecordsInfo1:searchRecordsInfos){
-                searchRecordsInfo1.setDeleteFlag(1l);
-                searchRecordsInfo1.setGmtUpdate(new Date());
-                searchRecordsInfoMapper.updateById(searchRecordsInfo1);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(SearchRecordsInfo searchRecordsInfo) throws ServiceException {
-        Date now = new Date();
-        searchRecordsInfo.setGmtUpdate(now);
-        return searchRecordsInfoMapper.updateById(searchRecordsInfo) > 0;
-    }
-
-    @Override
-    public SearchRecordsInfo get(Long id) throws ServiceException {
-        return searchRecordsInfoMapper.selectById(id);
-    }
-
-    @Override
-    public String export(Long commonId, String searchContent, String functionType, Date gmtCreate, Date gmtUpdate, Long deleteFlag, Integer page, Integer limit) throws ServiceException {
-        Wrapper<SearchRecordsInfo> wrapper = new EntityWrapper<SearchRecordsInfo>();
-        if (!StringUtils.isEmpty(commonId)) {
-            wrapper.eq("common_id", commonId);
-        }
-        if (!StringUtils.isEmpty(searchContent)) {
-            wrapper.eq("search_content", searchContent);
-        }
-        if (!StringUtils.isEmpty(functionType)) {
-            wrapper.eq("function_type", functionType);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        List<SearchRecordsInfo> list = searchRecordsInfoMapper.selectList(wrapper);
-        ExcelUtil<SearchRecordsInfo> util = new ExcelUtil<SearchRecordsInfo>(SearchRecordsInfo.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 62
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/category/AdminCategoryService.java

@@ -1,62 +0,0 @@
-package com.iotechn.unimall.admin.api.category;
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.annotation.param.Range;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.CategoryDO;
-import com.iotechn.unimall.data.dto.CategoryDTO;
-import com.iotechn.unimall.data.dto.CategoryTreeNodeDTO;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.List;
-
-/**
- * Created by rize on 2019/7/12.
- */
-@HttpOpenApi(group = "admin.category", description = "类目管理服务")
-public interface AdminCategoryService {
-
-    @HttpMethod(description = "获取二级类目树")
-    public List<CategoryTreeNodeDTO> categorySecondLevelTree() throws ServiceException;
-
-    @HttpMethod(description = "获取类目树")
-    public List<CategoryTreeNodeDTO> categoryTree() throws ServiceException;
-
-    @HttpMethod(description = "创建", permission = "operation:category:create", permissionParentName = "商品管理", permissionName = "类目管理")
-    public CategoryDO addCategory(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId,
-            @NotNull @HttpParam(name = "title", type = HttpParamType.COMMON, description = "类目标题") String title,
-            @HttpParam(name = "parentId", type = HttpParamType.COMMON, description = "类目父节点", valueDef = "0") Long parentId,
-            @HttpParam(name = "iconUrl", type = HttpParamType.COMMON, description = "类目图标") String iconUrl,
-            @HttpParam(name = "picUrl", type = HttpParamType.COMMON, description = "类目图片") String picUrl,
-            @HttpParam(name = "level", type = HttpParamType.COMMON, description = "类目等级") Integer level) throws ServiceException;
-
-    @HttpMethod(description = "删除", permission = "operation:category:delete", permissionParentName = "商品管理", permissionName = "类目管理")
-    public boolean deleteCategory(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId,
-            @NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "类目ID") Long id) throws ServiceException;
-
-    @HttpMethod(description = "修改", permission = "operation:category:update", permissionParentName = "商品管理", permissionName = "类目管理")
-    public CategoryTreeNodeDTO updateCategory(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId,
-            @NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "类目ID") Long id,
-            @NotNull @HttpParam(name = "title", type = HttpParamType.COMMON, description = "类目标题") String title,
-            @NotNull @HttpParam(name = "parentId", type = HttpParamType.COMMON, description = "类目父节点") Long parentId,
-            @HttpParam(name = "iconUrl", type = HttpParamType.COMMON, description = "类目图标") String iconUrl,
-            @HttpParam(name = "picUrl", type = HttpParamType.COMMON, description = "类目图片") String picUrl,
-            @HttpParam(name = "level", type = HttpParamType.COMMON, description = "类目等级") Integer level) throws ServiceException;
-
-    @HttpMethod(description = "查询", permission = "operation:category:query", permissionParentName = "商品管理", permissionName = "类目管理")
-    public Page<CategoryTreeNodeDTO> queryCategory(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId,
-            @HttpParam(name = "id", type = HttpParamType.COMMON, description = "类目ID") Long id,
-            @HttpParam(name = "title", type = HttpParamType.COMMON, description = "类目标题") String title,
-            @HttpParam(name = "level", type = HttpParamType.COMMON, description = "类目等级") Integer level,
-            @HttpParam(name = "parentId", type = HttpParamType.COMMON, description = "父类目id") Long parentId,
-            @Range(min = 1) @HttpParam(name = "pageNo", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer pageNo,
-            @Range(min = 1) @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "10") Integer limit) throws ServiceException;
-}

+ 0 - 304
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/category/AdminCategoryServiceImpl.java

@@ -1,304 +0,0 @@
-package com.iotechn.unimall.admin.api.category;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.iotechn.unimall.biz.service.category.CategoryBizService;
-import com.iotechn.unimall.core.exception.*;
-import com.iotechn.unimall.data.component.CacheComponent;
-import com.iotechn.unimall.data.domain.CategoryDO;
-import com.iotechn.unimall.data.domain.SpuDO;
-import com.iotechn.unimall.data.dto.CategoryTreeNodeDTO;
-import com.iotechn.unimall.data.mapper.CategoryMapper;
-import com.iotechn.unimall.data.mapper.SpuMapper;
-import com.iotechn.unimall.data.model.Page;
-import com.iotechn.unimall.plugin.core.inter.IPluginUpdateCategory;
-import com.iotechn.unimall.plugin.core.manager.PluginsManager;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.BeanUtils;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.CollectionUtils;
-
-import java.util.*;
-import java.util.stream.Collectors;
-
-/**
- * Created by rize on 2019/7/12.
- */
-@Service
-public class AdminCategoryServiceImpl implements AdminCategoryService {
-
-    @Autowired
-    private CategoryMapper categoryMapper;
-
-    @Autowired
-    private SpuMapper spuMapper;
-
-    @Autowired
-    private CategoryBizService categoryBizService;
-
-    @Autowired
-    private CacheComponent cacheComponent;
-
-    @Autowired
-    private PluginsManager pluginsManager;
-
-    private static final String CA_CATEGORY_TREE = "CA_CATEGORY_TREE";
-
-    private static final String ADMIN_QUERY_CATEGORY_LIST = "ADMIN_QUERY_CATEGORY_LIST";
-
-    private static final String CA_CATEGORY_SECOND_LEVEL_TREE = "CA_CATEGORY_SECOND_LEVEL_TREE";
-
-    /**
-     * @return
-     * @throws ServiceException
-     */
-
-
-    /*获取两级目录树*/
-    public List<CategoryTreeNodeDTO> categorySecondLevelTree() throws ServiceException {
-        List<CategoryTreeNodeDTO> objList = cacheComponent.getObjList(CA_CATEGORY_SECOND_LEVEL_TREE, CategoryTreeNodeDTO.class);
-        if (objList != null) {
-            return objList;
-        }
-        List<CategoryTreeNodeDTO> list = categoryBizService.categorySecondLevelTree();
-        cacheComponent.putObj(CA_CATEGORY_SECOND_LEVEL_TREE, list, 60 * 60);
-        return list;
-    }
-
-
-    /*获取三级目录树。*/
-    //TODO 做下优化
-    @Override
-    public List<CategoryTreeNodeDTO> categoryTree() throws ServiceException {
-        List<CategoryTreeNodeDTO> objList = cacheComponent.getObjList(CA_CATEGORY_TREE, CategoryTreeNodeDTO.class);
-        if (objList != null) {
-            return objList;
-        }
-        List<CategoryDO> categoryDOS = categoryMapper.selectList(new EntityWrapper<>());
-        List<CategoryTreeNodeDTO> list = categoryDOS.stream().filter((item) -> (item.getParentId().equals(0l))).map(item -> {
-            CategoryTreeNodeDTO dto = new CategoryTreeNodeDTO();
-            dto.setLabel(item.getTitle());
-            dto.setLevel(0);
-            dto.setFullName(dto.getLabel());
-            dto.setValue(item.getId());
-            dto.setChildren(new LinkedList<>());
-            return dto;
-        }).collect(Collectors.toList());
-        list.forEach(item -> {
-            categoryDOS.forEach(categoryDO -> {
-                if (categoryDO.getParentId().equals(item.getValue())) {
-                    CategoryTreeNodeDTO categoryTreeNodeDTO = new CategoryTreeNodeDTO();
-                    categoryTreeNodeDTO.setChildren(new LinkedList<>());
-                    categoryTreeNodeDTO.setValue(categoryDO.getId());
-                    categoryTreeNodeDTO.setLabel(categoryDO.getTitle());
-                    categoryTreeNodeDTO.setLevel(1);
-                    categoryTreeNodeDTO.setParent(item.getValue());
-                    categoryTreeNodeDTO.setFullName(item.getFullName() + "/" + categoryDO.getTitle());
-                    item.getChildren().add(categoryTreeNodeDTO);
-                    categoryDOS.forEach(subCategoryDO -> {
-                        if (subCategoryDO.getParentId().equals(categoryTreeNodeDTO.getValue())) {
-                            CategoryTreeNodeDTO childCategoryNodeDTO = new CategoryTreeNodeDTO();
-                            childCategoryNodeDTO.setLabel(subCategoryDO.getTitle());
-                            childCategoryNodeDTO.setValue(subCategoryDO.getId());
-                            childCategoryNodeDTO.setLevel(2);
-                            childCategoryNodeDTO.setParent(categoryTreeNodeDTO.getValue());
-                            childCategoryNodeDTO.setFullName(categoryTreeNodeDTO.getFullName() + "/" + subCategoryDO.getTitle());
-                            categoryTreeNodeDTO.getChildren().add(childCategoryNodeDTO);
-                        }
-                    });
-                }
-            });
-        });
-        cacheComponent.putObj(CA_CATEGORY_TREE, list, 60 * 60);
-        return list;
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public CategoryDO addCategory(Long adminId, String title, Long parentId, String iconUrl, String picUrl, Integer level) throws ServiceException {
-        CategoryDO parent = null;
-        CategoryDO categoryDO = new CategoryDO();
-        if (!parentId.equals(0l)) {
-            parent = categoryMapper.selectById(parentId);
-            if (parent == null) {
-                throw new AdminServiceException(ExceptionDefinition.PARENT_NODE_INFORMATION_ERROR);
-            }
-            categoryDO.setLevel(parent.getLevel() + 1);
-        } else {
-            categoryDO.setLevel(0);
-        }
-        categoryDO.setParentId(parentId);
-        categoryDO.setIconUrl(iconUrl);
-        categoryDO.setPicUrl(picUrl);
-        categoryDO.setTitle(title);
-        Date now = new Date();
-        categoryDO.setGmtCreate(now);
-        categoryDO.setGmtUpdate(now);
-
-        if (categoryMapper.insert(categoryDO) <= 0) {
-            throw new AdminServiceException(ExceptionDefinition.DATABASE_INSERT_FAILURE);
-        }
-        cacheComponent.del(CA_CATEGORY_TREE);
-        cacheComponent.del(ADMIN_QUERY_CATEGORY_LIST);
-        cacheComponent.del(CA_CATEGORY_SECOND_LEVEL_TREE);
-        cacheComponent.del(CategoryBizService.CA_CATEGORY_ID_HASH);
-        cacheComponent.del(CategoryBizService.CA_CATEGORY_LIST);
-        pluginInvokeUpdateCategory(categoryDO.getId());
-        return categoryDO;
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public boolean deleteCategory(Long adminId, Long id) throws ServiceException {
-        Integer count_category = categoryMapper.selectCount(new EntityWrapper<CategoryDO>().eq("parent_id", id));
-        Integer count_spu = spuMapper.selectCount(new EntityWrapper<SpuDO>().eq("category_id", id));
-
-        if (count_category != 0 || count_spu != 0) {
-            throw new AppServiceException(ExceptionDefinition.CATEGORY_OUGHT_TO_EMPTY);
-        }
-        cacheComponent.del(CA_CATEGORY_TREE);
-        cacheComponent.del(ADMIN_QUERY_CATEGORY_LIST);
-        cacheComponent.del(CA_CATEGORY_SECOND_LEVEL_TREE);
-        cacheComponent.del(CategoryBizService.CA_CATEGORY_ID_HASH);
-        cacheComponent.del(CategoryBizService.CA_CATEGORY_LIST);
-        pluginInvokeUpdateCategory(id);
-        return categoryMapper.deleteById(id) > 0;
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public CategoryTreeNodeDTO updateCategory(Long adminId, Long id, String title, Long parentId, String iconUrl, String picUrl, Integer level) throws ServiceException {
-        CategoryDO categoryDO = new CategoryDO();
-        if (id == null || parentId == null) {
-            throw new AdminServiceException(ExceptionDefinition.CATEGORY_OR_PARENT_NODE_IS_EMPTY);
-        }
-        categoryDO.setId(parentId);
-        CategoryDO categoryParent = categoryMapper.selectOne(categoryDO);
-
-        //传入父节点等于自身抛出异常
-        if (id.equals(parentId)) {
-            throw new AdminServiceException(ExceptionDefinition.PARENT_CAN_NOT_EQUALS_ONESELF);
-        }
-
-        if (categoryParent == null && !parentId.equals(0L)) {
-            throw new AdminServiceException(ExceptionDefinition.NOT_FIND_PARENT_NODE);
-        }
-        if (parentId.equals(0L)) {
-            categoryDO.setLevel(0);
-        } else {
-            categoryDO.setLevel(categoryParent.getLevel() + 1);
-        }
-        categoryDO.setId(id);
-        categoryDO.setGmtUpdate(new Date());
-        categoryDO.setParentId(parentId);
-        categoryDO.setTitle(title);
-        categoryDO.setPicUrl(picUrl);
-        categoryDO.setIconUrl(iconUrl);
-        if (categoryMapper.updateById(categoryDO) <= 0) {
-            throw new AdminServiceException(ExceptionDefinition.CATEGORY_UPDATE_FAILURE);
-        }
-        CategoryTreeNodeDTO categoryTreeNodeDTO = new CategoryTreeNodeDTO();
-        List<CategoryTreeNodeDTO> list = getCategoryList();
-        for (CategoryTreeNodeDTO temp : list) {
-            if (categoryDO.getId().equals(temp.getValue())) {
-                BeanUtils.copyProperties(temp, categoryTreeNodeDTO);
-                break;
-            }
-        }
-        cacheComponent.del(CA_CATEGORY_TREE);
-        cacheComponent.del(ADMIN_QUERY_CATEGORY_LIST);
-        cacheComponent.del(CA_CATEGORY_SECOND_LEVEL_TREE);
-        cacheComponent.del(CategoryBizService.CA_CATEGORY_ID_HASH);
-        cacheComponent.del(CategoryBizService.CA_CATEGORY_LIST);
-        pluginInvokeUpdateCategory(categoryDO.getId());
-        return categoryTreeNodeDTO;
-    }
-
-    //首先的到所有的类目的List<CategoryTreeNodeDTO>,在根据SQL查询得到的数据转化成传往前端的数据
-    @Override
-    public Page<CategoryTreeNodeDTO> queryCategory(Long adminId, Long id, String title, Integer level, Long parentId, Integer pageNo, Integer limit) throws ServiceException {
-        EntityWrapper wrapper = new EntityWrapper();
-        if (id != null) {
-            wrapper.eq("id", id);
-        }
-        if (title != null) {
-            wrapper.like("title", title);
-        }
-        if (level != null) {
-            wrapper.eq("level", level);
-        }
-        if (parentId != null) {
-            wrapper.eq("parent_id", parentId);
-        }
-        wrapper.orderBy("level");
-        Integer count = categoryMapper.selectCount(wrapper);
-
-        List<CategoryDO> categoryDOS = categoryMapper.selectPage(new RowBounds((pageNo - 1) * limit, limit), wrapper);
-        List<CategoryTreeNodeDTO> totalCategory = getCategoryList();
-        List<CategoryTreeNodeDTO> list = categoryDOS.stream().map(item -> {
-            CategoryTreeNodeDTO dto = new CategoryTreeNodeDTO();
-            for (CategoryTreeNodeDTO temp : totalCategory) {
-                if (temp.getValue().equals(item.getId())) {
-                    BeanUtils.copyProperties(temp, dto);
-                    return dto;
-                }
-            }
-            BeanUtils.copyProperties(item, dto);
-            ;
-            return dto;
-        }).collect(Collectors.toList());
-        Page<CategoryTreeNodeDTO> page = new Page<>(list, pageNo, limit, count);
-        return page;
-    }
-
-
-    //TODO 可以做出父节点查询所有子节点
-    //获得所有类目按类目等级排序的类目list,
-    private List<CategoryTreeNodeDTO> getCategoryList() {
-        List<CategoryTreeNodeDTO> objList = cacheComponent.getObjList(ADMIN_QUERY_CATEGORY_LIST, CategoryTreeNodeDTO.class);
-        if (objList != null) {
-            return objList;
-        }
-        EntityWrapper wrapper = new EntityWrapper();
-        wrapper.orderBy("level");
-        List<CategoryDO> categoryDOS = categoryMapper.selectList(wrapper);
-        List<CategoryTreeNodeDTO> list = categoryDOS.stream().map(item -> {
-            CategoryTreeNodeDTO dto = new CategoryTreeNodeDTO();
-            dto.setLabel(item.getTitle());
-            dto.setLevel(item.getLevel());
-            dto.setValue(item.getId());
-            dto.setParent(item.getParentId());
-            dto.setIconUrl(item.getIconUrl());
-            dto.setPicUrl(item.getPicUrl());
-            if (item.getLevel() == 0) {
-                dto.setFullName(dto.getLabel());
-            }
-            return dto;
-        }).collect(Collectors.toList());
-
-        for (CategoryTreeNodeDTO cOne : list) {
-
-            for (CategoryTreeNodeDTO cTwo : list) {
-                if (cOne.getParent().equals(cTwo.getValue())) {
-                    cOne.setFullName(cTwo.getFullName() + "/" + cOne.getLabel());
-                    break;
-                }
-            }
-
-        }
-        cacheComponent.putObj(ADMIN_QUERY_CATEGORY_LIST, list, 60 * 60);
-        return list;
-    }
-
-    private void pluginInvokeUpdateCategory(Long categoryId) {
-        List<IPluginUpdateCategory> plugins = pluginsManager.getPlugins(IPluginUpdateCategory.class);
-        if (!CollectionUtils.isEmpty(plugins)) {
-            for (IPluginUpdateCategory updateGoods : plugins) {
-                updateGoods.invokeCategoryUpdate(categoryId);
-            }
-        }
-    }
-
-
-}

+ 0 - 82
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/coupon/AdminCouponService.java

@@ -1,82 +0,0 @@
-package com.iotechn.unimall.admin.api.coupon;
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.CouponDO;
-import com.iotechn.unimall.data.dto.CouponAdminDTO;
-import com.iotechn.unimall.data.dto.CouponDTO;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-/**
- * Created with IntelliJ IDEA.
- * Description:
- * User: kbq
- * Date: 2019-07-12
- * Time: 下午10:47
- */
-
-@HttpOpenApi(group = "admin.coupon", description = "优惠卷")
-public interface AdminCouponService {
-
-    @HttpMethod(description = "创建", permission = "promote:coupon:create", permissionParentName = "推广管理", permissionName = "优惠管理")
-    public CouponDO addCoupon(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId,
-            @NotNull @HttpParam(name = "title", type = HttpParamType.COMMON, description = "优惠卷标题") String title,
-            @NotNull @HttpParam(name = "type", type = HttpParamType.COMMON, description = "优惠卷类别,如满减") Integer type,
-            @HttpParam(name = "description", type = HttpParamType.COMMON, description = "优惠卷描述") String description,
-            @NotNull @HttpParam(name = "total", type = HttpParamType.COMMON, description = "优惠卷总数") Integer total,
-            @NotNull @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "用户限制领取") Integer limit,
-            @NotNull @HttpParam(name = "discount", type = HttpParamType.COMMON, description = "优惠价格") Integer discount,
-            @NotNull @HttpParam(name = "min", type = HttpParamType.COMMON, description = "满足优惠的最低价格") Integer min,
-            @NotNull @HttpParam(name = "status", type = HttpParamType.COMMON, description = "优惠卷状态") Integer status,
-            @HttpParam(name = "categoryId", type = HttpParamType.COMMON, description = "优惠类别") Long categoryId,
-            @HttpParam(name = "days", type = HttpParamType.COMMON, description = "优惠时长") Integer days,
-            @HttpParam(name = "gmtStart", type = HttpParamType.COMMON, description = "优惠开始时间") Long gmtStart,
-            @HttpParam(name = "gmtEnd", type = HttpParamType.COMMON, description = "优惠结束时间") Long gmtEnd) throws ServiceException;
-
-    @HttpMethod(description = "删除", permission = "promote:coupon:delete", permissionParentName = "推广管理", permissionName = "优惠管理")
-    public Boolean deleteCoupon(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId,
-            @NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "优惠卷ID") Long id) throws ServiceException;
-
-    @HttpMethod(description = "修改", permission = "promote:coupon:update", permissionParentName = "推广管理", permissionName = "优惠管理")
-    public Boolean updateCoupon(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId,
-            @NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "优惠卷ID") Long id,
-            @NotNull @HttpParam(name = "title", type = HttpParamType.COMMON, description = "优惠卷标题") String title,
-            @NotNull @HttpParam(name = "type", type = HttpParamType.COMMON, description = "优惠卷类别,如满减") Integer type,
-            @HttpParam(name = "description", type = HttpParamType.COMMON, description = "优惠卷描述") String description,
-            @NotNull @HttpParam(name = "total", type = HttpParamType.COMMON, description = "优惠卷总数") Integer total,
-            @NotNull @HttpParam(name = "surplus", type = HttpParamType.COMMON, description = "优惠卷剩余") Integer surplus,
-            @NotNull @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "用户限制领取") Integer limit,
-            @NotNull @HttpParam(name = "discount", type = HttpParamType.COMMON, description = "优惠价格") Integer discount,
-            @NotNull @HttpParam(name = "min", type = HttpParamType.COMMON, description = "满足优惠的最低价格") Integer min,
-            @NotNull @HttpParam(name = "status", type = HttpParamType.COMMON, description = "优惠卷状态") Integer status,
-            @HttpParam(name = "categoryId", type = HttpParamType.COMMON, description = "优惠类别") Long categoryId,
-            @HttpParam(name = "days", type = HttpParamType.COMMON, description = "优惠时长") Integer days,
-            @HttpParam(name = "gmtStart", type = HttpParamType.COMMON, description = "优惠开始时间") Date gmtStart,
-            @HttpParam(name = "gmtEnd", type = HttpParamType.COMMON, description = "优惠结束时间") Date gmtEnd) throws ServiceException;
-
-    @HttpMethod(description = "修改", permission = "promote:coupon:update", permissionParentName = "推广管理", permissionName = "优惠管理")
-    public Boolean updateCouponStatus(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId,
-            @NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "优惠卷ID") Long id,
-            @NotNull @HttpParam(name = "status", type = HttpParamType.COMMON, description = "优惠卷状态") Integer status) throws ServiceException;
-
-
-    @HttpMethod(description = "查询", permission = "promote:coupon:query", permissionParentName = "推广管理", permissionName = "优惠管理")
-    public Page<CouponAdminDTO> queryCouponByTitle(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId,
-            @HttpParam(name = "title", type = HttpParamType.COMMON, description = "优惠卷标题") String title,
-            @HttpParam(name = "type", type = HttpParamType.COMMON, description = "优惠卷类型") Integer type,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "优惠卷状态") Integer status,
-            @HttpParam(name = "pageNo", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer pageNo,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "10") Integer limit) throws ServiceException;
-
-}

+ 0 - 123
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/coupon/AdminCouponServiceImpl.java

@@ -1,123 +0,0 @@
-package com.iotechn.unimall.admin.api.coupon;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.iotechn.unimall.core.exception.AdminServiceException;
-import com.iotechn.unimall.core.exception.ExceptionDefinition;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.CouponDO;
-import com.iotechn.unimall.data.dto.CouponAdminDTO;
-import com.iotechn.unimall.data.mapper.CouponMapper;
-import com.iotechn.unimall.data.mapper.UserCouponMapper;
-import com.iotechn.unimall.data.model.Page;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.CollectionUtils;
-import org.springframework.util.StringUtils;
-
-import java.util.Date;
-import java.util.List;
-
-/**
- * Created with IntelliJ IDEA.
- * Description:
- * User: kbq
- * Date: 2019-07-12
- * Time: 下午11:26
- */
-@Service
-public class AdminCouponServiceImpl implements AdminCouponService {
-
-    @Autowired
-    private CouponMapper couponMapper;
-
-    @Autowired
-    private UserCouponMapper userCouponMapper;
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public CouponDO addCoupon(Long adminId, String title, Integer type, String description, Integer total, Integer limit, Integer discount, Integer min, Integer status, Long categoryId, Integer days, Long gmtStart, Long gmtEnd) throws ServiceException {
-
-        Date start = null;
-        Date end = null;
-        if (gmtEnd != null && gmtStart != null) {
-            start = new Date(gmtStart);
-            end = new Date(gmtEnd);
-        }
-
-        CouponDO couponDO = new CouponDO(title, type, description, total, total, limit, discount, min, status, categoryId, days, start, end);
-
-        Date now = new Date();
-        couponDO.setGmtCreate(now);
-        couponDO.setGmtUpdate(now);
-        if (couponMapper.insert(couponDO) > 0) {
-            return couponDO;
-        }
-        throw new AdminServiceException(ExceptionDefinition.ADMIN_UNKNOWN_EXCEPTION);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean deleteCoupon(Long adminId, Long id) throws ServiceException {
-        EntityWrapper wrapperC = new EntityWrapper();
-        wrapperC.eq("id", id);
-        if (couponMapper.delete(wrapperC) <= 0) {
-            throw new AdminServiceException(ExceptionDefinition.ADMIN_UNKNOWN_EXCEPTION);
-        }
-        EntityWrapper wrapperUC = new EntityWrapper();
-        wrapperUC.eq("coupon_id", id);
-        userCouponMapper.delete(wrapperUC);
-        return true;
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean updateCoupon(Long adminId, Long id, String title, Integer type, String description, Integer total, Integer surplus, Integer limit, Integer discount, Integer min, Integer status, Long categoryId, Integer days, Date gmtStart, Date gmtEnd) throws ServiceException {
-        CouponDO couponDO = new CouponDO(title, type, description, total, surplus, limit, discount, min, status, categoryId, days, gmtStart, gmtEnd);
-        couponDO.setId(id);
-        List<CouponDO> couponDOList = couponMapper.selectList(new EntityWrapper<CouponDO>().eq("id", id));
-        if (CollectionUtils.isEmpty(couponDOList)) {
-            throw new AdminServiceException(ExceptionDefinition.COUPON_NOT_EXIST);
-        }
-        Date now = new Date();
-        couponDO.setGmtCreate(couponDOList.get(0).getGmtCreate());
-        couponDO.setGmtUpdate(now);
-        return couponMapper.updateAllColumnById(couponDO) > 0;
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean updateCouponStatus(Long adminId, Long id, Integer status) throws ServiceException {
-        CouponDO couponDO = new CouponDO();
-        couponDO.setId(id);
-        couponDO.setStatus(status);
-        couponDO.setGmtUpdate(new Date());
-        return couponMapper.updateById(couponDO) > 0;
-    }
-
-    @Override
-    public Page<CouponAdminDTO> queryCouponByTitle(Long adminId, String title, Integer type, Integer status, Integer pageNo, Integer limit) throws ServiceException {
-        EntityWrapper wrapper = new EntityWrapper();
-        Date now = new Date();
-        if (!StringUtils.isEmpty(title)) {
-            wrapper.like("title", title);
-        }
-        if (type != null) {
-            wrapper.eq("type", type);
-        }
-        if (status != null) {
-            if (status >= 0 && status < 2) {
-                wrapper.eq("status", status);
-                wrapper.andNew().gt("gmt_end", now).or().isNotNull("days"); //coupon -> conpon.gt("gmt_end", now).or().isNotNull("days")
-            } else if (status < 0) {
-                wrapper.lt("gmt_end", now);
-            } else {
-                throw new AdminServiceException(ExceptionDefinition.COUPON_CHECK_DATA_FAILED);
-            }
-        }
-        Integer count = couponMapper.selectCount(wrapper);
-        List<CouponAdminDTO> couponDTOList = couponMapper.getAdminCouponList(title, type, status, now, (pageNo - 1) * limit, limit);
-        Page<CouponAdminDTO> page = new Page<CouponAdminDTO>(couponDTOList, pageNo, limit, count);
-        return page;
-    }
-}

+ 0 - 20
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/dashboard/DashboardService.java

@@ -1,20 +0,0 @@
-package com.iotechn.unimall.admin.api.dashboard;
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-
-/**
- * Created by rize on 2019/7/15.
- */
-@HttpOpenApi(group = "admin.dashboard" , description = "首页数据服务")
-public interface DashboardService {
-
-    @HttpMethod(description = "聚合数据")
-    public Object integral(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员Id") Long adminId) throws ServiceException;
-
-}

+ 0 - 86
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/dashboard/DashboardServiceImpl.java

@@ -1,86 +0,0 @@
-package com.iotechn.unimall.admin.api.dashboard;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.OrderDO;
-import com.iotechn.unimall.data.domain.SpuDO;
-import com.iotechn.unimall.data.dto.DashboardIntegralDTO;
-import com.iotechn.unimall.data.enums.OrderStatusType;
-import com.iotechn.unimall.data.mapper.OrderMapper;
-import com.iotechn.unimall.data.mapper.SpuMapper;
-import com.iotechn.unimall.data.model.KVModel;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-
-import java.text.SimpleDateFormat;
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.LinkedList;
-import java.util.List;
-
-/**
- * Created by rize on 2019/7/15.
- */
-@Service
-public class DashboardServiceImpl implements DashboardService {
-
-    @Autowired
-    private OrderMapper orderMapper;
-
-    @Autowired
-    private SpuMapper spuMapper;
-
-    @Override
-    public Object integral(Long adminId) throws ServiceException {
-        DashboardIntegralDTO dto = new DashboardIntegralDTO();
-        Integer orderWaitStock = orderMapper.selectCount(new EntityWrapper<OrderDO>().eq("status", OrderStatusType.WAIT_STOCK.getCode()));
-        Integer spuCount = spuMapper.selectCount(new EntityWrapper<SpuDO>());
-        List<KVModel<String, Long>> area = orderMapper.selectAreaStatistics();
-        List<KVModel<String, Long>> channel = orderMapper.selectChannelStatistics();
-        dto.setArea(area);
-        dto.setChannel(channel);
-        dto.setWaitStockCount(orderWaitStock);
-        dto.setGoodsCount(spuCount);
-        Integer days = 7;
-        SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd 00:00:00");
-        String startDay = sdf.format(new Date(System.currentTimeMillis() - 1000l * 60 * 60 * 24 * days));
-        List<KVModel<String, Long>> orderCountKVList = orderMapper.selectOrderCountStatistics(startDay);
-        List<KVModel<String, Long>> orderSumKVList = orderMapper.selectOrderSumStatistics(startDay);
-        SimpleDateFormat sdfDay = new SimpleDateFormat("yyyy-MM-dd");
-        List<Object[]> orderCount = new LinkedList<>();
-        Object[] orderCountNameArray = new Object[days];
-        Object[] orderCountValueArray = new Object[days];
-        orderCount.add(orderCountNameArray);
-        orderCount.add(orderCountValueArray);
-        dto.setDaysOrder(orderCount);
-        List<Object[]> orderSum = new LinkedList<>();
-        Object[] orderSumNameArray = new Object[days];
-        Object[] orderSumValueArray = new Object[days];
-        orderSum.add(orderSumNameArray);
-        orderSum.add(orderSumValueArray);
-        dto.setDaysSum(orderSum);
-        //这里是在补全 group by 为 0 的情况
-        for (int i = 0; i < days; i++) {
-            Date date = new Date(System.currentTimeMillis() - 1000l * 60 * 60 * 24 * i);
-            String key = sdfDay.format(date);
-            int i1 = orderCountKVList.indexOf(new KVModel<>(key, null));
-            if (i1 >= 0) {
-                orderCountNameArray[days - i - 1] = key;
-                orderCountValueArray[days - i - 1] = orderCountKVList.get(i1).getValue();
-            } else {
-                orderCountNameArray[days - i - 1] = key;
-                orderCountValueArray[days - i - 1] = 0;
-            }
-
-            int i2 = orderSumKVList.indexOf(new KVModel<>(key, null));
-            if (i2 >= 0) {
-                orderSumNameArray[days - i - 1] = key;
-                orderSumValueArray[days - i - 1] = orderSumKVList.get(i2).getValue();
-            } else {
-                orderSumNameArray[days - i - 1] = key;
-                orderSumValueArray[days - i - 1] = 0;
-            }
-        }
-        return dto;
-    }
-}

+ 0 - 62
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/freight/AdminFreightTemplateService.java

@@ -1,62 +0,0 @@
-package com.iotechn.unimall.admin.api.freight;
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.annotation.param.Range;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.FreightTemplateCarriageDO;
-import com.iotechn.unimall.data.dto.freight.FreightTemplateDTO;
-
-import java.util.List;
-
-/**
- * Created with IntelliJ IDEA.
- * Description:
- * User: kbq
- * Date: 2019-07-07
- * Time: 下午3:37
- */
-@HttpOpenApi(group = "admin.freight", description = "运费模板")
-public interface AdminFreightTemplateService {
-
-    @HttpMethod(description = "创建", permission = "operation:freight:create", permissionParentName = "运营管理", permissionName = "运费模板管理")
-    public boolean addFreightTemplate(
-            @NotNull @HttpParam(name = "templateName", type = HttpParamType.COMMON, description = "模板名称") String templateName,
-            @HttpParam(name = "spuLocation", type = HttpParamType.COMMON, description = "宝贝地址") String spuLocation,
-            @NotNull @HttpParam(name = "deliveryDeadline", type = HttpParamType.COMMON, description = "发货期限") Integer deliveryDeadline,
-            @NotNull @HttpParam(name = "defaultFreePrice", type = HttpParamType.COMMON, description = "默认满价包邮系列") Integer defaultFreePrice,
-            @NotNull @HttpParam(name = "defaultFirstNum", type = HttpParamType.COMMON, description = "默认首费") Integer defaultFirstNum,
-            @NotNull @Range(min = 1) @HttpParam(name = "defaultFirstPrice", type = HttpParamType.COMMON, description = "默认首件数量") Integer defaultFirstPrice,
-            @NotNull @HttpParam(name = "defaultContinueNum", type = HttpParamType.COMMON, description = "默认续费") Integer defaultContinueNum,
-            @NotNull @Range(min = 1) @HttpParam(name = "defaultContinuePrice", type = HttpParamType.COMMON, description = "默认续件数量") Integer defaultContinuePrice,
-            @HttpParam(name = "freightTemplateCarriageDOList", type = HttpParamType.COMMON, description = "特殊运费区") List freightTemplateCarriageDOList,
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId
-    ) throws ServiceException;
-
-    @HttpMethod(description = "删除", permission = "operation:freight:delete", permissionParentName = "运营管理", permissionName = "运费模板管理")
-    public boolean deleteFreightTemplate(
-            @NotNull @HttpParam(name = "templateId", type = HttpParamType.COMMON, description = "模板ID") Long templateId,
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "更新", permission = "operation:freight:update", permissionParentName = "运营管理", permissionName = "运费模板管理")
-    public boolean updateFreightTemplate(
-            @NotNull @HttpParam(name = "templateId", type = HttpParamType.COMMON, description = "模板名称") Long templateId,
-            @NotNull @HttpParam(name = "templateName", type = HttpParamType.COMMON, description = "模板名称") String templateName,
-            @HttpParam(name = "spuLocation", type = HttpParamType.COMMON, description = "宝贝地址") String spuLocation,
-            @NotNull @HttpParam(name = "deliveryDeadline", type = HttpParamType.COMMON, description = "发货期限") Integer deliveryDeadline,
-            @NotNull @HttpParam(name = "defaultFreePrice", type = HttpParamType.COMMON, description = "默认满价包邮系列") Integer defaultFreePrice,
-            @NotNull @Range(min = 1) @HttpParam(name = "defaultFirstNum", type = HttpParamType.COMMON, description = "默认首费") Integer defaultFirstNum,
-            @NotNull @Range(min = 0) @HttpParam(name = "defaultFirstPrice", type = HttpParamType.COMMON, description = "默认首件数量") Integer defaultFirstPrice,
-            @NotNull @Range(min = 1) @HttpParam(name = "defaultContinueNum", type = HttpParamType.COMMON, description = "默认续费") Integer defaultContinueNum,
-            @NotNull @Range(min = 0) @HttpParam(name = "defaultContinuePrice", type = HttpParamType.COMMON, description = "默认续件数量") Integer defaultContinuePrice,
-            @HttpParam(name = "freightTemplateCarriageDOList", type = HttpParamType.COMMON, description = "特殊运费区") List templateCarriageDOList,
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "查询", permission = "operation:freight:query", permissionParentName = "运营管理", permissionName = "运费模板管理")
-    public List<FreightTemplateDTO> getAllFreightTemplate(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId) throws ServiceException;
-
-}

+ 0 - 147
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/freight/AdminFreightTemplateServiceImpl.java

@@ -1,147 +0,0 @@
-package com.iotechn.unimall.admin.api.freight;
-
-import com.alibaba.fastjson.JSON;
-import com.alibaba.fastjson.JSONObject;
-import com.alibaba.fastjson.TypeReference;
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.iotechn.unimall.biz.service.goods.GoodsBizService;
-import com.iotechn.unimall.core.exception.AdminServiceException;
-import com.iotechn.unimall.core.exception.ExceptionDefinition;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.component.CacheComponent;
-import com.iotechn.unimall.data.domain.FreightTemplateCarriageDO;
-import com.iotechn.unimall.data.domain.FreightTemplateDO;
-import com.iotechn.unimall.data.domain.SpuDO;
-import com.iotechn.unimall.data.dto.freight.FreightTemplateDTO;
-import com.iotechn.unimall.data.mapper.FreightTemplateCarriageMapper;
-import com.iotechn.unimall.data.mapper.FreightTemplateMapper;
-import com.iotechn.unimall.data.mapper.SpuMapper;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.CollectionUtils;
-
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.List;
-import java.util.stream.Collectors;
-
-/**
- * Created with IntelliJ IDEA.
- * Description:
- * User: kbq
- * Date: 2019-07-07
- * Time: 下午4:25
- */
-@Service
-public class AdminFreightTemplateServiceImpl implements AdminFreightTemplateService {
-
-    @Autowired
-    private FreightTemplateMapper freightTemplateMapper;
-
-    @Autowired
-    private FreightTemplateCarriageMapper freightTemplateCarriageMapper;
-
-    @Autowired
-    private SpuMapper spuMapper;
-
-    @Autowired
-    private CacheComponent cacheComponent;
-
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public boolean addFreightTemplate(String templateName, String spuLocation, Integer deliveryDeadline, Integer defaultFreePrice, Integer defaultFirstNum, Integer defaultFirstPrice, Integer defaultContinueNum, Integer defaultContinuePrice, List freightTemplateCarriageDOList, Long adminId) throws ServiceException {
-        Date now = new Date();
-        FreightTemplateDO freightTemplateDO = new FreightTemplateDO(templateName, spuLocation, deliveryDeadline, defaultFreePrice, defaultFirstNum, defaultFirstPrice, defaultContinueNum, defaultContinuePrice);
-        freightTemplateDO.setGmtCreate(now);
-        freightTemplateDO.setGmtUpdate(now);
-        int judgeSQL = freightTemplateMapper.insert(freightTemplateDO); //插入模板主表
-        if (judgeSQL <= 0) {
-            throw new AdminServiceException(ExceptionDefinition.FREIGHT_TEMPLATE_INSERT_FAILED);
-        }
-        if (CollectionUtils.isEmpty(freightTemplateCarriageDOList)) {
-            return true;
-        }
-        List<FreightTemplateCarriageDO> collect = (List<FreightTemplateCarriageDO>) freightTemplateCarriageDOList.stream().map(item -> {
-            FreightTemplateCarriageDO t = JSONObject.toJavaObject((JSON) item, FreightTemplateCarriageDO.class);
-            return t;
-        }).collect(Collectors.toList());
-        insertFreightTemplateCarriage(freightTemplateDO, collect, now);
-        return true;
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public boolean deleteFreightTemplate(Long templateId, Long adminId) throws ServiceException {
-        if (spuMapper.selectCount(new EntityWrapper<SpuDO>().eq("freight_template_id", templateId)) > 0) {
-            throw new AdminServiceException(ExceptionDefinition.FREIGHT_SPU_QUERY_HAS);
-        }
-        if (freightTemplateMapper.delete(new EntityWrapper<FreightTemplateDO>().eq("id", templateId)) <= 0) {
-            throw new AdminServiceException(ExceptionDefinition.FREIGHT_TEMPLATE_DELETE_FAILED);
-        }
-        if (freightTemplateCarriageMapper.delete(
-                new EntityWrapper<FreightTemplateCarriageDO>()
-                        .eq("template_id", templateId)) > 0) {
-            cacheComponent.delPrefixKey(GoodsBizService.CA_SPU_PREFIX);
-            return true;
-        }
-        throw new AdminServiceException(ExceptionDefinition.FREIGHT_TEMPLATE_UPDATE_FAILED);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public boolean updateFreightTemplate(Long templateId, String templateName, String spuLocation, Integer deliveryDeadline, Integer defaultFreePrice, Integer defaultFirstNum, Integer defaultFirstPrice, Integer defaultContinueNum, Integer defaultContinuePrice, List freightTemplateCarriageDOList, Long adminId) throws ServiceException {
-        Date now = new Date();
-        FreightTemplateDO freightTemplateDO = new FreightTemplateDO(templateName, spuLocation, deliveryDeadline, defaultFreePrice, defaultFirstNum, defaultFirstPrice, defaultContinueNum, defaultContinuePrice);
-        freightTemplateDO.setId(templateId);
-        freightTemplateDO.setGmtUpdate(now);
-        if (freightTemplateMapper.updateById(freightTemplateDO) <= 0) {    //如果主表修改失败
-            throw new AdminServiceException(ExceptionDefinition.FREIGHT_TEMPLATE_UPDATE_FAILED);
-        }
-        freightTemplateCarriageMapper.delete(new EntityWrapper<FreightTemplateCarriageDO>().eq("template_id", templateId));
-        if (CollectionUtils.isEmpty(freightTemplateCarriageDOList)) {
-            return true;
-        }
-        List<FreightTemplateCarriageDO> collect = (List<FreightTemplateCarriageDO>) freightTemplateCarriageDOList.stream().map(item -> {
-            FreightTemplateCarriageDO t = JSONObject.toJavaObject((JSON) item, FreightTemplateCarriageDO.class);
-            return t;
-        }).collect(Collectors.toList());
-        insertFreightTemplateCarriage(freightTemplateDO, collect, now);
-        cacheComponent.delPrefixKey(GoodsBizService.CA_SPU_PREFIX);
-        return true;
-    }
-
-    private void insertFreightTemplateCarriage(FreightTemplateDO freightTemplateDO, List<FreightTemplateCarriageDO> freightTemplateCarriageDOList, Date now) throws ServiceException {
-        //表中设定可默认值,所以就不检查是否为空
-        for (FreightTemplateCarriageDO freightTemplateCarriageDO : freightTemplateCarriageDOList) {
-            freightTemplateCarriageDO.setTemplateId(freightTemplateDO.getId());
-            freightTemplateCarriageDO.setGmtCreate(now);
-            freightTemplateCarriageDO.setGmtUpdate(now);
-            Integer judgeSQL = freightTemplateCarriageMapper.insert(freightTemplateCarriageDO);
-            if (judgeSQL <= 0) {
-                throw new AdminServiceException(ExceptionDefinition.FREIGHT_CARRIAGE_INSERT_FAILED);
-            }
-        }
-    }
-
-    @Override
-    public List<FreightTemplateDTO> getAllFreightTemplate(Long adminId) throws ServiceException {
-        List<FreightTemplateDO> freightTemplateDOList = freightTemplateMapper.selectList(null); //查出主表所有数据
-        List<FreightTemplateDTO> freightTemplateDTOList = new ArrayList<>();
-        if (freightTemplateDOList == null || freightTemplateDOList.size() == 0) { //如果主表没有记录
-            return freightTemplateDTOList;
-        }
-        for (FreightTemplateDO freightTemplateDO : freightTemplateDOList) {  //查出副表中,主表每条数据对应的数据
-            FreightTemplateDTO freightTemplateDTO = new FreightTemplateDTO();
-            List<FreightTemplateCarriageDO> freightTemplateCarriageDOList = freightTemplateCarriageMapper.selectList(new EntityWrapper<FreightTemplateCarriageDO>()
-                    .eq("template_id", freightTemplateDO.getId()));
-            freightTemplateDTO.setFreightTemplateDO(freightTemplateDO);
-            freightTemplateDTO.setFreightTemplateCarriageDOList(freightTemplateCarriageDOList);
-            freightTemplateDTOList.add(freightTemplateDTO);
-        }
-        return freightTemplateDTOList;
-    }
-
-
-}

+ 0 - 64
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/goods/AdminGoodsService.java

@@ -1,64 +0,0 @@
-package com.iotechn.unimall.admin.api.goods;
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.dto.goods.SpuDTO;
-import com.iotechn.unimall.data.dto.goods.SpuTreeNodeDTO;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.List;
-
-/**
- * Created by rize on 2019/7/11.
- */
-@HttpOpenApi(group = "admin.goods", description = "管理员商品服务")
-public interface AdminGoodsService {
-
-    @HttpMethod(description = "获取SPU树")
-    public List<SpuTreeNodeDTO> getSpuBigTree(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员Id") Long adminId) throws ServiceException;
-
-
-    @HttpMethod(description = "创建", permission = "operation:goods:create", permissionParentName = "商品管理", permissionName = "商品管理")
-    public String create(
-            @NotNull @HttpParam(name = "spuDTO", type = HttpParamType.COMMON, description = "商品JSON数据") SpuDTO spuDTO,
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId) throws ServiceException;
-
-
-    @HttpMethod(description = "编辑", permission = "operation:goods:edit", permissionParentName = "商品管理", permissionName = "商品管理")
-    public String edit(
-            @NotNull @HttpParam(name = "spuDTO", type = HttpParamType.COMMON, description = "商品JSON数据") SpuDTO spuDTO,
-            @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "列表", permission = "operation:goods:list", permissionParentName = "商品管理", permissionName = "商品管理")
-    public Page<SpuDTO> list(
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit,
-            @HttpParam(name = "categoryId", type = HttpParamType.COMMON, description = "搜索分类") Long categoryId,
-            @HttpParam(name = "title", type = HttpParamType.COMMON, description = "搜索标题") String title,
-            @HttpParam(name = "barcode", type = HttpParamType.COMMON, description = "商品条形码") String barcode,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "商品状态") Integer status,
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员Id") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "详情", permission = "operation:goods:detail", permissionParentName = "商品管理", permissionName = "商品管理")
-    public SpuDTO detail(
-            @NotNull @HttpParam(name = "spuId", type = HttpParamType.COMMON, description = "商品Id") Long spuId,
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员Id") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "上下架", permission = "operation:goods:edit", permissionParentName = "商品管理", permissionName = "商品管理")
-    public SpuDTO freezeOrActivation(
-            @NotNull @HttpParam(name = "spuId", type = HttpParamType.COMMON, description = "商品Id") Long spuId,
-            @NotNull @HttpParam(name = "status", type = HttpParamType.COMMON, description = "商品想要变为的状态") Integer status,
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员Id") Long adminId) throws ServiceException;
-
-
-    @HttpMethod(description = "删除", permission = "operation:goods:delete", permissionParentName = "商品管理", permissionName = "商品管理")
-    public String delete(
-            @NotNull @HttpParam(name = "spuId", type = HttpParamType.COMMON, description = "商品Id") Long spuId,
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员Id") Long adminId) throws ServiceException;
-
-}

+ 0 - 414
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/goods/AdminGoodsServiceImpl.java

@@ -1,414 +0,0 @@
-package com.iotechn.unimall.admin.api.goods;
-
-import com.baomidou.mybatisplus.entity.Column;
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.biz.service.goods.GoodsBizService;
-import com.iotechn.unimall.core.Const;
-import com.iotechn.unimall.core.exception.AdminServiceException;
-import com.iotechn.unimall.core.exception.ExceptionDefinition;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.component.CacheComponent;
-import com.iotechn.unimall.data.domain.*;
-import com.iotechn.unimall.data.dto.goods.SpuDTO;
-import com.iotechn.unimall.data.dto.goods.SpuTreeNodeDTO;
-import com.iotechn.unimall.data.enums.BizType;
-import com.iotechn.unimall.data.enums.SpuStatusType;
-import com.iotechn.unimall.data.mapper.*;
-import com.iotechn.unimall.data.model.Page;
-import com.iotechn.unimall.plugin.core.inter.IPluginUpdateGoods;
-import com.iotechn.unimall.plugin.core.manager.PluginsManager;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.BeanUtils;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.CollectionUtils;
-import org.springframework.util.StringUtils;
-
-import java.util.*;
-import java.util.stream.Collectors;
-
-/**
- * Created by rize on 2019/7/11.
- */
-@Service
-public class AdminGoodsServiceImpl implements AdminGoodsService {
-
-    @Autowired
-    private CategoryMapper categoryMapper;
-
-    @Autowired
-    private SpuMapper spuMapper;
-
-    @Autowired
-    private SkuMapper skuMapper;
-
-    @Autowired
-    private SpuAttributeMapper spuAttributeMapper;
-
-    @Autowired
-    private ImgMapper imgMapper;
-
-    @Autowired
-    private CartMapper cartMapper;
-
-    @Autowired
-    private GoodsBizService goodsBizService;
-
-    @Autowired
-    private PluginsManager pluginsManager;
-
-    @Autowired
-    private CacheComponent cacheComponent;
-
-    private static final Column[] spuBaseColumns = {
-            Column.create().column("id"),
-            Column.create().column("original_price").as("originalPrice"),
-            Column.create().column("price"),
-            Column.create().column("vip_price").as("vipPrice"),
-            Column.create().column("title"),
-            Column.create().column("sales"),
-            Column.create().column("img"),
-            Column.create().column("description"),
-            Column.create().column("category_id").as("categoryId"),
-            Column.create().column("freight_template_id").as("freightTemplateId"),
-            Column.create().column("unit"),
-            Column.create().column("status")};
-
-    /**
-     * 后台低频接口, 无需缓存
-     * @return
-     * @throws ServiceException
-     */
-    public List<SpuTreeNodeDTO> getSpuBigTree(Long adminId) throws  ServiceException{
-        List<CategoryDO> categoryDOS = categoryMapper.selectList(new EntityWrapper<CategoryDO>().orderBy("level"));
-        List<SpuDO> spuDOS = spuMapper.getSpuTitleAll();
-        List<SpuTreeNodeDTO> list = new ArrayList<>();
-        Integer recordLevelOne = 0;
-        Integer recordLevelTwo = 0;
-        for (int i = 0; i < categoryDOS.size(); i++) {
-            if(i != 0 && categoryDOS.get(i-1).getLevel().equals(0) && categoryDOS.get(i).getLevel().equals(1)){
-                recordLevelOne = i;
-            }
-            if(i != 0 && categoryDOS.get(i-1).getLevel().equals(1) && categoryDOS.get(i).getLevel().equals(2)){
-                recordLevelTwo = i;
-                break;
-            }
-        }
-
-        for (int i = 0; i < recordLevelOne; i++) {
-            CategoryDO categoryOnI = categoryDOS.get(i);    //一级类目
-            SpuTreeNodeDTO dtoOnI = new SpuTreeNodeDTO();
-            dtoOnI.setLabel(categoryOnI.getTitle());
-            dtoOnI.setValue("C_" + categoryOnI.getId());
-            dtoOnI.setId(categoryOnI.getId());
-            dtoOnI.setChildren(new LinkedList<>());
-            for (int j = recordLevelOne; j < recordLevelTwo; j++) {
-                CategoryDO categoryOnJ = categoryDOS.get(j);    //二级类目
-                if(!categoryOnJ.getParentId().equals(dtoOnI.getId())){
-                    continue;
-                }
-
-                SpuTreeNodeDTO dtoOnJ = new SpuTreeNodeDTO();
-                dtoOnJ.setLabel(categoryOnJ.getTitle());
-                dtoOnJ.setValue("C_" + categoryOnJ.getId());
-                dtoOnJ.setId(categoryOnJ.getId());
-                dtoOnJ.setChildren(new LinkedList<>());
-                
-                for (int p = recordLevelTwo; p <categoryDOS.size() ; p++) {
-                    CategoryDO categoryOnP = categoryDOS.get(p);    //三级类目
-                    if(!categoryOnP.getParentId().equals(dtoOnJ.getId())){
-                        continue;
-                    }
-
-                    SpuTreeNodeDTO dtoOnP = new SpuTreeNodeDTO();
-                    dtoOnP.setLabel(categoryOnP.getTitle());
-                    dtoOnP.setValue("C_" + categoryOnP.getId());
-                    dtoOnP.setId(categoryOnP.getId());
-                    dtoOnP.setChildren(new LinkedList<>());
-
-                    for (int k = 0; k < spuDOS.size(); k++) {
-                        if(k != 0 && spuDOS.get(k-1).getCategoryId().equals(dtoOnP.getId()) && !spuDOS.get(k).getCategoryId().equals(dtoOnP.getId())){
-                            break;
-                        }
-                        SpuDO spuDO = spuDOS.get(k);        //商品
-                        if(spuDO.getCategoryId().equals(dtoOnP.getId())){
-                            SpuTreeNodeDTO dtoOnK = new SpuTreeNodeDTO();
-                            dtoOnK.setLabel(spuDO.getTitle());
-                            dtoOnK.setValue("G_" + spuDO.getId());
-                            dtoOnK.setId(spuDO.getId());
-                            dtoOnK.setChildren(new LinkedList<>());
-                            dtoOnP.getChildren().add(dtoOnK);
-                        }
-                    }
-                    dtoOnJ.getChildren().add(dtoOnP);
-                }
-                dtoOnI.getChildren().add(dtoOnJ);
-            }
-            list.add(dtoOnI);
-        }
-        return list;
-    }
-
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public String create(SpuDTO spuDTO, Long adminId) throws ServiceException {
-        //参数校验
-        if (CollectionUtils.isEmpty(spuDTO.getSkuList())) {
-            throw new AdminServiceException(ExceptionDefinition.GOODS_SKU_LIST_EMPTY);
-        }
-        if (spuDTO.getId() != null) {
-            throw new AdminServiceException(ExceptionDefinition.GOODS_CREATE_HAS_ID);
-        }
-        if (spuDTO.getOriginalPrice() < spuDTO.getPrice() || spuDTO.getPrice() < spuDTO.getVipPrice() || spuDTO.getOriginalPrice() < spuDTO.getVipPrice()) {
-            throw new AdminServiceException(ExceptionDefinition.GOODS_PRICE_CHECKED_FAILED);
-        }
-        //校验Sku是否重复
-        List<String> barCodes = spuDTO.getSkuList().stream().map(item -> item.getBarCode()).collect(Collectors.toList());
-        List<SkuDO> existSkuDO = skuMapper.selectList(new EntityWrapper<SkuDO>().in("bar_code", barCodes));
-        if (!CollectionUtils.isEmpty(existSkuDO)) {
-            String spuIds = existSkuDO.stream().map(item -> item.getSpuId().toString()).collect(Collectors.joining(","));
-            String skuIds = existSkuDO.stream().map(item -> item.getBarCode()).collect(Collectors.joining(","));
-            throw new AdminServiceException(ExceptionDefinition
-                    .buildVariableException(ExceptionDefinition.GOODS_CREATE_BARCODE_REPEAT, spuIds, skuIds));
-        }
-        Date now = new Date();
-        SpuDO spuDO = new SpuDO();
-        BeanUtils.copyProperties(spuDTO, spuDO);
-        spuDO.setGmtUpdate(now);
-        spuDO.setGmtCreate(now);
-        spuDO.setSales(0);
-        spuMapper.insert(spuDO);
-        spuDTO.setId(spuDO.getId());
-        //插入SKU表
-        for (SkuDO skuDO : spuDTO.getSkuList()) {
-            if (skuDO.getOriginalPrice() < skuDO.getPrice() || skuDO.getPrice() < skuDO.getVipPrice() || skuDO.getOriginalPrice() < skuDO.getVipPrice()) {
-                throw new AdminServiceException(ExceptionDefinition.GOODS_PRICE_CHECKED_FAILED);
-            }
-            skuDO.setSpuId(spuDO.getId());
-            skuDO.setGmtUpdate(now);
-            skuDO.setGmtCreate(now);
-            skuDO.setFreezeStock(0);
-            skuMapper.insert(skuDO);
-        }
-        //插入spuAttr
-        insertSpuAttribute(spuDTO, now);
-        //插入IMG
-        insertSpuImg(spuDTO, spuDO.getId(), now);
-        goodsBizService.clearGoodsCache(spuDO.getId());
-        pluginUpdateInvoke(spuDO.getId());
-
-        cacheComponent.delPrefixKey(GoodsBizService.CA_SPU_PAGE_PREFIX);
-        return "ok";
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public String edit(SpuDTO spuDTO, Long adminId) throws ServiceException {
-        if (spuDTO.getId() == null) {
-            throw new AdminServiceException(ExceptionDefinition.PARAM_CHECK_FAILED);
-        }
-        if (CollectionUtils.isEmpty(spuDTO.getSkuList())) {
-            throw new AdminServiceException(ExceptionDefinition.GOODS_SKU_LIST_EMPTY);
-        }
-        if (spuDTO.getOriginalPrice() < spuDTO.getPrice() || spuDTO.getPrice() < spuDTO.getVipPrice() || spuDTO.getOriginalPrice() < spuDTO.getVipPrice()) {
-            throw new AdminServiceException(ExceptionDefinition.GOODS_PRICE_CHECKED_FAILED);
-        }
-        Date now = new Date();
-        SpuDO spuDO = new SpuDO();
-        BeanUtils.copyProperties(spuDTO, spuDO);
-        spuDO.setGmtUpdate(now);
-        spuMapper.updateById(spuDO);
-        List<String> barCodes = new LinkedList<>();
-        for (SkuDO skuDO : spuDTO.getSkuList()) {
-            if (skuDO.getOriginalPrice() < skuDO.getPrice() || skuDO.getPrice() < skuDO.getVipPrice() || skuDO.getOriginalPrice() < skuDO.getVipPrice()) {
-                throw new AdminServiceException(ExceptionDefinition.GOODS_PRICE_CHECKED_FAILED);
-            }
-            skuDO.setId(null);
-            skuDO.setSpuId(spuDO.getId());
-            skuDO.setGmtUpdate(now);
-            skuDO.setFreezeStock(0);
-            if (skuMapper.update(skuDO,
-                    new EntityWrapper<SkuDO>()
-                            .eq("bar_code", skuDO.getBarCode())) <= 0) {
-                skuDO.setGmtCreate(now);
-                skuMapper.insert(skuDO);
-            }
-            barCodes.add(skuDO.getBarCode());
-        }
-        //删除多余barCode
-        skuMapper.delete(new EntityWrapper<SkuDO>().eq("spu_id", spuDO.getId()).notIn("bar_code",barCodes));
-        //插入spuAttr
-        spuAttributeMapper.delete(new EntityWrapper<SpuAttributeDO>().eq("spu_id", spuDTO.getId()));
-        insertSpuAttribute(spuDTO, now);
-        imgMapper.delete(new EntityWrapper<ImgDO>().eq("biz_id", spuDO.getId()).eq("biz_type", BizType.GOODS.getCode()));
-        //插入IMG
-        insertSpuImg(spuDTO, spuDO.getId(), now);
-        goodsBizService.clearGoodsCache(spuDTO.getId());
-        pluginUpdateInvoke(spuDTO.getId());
-
-        cacheComponent.delPrefixKey(GoodsBizService.CA_SPU_PAGE_PREFIX);
-        return "ok";
-    }
-
-    private void insertSpuAttribute(SpuDTO spuDTO, Date now) {
-        if (!CollectionUtils.isEmpty(spuDTO.getAttributeList())) {
-            for (SpuAttributeDO spuAttributeDO : spuDTO.getAttributeList()) {
-                spuAttributeDO.setSpuId(spuDTO.getId());
-                spuAttributeDO.setGmtUpdate(now);
-                spuAttributeDO.setGmtCreate(now);
-                spuAttributeMapper.insert(spuAttributeDO);
-            }
-        }
-    }
-
-    private void insertSpuImg(SpuDTO spuDTO, Long bizId, Date now) {
-        List<String> imgList = spuDTO.getImgList();
-        List<ImgDO> imgDOList = imgList.stream().map(item -> {
-            ImgDO imgDO = new ImgDO();
-            imgDO.setBizType(BizType.GOODS.getCode());
-            imgDO.setBizId(bizId);
-            imgDO.setUrl(item);
-            imgDO.setGmtCreate(now);
-            imgDO.setGmtUpdate(now);
-            return imgDO;
-        }).collect(Collectors.toList());
-        imgMapper.insertImgs(imgDOList);
-    }
-
-    @Override
-    public Page<SpuDTO> list(Integer page, Integer limit, Long categoryId, String title,String barcode, Integer status, Long adminId) throws ServiceException {
-        Wrapper<SpuDO> wrapper = new EntityWrapper<SpuDO>();
-
-        if (!StringUtils.isEmpty(title)) {
-            wrapper.like("title", title);
-        }
-
-        if (categoryId != null && categoryId != 0L) {
-            List<CategoryDO> childrenList = categoryMapper.selectList(new EntityWrapper<CategoryDO>().eq("parent_id", categoryId));
-            // 传入类目拥有的三级类目集合
-            LinkedList<Long> childrenIds = new LinkedList<>();
-
-            // 传入类目没有子类目
-            if (CollectionUtils.isEmpty(childrenList)) {
-                // 则传入类目为三级类目
-                childrenIds.add(categoryId);
-            } else {
-
-                CategoryDO categoryDO = categoryMapper.selectById(categoryId);
-
-                // 检验传入类目是一级还是二级类目
-                if (categoryDO.getParentId() != 0L) {
-                    //二级分类
-                    childrenList.forEach(item -> {
-                        childrenIds.add(item.getId());
-                    });
-                } else {
-                    //一级分类
-                    childrenList.forEach(item -> {
-                        List<CategoryDO> leafList = categoryMapper.selectList(new EntityWrapper<CategoryDO>().eq("parent_id", item.getId()));
-                        if (!CollectionUtils.isEmpty(leafList)) {
-                            leafList.forEach(leafItem -> {
-                                childrenIds.add(leafItem.getId());
-                            });
-                        }
-                    });
-                }
-            }
-            wrapper.in("category_id", childrenIds);
-        }
-
-        if(status != null){
-            wrapper.eq("status", status.intValue() <= SpuStatusType.STOCK.getCode()?SpuStatusType.STOCK.getCode():SpuStatusType.SELLING.getCode());
-        }
-
-        if(barcode != null){
-            List<SkuDO> skuDOList = skuMapper.selectList(new EntityWrapper<SkuDO>().eq("bar_code", barcode));
-            if(!CollectionUtils.isEmpty(skuDOList)){
-                SkuDO skuDO = skuDOList.get(0);
-                wrapper.eq("id",skuDO.getSpuId());
-            }
-        }
-
-        wrapper.setSqlSelect(spuBaseColumns);
-        List<SpuDO> spuDOS = spuMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-
-        //组装SPU
-        List<SpuDTO> spuDTOList = new ArrayList<>();
-        spuDOS.forEach(item -> {
-            SpuDTO spuDTO = new SpuDTO();
-            BeanUtils.copyProperties(item, spuDTO);
-            List<SkuDO> skuDOList = skuMapper.selectList(new EntityWrapper<SkuDO>().eq("spu_id", item.getId()));
-            spuDTO.setSkuList(skuDOList);
-            spuDTOList.add(spuDTO);
-        });
-
-        Integer count = spuMapper.selectCount(wrapper);
-        Page<SpuDTO> dtoPage = new Page<>(spuDTOList, page, limit, count);
-
-        return dtoPage;
-    }
-
-    @Override
-    public SpuDTO detail(Long spuId, Long adminId) throws ServiceException {
-        return goodsBizService.getGoods(spuId, null);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public String delete(Long spuId, Long adminId) throws ServiceException {
-        if (spuMapper.deleteById(spuId) <= 0) {
-            throw new AdminServiceException(ExceptionDefinition.GOODS_NOT_EXIST);
-        }
-        cartMapper.delete(new EntityWrapper<CartDO>().in("sku_id", skuMapper.getSkuIds(spuId)));
-        skuMapper.delete(new EntityWrapper<SkuDO>().eq("spu_id", spuId));
-        imgMapper.delete(new EntityWrapper<ImgDO>().eq("biz_id", spuId).eq("biz_type", BizType.GOODS.getCode()));
-        spuAttributeMapper.delete(new EntityWrapper<SpuAttributeDO>().eq("spu_id", spuId));
-        goodsBizService.clearGoodsCache(spuId);
-        pluginUpdateInvoke(spuId);
-
-        cacheComponent.delPrefixKey(GoodsBizService.CA_SPU_PAGE_PREFIX);
-        return "ok";
-    }
-
-    private void pluginUpdateInvoke(Long spuId) {
-        List<IPluginUpdateGoods> plugins = pluginsManager.getPlugins(IPluginUpdateGoods.class);
-        if (!CollectionUtils.isEmpty(plugins)) {
-            for (IPluginUpdateGoods updateGoods : plugins) {
-                updateGoods.invokeGoodsUpdate(spuId);
-            }
-        }
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public SpuDTO freezeOrActivation(Long spuId, Integer status, Long adminId) throws ServiceException {
-        SpuDO spuDO = spuMapper.selectById(spuId);
-
-        if(spuDO == null){
-            throw new AdminServiceException(ExceptionDefinition.GOODS_NOT_EXIST);
-        }
-
-        status = status <= SpuStatusType.STOCK.getCode() ? SpuStatusType.STOCK.getCode() : SpuStatusType.SELLING.getCode();
-
-        if(spuDO.getStatus().intValue() == status.intValue()){
-            throw new AdminServiceException(ExceptionDefinition.GOODS_NEED_STATUS_ERROR);
-        }
-
-        spuDO.setStatus(status);
-        spuDO.setGmtUpdate(new Date());
-        if(spuMapper.updateById(spuDO) <= 0){
-            throw new AdminServiceException(ExceptionDefinition.GOODS_UPDATE_SQL_FAILED);
-        }
-
-        SpuDTO spuDTO = new SpuDTO();
-        BeanUtils.copyProperties(spuDO,spuDTO);
-        List<SkuDO> skuDOList = skuMapper.selectList(new EntityWrapper<SkuDO>().eq("spu_id", spuDO.getId()));
-        spuDTO.setSkuList(skuDOList);
-
-        cacheComponent.delPrefixKey(GoodsBizService.CA_SPU_PAGE_PREFIX);
-        return spuDTO;
-    }
-}

+ 0 - 55
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/goods/AdminGroupShopGoodsService.java

@@ -1,55 +0,0 @@
-package com.iotechn.unimall.admin.api.goods;
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.annotation.param.Range;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.GroupShopSkuDO;
-import com.iotechn.unimall.data.dto.goods.GroupShopDTO;
-import com.iotechn.unimall.data.dto.goods.SpuDTO;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.List;
-
-@HttpOpenApi(group = "admin.groupShop", description = "管理团购商品服务")
-public interface AdminGroupShopGoodsService {
-
-    @HttpMethod(description = "增加", permission = "operation:groupShop:create", permissionParentName = "商品管理", permissionName = "团购商品管理")
-    public String addGroupShopSpu(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员Id") Long adminId,
-            @NotNull @HttpParam(name = "spuId", type = HttpParamType.COMMON, description = "spuId") Long spuId,
-            @NotNull @HttpParam(name = "gmtStart", type = HttpParamType.COMMON, description = "团购开始时间戳") Long gmtStart,
-            @NotNull @HttpParam(name = "gmtEnd", type = HttpParamType.COMMON, description = "团购结束时间戳") Long gmtEnd,
-            @NotNull @Range(min = 1) @HttpParam(name = "minimumNumber", type = HttpParamType.COMMON, description = "团购最低人数") Integer minimumNumber,
-            @NotNull @HttpParam(name = "automaticRefund", type = HttpParamType.COMMON, description = "团购人数未满是否自动退款")  Integer automaticRefund,
-            @NotNull @HttpParam(name = "groupShopSkuList", type = HttpParamType.COMMON, description = "团购sku链表") List groupShopSkuList) throws ServiceException;
-
-    @HttpMethod(description = "删除", permission = "operation:groupShop:delete", permissionParentName = "商品管理", permissionName = "团购商品管理")
-    public String deleteGroupShopSpu(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员Id") Long adminId,
-            @NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "团购商品的Id") Long id) throws  ServiceException;
-
-    @HttpMethod(description = "修改", permission = "operation:groupShop:update", permissionParentName = "商品管理", permissionName = "团购商品管理")
-    public GroupShopDTO editGroupShopSpu(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员Id") Long adminId,
-            @NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "团购商品spuID") Long id,
-            @NotNull @HttpParam(name = "spuId", type = HttpParamType.COMMON, description = "spuId") Long spuId,
-            @NotNull @HttpParam(name = "gmtStart", type = HttpParamType.COMMON, description = "团购开始时间戳") Long gmtStart,
-            @NotNull @HttpParam(name = "gmtEnd", type = HttpParamType.COMMON, description = "团购结束时间戳") Long gmtEnd,
-            @NotNull @Range(min = 1) @HttpParam(name = "minimumNumber", type = HttpParamType.COMMON, description = "团购最低人数") Integer minimumNumber,
-            @NotNull @HttpParam(name = "automaticRefund", type = HttpParamType.COMMON, description = "团购人数未满是否自动退款")  Integer automaticRefund,
-            @NotNull @HttpParam(name = "groupShopSkuList", type = HttpParamType.COMMON, description = "团购sku链表") List groupShopSkuDOList ) throws ServiceException;
-
-    @HttpMethod(description = "查询", permission = "operation:groupShop:query", permissionParentName = "商品管理", permissionName = "团购商品管理")
-    public Page<GroupShopDTO> queryGroupShop(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员Id") Long adminId,
-            @HttpParam(name = "id", type = HttpParamType.COMMON, description = "团购商品的ID") Long id,
-            @HttpParam(name = "spuName", type = HttpParamType.COMMON, description = "团购商品的名称") String spuName,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "团购商品的状态") Integer status,
-            @Range(min = 1) @HttpParam(name = "page", type = HttpParamType.COMMON, description = "团购商品页码", valueDef = "1") Integer page,
-            @Range(min = 1) @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "团购商品长度", valueDef = "20") Integer limit ) throws ServiceException;
-
-}

+ 0 - 290
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/goods/AdminGroupShopGoodsServiceImpl.java

@@ -1,290 +0,0 @@
-package com.iotechn.unimall.admin.api.goods;/*
-@PackageName:com.iotechn.unimall.admin.api.goods
-@ClassName: AdminGroupShopGoodsServiceImpl
-@Description:
-@author kbq
-@date 19-11-13下午4:21
-*/
-
-import com.alibaba.fastjson.JSON;
-import com.alibaba.fastjson.JSONObject;
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.iotechn.unimall.admin.api.order.AdminOrderService;
-import com.iotechn.unimall.core.exception.AdminServiceException;
-import com.iotechn.unimall.core.exception.ExceptionDefinition;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.component.CacheComponent;
-import com.iotechn.unimall.data.domain.*;
-import com.iotechn.unimall.data.dto.goods.GroupShopSkuDTO;
-import com.iotechn.unimall.data.dto.goods.GroupShopDTO;
-import com.iotechn.unimall.data.enums.GroupShopAutomaticRefundType;
-import com.iotechn.unimall.data.enums.StatusType;
-import com.iotechn.unimall.data.mapper.*;
-import com.iotechn.unimall.data.model.Page;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.BeanUtils;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.scheduling.annotation.EnableScheduling;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.CollectionUtils;
-
-import java.util.Comparator;
-import java.util.Date;
-import java.util.LinkedList;
-import java.util.List;
-import java.util.stream.Collectors;
-
-@Service
-@EnableScheduling
-public class AdminGroupShopGoodsServiceImpl implements AdminGroupShopGoodsService {
-
-    @Autowired
-    private SkuMapper skuMapper;
-
-    @Autowired
-    private SpuMapper spuMapper;
-
-    @Autowired
-    private GroupShopMapper groupShopMapper;
-
-    @Autowired
-    private GroupShopSkuMapper groupShopSkuMapper;
-
-    @Autowired
-    private CacheComponent cacheComponent;
-
-    private static final String GROUP_SHOP_CACHE = "CA_GROUP_SHOP";
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public String addGroupShopSpu(Long adminId, Long spuId, Long gmtStart, Long gmtEnd, Integer minimumNumber, Integer automaticRefund, List groupShopSkuList) throws ServiceException {
-        // 1.转化为对应的GroupShopSkuDo类的链表
-        List<GroupShopSkuDO> groupShopSkuDOList = (List<GroupShopSkuDO>) groupShopSkuList.stream().map(t -> {
-            GroupShopSkuDO groupShopSkuDO = JSONObject.toJavaObject((JSON) t, GroupShopSkuDO.class);
-            return groupShopSkuDO;
-        }).sorted(Comparator.comparingInt(o -> ((GroupShopSkuDO) o).getSkuGroupShopPrice())).collect(Collectors.toList());
-
-        if (gmtStart.compareTo(gmtEnd) >= 0) {
-            throw new AdminServiceException(ExceptionDefinition.GROUP_SHOP_START_MUST_LESS_THAN_END);
-        }
-
-        // 2.检验数据库中是否存在spuId对应的sku
-        SpuDO spuDO = spuMapper.selectById(spuId);
-        List<SkuDO> skuDOList = skuMapper.selectList((new EntityWrapper<SkuDO>().eq("spu_id", spuId)));
-        if (spuDO == null || CollectionUtils.isEmpty(skuDOList)) {
-            throw new AdminServiceException(ExceptionDefinition.SPU_NO_EXITS_OR_ONLY_SPU);
-        }
-        // 2.1 检验groupShop表中是否存在此商品
-        Integer count = groupShopMapper.selectCount((new EntityWrapper<GroupShopDO>().eq("spu_id", spuId)));
-        if (count > 0) {
-            throw new AdminServiceException(ExceptionDefinition.GROUP_SHOP_ALREADY_EXIT);
-        }
-
-        Date timeStart = new Date(gmtStart);
-        Date timeEnd = new Date(gmtEnd);
-        Date now = new Date();
-        GroupShopDO groupShopDO = new GroupShopDO();
-
-        groupShopDO.setAlreadyBuyNumber(0);
-        groupShopDO.setMinimumNumber(minimumNumber);
-        groupShopDO.setGmtStart(timeStart);
-        groupShopDO.setGmtEnd(timeEnd);
-        groupShopDO.setAutomaticRefund(automaticRefund.compareTo(0) > 0 ? GroupShopAutomaticRefundType.YES.getCode() : GroupShopAutomaticRefundType.NO.getCode());
-        groupShopDO.setSpuId(spuId);
-        groupShopDO.setMinPrice(groupShopSkuDOList.get(0).getSkuGroupShopPrice());
-        groupShopDO.setMaxPrice(groupShopSkuDOList.get(groupShopSkuDOList.size() - 1).getSkuGroupShopPrice());
-        groupShopDO.setGmtCreate(now);
-        groupShopDO.setGmtUpdate(now);
-        // 3.设置是否在活动时间的状态
-        setGroupShopStatus(now, gmtStart, gmtEnd, spuDO, groupShopDO);
-        if (groupShopMapper.insert(groupShopDO) <= 0) {
-            throw new AdminServiceException(ExceptionDefinition.GROUP_SHOP_SPU_ADD_SQL_QUERY_ERROR);
-        }
-
-        if (skuDOList.size() != groupShopSkuDOList.size()) {
-            throw new AdminServiceException(ExceptionDefinition.GROUP_SHOP_SKU_NUMBER_ERROR);
-        }
-        // 4.插入groupShopSkuList
-        this.insertGroupShopSkuList(groupShopSkuDOList, skuDOList, groupShopDO.getId(), now);
-        cacheComponent.delPrefixKey(GROUP_SHOP_CACHE);
-        return "ok";
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public String deleteGroupShopSpu(Long adminId, Long id) throws ServiceException {
-
-        GroupShopDO groupShopDO = groupShopMapper.selectById(id);
-        if (groupShopDO == null) {
-            throw new AdminServiceException(ExceptionDefinition.SPU_NO_EXITS_OR_ONLY_SPU);
-        }
-
-        if (groupShopDO.getStatus() > 0) {
-            throw new AdminServiceException(ExceptionDefinition.GROUP_SHOP_ALREAD_ATCIVE);
-        }
-
-        if (groupShopMapper.deleteById(id) <= 0) {
-            throw new AdminServiceException(ExceptionDefinition.GROUP_SHOP_SPU_DELETE_SQL_QUERY_ERROR);
-        }
-        if (groupShopSkuMapper.delete((new EntityWrapper<GroupShopSkuDO>().eq("group_shop_id", id))) <= 0) {
-            throw new AdminServiceException(ExceptionDefinition.GROUP_SHOP_SKU_DELETE_SQL_QUERY_ERROR);
-        }
-
-        cacheComponent.delPrefixKey(GROUP_SHOP_CACHE);
-        return "ok";
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public GroupShopDTO editGroupShopSpu(Long adminId, Long id, Long spuId, Long gmtStart, Long gmtEnd, Integer minimumNumber, Integer automaticRefund, List groupShopSkuList) throws ServiceException {
-        // 1.转化为对应的GroupShopSkuDo类的链表
-        List<GroupShopSkuDO> groupShopSkuDOList = (List<GroupShopSkuDO>) groupShopSkuList.stream().map(t -> {
-            GroupShopSkuDO groupShopSkuDO = JSONObject.toJavaObject((JSON) t, GroupShopSkuDO.class);
-            return groupShopSkuDO;
-        }).sorted(Comparator.comparingInt(o -> ((GroupShopSkuDO) o).getSkuGroupShopPrice())).collect(Collectors.toList());
-
-        if (gmtStart.compareTo(gmtEnd) >= 0) {
-            throw new AdminServiceException(ExceptionDefinition.GROUP_SHOP_START_MUST_LESS_THAN_END);
-        }
-
-        SpuDO spuDO = spuMapper.selectById(spuId);
-        List<SkuDO> skuDOList = skuMapper.selectList((new EntityWrapper<SkuDO>().eq("spu_id", spuId)));
-        if (spuDO == null || CollectionUtils.isEmpty(skuDOList)) {
-            throw new AdminServiceException(ExceptionDefinition.SPU_NO_EXITS_OR_ONLY_SPU);
-        }
-
-        GroupShopDO groupShopDO = groupShopMapper.selectById(id);
-        if (groupShopDO == null) {
-            throw new AdminServiceException(ExceptionDefinition.GROUP_SHOP_SPU_NO_EXITS);
-        }
-
-        if (groupShopDO.getStatus() > 0) {
-            throw new AdminServiceException(ExceptionDefinition.GROUP_SHOP_ALREAD_ATCIVE);
-        }
-
-        Date timeStart = new Date(gmtStart);
-        Date timeEnd = new Date(gmtEnd);
-        Date now = new Date();
-
-        groupShopDO.setMinimumNumber(minimumNumber);
-        groupShopDO.setGmtStart(timeStart);
-        groupShopDO.setGmtEnd(timeEnd);
-        groupShopDO.setAutomaticRefund(automaticRefund.compareTo(0) > 0 ? StatusType.ACTIVE.getCode() : StatusType.LOCK.getCode());
-        groupShopDO.setSpuId(spuId);
-        groupShopDO.setMinPrice(groupShopSkuDOList.get(0).getSkuGroupShopPrice());
-        groupShopDO.setMinPrice(groupShopSkuDOList.get(groupShopSkuDOList.size() - 1).getSkuGroupShopPrice());
-        groupShopDO.setGmtUpdate(now);
-        this.setGroupShopStatus(now, gmtStart, gmtEnd, spuDO, groupShopDO);
-        if (groupShopMapper.updateById(groupShopDO) <= 0) {
-            throw new AdminServiceException(ExceptionDefinition.GROUP_SHOP_SPU_UPDATE_SQL_QUERY_ERROR);
-        }
-
-        if (groupShopSkuMapper.delete((new EntityWrapper<GroupShopSkuDO>().eq("group_shop_id", id))) <= 0) {
-            throw new AdminServiceException(ExceptionDefinition.GROUP_SHOP_SKU_DELETE_SQL_QUERY_ERROR);
-        }
-
-        if (skuDOList.size() != groupShopSkuDOList.size()) {
-            throw new AdminServiceException(ExceptionDefinition.GROUP_SHOP_SKU_NUMBER_ERROR);
-        }
-        // 4.插入groupShopSkuList
-        this.insertGroupShopSkuList(groupShopSkuDOList, skuDOList, groupShopDO.getId(), now);
-        cacheComponent.delPrefixKey(GROUP_SHOP_CACHE);
-        return new GroupShopDTO();
-    }
-
-    @Override
-    public Page<GroupShopDTO> queryGroupShop(Long adminId, Long id, String spuName, Integer status, Integer page, Integer limit) throws ServiceException {
-        EntityWrapper<GroupShopDO> groupShopSpuDOEntityWrapper = new EntityWrapper<GroupShopDO>();
-        if (id != null) {
-            groupShopSpuDOEntityWrapper.eq("id", id);
-        }
-
-        if (status != null) {
-            groupShopSpuDOEntityWrapper.eq("status", status);
-        }
-
-        if (spuName != null) {
-            EntityWrapper<SpuDO> spuDOEntityWrapper = new EntityWrapper<>();
-            spuDOEntityWrapper.setSqlSelect("id");
-            spuDOEntityWrapper.like("title", spuName);
-            List<Object> objectList = spuMapper.selectObjs(spuDOEntityWrapper);
-            List<String> collect = objectList.stream().map(s -> String.valueOf(s)).collect(Collectors.toList());
-            groupShopSpuDOEntityWrapper.in("spu_id", collect);
-        }
-
-        List<GroupShopDO> groupShopDOList = groupShopMapper.selectPage(new RowBounds((page - 1) * limit, limit), groupShopSpuDOEntityWrapper);
-        Integer count = groupShopMapper.selectCount(groupShopSpuDOEntityWrapper);
-        List<GroupShopDTO> groupShopDTOList = new LinkedList<>();
-
-        for (GroupShopDO groupShopDO : groupShopDOList) {
-            GroupShopDTO groupShopDTO = new GroupShopDTO();
-            SpuDO spuDO = spuMapper.selectById(groupShopDO.getSpuId());
-            BeanUtils.copyProperties(spuDO, groupShopDTO);
-            BeanUtils.copyProperties(groupShopDO, groupShopDTO);
-            /**
-             * 添加groupShopSkuDTOList
-             */
-            List<SkuDO> skuDOList = skuMapper.selectList((new EntityWrapper<SkuDO>().eq("spu_id", spuDO.getId())));
-            List<GroupShopSkuDO> groupShopSkuDOList = groupShopSkuMapper.selectList((new EntityWrapper<GroupShopSkuDO>()).eq("group_shop_id", groupShopDO.getId()));
-            List<GroupShopSkuDTO> groupShopSkuDTOList = groupShopSkuDOList.stream().map(s -> {
-                GroupShopSkuDTO groupShopSkuDTO = new GroupShopSkuDTO();
-                BeanUtils.copyProperties(s, groupShopSkuDTO);
-                return groupShopSkuDTO;
-            }).collect(Collectors.toList());
-
-            for (SkuDO skuDO : skuDOList) {
-                for (GroupShopSkuDTO groupShopSkuDTO : groupShopSkuDTOList) {
-                    if (groupShopSkuDTO.getSkuId().equals(skuDO.getId())) {
-                        BeanUtils.copyProperties(skuDO, groupShopSkuDTO);
-                        break;
-                    }
-                }
-            }
-            groupShopDTO.setGroupShopSkuDTOList(groupShopSkuDTOList);
-            groupShopDTOList.add(groupShopDTO);
-        }
-        return new Page<GroupShopDTO>(groupShopDTOList, page, limit, count);
-    }
-
-    private void setGroupShopStatus(Date now, Long gmtStart, Long gmtEnd, SpuDO spuDO, GroupShopDO groupShopDO) {
-        if (now.getTime() >= gmtStart.longValue() && now.getTime() < gmtEnd.longValue()) {
-            //3.1 商品本身是否处于下架状态
-            if (spuDO.getStatus().equals(StatusType.ACTIVE.getCode())) {
-                groupShopDO.setStatus(StatusType.ACTIVE.getCode());
-            } else {
-                groupShopDO.setStatus(StatusType.LOCK.getCode());
-            }
-        } else {
-            groupShopDO.setStatus(StatusType.LOCK.getCode());
-        }
-    }
-
-    private void insertGroupShopSkuList(List<GroupShopSkuDO> groupShopSkuDOList, List<SkuDO> skuDOList, Long groupShopId, Date now) throws ServiceException {
-        for (GroupShopSkuDO groupShopSkuDO : groupShopSkuDOList) {
-            boolean judge = false;
-            for (SkuDO sku : skuDOList) {
-                if (sku.getId().equals(groupShopSkuDO.getSkuId())) {
-                    judge = true;
-                    break;
-                }
-            }
-
-            if (!judge) {
-                throw new AdminServiceException(ExceptionDefinition.GROUP_SHOP_SKU_ID_ERROR);
-            }
-
-            if (groupShopSkuDO.getSkuGroupShopPrice() == null || groupShopSkuDO.getSkuGroupShopPrice().equals(0)) {
-                throw new AdminServiceException(ExceptionDefinition.GROUP_SHOP_SKU_PRICE_ERROR);
-            }
-
-            groupShopSkuDO.setGroupShopId(groupShopId);
-            groupShopSkuDO.setGmtCreate(now);
-            groupShopSkuDO.setGmtUpdate(now);
-            if (groupShopSkuMapper.insert(groupShopSkuDO) <= 0) {
-                throw new AdminServiceException(ExceptionDefinition.GROUP_SHOP_SKU_ADD_SQL_QUERY_ERROR);
-            }
-        }
-    }
-
-}

+ 0 - 66
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/IMarketAdvertisementInfoService.java

@@ -1,66 +0,0 @@
-package com.iotechn.unimall.admin.api.market;
-
-
-import com.iotechn.unimall.data.domain.market.MarketAdvertisementInfo;
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-/**
- * 广告信息Service接口
- *
- * @author jlb
- * @date 2022-08-01
- */
-@HttpOpenApi(group = "admin.market.marketAdvertisementInfo", description = "广告信息")
-public interface IMarketAdvertisementInfoService {
-    @HttpMethod(description = "新增", permission = "admin:market:marketAdvertisementInfo:add", permissionParentName = "宠物管理", permissionName = "广告信息管理")
-    public Boolean add(@NotNull @HttpParam(name = "marketAdvertisementInfo", type = HttpParamType.COMMON, description = "广告信息") MarketAdvertisementInfo marketAdvertisementInfo,
-                       @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "列表", permission = "admin:market:marketAdvertisementInfo:list", permissionParentName = "宠物管理", permissionName = "广告信息管理")
-    public Page<MarketAdvertisementInfo> list(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "advertisementName", type = HttpParamType.COMMON, description = "广告名称") String advertisementName,
-            @HttpParam(name = "url", type = HttpParamType.COMMON, description = "图片") String url,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-            throws ServiceException;
-
-    @HttpMethod(description = "删除", permission = "admin:market:marketAdvertisementInfo:delete", permissionParentName = "宠物管理", permissionName = "广告信息管理")
-    public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "") String id) throws ServiceException;
-
-    @HttpMethod(description = "修改", permission = "admin:market:marketAdvertisementInfo:update", permissionParentName = "宠物管理", permissionName = "广告信息管理")
-    public Boolean update(@NotNull @HttpParam(name = "marketAdvertisementInfo", type = HttpParamType.COMMON, description = "广告信息") MarketAdvertisementInfo marketAdvertisementInfo,
-                          @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "查询", permission = "admin:market:marketAdvertisementInfo:get", permissionParentName = "宠物管理", permissionName = "广告信息管理")
-    public MarketAdvertisementInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "") Long id) throws ServiceException;
-
-    @HttpMethod(description = "导出excl表", permission = "admin:market:marketAdvertisementInfo:export", permissionParentName = "宠物管理", permissionName = "广告信息管理")
-    public String export(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "advertisementName", type = HttpParamType.COMMON, description = "广告名称") String advertisementName,
-            @HttpParam(name = "url", type = HttpParamType.COMMON, description = "图片") String url,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit) throws ServiceException;
-
-}

+ 0 - 50
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/IMarketCaseService.java

@@ -1,50 +0,0 @@
-package com.iotechn.unimall.admin.api.market;
-
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketCase;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-
-/**
- * 关注Service接口
- * 
- * @author jlb
- * @date 2023-02-03
- */
-@HttpOpenApi(group = "admin.unimall.marketCase", description = "关注")
-public interface IMarketCaseService{
-	@HttpMethod(description = "新增")
-	public Boolean add(@NotNull @HttpParam(name = "marketCase", type = HttpParamType.COMMON, description = "关注") MarketCase marketCase,
-						   @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId)throws ServiceException;
-
-	@HttpMethod(description = "列表")
-	public Page<MarketCase> list(
-								@HttpParam(name = "concernedId", type = HttpParamType.COMMON, description = "被关注人id") String concernedId,
-							@HttpParam(name = "followersId", type = HttpParamType.COMMON, description = "关注人id") String followersId,
-					@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-		@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-		throws ServiceException;
-
-	@HttpMethod(description = "删除")
-	public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = " ")String id)throws ServiceException;
-
-	@HttpMethod(description = "修改")
-	public Boolean update(@NotNull @HttpParam(name = "marketCase", type = HttpParamType.COMMON, description = "关注") MarketCase marketCase,
-						  @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId)throws ServiceException;
-
-	@HttpMethod(description = "查询")
-	public MarketCase get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = " ")Long id)throws ServiceException;
-	
-	@HttpMethod(description = "导出excl表", permission = "admin:unimall:marketCase:export",permissionParentName = "宠物管理", permissionName = "关注管理")
-	public String export(@HttpParam(name = "concernedId", type = HttpParamType.COMMON, description = "被关注人id") String concernedId,
-							@HttpParam(name = "followersId", type = HttpParamType.COMMON, description = "关注人id") String followersId,
-				@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-	@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)throws ServiceException;
-	
-}

+ 0 - 67
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/IMarketCircleInfoService.java

@@ -1,67 +0,0 @@
-package com.iotechn.unimall.admin.api.market;
-
-
-import com.iotechn.unimall.data.domain.market.MarketCircleInfo;
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-
-/**
- * 生鲜圈Service接口
- * 
- * @author jlb
- * @date 2023-01-03
- */
-@HttpOpenApi(group = "admin.market.marketCircleInfo", description = "生鲜圈")
-public interface IMarketCircleInfoService{
-	@HttpMethod(description = "新增", permission = "admin:market:marketCircleInfo:add", permissionParentName = "宠物管理", permissionName = "生鲜圈管理")
-	public Boolean add(@NotNull @HttpParam(name = "marketCircleInfo", type = HttpParamType.COMMON, description = "生鲜圈") MarketCircleInfo marketCircleInfo,
-						   @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId)throws ServiceException;
-
-	@HttpMethod(description = "列表", permission = "admin:market:marketCircleInfo:list",permissionParentName = "宠物管理", permissionName = "生鲜圈管理")
-	public Page<MarketCircleInfo> list(
-								@HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-							@HttpParam(name = "shopId", type = HttpParamType.COMMON, description = "店铺id") Long shopId,
-							@HttpParam(name = "content", type = HttpParamType.COMMON, description = "内容") String content,
-							@HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-							@HttpParam(name = "url", type = HttpParamType.COMMON, description = "附件") String url,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-							@HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-					@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-		@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-		throws ServiceException;
-
-	@HttpMethod(description = "删除", permission = "admin:market:marketCircleInfo:delete",permissionParentName = "宠物管理", permissionName = "生鲜圈管理")
-	public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")String id)throws ServiceException;
-
-	@HttpMethod(description = "修改", permission = "admin:market:marketCircleInfo:update",permissionParentName = "宠物管理", permissionName = "生鲜圈管理")
-	public Boolean update(@NotNull @HttpParam(name = "marketCircleInfo", type = HttpParamType.COMMON, description = "生鲜圈") MarketCircleInfo marketCircleInfo,
-						  @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId)throws ServiceException;
-
-	@HttpMethod(description = "查询", permission = "admin:market:marketCircleInfo:get",permissionParentName = "宠物管理", permissionName = "生鲜圈管理")
-	public MarketCircleInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")Long id)throws ServiceException;
-	
-	@HttpMethod(description = "导出excl表", permission = "admin:market:marketCircleInfo:export",permissionParentName = "宠物管理", permissionName = "生鲜圈管理")
-	public String export(
-								@HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-							@HttpParam(name = "shopId", type = HttpParamType.COMMON, description = "店铺id") Long shopId,
-							@HttpParam(name = "content", type = HttpParamType.COMMON, description = "内容") String content,
-							@HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-							@HttpParam(name = "url", type = HttpParamType.COMMON, description = "附件") String url,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-							@HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-				@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-	@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)throws ServiceException;
-	
-}

+ 0 - 70
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/IMarketOrderDetailService.java

@@ -1,70 +0,0 @@
-package com.iotechn.unimall.admin.api.market;
-
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketOrderDetail;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-/**
- * 订单详情Service接口
- *
- * @author jlb
- * @date 2022-08-01
- */
-@HttpOpenApi(group = "admin.unimall.marketOrderDetail", description = "订单详情")
-public interface IMarketOrderDetailService {
-    @HttpMethod(description = "新增", permission = "admin:unimall:marketOrderDetail:add", permissionParentName = "宠物管理", permissionName = "订单详情管理")
-    public Boolean add(@NotNull @HttpParam(name = "marketOrderDetail", type = HttpParamType.COMMON, description = "订单详情") MarketOrderDetail marketOrderDetail,
-                       @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "列表", permission = "admin:unimall:marketOrderDetail:list", permissionParentName = "宠物管理", permissionName = "订单详情管理")
-    public Page<MarketOrderDetail> list(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "orderId", type = HttpParamType.COMMON, description = "订单id") String orderId,
-            @HttpParam(name = "name", type = HttpParamType.COMMON, description = "商品名称") String name,
-            @HttpParam(name = "price", type = HttpParamType.COMMON, description = "单价") Double price,
-            @HttpParam(name = "num", type = HttpParamType.COMMON, description = "数量") Long num,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-            throws ServiceException;
-
-    @HttpMethod(description = "删除", permission = "admin:unimall:marketOrderDetail:delete", permissionParentName = "宠物管理", permissionName = "订单详情管理")
-    public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "") String id) throws ServiceException;
-
-    @HttpMethod(description = "修改", permission = "admin:unimall:marketOrderDetail:update", permissionParentName = "宠物管理", permissionName = "订单详情管理")
-    public Boolean update(@NotNull @HttpParam(name = "marketOrderDetail", type = HttpParamType.COMMON, description = "订单详情") MarketOrderDetail marketOrderDetail,
-                          @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "查询", permission = "admin:unimall:marketOrderDetail:get", permissionParentName = "宠物管理", permissionName = "订单详情管理")
-    public MarketOrderDetail get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "") Long id) throws ServiceException;
-
-    @HttpMethod(description = "导出excl表", permission = "admin:unimall:marketOrderDetail:export", permissionParentName = "宠物管理", permissionName = "订单详情管理")
-    public String export(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "orderId", type = HttpParamType.COMMON, description = "订单id") String orderId,
-            @HttpParam(name = "name", type = HttpParamType.COMMON, description = "商品名称") String name,
-            @HttpParam(name = "price", type = HttpParamType.COMMON, description = "单价") Double price,
-            @HttpParam(name = "num", type = HttpParamType.COMMON, description = "数量") Long num,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit) throws ServiceException;
-
-}

+ 0 - 68
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/IMarketOrderInfoService.java

@@ -1,68 +0,0 @@
-package com.iotechn.unimall.admin.api.market;
-
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketOrderInfo;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-/**
- * 订单信息Service接口
- *
- * @author jlb
- * @date 2022-08-01
- */
-@HttpOpenApi(group = "admin.unimall.marketOrderInfo", description = "订单信息")
-public interface IMarketOrderInfoService {
-    @HttpMethod(description = "新增", permission = "admin:unimall:marketOrderInfo:add", permissionParentName = "宠物管理", permissionName = "订单信息管理")
-    public Boolean add(@NotNull @HttpParam(name = "marketOrderInfo", type = HttpParamType.COMMON, description = "订单信息") MarketOrderInfo marketOrderInfo,
-                       @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "列表", permission = "admin:unimall:marketOrderInfo:list", permissionParentName = "宠物管理", permissionName = "订单信息管理")
-    public Page<MarketOrderInfo> list(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "orderNo", type = HttpParamType.COMMON, description = "订单编号") String orderNo,
-            @HttpParam(name = "customer", type = HttpParamType.COMMON, description = "客户") String customer,
-            @HttpParam(name = "pets", type = HttpParamType.COMMON, description = "收货地址") String pets,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-            throws ServiceException;
-
-    @HttpMethod(description = "删除", permission = "admin:unimall:marketOrderInfo:delete", permissionParentName = "宠物管理", permissionName = "订单信息管理")
-    public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "") String id) throws ServiceException;
-
-    @HttpMethod(description = "修改", permission = "admin:unimall:marketOrderInfo:update", permissionParentName = "宠物管理", permissionName = "订单信息管理")
-    public Boolean update(@NotNull @HttpParam(name = "marketOrderInfo", type = HttpParamType.COMMON, description = "订单信息") MarketOrderInfo marketOrderInfo,
-                          @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "查询", permission = "admin:unimall:marketOrderInfo:get", permissionParentName = "宠物管理", permissionName = "订单信息管理")
-    public MarketOrderInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "") Long id) throws ServiceException;
-
-    @HttpMethod(description = "导出excl表", permission = "admin:unimall:marketOrderInfo:export", permissionParentName = "宠物管理", permissionName = "订单信息管理")
-    public String export(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "orderNo", type = HttpParamType.COMMON, description = "订单编号") String orderNo,
-            @HttpParam(name = "customer", type = HttpParamType.COMMON, description = "客户") String customer,
-            @HttpParam(name = "pets", type = HttpParamType.COMMON, description = "收货地址") String pets,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit) throws ServiceException;
-
-}

+ 0 - 74
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/IMarketProdectInfoService.java

@@ -1,74 +0,0 @@
-package com.iotechn.unimall.admin.api.market;
-
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketProdectInfo;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-/**
- * 商品信息Service接口
- *
- * @author jlb
- * @date 2022-08-01
- */
-@HttpOpenApi(group = "admin.unimall.marketProdectInfo", description = "商品信息")
-public interface IMarketProdectInfoService {
-    @HttpMethod(description = "新增", permission = "admin:unimall:marketProdectInfo:add", permissionParentName = "宠物管理", permissionName = "商品信息管理")
-    public Boolean add(@NotNull @HttpParam(name = "marketProdectInfo", type = HttpParamType.COMMON, description = "商品信息") MarketProdectInfo marketProdectInfo,
-                       @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "列表", permission = "admin:unimall:marketProdectInfo:list", permissionParentName = "宠物管理", permissionName = "商品信息管理")
-    public Page<MarketProdectInfo> list(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "prodectName", type = HttpParamType.COMMON, description = "商品名称") String prodectName,
-            @HttpParam(name = "classificationKey", type = HttpParamType.COMMON, description = "商品分类key") String classificationKey,
-            @HttpParam(name = "classification", type = HttpParamType.COMMON, description = "商品分类") String classification,
-            @HttpParam(name = "url", type = HttpParamType.COMMON, description = "封面") String url,
-            @HttpParam(name = "productDetails", type = HttpParamType.COMMON, description = "商品详情") String productDetails,
-            @HttpParam(name = "commodity price", type = HttpParamType.COMMON, description = "商品售价") Double commodityPrice,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-            throws ServiceException;
-
-    @HttpMethod(description = "删除", permission = "admin:unimall:marketProdectInfo:delete", permissionParentName = "宠物管理", permissionName = "商品信息管理")
-    public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "") String id) throws ServiceException;
-
-    @HttpMethod(description = "修改", permission = "admin:unimall:marketProdectInfo:update", permissionParentName = "宠物管理", permissionName = "商品信息管理")
-    public Boolean update(@NotNull @HttpParam(name = "marketProdectInfo", type = HttpParamType.COMMON, description = "商品信息") MarketProdectInfo marketProdectInfo,
-                          @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "查询", permission = "admin:unimall:marketProdectInfo:get", permissionParentName = "宠物管理", permissionName = "商品信息管理")
-    public MarketProdectInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "") Long id) throws ServiceException;
-
-    @HttpMethod(description = "导出excl表", permission = "admin:unimall:marketProdectInfo:export", permissionParentName = "宠物管理", permissionName = "商品信息管理")
-    public String export(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "prodectName", type = HttpParamType.COMMON, description = "商品名称") String prodectName,
-            @HttpParam(name = "classificationKey", type = HttpParamType.COMMON, description = "商品分类key") String classificationKey,
-            @HttpParam(name = "classification", type = HttpParamType.COMMON, description = "商品分类") String classification,
-            @HttpParam(name = "url", type = HttpParamType.COMMON, description = "封面") String url,
-            @HttpParam(name = "productDetails", type = HttpParamType.COMMON, description = "商品详情") String productDetails,
-            @HttpParam(name = "commodity price", type = HttpParamType.COMMON, description = "商品售价") Double commodityPrice,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit) throws ServiceException;
-
-}

+ 0 - 71
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/IMarketReceivingAddressService.java

@@ -1,71 +0,0 @@
-package com.iotechn.unimall.admin.api.market;
-
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketReceivingAddress;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-
-/**
- * 收货地址Service接口
- * 
- * @author jlb
- * @date 2022-08-01
- */
-@HttpOpenApi(group = "admin.unimall.marketReceivingAddress", description = "收货地址")
-public interface IMarketReceivingAddressService{
-	@HttpMethod(description = "新增", permission = "admin:unimall:marketReceivingAddress:add", permissionParentName = "宠物管理", permissionName = "收货地址管理")
-	public Boolean add(@NotNull @HttpParam(name = "marketReceivingAddress", type = HttpParamType.COMMON, description = "收货地址") MarketReceivingAddress marketReceivingAddress,
-						   @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId)throws ServiceException;
-
-	@HttpMethod(description = "列表", permission = "admin:unimall:marketReceivingAddress:list",permissionParentName = "宠物管理", permissionName = "收货地址管理")
-	public Page<MarketReceivingAddress> list(
-								@HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-							@HttpParam(name = "cusId", type = HttpParamType.COMMON, description = "客户id") String cusId,
-							@HttpParam(name = "consigneeName", type = HttpParamType.COMMON, description = "收货人姓名") String consigneeName,
-							@HttpParam(name = "phone", type = HttpParamType.COMMON, description = "手机号") String phone,
-							@HttpParam(name = "location", type = HttpParamType.COMMON, description = "所在地区") String location,
-							@HttpParam(name = "address", type = HttpParamType.COMMON, description = "详细地址") String address,
-							@HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-							@HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-					@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-		@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-		throws ServiceException;
-
-	@HttpMethod(description = "删除", permission = "admin:unimall:marketReceivingAddress:delete",permissionParentName = "宠物管理", permissionName = "收货地址管理")
-	public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")String id)throws ServiceException;
-
-	@HttpMethod(description = "修改", permission = "admin:unimall:marketReceivingAddress:update",permissionParentName = "宠物管理", permissionName = "收货地址管理")
-	public Boolean update(@NotNull @HttpParam(name = "marketReceivingAddress", type = HttpParamType.COMMON, description = "收货地址") MarketReceivingAddress marketReceivingAddress,
-						  @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId)throws ServiceException;
-
-	@HttpMethod(description = "查询", permission = "admin:unimall:marketReceivingAddress:get",permissionParentName = "宠物管理", permissionName = "收货地址管理")
-	public MarketReceivingAddress get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")Long id)throws ServiceException;
-	
-	@HttpMethod(description = "导出excl表", permission = "admin:unimall:marketReceivingAddress:export",permissionParentName = "宠物管理", permissionName = "收货地址管理")
-	public String export(
-								@HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-							@HttpParam(name = "cusId", type = HttpParamType.COMMON, description = "客户id") String cusId,
-							@HttpParam(name = "consigneeName", type = HttpParamType.COMMON, description = "收货人姓名") String consigneeName,
-							@HttpParam(name = "phone", type = HttpParamType.COMMON, description = "手机号") String phone,
-							@HttpParam(name = "location", type = HttpParamType.COMMON, description = "所在地区") String location,
-							@HttpParam(name = "address", type = HttpParamType.COMMON, description = "详细地址") String address,
-							@HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-							@HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-				@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-	@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)throws ServiceException;
-	
-}

+ 0 - 74
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/IMarketShopInfoService.java

@@ -1,74 +0,0 @@
-package com.iotechn.unimall.admin.api.market;
-
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketShopInfo;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-/**
- * 商店信息Service接口
- *
- * @author jlb
- * @date 2022-08-01
- */
-@HttpOpenApi(group = "admin.unimall.marketShopInfo", description = "商店信息")
-public interface IMarketShopInfoService {
-    @HttpMethod(description = "新增", permission = "admin:unimall:marketShopInfo:add", permissionParentName = "宠物管理", permissionName = "商店信息管理")
-    public Boolean add(@NotNull @HttpParam(name = "marketShopInfo", type = HttpParamType.COMMON, description = "商店信息") MarketShopInfo marketShopInfo,
-                       @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "列表", permission = "admin:unimall:marketShopInfo:list", permissionParentName = "宠物管理", permissionName = "商店信息管理")
-    public Page<MarketShopInfo> list(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "name", type = HttpParamType.COMMON, description = "名称") String name,
-            @HttpParam(name = "postion", type = HttpParamType.COMMON, description = "位置") String postion,
-            @HttpParam(name = "url", type = HttpParamType.COMMON, description = "封面") String url,
-            @HttpParam(name = "phone", type = HttpParamType.COMMON, description = "手机") String phone,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "level", type = HttpParamType.COMMON, description = "信誉等级") String level,
-            @HttpParam(name = "caseWorld", type = HttpParamType.COMMON, description = "关键词") String caseWorld,
-            @HttpParam(name = "lon", type = HttpParamType.COMMON, description = "经度") String lon,
-            @HttpParam(name = "lat", type = HttpParamType.COMMON, description = "纬度") String lat,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-            throws ServiceException;
-
-    @HttpMethod(description = "删除", permission = "admin:unimall:marketShopInfo:delete", permissionParentName = "宠物管理", permissionName = "商店信息管理")
-    public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "") String id) throws ServiceException;
-
-    @HttpMethod(description = "修改", permission = "admin:unimall:marketShopInfo:update", permissionParentName = "宠物管理", permissionName = "商店信息管理")
-    public Boolean update(@NotNull @HttpParam(name = "marketShopInfo", type = HttpParamType.COMMON, description = "商店信息") MarketShopInfo marketShopInfo,
-                          @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "查询", permission = "admin:unimall:marketShopInfo:get", permissionParentName = "宠物管理", permissionName = "商店信息管理")
-    public MarketShopInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "") Long id) throws ServiceException;
-
-    @HttpMethod(description = "导出excl表", permission = "admin:unimall:marketShopInfo:export", permissionParentName = "宠物管理", permissionName = "商店信息管理")
-    public String export(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "name", type = HttpParamType.COMMON, description = "名称") String name,
-            @HttpParam(name = "postion", type = HttpParamType.COMMON, description = "位置") String postion,
-            @HttpParam(name = "url", type = HttpParamType.COMMON, description = "封面") String url,
-            @HttpParam(name = "phone", type = HttpParamType.COMMON, description = "手机") String phone,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit) throws ServiceException;
-
-}

+ 0 - 140
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/impl/MarketAdvertisementInfoServiceImpl.java

@@ -1,140 +0,0 @@
-package com.iotechn.unimall.admin.api.market.impl;
-
-import java.util.List;
-
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.StringUtils;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import com.iotechn.unimall.data.mapper.market.MarketAdvertisementInfoMapper;
-import com.iotechn.unimall.data.domain.market.MarketAdvertisementInfo;
-import com.iotechn.unimall.admin.api.market.IMarketAdvertisementInfoService;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 广告信息Service业务层处理
- *
- * @author jlb
- * @date 2022-08-01
- */
-@Service
-public class MarketAdvertisementInfoServiceImpl implements IMarketAdvertisementInfoService {
-    @Autowired
-    private MarketAdvertisementInfoMapper marketAdvertisementInfoMapper;
-
-    @Override
-    public Boolean add(MarketAdvertisementInfo marketAdvertisementInfo, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketAdvertisementInfo.setGmtCreate(now);
-        marketAdvertisementInfo.setGmtUpdate(now);
-        marketAdvertisementInfo.setAdminId(adminId);
-        return marketAdvertisementInfoMapper.insert(marketAdvertisementInfo) > 0;
-    }
-
-    @Override
-    public Page<MarketAdvertisementInfo> list(Long companyId, String advertisementName, String url, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketAdvertisementInfo> wrapper = new EntityWrapper<MarketAdvertisementInfo>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(advertisementName)) {
-            wrapper.eq("advertisement_name", advertisementName);
-        }
-        if (!StringUtils.isEmpty(url)) {
-            wrapper.eq("url", url);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        wrapper.eq("delete_flag", 0);
-        List<MarketAdvertisementInfo> list = marketAdvertisementInfoMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-        Integer count = marketAdvertisementInfoMapper.selectCount(wrapper);
-        return new Page<MarketAdvertisementInfo>(list, page, limit, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt : ids) {
-            MarketAdvertisementInfo tmp = marketAdvertisementInfoMapper.selectById(Long.parseLong(tt));
-            if (tmp != null) {
-                tmp.setDeleteFlag(1);
-                marketAdvertisementInfoMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(MarketAdvertisementInfo marketAdvertisementInfo, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketAdvertisementInfo.setGmtUpdate(now);
-        marketAdvertisementInfo.setAdminId(adminId);
-        return marketAdvertisementInfoMapper.updateById(marketAdvertisementInfo) > 0;
-    }
-
-    @Override
-    public MarketAdvertisementInfo get(Long id) throws ServiceException {
-        return marketAdvertisementInfoMapper.selectById(id);
-    }
-
-    @Override
-    public String export(Long companyId, String advertisementName, String url, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketAdvertisementInfo> wrapper = new EntityWrapper<MarketAdvertisementInfo>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(advertisementName)) {
-            wrapper.eq("advertisement_name", advertisementName);
-        }
-        if (!StringUtils.isEmpty(url)) {
-            wrapper.eq("url", url);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        List<MarketAdvertisementInfo> list = marketAdvertisementInfoMapper.selectList(wrapper);
-        ExcelUtil<MarketAdvertisementInfo> util = new ExcelUtil<MarketAdvertisementInfo>(MarketAdvertisementInfo.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 96
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/impl/MarketCaseServiceImpl.java

@@ -1,96 +0,0 @@
-package com.iotechn.unimall.admin.api.market.impl;
-
-import java.util.List;
-
-import com.iotechn.unimall.admin.api.market.IMarketCaseService;
-import com.iotechn.unimall.data.domain.market.MarketCase;
-import com.iotechn.unimall.data.mapper.market.MarketCaseMapper;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.StringUtils;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 关注Service业务层处理
- * 
- * @author jlb
- * @date 2023-02-03
- */
-@Service
-public class MarketCaseServiceImpl implements IMarketCaseService {
-	@Autowired
-	private MarketCaseMapper marketCaseMapper;
-	
-	@Override
-	public Boolean add(MarketCase marketCase, Long adminId) throws ServiceException {
-		Date now = new Date();
-		marketCase.setGmtCreate(now);
-		marketCase.setGmtUpdate(now);
-		marketCase.setAdminId(adminId);
-		return marketCaseMapper.insert(marketCase)>0;
-	}
-
-	@Override
-	public Page<MarketCase> list(String concernedId,String followersId, Integer page, Integer limit)throws ServiceException {
-		Wrapper<MarketCase> wrapper = new EntityWrapper<MarketCase>();
-														if (!StringUtils.isEmpty(concernedId)) {
-					wrapper.eq("concerned_id", concernedId);
-				}
-												if (!StringUtils.isEmpty(followersId)) {
-					wrapper.eq("followers_id", followersId);
-				}
-							wrapper.eq("delete_flag", 0);
-		List<MarketCase> list = marketCaseMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-		Integer count = marketCaseMapper.selectCount(wrapper);
-		return new Page<MarketCase>(list, page, limit, count);
-	}
-
-	@Override
-	@Transactional(rollbackFor = Exception.class)
-	public Boolean delete(String id) {
-		String[] ids = String.valueOf(id).split(",");
-		for (String tt:ids) {
-			MarketCase tmp =  marketCaseMapper.selectById(Long.parseLong(tt));
-			if(tmp != null){
-				tmp.setDeleteFlag(1);
-				marketCaseMapper.updateById(tmp);
-			}
-		}
-		return true;
-	}
-
-	@Override
-	public Boolean update(MarketCase marketCase,Long adminId) throws ServiceException {
-		Date now = new Date();
-		marketCase.setGmtUpdate(now);
-		marketCase.setAdminId(adminId);
-		return marketCaseMapper.updateById(marketCase)>0;
-	}
-
-	@Override
-	public MarketCase get(Long id) throws ServiceException {
-		return marketCaseMapper.selectById(id);
-	}
-	
-	@Override
-	public String export(String concernedId,String followersId, Integer page, Integer limit)throws ServiceException {
-		Wrapper<MarketCase> wrapper = new EntityWrapper<MarketCase>();
-														if (!StringUtils.isEmpty(concernedId)) {
-					wrapper.eq("concerned_id", concernedId);
-				}
-												if (!StringUtils.isEmpty(followersId)) {
-					wrapper.eq("followers_id", followersId);
-				}
-							List<MarketCase> list = marketCaseMapper.selectList(wrapper);
-		ExcelUtil<MarketCase> util = new ExcelUtil<MarketCase>(MarketCase.class);
-		return util.exportExcel(list, "操作日志");
-	}
-}

+ 0 - 150
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/impl/MarketCircleInfoServiceImpl.java

@@ -1,150 +0,0 @@
-package com.iotechn.unimall.admin.api.market.impl;
-
-import java.util.List;
-
-import com.iotechn.unimall.data.mapper.market.MarketShopInfoMapper;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.StringUtils;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import com.iotechn.unimall.data.mapper.market.MarketCircleInfoMapper;
-import com.iotechn.unimall.data.domain.market.MarketCircleInfo;
-import com.iotechn.unimall.admin.api.market.IMarketCircleInfoService;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 生鲜圈Service业务层处理
- * 
- * @author jlb
- * @date 2023-01-03
- */
-@Service
-public class MarketCircleInfoServiceImpl implements IMarketCircleInfoService{
-	@Autowired
-	private MarketCircleInfoMapper marketCircleInfoMapper;
-	@Autowired
-	private MarketShopInfoMapper marketShopInfoMapper;
-	
-	@Override
-	public Boolean add(MarketCircleInfo marketCircleInfo,Long adminId) throws ServiceException {
-		Date now = new Date();
-		marketCircleInfo.setGmtCreate(now);
-		marketCircleInfo.setGmtUpdate(now);
-		marketCircleInfo.setAdminId(adminId);
-		return marketCircleInfoMapper.insert(marketCircleInfo)>0;
-	}
-
-	@Override
-	public Page<MarketCircleInfo> list(Long companyId,Long shopId,String content,String status,String url,Integer deleteFlag,Date gmtCreate,Date gmtUpdate,Long userId,Long adminId, Integer page, Integer limit)throws ServiceException {
-		Wrapper<MarketCircleInfo> wrapper = new EntityWrapper<MarketCircleInfo>();
-														if (!StringUtils.isEmpty(companyId)) {
-					wrapper.eq("company_id", companyId);
-				}
-												if (!StringUtils.isEmpty(shopId)) {
-					wrapper.eq("shop_id", shopId);
-				}
-												if (!StringUtils.isEmpty(content)) {
-					wrapper.eq("content", content);
-				}
-												if (!StringUtils.isEmpty(status)) {
-					wrapper.eq("status", status);
-				}
-												if (!StringUtils.isEmpty(url)) {
-					wrapper.eq("url", url);
-				}
-												if (!StringUtils.isEmpty(deleteFlag)) {
-					wrapper.eq("delete_flag", deleteFlag);
-				}
-												if (!StringUtils.isEmpty(gmtCreate)) {
-					wrapper.eq("gmt_create", gmtCreate);
-				}
-												if (!StringUtils.isEmpty(gmtUpdate)) {
-					wrapper.eq("gmt_update", gmtUpdate);
-				}
-												if (!StringUtils.isEmpty(userId)) {
-					wrapper.eq("user_id", userId);
-				}
-												if (!StringUtils.isEmpty(adminId)) {
-					wrapper.eq("admin_id", adminId);
-				}
-							wrapper.eq("delete_flag", 0);
-		List<MarketCircleInfo> list = marketCircleInfoMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-		for(MarketCircleInfo tmp : list){
-			tmp.setShopName(marketShopInfoMapper.selectById(tmp.getShopId()).getName());
-		}
-		Integer count = marketCircleInfoMapper.selectCount(wrapper);
-		return new Page<MarketCircleInfo>(list, page, limit, count);
-	}
-
-	@Override
-	@Transactional(rollbackFor = Exception.class)
-	public Boolean delete(String id) {
-		String[] ids = String.valueOf(id).split(",");
-		for (String tt:ids) {
-			MarketCircleInfo tmp =  marketCircleInfoMapper.selectById(Long.parseLong(tt));
-			if(tmp != null){
-				tmp.setDeleteFlag(1);
-				marketCircleInfoMapper.updateById(tmp);
-			}
-		}
-		return true;
-	}
-
-	@Override
-	public Boolean update(MarketCircleInfo marketCircleInfo,Long adminId) throws ServiceException {
-		Date now = new Date();
-		marketCircleInfo.setGmtUpdate(now);
-		marketCircleInfo.setAdminId(adminId);
-		return marketCircleInfoMapper.updateById(marketCircleInfo)>0;
-	}
-
-	@Override
-	public MarketCircleInfo get(Long id) throws ServiceException {
-		return marketCircleInfoMapper.selectById(id);
-	}
-	
-	@Override
-	public String export(Long companyId,Long shopId,String content,String status,String url,Integer deleteFlag,Date gmtCreate,Date gmtUpdate,Long userId,Long adminId, Integer page, Integer limit)throws ServiceException {
-		Wrapper<MarketCircleInfo> wrapper = new EntityWrapper<MarketCircleInfo>();
-														if (!StringUtils.isEmpty(companyId)) {
-					wrapper.eq("company_id", companyId);
-				}
-												if (!StringUtils.isEmpty(shopId)) {
-					wrapper.eq("shop_id", shopId);
-				}
-												if (!StringUtils.isEmpty(content)) {
-					wrapper.eq("content", content);
-				}
-												if (!StringUtils.isEmpty(status)) {
-					wrapper.eq("status", status);
-				}
-												if (!StringUtils.isEmpty(url)) {
-					wrapper.eq("url", url);
-				}
-												if (!StringUtils.isEmpty(deleteFlag)) {
-					wrapper.eq("delete_flag", deleteFlag);
-				}
-												if (!StringUtils.isEmpty(gmtCreate)) {
-					wrapper.eq("gmt_create", gmtCreate);
-				}
-												if (!StringUtils.isEmpty(gmtUpdate)) {
-					wrapper.eq("gmt_update", gmtUpdate);
-				}
-												if (!StringUtils.isEmpty(userId)) {
-					wrapper.eq("user_id", userId);
-				}
-												if (!StringUtils.isEmpty(adminId)) {
-					wrapper.eq("admin_id", adminId);
-				}
-							List<MarketCircleInfo> list = marketCircleInfoMapper.selectList(wrapper);
-		ExcelUtil<MarketCircleInfo> util = new ExcelUtil<MarketCircleInfo>(MarketCircleInfo.class);
-		return util.exportExcel(list, "操作日志");
-	}
-}

+ 0 - 149
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/impl/MarketOrderDetailServiceImpl.java

@@ -1,149 +0,0 @@
-package com.iotechn.unimall.admin.api.market.impl;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.admin.api.market.IMarketOrderDetailService;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketOrderDetail;
-import com.iotechn.unimall.data.mapper.market.MarketOrderDetailMapper;
-import com.iotechn.unimall.data.model.Page;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.StringUtils;
-
-import java.util.Date;
-import java.util.List;
-
-/**
- * 订单详情Service业务层处理
- *
- * @author jlb
- * @date 2022-08-01
- */
-@Service
-public class MarketOrderDetailServiceImpl implements IMarketOrderDetailService {
-    @Autowired
-    private MarketOrderDetailMapper marketOrderDetailMapper;
-
-    @Override
-    public Boolean add(MarketOrderDetail marketOrderDetail, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketOrderDetail.setGmtCreate(now);
-        marketOrderDetail.setGmtUpdate(now);
-        marketOrderDetail.setAdminId(adminId);
-        return marketOrderDetailMapper.insert(marketOrderDetail) > 0;
-    }
-
-    @Override
-    public Page<MarketOrderDetail> list(Long companyId, String orderId, String name, Double price, Long num, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketOrderDetail> wrapper = new EntityWrapper<MarketOrderDetail>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(orderId)) {
-            wrapper.eq("order_id", orderId);
-        }
-        if (!StringUtils.isEmpty(name)) {
-            wrapper.eq("name", name);
-        }
-        if (!StringUtils.isEmpty(price)) {
-            wrapper.eq("price", price);
-        }
-        if (!StringUtils.isEmpty(num)) {
-            wrapper.eq("num", num);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        wrapper.eq("delete_flag", 0);
-        List<MarketOrderDetail> list = marketOrderDetailMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-        Integer count = marketOrderDetailMapper.selectCount(wrapper);
-        return new Page<MarketOrderDetail>(list, page, limit, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt : ids) {
-            MarketOrderDetail tmp = marketOrderDetailMapper.selectById(Long.parseLong(tt));
-            if (tmp != null) {
-                tmp.setDeleteFlag(1);
-                marketOrderDetailMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(MarketOrderDetail marketOrderDetail, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketOrderDetail.setGmtUpdate(now);
-        marketOrderDetail.setAdminId(adminId);
-        return marketOrderDetailMapper.updateById(marketOrderDetail) > 0;
-    }
-
-    @Override
-    public MarketOrderDetail get(Long id) throws ServiceException {
-        return marketOrderDetailMapper.selectById(id);
-    }
-
-    @Override
-    public String export(Long companyId, String orderId, String name, Double price, Long num, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketOrderDetail> wrapper = new EntityWrapper<MarketOrderDetail>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(orderId)) {
-            wrapper.eq("order_id", orderId);
-        }
-        if (!StringUtils.isEmpty(name)) {
-            wrapper.eq("name", name);
-        }
-        if (!StringUtils.isEmpty(price)) {
-            wrapper.eq("price", price);
-        }
-        if (!StringUtils.isEmpty(num)) {
-            wrapper.eq("num", num);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        List<MarketOrderDetail> list = marketOrderDetailMapper.selectList(wrapper);
-        ExcelUtil<MarketOrderDetail> util = new ExcelUtil<MarketOrderDetail>(MarketOrderDetail.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 146
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/impl/MarketOrderInfoServiceImpl.java

@@ -1,146 +0,0 @@
-package com.iotechn.unimall.admin.api.market.impl;
-
-import java.util.List;
-
-import com.iotechn.unimall.admin.api.market.IMarketOrderInfoService;
-import com.iotechn.unimall.data.domain.market.MarketOrderInfo;
-import com.iotechn.unimall.data.mapper.market.MarketOrderInfoMapper;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.StringUtils;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 订单信息Service业务层处理
- *
- * @author jlb
- * @date 2022-08-01
- */
-@Service
-public class MarketOrderInfoServiceImpl implements IMarketOrderInfoService {
-    @Autowired
-    private MarketOrderInfoMapper marketOrderInfoMapper;
-
-    @Override
-    public Boolean add(MarketOrderInfo marketOrderInfo, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketOrderInfo.setGmtCreate(now);
-        marketOrderInfo.setGmtUpdate(now);
-        marketOrderInfo.setAdminId(adminId);
-        return marketOrderInfoMapper.insert(marketOrderInfo) > 0;
-    }
-
-    @Override
-    public Page<MarketOrderInfo> list(Long companyId, String orderNo, String customer, String pets, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketOrderInfo> wrapper = new EntityWrapper<MarketOrderInfo>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(orderNo)) {
-            wrapper.eq("order_no", orderNo);
-        }
-        if (!StringUtils.isEmpty(customer)) {
-            wrapper.eq("customer", customer);
-        }
-        if (!StringUtils.isEmpty(pets)) {
-            wrapper.eq("pets", pets);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        wrapper.eq("delete_flag", 0);
-        List<MarketOrderInfo> list = marketOrderInfoMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-        Integer count = marketOrderInfoMapper.selectCount(wrapper);
-        return new Page<MarketOrderInfo>(list, page, limit, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt : ids) {
-            MarketOrderInfo tmp = marketOrderInfoMapper.selectById(Long.parseLong(tt));
-            if (tmp != null) {
-                tmp.setDeleteFlag(1);
-                marketOrderInfoMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(MarketOrderInfo marketOrderInfo, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketOrderInfo.setGmtUpdate(now);
-        marketOrderInfo.setAdminId(adminId);
-        return marketOrderInfoMapper.updateById(marketOrderInfo) > 0;
-    }
-
-    @Override
-    public MarketOrderInfo get(Long id) throws ServiceException {
-        return marketOrderInfoMapper.selectById(id);
-    }
-
-    @Override
-    public String export(Long companyId, String orderNo, String customer, String pets, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketOrderInfo> wrapper = new EntityWrapper<MarketOrderInfo>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(orderNo)) {
-            wrapper.eq("order_no", orderNo);
-        }
-        if (!StringUtils.isEmpty(customer)) {
-            wrapper.eq("customer", customer);
-        }
-        if (!StringUtils.isEmpty(pets)) {
-            wrapper.eq("pets", pets);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        List<MarketOrderInfo> list = marketOrderInfoMapper.selectList(wrapper);
-        ExcelUtil<MarketOrderInfo> util = new ExcelUtil<MarketOrderInfo>(MarketOrderInfo.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 164
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/impl/MarketProdectInfoServiceImpl.java

@@ -1,164 +0,0 @@
-package com.iotechn.unimall.admin.api.market.impl;
-
-import java.util.List;
-
-import com.iotechn.unimall.admin.api.market.IMarketProdectInfoService;
-import com.iotechn.unimall.data.domain.market.MarketProdectInfo;
-import com.iotechn.unimall.data.mapper.market.MarketProdectInfoMapper;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.StringUtils;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 商品信息Service业务层处理
- *
- * @author jlb
- * @date 2022-08-01
- */
-@Service
-public class MarketProdectInfoServiceImpl implements IMarketProdectInfoService {
-    @Autowired
-    private MarketProdectInfoMapper marketProdectInfoMapper;
-
-    @Override
-    public Boolean add(MarketProdectInfo marketProdectInfo, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketProdectInfo.setGmtCreate(now);
-        marketProdectInfo.setGmtUpdate(now);
-        marketProdectInfo.setAdminId(adminId);
-        return marketProdectInfoMapper.insert(marketProdectInfo) > 0;
-    }
-
-    @Override
-    public Page<MarketProdectInfo> list(Long companyId, String prodectName, String classificationKey, String classification, String url, String productDetails, Double commodityPrice, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketProdectInfo> wrapper = new EntityWrapper<MarketProdectInfo>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(prodectName)) {
-            wrapper.eq("prodect_name", prodectName);
-        }
-        if (!StringUtils.isEmpty(classificationKey)) {
-            wrapper.eq("classification_key", classificationKey);
-        }
-        if (!StringUtils.isEmpty(classification)) {
-            wrapper.eq("classification", classification);
-        }
-        if (!StringUtils.isEmpty(url)) {
-            wrapper.eq("url", url);
-        }
-        if (!StringUtils.isEmpty(productDetails)) {
-            wrapper.eq("product_details", productDetails);
-        }
-        if (!StringUtils.isEmpty(commodityPrice)) {
-            wrapper.eq("commodity price", commodityPrice);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        wrapper.eq("delete_flag", 0);
-        List<MarketProdectInfo> list = marketProdectInfoMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-        Integer count = marketProdectInfoMapper.selectCount(wrapper);
-        return new Page<MarketProdectInfo>(list, page, limit, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt : ids) {
-            MarketProdectInfo tmp = marketProdectInfoMapper.selectById(Long.parseLong(tt));
-            if (tmp != null) {
-                tmp.setDeleteFlag(1);
-                marketProdectInfoMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(MarketProdectInfo marketProdectInfo, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketProdectInfo.setGmtUpdate(now);
-        marketProdectInfo.setAdminId(adminId);
-        return marketProdectInfoMapper.updateById(marketProdectInfo) > 0;
-    }
-
-    @Override
-    public MarketProdectInfo get(Long id) throws ServiceException {
-        return marketProdectInfoMapper.selectById(id);
-    }
-
-    @Override
-    public String export(Long companyId, String prodectName, String classificationKey, String classification, String url, String productDetails, Double commodityPrice, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketProdectInfo> wrapper = new EntityWrapper<MarketProdectInfo>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(prodectName)) {
-            wrapper.eq("prodect_name", prodectName);
-        }
-        if (!StringUtils.isEmpty(classificationKey)) {
-            wrapper.eq("classification_key", classificationKey);
-        }
-        if (!StringUtils.isEmpty(classification)) {
-            wrapper.eq("classification", classification);
-        }
-        if (!StringUtils.isEmpty(url)) {
-            wrapper.eq("url", url);
-        }
-        if (!StringUtils.isEmpty(productDetails)) {
-            wrapper.eq("product_details", productDetails);
-        }
-        if (!StringUtils.isEmpty(commodityPrice)) {
-            wrapper.eq("commodity price", commodityPrice);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        List<MarketProdectInfo> list = marketProdectInfoMapper.selectList(wrapper);
-        ExcelUtil<MarketProdectInfo> util = new ExcelUtil<MarketProdectInfo>(MarketProdectInfo.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 158
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/impl/MarketReceivingAddressServiceImpl.java

@@ -1,158 +0,0 @@
-package com.iotechn.unimall.admin.api.market.impl;
-
-import java.util.List;
-
-import com.iotechn.unimall.admin.api.market.IMarketReceivingAddressService;
-import com.iotechn.unimall.data.domain.market.MarketReceivingAddress;
-import com.iotechn.unimall.data.mapper.market.MarketReceivingAddressMapper;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.StringUtils;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 收货地址Service业务层处理
- *
- * @author jlb
- * @date 2022-08-01
- */
-@Service
-public class MarketReceivingAddressServiceImpl implements IMarketReceivingAddressService {
-    @Autowired
-    private MarketReceivingAddressMapper marketReceivingAddressMapper;
-
-    @Override
-    public Boolean add(MarketReceivingAddress marketReceivingAddress, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketReceivingAddress.setGmtCreate(now);
-        marketReceivingAddress.setGmtUpdate(now);
-        marketReceivingAddress.setAdminId(adminId);
-        return marketReceivingAddressMapper.insert(marketReceivingAddress) > 0;
-    }
-
-    @Override
-    public Page<MarketReceivingAddress> list(Long companyId, String cusId, String consigneeName, String phone, String location, String address, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketReceivingAddress> wrapper = new EntityWrapper<MarketReceivingAddress>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(cusId)) {
-            wrapper.eq("cus_id", cusId);
-        }
-        if (!StringUtils.isEmpty(consigneeName)) {
-            wrapper.eq("consignee_name", consigneeName);
-        }
-        if (!StringUtils.isEmpty(phone)) {
-            wrapper.eq("phone", phone);
-        }
-        if (!StringUtils.isEmpty(location)) {
-            wrapper.eq("location", location);
-        }
-        if (!StringUtils.isEmpty(address)) {
-            wrapper.eq("address", address);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        wrapper.eq("delete_flag", 0);
-        List<MarketReceivingAddress> list = marketReceivingAddressMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-        Integer count = marketReceivingAddressMapper.selectCount(wrapper);
-        return new Page<MarketReceivingAddress>(list, page, limit, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt : ids) {
-            MarketReceivingAddress tmp = marketReceivingAddressMapper.selectById(Long.parseLong(tt));
-            if (tmp != null) {
-                tmp.setDeleteFlag(1);
-                marketReceivingAddressMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(MarketReceivingAddress marketReceivingAddress, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketReceivingAddress.setGmtUpdate(now);
-        marketReceivingAddress.setAdminId(adminId);
-        return marketReceivingAddressMapper.updateById(marketReceivingAddress) > 0;
-    }
-
-    @Override
-    public MarketReceivingAddress get(Long id) throws ServiceException {
-        return marketReceivingAddressMapper.selectById(id);
-    }
-
-    @Override
-    public String export(Long companyId, String cusId, String consigneeName, String phone, String location, String address, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketReceivingAddress> wrapper = new EntityWrapper<MarketReceivingAddress>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(cusId)) {
-            wrapper.eq("cus_id", cusId);
-        }
-        if (!StringUtils.isEmpty(consigneeName)) {
-            wrapper.eq("consignee_name", consigneeName);
-        }
-        if (!StringUtils.isEmpty(phone)) {
-            wrapper.eq("phone", phone);
-        }
-        if (!StringUtils.isEmpty(location)) {
-            wrapper.eq("location", location);
-        }
-        if (!StringUtils.isEmpty(address)) {
-            wrapper.eq("address", address);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        List<MarketReceivingAddress> list = marketReceivingAddressMapper.selectList(wrapper);
-        ExcelUtil<MarketReceivingAddress> util = new ExcelUtil<MarketReceivingAddress>(MarketReceivingAddress.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 167
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/market/impl/MarketShopInfoServiceImpl.java

@@ -1,167 +0,0 @@
-package com.iotechn.unimall.admin.api.market.impl;
-
-import java.util.List;
-
-import com.iotechn.unimall.admin.api.market.IMarketShopInfoService;
-import com.iotechn.unimall.data.domain.market.MarketShopInfo;
-import com.iotechn.unimall.data.mapper.market.MarketShopInfoMapper;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.StringUtils;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 商店信息Service业务层处理
- *
- * @author jlb
- * @date 2022-08-01
- */
-@Service
-public class MarketShopInfoServiceImpl implements IMarketShopInfoService {
-    @Autowired
-    private MarketShopInfoMapper marketShopInfoMapper;
-
-
-    @Override
-    public Boolean add(MarketShopInfo marketShopInfo, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketShopInfo.setGmtCreate(now);
-        marketShopInfo.setGmtUpdate(now);
-        marketShopInfo.setAdminId(adminId);
-        return marketShopInfoMapper.insert(marketShopInfo) > 0;
-    }
-
-
-    @Override
-    public Page<MarketShopInfo> list(Long companyId, String name, String postion, String url, String phone, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, String level, String caseWorld, String lon, String lat, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketShopInfo> wrapper = new EntityWrapper<MarketShopInfo>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(name)) {
-            wrapper.eq("name", name);
-        }
-        if (!StringUtils.isEmpty(postion)) {
-            wrapper.eq("postion", postion);
-        }
-        if (!StringUtils.isEmpty(url)) {
-            wrapper.eq("url", url);
-        }
-        if (!StringUtils.isEmpty(phone)) {
-            wrapper.eq("phone", phone);
-        }
-        if (!StringUtils.isEmpty(level)) {
-            wrapper.eq("level", level);
-        }
-        if (!StringUtils.isEmpty(caseWorld)) {
-            wrapper.eq("caseWorld", caseWorld);
-        }
-        if (!StringUtils.isEmpty(lon)) {
-            wrapper.eq("lon", lon);
-        }
-        if (!StringUtils.isEmpty(lat)) {
-            wrapper.eq("lat", lat);
-        }
-
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        wrapper.eq("delete_flag", 0);
-        List<MarketShopInfo> list = marketShopInfoMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-        Integer count = marketShopInfoMapper.selectCount(wrapper);
-        return new Page<MarketShopInfo>(list, page, limit, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt : ids) {
-            MarketShopInfo tmp = marketShopInfoMapper.selectById(Long.parseLong(tt));
-            if (tmp != null) {
-                tmp.setDeleteFlag(1);
-                marketShopInfoMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(MarketShopInfo marketShopInfo, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketShopInfo.setGmtUpdate(now);
-        marketShopInfo.setAdminId(adminId);
-        return marketShopInfoMapper.updateById(marketShopInfo) > 0;
-    }
-
-    @Override
-    public MarketShopInfo get(Long id) throws ServiceException {
-        return marketShopInfoMapper.selectById(id);
-    }
-
-    @Override
-    public String export(Long companyId, String name, String postion, String url, String phone, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketShopInfo> wrapper = new EntityWrapper<MarketShopInfo>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(name)) {
-            wrapper.eq("name", name);
-        }
-        if (!StringUtils.isEmpty(postion)) {
-            wrapper.eq("postion", postion);
-        }
-        if (!StringUtils.isEmpty(url)) {
-            wrapper.eq("url", url);
-        }
-        if (!StringUtils.isEmpty(phone)) {
-            wrapper.eq("phone", phone);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        List<MarketShopInfo> list = marketShopInfoMapper.selectList(wrapper);
-        ExcelUtil<MarketShopInfo> util = new ExcelUtil<MarketShopInfo>(MarketShopInfo.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 57
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/order/AdminOrderService.java

@@ -1,57 +0,0 @@
-package com.iotechn.unimall.admin.api.order;
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.annotation.param.Range;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.OrderDO;
-import com.iotechn.unimall.data.dto.order.OrderDTO;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.List;
-
-/**
- * Created by rize on 2019/7/10.
- */
-@HttpOpenApi(group = "admin.order", description = "管理员订单服务")
-public interface AdminOrderService {
-
-    @HttpMethod(description = "列表", permission = "operation:order:list", permissionParentName = "运营管理", permissionName = "订单管理")
-    public Page<OrderDO> list(
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "订单页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "订单状态") Integer status,
-            @HttpParam(name = "orderNo", type = HttpParamType.COMMON, description = "订单号") String orderNo,
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员Id") Long adminId) throws ServiceException;
-
-
-    @HttpMethod(description = "退款", permission = "operation:order:refund", permissionParentName = "运营管理", permissionName = "订单管理")
-    public String refund(
-            @NotNull @HttpParam(name = "orderNo", type = HttpParamType.COMMON, description = "订单号") String orderNo,
-            @NotNull @HttpParam(name = "type", type = HttpParamType.COMMON, description = "0.拒绝退款 1.同意退款") Integer type,
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员Id") Long adminId) throws ServiceException;
-
-
-    @HttpMethod(description = "发货", permission = "operation:order:ship", permissionParentName = "运营管理", permissionName = "订单管理")
-    public String ship(
-            @NotNull @HttpParam(name = "orderNo", type = HttpParamType.COMMON, description = "订单号") String orderNo,
-            @NotNull @HttpParam(name = "shipCode", type = HttpParamType.COMMON, description = "承运商Code") String shipCode,
-            @HttpParam(name = "shipNo", type = HttpParamType.COMMON, description = "运单号") String shipNo,
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员Id") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "详情", permission = "operation:order:detail", permissionParentName = "运营管理", permissionName = "订单管理")
-    public OrderDTO detail(
-            @NotNull @HttpParam(name = "orderId", type = HttpParamType.COMMON, description = "订单Id") Long orderNo,
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员Id") Long adminId) throws ServiceException;
-
-
-    @HttpMethod(description = "根据传入时间和订单状态查询订单信息")
-    public List<OrderDTO> queryToExcel(
-            @HttpParam(name = "gmtStart", type = HttpParamType.COMMON, description = "查询开始时间") Long gmtStart,
-            @HttpParam(name = "gmtEnd", type = HttpParamType.COMMON, description = "查询结束时间") Long gmtEnd,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "订单状态", valueDef = "20") Integer status,
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员Id") Long adminId) throws ServiceException;
-}

+ 0 - 198
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/order/AdminOrderServiceImpl.java

@@ -1,198 +0,0 @@
-package com.iotechn.unimall.admin.api.order;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.github.binarywang.wxpay.bean.request.WxPayRefundRequest;
-import com.github.binarywang.wxpay.bean.result.WxPayRefundResult;
-import com.github.binarywang.wxpay.service.WxPayService;
-import com.iotechn.unimall.biz.service.order.OrderBizService;
-import com.iotechn.unimall.core.exception.AdminServiceException;
-import com.iotechn.unimall.core.exception.ExceptionDefinition;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.component.LockComponent;
-import com.iotechn.unimall.data.domain.OrderDO;
-import com.iotechn.unimall.data.domain.OrderSkuDO;
-import com.iotechn.unimall.data.domain.UserDO;
-import com.iotechn.unimall.data.dto.order.OrderDTO;
-import com.iotechn.unimall.data.enums.OrderStatusType;
-import com.iotechn.unimall.data.enums.UserLoginType;
-import com.iotechn.unimall.data.mapper.OrderMapper;
-import com.iotechn.unimall.data.mapper.OrderSkuMapper;
-import com.iotechn.unimall.data.mapper.UserMapper;
-import com.iotechn.unimall.data.model.Page;
-import org.apache.ibatis.session.RowBounds;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.springframework.beans.BeanUtils;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.beans.factory.annotation.Value;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.StringUtils;
-
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.List;
-
-/**
- * Created by rize on 2019/7/10.
- */
-@Service
-public class AdminOrderServiceImpl implements AdminOrderService {
-
-    private static final Logger logger = LoggerFactory.getLogger(AdminOrderServiceImpl.class);
-
-    @Autowired
-    private OrderBizService orderBizService;
-
-    @Autowired
-    private WxPayService wxPayService;
-
-    @Autowired
-    private OrderMapper orderMapper;
-
-    @Autowired
-    private OrderSkuMapper orderSkuMapper;
-
-    @Autowired
-    private LockComponent lockComponent;
-
-    @Autowired
-    private UserMapper userMapper;
-
-    @Value("${com.iotechn.unimall.wx.mini.app-id}")
-    private String wxMiNiAppid;
-
-    @Value("${com.iotechn.unimall.wx.app.app-id}")
-    private String wxAppAppid;
-
-    @Override
-    public Page<OrderDO> list(Integer pageNo, Integer pageSize, Integer status, String orderNo, Long adminId) throws ServiceException {
-        Wrapper<OrderDO> wrapper = new EntityWrapper<OrderDO>();
-        wrapper.orderBy("id", false);
-        if (!StringUtils.isEmpty(orderNo)) {
-            wrapper.eq("order_no", orderNo);
-        }
-        if (status != null) {
-            wrapper.eq("status", status);
-        }
-        List<OrderDO> orderDOS = orderMapper.selectPage(new RowBounds((pageNo - 1) * pageSize, pageSize), wrapper);
-        Integer count = orderMapper.selectCount(wrapper);
-        return new Page<OrderDO>(orderDOS, pageNo, pageSize, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public String refund(String orderNo, Integer type, Long adminId) throws ServiceException {
-        if (lockComponent.tryLock(OrderBizService.ORDER_REFUND_LOCK + orderNo, 30)) {
-            try {
-                //1.校验订单状态是否处于退款中
-                OrderDO orderDO = orderBizService.checkOrderExist(orderNo, null);
-                if (orderDO.getStatus() != OrderStatusType.REFUNDING.getCode()) {
-                    throw new AdminServiceException(ExceptionDefinition.ORDER_STATUS_NOT_SUPPORT_REFUND);
-                }
-                //2.退款处理
-                if (type == 0) {
-                    //2.1 店主拒绝退款
-                    OrderDO updateOrderDO = new OrderDO();
-                    updateOrderDO.setStatus(OrderStatusType.WAIT_CONFIRM.getCode());
-                    updateOrderDO.setGmtUpdate(new Date());
-                    orderBizService.changeOrderStatus(orderNo, OrderStatusType.REFUNDING.getCode(), updateOrderDO);
-                    return "ok";
-                } else if (type == 1) {
-                    //2.2 店主同意退款
-                    //2.2.1 先流转状态
-                    OrderDO updateOrderDO = new OrderDO();
-                    updateOrderDO.setStatus(OrderStatusType.REFUNDED.getCode());
-                    updateOrderDO.setGmtUpdate(new Date());
-                    orderBizService.changeOrderStatus(orderNo, OrderStatusType.REFUNDING.getCode(), updateOrderDO);
-                    Long userId = orderDO.getUserId();
-                    UserDO userDO = userMapper.selectById(userId);
-                    Integer loginType = userDO.getLoginType();
-                    //2.2.2 向微信支付平台发送退款请求
-                    WxPayRefundRequest wxPayRefundRequest = new WxPayRefundRequest();
-                    wxPayRefundRequest.setAppid(loginType == UserLoginType.MP_WEIXIN.getCode() ? wxMiNiAppid : wxAppAppid);
-                    wxPayRefundRequest.setOutTradeNo(orderNo);
-                    wxPayRefundRequest.setOutRefundNo("refund_" + orderNo);
-                    wxPayRefundRequest.setTotalFee(orderDO.getPayPrice() - orderDO.getFreightPrice());
-                    wxPayRefundRequest.setRefundFee(orderDO.getPayPrice() - orderDO.getFreightPrice());
-                    WxPayRefundResult wxPayRefundResult = wxPayService.refund(wxPayRefundRequest);
-                    if (!wxPayRefundResult.getReturnCode().equals("SUCCESS")) {
-                        logger.warn("[微信退款] 失败 : " + wxPayRefundResult.getReturnMsg());
-                        throw new AdminServiceException(wxPayRefundResult.getReturnMsg(),
-                                ExceptionDefinition.THIRD_PART_SERVICE_EXCEPTION.getCode());
-                    }
-                    if (!wxPayRefundResult.getResultCode().equals("SUCCESS")) {
-                        logger.warn("[微信退款] 失败 : " + wxPayRefundResult.getReturnMsg());
-                        throw new AdminServiceException(wxPayRefundResult.getReturnMsg(),
-                                ExceptionDefinition.THIRD_PART_SERVICE_EXCEPTION.getCode());
-                    }
-                    return "ok";
-                } else {
-                    throw new AdminServiceException(ExceptionDefinition.PARAM_CHECK_FAILED);
-                }
-            } catch (ServiceException e) {
-                throw e;
-            } catch (Exception e) {
-                logger.error("[微信退款] 异常", e);
-                throw new AdminServiceException(ExceptionDefinition.ADMIN_UNKNOWN_EXCEPTION);
-            } finally {
-                lockComponent.release(OrderBizService.ORDER_REFUND_LOCK + orderNo);
-            }
-        } else {
-            throw new AdminServiceException(ExceptionDefinition.SYSTEM_BUSY);
-        }
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public String ship(String orderNo, String shipCode, String shipNo, Long adminId) throws ServiceException {
-        orderBizService.checkOrderExist(orderNo, null);
-        OrderDO updateOrderDO = new OrderDO();
-        Date now = new Date();
-        updateOrderDO.setGmtUpdate(now);
-        updateOrderDO.setGmtShip(now);
-        updateOrderDO.setStatus(OrderStatusType.WAIT_CONFIRM.getCode());
-        if (!"NONE".equals(shipCode)) {
-            updateOrderDO.setShipCode(shipCode);
-            updateOrderDO.setShipNo(shipNo);
-        }
-        //流转订单状态
-        orderBizService.changeOrderStatus(orderNo, OrderStatusType.WAIT_STOCK.getCode(), updateOrderDO);
-        return "ok";
-    }
-
-    @Override
-    public OrderDTO detail(Long orderId, Long adminId) throws ServiceException {
-        return orderBizService.getOrderDetail(orderId, null);
-    }
-
-    @Override
-    public List<OrderDTO> queryToExcel(Long gmtStart, Long gmtEnd, Integer status, Long adminId) throws ServiceException {
-        EntityWrapper wrapper = new EntityWrapper();
-        if(gmtStart != null && gmtEnd != null){
-            if(gmtStart > gmtStart){
-                throw new AdminServiceException(ExceptionDefinition.ORDER_EXCEL_PARAM_ERROR);
-            }
-            wrapper.between("gmt_create",new Date(gmtStart) ,new Date(gmtEnd));
-        }
-        if(status != null){
-            wrapper.eq("status", status);
-        }
-        List<OrderDO> orderDOS = orderMapper.selectList(wrapper);
-        if(orderDOS == null || orderDOS.size() == 0){
-            return null;
-        }
-        List<OrderDTO> orderDTOList = new ArrayList<>();
-        for (OrderDO temp: orderDOS ) {
-            OrderDTO orderDTO = new OrderDTO();
-            BeanUtils.copyProperties(temp, orderDTO);
-            orderDTOList.add(orderDTO);
-        }
-        for (OrderDTO orderDTO:orderDTOList) {
-                List<OrderSkuDO> orderSkuDOList =  orderSkuMapper.selectList(new EntityWrapper<OrderSkuDO>().eq("order_no",orderDTO.getOrderNo() ));
-                orderDTO.setSkuList(orderSkuDOList);
-        }
-        return orderDTOList;
-    }
-}

+ 0 - 54
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/recommend/AdminRecommendService.java

@@ -1,54 +0,0 @@
-package com.iotechn.unimall.admin.api.recommend;
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.annotation.param.Range;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.RecommendDO;
-import com.iotechn.unimall.data.dto.RecommendDTO;
-import com.iotechn.unimall.data.model.Page;
-import org.apache.ibatis.annotations.Param;
-
-import java.rmi.ServerException;
-import java.util.List;
-
-/**
- * Created with IntelliJ IDEA.
- * Description:
- * User: kbq
- * Date: 2019-07-08
- * Time: 下午3:42
- */
-
-@HttpOpenApi(group = "admin.recommend", description = "推荐商品")
-public interface AdminRecommendService {
-
-    @HttpMethod(description = "创建", permission = "promote:recommend:create", permissionParentName = "推广管理", permissionName = "推荐管理")
-    public Boolean addRecommend(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId,
-            @NotNull @HttpParam(name = "spuId", type = HttpParamType.COMMON, description = "商品Id") Long spuId,
-            @NotNull @HttpParam(name = "recommendType", type = HttpParamType.COMMON, description = "推荐类型") Integer recommendType) throws ServiceException;
-
-    @HttpMethod(description = "删除", permission = "promote:recommend:delete", permissionParentName = "推广管理", permissionName = "推荐管理")
-    public Boolean deleteRecommend(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId,
-            @NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "推荐id") Long id,
-            @NotNull @HttpParam(name = "recommendType", type = HttpParamType.COMMON, description = "推荐类型") Integer recommendType) throws ServiceException;
-
-    @HttpMethod(description = "查询", permission = "promote:recommend:query", permissionParentName = "推广管理", permissionName = "推荐管理")
-    public Page<RecommendDTO> queryRecommendByType(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId,
-            @HttpParam(name = "recommendType", type = HttpParamType.COMMON, description = "推荐类型") Integer recommendType,
-            @Range(min = 1) @HttpParam(name = "pageNo", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer pageNo,
-            @Range(min = 1) @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页面长度", valueDef = "10") Integer pageSize) throws ServiceException;
-
-    @HttpMethod(description = "查询", permission = "promote:recommend:query", permissionParentName = "推广管理", permissionName = "推荐管理")
-    public Page<RecommendDTO> queryAllRecommend(
-            @NotNull @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "管理员ID") Long adminId,
-            @Range(min = 1) @HttpParam(name = "pageNo", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer pageNo,
-            @Range(min = 1) @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页面长度", valueDef = "10") Integer pageSize) throws ServiceException;
-
-}

+ 0 - 99
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/recommend/AdminRecommendServiceImpl.java

@@ -1,99 +0,0 @@
-package com.iotechn.unimall.admin.api.recommend;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.iotechn.unimall.biz.service.recommend.RecommendBizService;
-import com.iotechn.unimall.core.exception.AdminServiceException;
-import com.iotechn.unimall.core.exception.ExceptionDefinition;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.component.CacheComponent;
-import com.iotechn.unimall.data.domain.RecommendDO;
-import com.iotechn.unimall.data.domain.SpuDO;
-import com.iotechn.unimall.data.dto.RecommendDTO;
-import com.iotechn.unimall.data.mapper.RecommendMapper;
-import com.iotechn.unimall.data.mapper.SpuMapper;
-import com.iotechn.unimall.data.model.Page;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-
-import java.util.Date;
-import java.util.List;
-
-/**
- * Created with IntelliJ IDEA.
- * Description:
- * User: kbq
- * Date: 2019-07-08
- * Time: 下午5:47
- */
-@Service
-public class AdminRecommendServiceImpl implements AdminRecommendService {
-
-    @Autowired
-    private CacheComponent cacheComponent;
-    @Autowired
-    private RecommendMapper recommendMapper;
-    @Autowired
-    private SpuMapper spuMapper;
-    @Autowired
-    private RecommendBizService recommendBizService;
-
-    private final static String RECOMMEND_NAME = "RECOMMEND_TYPE_";
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean addRecommend(Long adminId, Long spuId, Integer recommendType) throws ServiceException {
-
-        if (!(spuMapper.selectCount(new EntityWrapper<SpuDO>().eq("id", spuId)) > 0)) {
-            throw new AdminServiceException(ExceptionDefinition.RECOMMEND_SPU_NO_HAS);
-        }
-
-        if (recommendMapper.selectCount(new EntityWrapper<RecommendDO>()
-                .eq("spu_id", spuId)
-                .eq("recommend_type", recommendType)) > 0) {
-            throw new AdminServiceException(ExceptionDefinition.RECOMMEND_ALREADY_HAS);
-        }
-        RecommendDO recommendDO = new RecommendDO(spuId, recommendType);
-        Date now = new Date();
-        recommendDO.setGmtCreate(now);
-        recommendDO.setGmtUpdate(now);
-        if (!(recommendMapper.insert(recommendDO) > 0)) {
-            throw new AdminServiceException(ExceptionDefinition.RECOMMEND_SQL_ADD_FAILED);
-        }
-        cacheComponent.delPrefixKey(RECOMMEND_NAME+recommendType);
-        return true;
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean deleteRecommend(Long adminId, Long id, Integer recommendType) throws ServiceException {
-
-        Integer judgeSQL = recommendMapper.delete(new EntityWrapper<RecommendDO>()
-                .eq("id", id)
-                .eq("recommend_type",recommendType));
-
-        if(judgeSQL > 0){
-            cacheComponent.delPrefixKey(RECOMMEND_NAME + recommendType);
-            return true;
-        }
-
-        throw new AdminServiceException(ExceptionDefinition.RECOMMEND_SQL_DELETE_FAILED);
-    }
-
-    @Override
-    public Page<RecommendDTO> queryRecommendByType(Long adminId, Integer recommendType, Integer pageNo, Integer pageSize) throws ServiceException {
-        if(recommendType == null){
-            return recommendBizService.queryAllRecommend(pageNo, pageSize);
-        }
-
-        Integer count = recommendMapper.selectCount(new EntityWrapper<RecommendDO>().eq("recommend_type",recommendType));
-        List<RecommendDTO> recommendDTOList = recommendMapper.getRecommendByType(recommendType,(pageNo-1)*pageSize,pageSize);
-        Page<RecommendDTO> page = new Page<>(recommendDTOList,pageNo,pageSize,count);
-        return page;
-    }
-
-    @Override
-    public Page<RecommendDTO> queryAllRecommend(Long adminId, Integer pageNo, Integer pageSize) throws ServiceException {
-        return recommendBizService.queryAllRecommend(pageNo, pageSize);
-    }
-}

+ 0 - 67
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/address/AddressService.java

@@ -1,67 +0,0 @@
-package com.iotechn.unimall.app.api.address;
-
-/*
-@author kbq
-@date  2019/7/4 - 21:36
-*/
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.AddressDO;
-
-import java.rmi.ServerException;
-import java.util.List;
-
-@HttpOpenApi(group = "address", description = "收货地址")
-public interface AddressService {
-
-    @HttpMethod(description = "增加收货地址")
-    public Boolean addAddress(
-            @NotNull @HttpParam(name = "province", type = HttpParamType.COMMON, description = "省份") String province,
-            @NotNull @HttpParam(name = "city", type = HttpParamType.COMMON, description = "城市") String city,
-            @NotNull @HttpParam(name = "county", type = HttpParamType.COMMON, description = "区县") String county,
-            @NotNull @HttpParam(name = "address", type = HttpParamType.COMMON, description = "详细地址") String address,
-            @NotNull @HttpParam(name = "defaultAddress", type = HttpParamType.COMMON, description = "默认地址") Integer defaultAddress,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户ID") Long userId,
-            @NotNull @HttpParam(name = "phone", type = HttpParamType.COMMON, description = "电话") String phone,
-            @NotNull @HttpParam(name = "consignee", type = HttpParamType.COMMON, description = "收件人") String consignee) throws ServiceException;
-
-
-    @HttpMethod(description = "删除收货地址")
-    public Boolean deleteAddress(
-            @NotNull @HttpParam(name = "addressId", type = HttpParamType.COMMON, description = "收货地址ID") Long addressId,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户ID") Long userId) throws ServiceException;
-
-
-    @HttpMethod(description = "修改收货地址")
-    public Boolean updateAddress(
-            @NotNull @HttpParam(name = "addressId", type = HttpParamType.COMMON, description = "地址Id") Long addressId,
-            @NotNull @HttpParam(name = "province", type = HttpParamType.COMMON, description = "省份") String province,
-            @NotNull @HttpParam(name = "city", type = HttpParamType.COMMON, description = "城市") String city,
-            @NotNull @HttpParam(name = "county", type = HttpParamType.COMMON, description = "区县") String county,
-            @NotNull @HttpParam(name = "address", type = HttpParamType.COMMON, description = "详细地址") String address,
-            @NotNull @HttpParam(name = "defaultAddress", type = HttpParamType.COMMON, description = "默认地址") Integer defaultAddress,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户ID") Long userId,
-            @NotNull @HttpParam(name = "phone", type = HttpParamType.COMMON, description = "电话") String phone,
-            @NotNull @HttpParam(name = "consignee", type = HttpParamType.COMMON, description = "收件人") String consignee) throws ServiceException;
-
-
-    @HttpMethod(description = "查询用户所有收货地址")
-    public List<AddressDO> getAllAddress(
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId) throws ServiceException;
-
-
-    @HttpMethod(description = "根据地址ID,查询收货地址")
-    public AddressDO getAddressById(
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId,
-            @NotNull @HttpParam(name = "addressId", type = HttpParamType.COMMON, description = "地址Id") Long addressId) throws ServiceException;
-
-
-    @HttpMethod(description = "获取用户默认地址")
-    public AddressDO getDefAddress(
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户id") Long userId) throws ServiceException;
-}

+ 0 - 142
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/address/AddressServiceImpl.java

@@ -1,142 +0,0 @@
-package com.iotechn.unimall.app.api.address;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.iotechn.unimall.core.exception.ExceptionDefinition;
-import com.iotechn.unimall.core.exception.AppServiceException;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.AddressDO;
-import com.iotechn.unimall.data.mapper.AddressMapper;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.CollectionUtils;
-
-import java.util.Date;
-import java.util.List;
-
-/*
-@author kbq
-@date  2019/7/4 - 22:07
-*/
-@Service
-public class AddressServiceImpl implements AddressService {
-
-    @Autowired
-    private AddressMapper addressMapper;
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean addAddress(String province, String city, String county, String address, Integer defaultAddress, Long userId, String phone, String consignee) throws ServiceException {
-        Integer addressNum = addressMapper.selectCount(new EntityWrapper<AddressDO>().eq("user_id", userId));
-        AddressDO addressDO = null;
-        if (addressNum == 0) {
-            addressDO = new AddressDO(province, city, county, address, 1, userId, phone, consignee);
-        } else {
-            if (defaultAddress != 0) {
-                AddressDO preDefault = new AddressDO();
-                preDefault.setDefaultAddress(0);
-                if (!(addressMapper.update(preDefault //该用户有地址却没有默认地址,抛出该异常
-                        , new EntityWrapper<AddressDO>()
-                                .eq("user_id", userId)
-                                .eq("default_address", 1)) > 0)) {
-                    throw new AppServiceException(ExceptionDefinition.ADDRESS_QUERY_FAILED);
-                }
-                addressDO = new AddressDO(province, city, county, address, 1, userId, phone, consignee);
-            } else {
-                addressDO = new AddressDO(province, city, county, address, 0, userId, phone, consignee);
-            }
-        }
-        Date now = new Date();
-        addressDO.setGmtCreate(now);
-        addressDO.setGmtUpdate(now);
-        if (addressMapper.insert(addressDO) > 0) {
-            return true;
-        } else {
-            throw new AppServiceException(ExceptionDefinition.ADDRESS_DATABASE_QUERY_FAILED);
-        }
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean deleteAddress(Long addressId, Long userId) throws ServiceException {
-        Integer defaultNum = addressMapper.selectCount(new EntityWrapper<AddressDO>()
-                .eq("user_id", userId)
-                .eq("id", addressId)
-                .eq("default_address", 1));
-        if (defaultNum == 0) {
-            return addressMapper.delete(new EntityWrapper<AddressDO>()
-                    .eq("id", addressId)
-                    .eq("user_id", userId)) > 0;
-        } else {
-            if (!(addressMapper.delete(new EntityWrapper<AddressDO>()
-                    .eq("id", addressId)
-                    .eq("user_id", userId)) > 0)) {
-                throw new AppServiceException(ExceptionDefinition.ADDRESS_DATABASE_QUERY_FAILED);
-            } else {
-                List<AddressDO> addressDOS = addressMapper.selectList(new EntityWrapper<AddressDO>().eq("user_id", userId));
-                if (addressDOS.size() != 0) {
-                    AddressDO addressDO = addressDOS.get(0);
-                    addressDO.setDefaultAddress(1);
-                    return addressMapper.updateById(addressDO) > 0;
-                }
-                return true;
-            }
-        }
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean updateAddress(Long addressId, String province, String city, String county, String address, Integer defaultAddress, Long userId, String phone, String consignee) throws ServiceException {
-        AddressDO addressDO = new AddressDO(province, city, county, address, defaultAddress, userId, phone, consignee);
-        Date now = new Date();
-        if (defaultAddress != 0) {
-            defaultAddress = 1;
-            List<AddressDO> addressDOS = addressMapper.selectList(new EntityWrapper<AddressDO>().eq("user_id", userId).eq("default_address", 1));
-            if (addressDOS.size() != 0) {
-                AddressDO preDefault = addressDOS.get(0);
-                preDefault.setDefaultAddress(0);
-                addressMapper.updateById(preDefault);
-            }
-        }
-        addressDO.setDefaultAddress(defaultAddress);
-        addressDO.setGmtUpdate(now);
-        return addressMapper.update(addressDO, new EntityWrapper<AddressDO>()
-                .eq("id", addressId)
-                .eq("user_id", userId)) > 0;
-
-    }
-
-    @Override
-    public List<AddressDO> getAllAddress(Long userId) throws ServiceException {
-        return addressMapper.selectList(new EntityWrapper<AddressDO>()
-                .eq("user_id", userId));
-    }
-
-    @Override
-    public AddressDO getAddressById(Long userId, Long addressId) throws ServiceException {
-        AddressDO addressDO = new AddressDO();
-        addressDO.setUserId(userId);
-        addressDO.setId(addressId);
-        return addressMapper.selectOne(addressDO);
-    }
-
-    @Override
-    public AddressDO getDefAddress(Long userId) throws ServiceException {
-        List<AddressDO> addressDOS = addressMapper.selectList(
-                new EntityWrapper<AddressDO>()
-                        .eq("user_id", userId)
-                        .eq("default_address", 1));
-        if (CollectionUtils.isEmpty(addressDOS)) {
-            AddressDO addressDO = new AddressDO();
-            addressDO.setCity("XXX");
-            addressDO.setProvince("XXX");
-            addressDO.setCounty("XXX");
-            addressDO.setAddress("不需要收货地址");
-            addressDO.setConsignee("匿名");
-            addressDO.setPhone("XXXXXXXXXXX");
-            return addressDO;
-        } else {
-            return addressDOS.get(0);
-        }
-    }
-}

+ 0 - 51
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/appraise/AppraiseService.java

@@ -1,51 +0,0 @@
-package com.iotechn.unimall.app.api.appraise;
-
-/*
-@author kbq
-@date  2019/7/6 - 10:18
-*/
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.dto.appraise.AppraiseRequestDTO;
-import com.iotechn.unimall.data.dto.appraise.AppraiseResponseDTO;
-import com.iotechn.unimall.data.model.Page;
-
-@HttpOpenApi(group = "appraise", description = "评价商品")
-public interface AppraiseService {
-
-    @HttpMethod(description = "增加评价")
-    public Boolean addAppraise(
-            @NotNull @HttpParam(name = "appraiseRequestDTO", type = HttpParamType.COMMON, description = "来自订单的评价数据") AppraiseRequestDTO appraiseRequestDTO,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "上传用户ID") Long userId) throws ServiceException;
-
-    @HttpMethod(description = "根据评论Id删除评论")
-    public Boolean deleteAppraiseById(
-            @NotNull @HttpParam(name = "appraiseId", type = HttpParamType.COMMON, description = "评论ID") Long appraiseId,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "上传用户ID") Long userId) throws ServiceException;
-
-
-    @HttpMethod(description = "查询用户所有评论")
-    public Page<AppraiseResponseDTO> getUserAllAppraise(
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "上传用户ID") Long userId,
-            @HttpParam(name = "pageNo", type = HttpParamType.COMMON, valueDef = "1", description = "查询页数") Integer pageNo,
-            @HttpParam(name = "pageSize", type = HttpParamType.COMMON, valueDef = "10", description = "查询长度") Integer pageSize) throws ServiceException;
-
-
-    @HttpMethod(description = "查询商品的所有评论")
-    public Page<AppraiseResponseDTO> getSpuAllAppraise(
-            @NotNull @HttpParam(name = "spuId", type = HttpParamType.COMMON, description = "商品Id") Long spuId,
-            @HttpParam(name = "pageNo", type = HttpParamType.COMMON, valueDef = "1", description = "查询页数") Integer pageNo,
-            @HttpParam(name = "pageSize", type = HttpParamType.COMMON, valueDef = "10", description = "查询长度") Integer pageSize) throws ServiceException;
-
-    @HttpMethod(description = "查询某一条评论")
-    public AppraiseResponseDTO getOneById(
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "上传用户ID") Long userId,
-            @NotNull @HttpParam(name = "AppraiseId", type = HttpParamType.COMMON, description = "评论Id") Long appraiseId) throws ServiceException;
-
-
-}

+ 0 - 166
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/appraise/AppraiseServiceImpl.java

@@ -1,166 +0,0 @@
-package com.iotechn.unimall.app.api.appraise;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.iotechn.unimall.biz.service.appriaise.AppraiseBizService;
-import com.iotechn.unimall.core.exception.ExceptionDefinition;
-import com.iotechn.unimall.core.exception.AppServiceException;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.component.CacheComponent;
-import com.iotechn.unimall.data.domain.AppraiseDO;
-import com.iotechn.unimall.data.domain.ImgDO;
-import com.iotechn.unimall.data.domain.OrderDO;
-import com.iotechn.unimall.data.domain.OrderSkuDO;
-import com.iotechn.unimall.data.dto.appraise.AppraiseRequestItemDTO;
-import com.iotechn.unimall.data.dto.appraise.AppraiseRequestDTO;
-import com.iotechn.unimall.data.dto.appraise.AppraiseResponseDTO;
-import com.iotechn.unimall.data.enums.BizType;
-import com.iotechn.unimall.data.enums.OrderStatusType;
-import com.iotechn.unimall.data.mapper.AppraiseMapper;
-import com.iotechn.unimall.data.mapper.ImgMapper;
-import com.iotechn.unimall.data.mapper.OrderMapper;
-import com.iotechn.unimall.data.mapper.OrderSkuMapper;
-import com.iotechn.unimall.data.model.Page;
-import org.springframework.beans.BeanUtils;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.CollectionUtils;
-
-import java.util.Date;
-import java.util.List;
-
-/*
-@author kbq
-@date  2019/7/6 - 11:08
-*/
-@Service
-public class AppraiseServiceImpl implements AppraiseService {
-
-    @Autowired
-    private OrderMapper orderMapper;
-    @Autowired
-    private ImgMapper imgMapper;
-    @Autowired
-    private AppraiseMapper appraiseMapper;
-    @Autowired
-    private OrderSkuMapper orderSkuMapper;
-    @Autowired
-    private CacheComponent cacheComponent;
-    @Autowired
-    private AppraiseBizService appraiseBizService;
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean addAppraise(AppraiseRequestDTO appraiseRequestDTO, Long userId) throws ServiceException {
-        if (appraiseRequestDTO.getOrderId() == null) {
-            throw new AppServiceException(ExceptionDefinition.APPRAISE_PARAM_CHECK_FAILED);
-        }
-        //校验是否有对应等待评价的订单
-        Integer integer = orderMapper.selectCount(
-                new EntityWrapper<OrderDO>()
-                        .eq("id", appraiseRequestDTO.getOrderId())
-                        .eq("status", OrderStatusType.WAIT_APPRAISE.getCode())
-                        .eq("user_id", userId));
-        if (integer == 0) {
-            throw new AppServiceException(ExceptionDefinition.APPRAISE_ORDER_CHECK_FAILED);
-        }
-
-        //如果传入评价list中没有数据,就直接转变订单状态发出
-        Date now = new Date();
-        if (CollectionUtils.isEmpty(appraiseRequestDTO.getAppraiseDTOList())) {
-            OrderDO orderDO = new OrderDO();
-            orderDO.setStatus(OrderStatusType.COMPLETE.getCode());
-            orderDO.setId(appraiseRequestDTO.getOrderId());
-            orderDO.setGmtUpdate(now);
-            orderMapper.updateById(orderDO);
-        }
-
-        //循环读取订单评价中所有商品的评价
-        for (AppraiseRequestItemDTO appraiseDTO : appraiseRequestDTO.getAppraiseDTOList()) {
-            Integer count = orderSkuMapper.selectCount(new EntityWrapper<OrderSkuDO>()
-                    .eq("order_id", appraiseRequestDTO.getOrderId())
-                    .eq("spu_id", appraiseDTO.getSpuId())
-                    .eq("sku_id", appraiseDTO.getSkuId()));
-            //从order_sku表中 验证是否有对应的表单和商品
-            if (count == 0) {
-                throw new AppServiceException(ExceptionDefinition.APPRAISE_PARAM_CHECK_FAILED);
-            }
-
-            AppraiseDO appraiseDO = new AppraiseDO();
-            BeanUtils.copyProperties(appraiseDTO, appraiseDO);
-            appraiseDO.setSpuId(appraiseDTO.getSpuId());
-            appraiseDO.setId(null); //防止传入id,导致插入数据库出错
-            appraiseDO.setOrderId(appraiseRequestDTO.getOrderId()); //从传入数据取出,不使用DTO中的冗余数据
-            appraiseDO.setUserId(userId);
-            appraiseDO.setGmtCreate(now);
-            appraiseDO.setGmtUpdate(appraiseDO.getGmtCreate());
-            appraiseMapper.insert(appraiseDO);  //插入该订单该商品评价
-            cacheComponent.delPrefixKey(AppraiseBizService.CA_APPRAISE_KEY + appraiseDO.getSpuId()); //删除商品评论缓存
-            if (appraiseDTO.getImgUrl() == null || appraiseDTO.getImgUrl().equals("")) {
-                continue;
-            }
-            String imgUrlS = appraiseDTO.getImgUrl();
-            String[] imgUrlList = imgUrlS.split(",");   //传入图片
-            for (String imgurl : imgUrlList) {
-                ImgDO imgDO = new ImgDO();
-                imgDO.setBizType(BizType.COMMENT.getCode());
-                imgDO.setBizId(appraiseDO.getId());
-                imgDO.setUrl(imgurl);
-                imgDO.setGmtCreate(now);
-                imgDO.setGmtUpdate(imgDO.getGmtCreate());
-                imgMapper.insert(imgDO);
-            }
-        }
-
-        //改变订单状态
-        OrderDO orderDO = new OrderDO();
-        orderDO.setStatus(OrderStatusType.COMPLETE.getCode());
-        orderDO.setId(appraiseRequestDTO.getOrderId());
-        orderDO.setGmtUpdate(now);
-        orderMapper.updateById(orderDO);
-        return true;
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean deleteAppraiseById(Long appraiseId, Long userId) throws ServiceException {
-        Integer delete = appraiseMapper.delete(new EntityWrapper<AppraiseDO>()
-                .eq("id", appraiseId)
-                .eq("user_id", userId)); //根据用户Id,评价Id
-        if (delete > 0) {
-            return true;
-        } else {
-            throw new AppServiceException(ExceptionDefinition.APPRAISE_PARAM_CHECK_FAILED);
-        }
-    }
-
-    @Override
-    public Page<AppraiseResponseDTO> getUserAllAppraise(Long userId, Integer pageNo, Integer pageSize) throws ServiceException {
-        Integer count = appraiseMapper.selectCount(new EntityWrapper<AppraiseDO>().eq("user_id", userId));
-        List<AppraiseResponseDTO> appraiseResponseDTOS = appraiseMapper.selectUserAllAppraise(userId, pageSize * (pageNo - 1), pageSize);
-        for (AppraiseResponseDTO appraiseResponseDTO : appraiseResponseDTOS) {
-            appraiseResponseDTO.setImgList(imgMapper.getImgs(BizType.COMMENT.getCode(), appraiseResponseDTO.getId()));
-        }
-        Page<AppraiseResponseDTO> page = new Page<>(appraiseResponseDTOS, pageNo, pageSize, count);
-        return page;
-    }
-
-
-    @Override
-    public Page<AppraiseResponseDTO> getSpuAllAppraise(Long spuId, Integer pageNo, Integer pageSize) throws ServiceException {
-        return appraiseBizService.getSpuAllAppraise(spuId, pageNo, pageSize);
-    }
-
-    @Override
-    public AppraiseResponseDTO getOneById(Long userId, Long appraiseId) throws ServiceException {
-        AppraiseResponseDTO appraiseResponseDTO = appraiseMapper.selectOneById(appraiseId);
-        if (appraiseResponseDTO == null) {
-            throw new AppServiceException(ExceptionDefinition.APPRAISE_PARAM_CHECK_FAILED);
-        }
-        appraiseResponseDTO.setImgList(imgMapper.getImgs(BizType.COMMENT.getCode(), appraiseResponseDTO.getId()));
-
-        return appraiseResponseDTO;
-    }
-
-
-}

+ 0 - 61
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/cart/CartService.java

@@ -1,61 +0,0 @@
-package com.iotechn.unimall.app.api.cart;
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.annotation.param.Range;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.dto.CartDTO;
-
-import java.util.List;
-
-/**
- * Created by rize on 2019/7/3.
- */
-@HttpOpenApi(group = "cart", description = "购物车服务")
-public interface CartService {
-
-    @HttpMethod(description = "加入购物车")
-    public Boolean addCartItem(
-            @NotNull @HttpParam(name = "skuId", type = HttpParamType.COMMON, description = "商品Id") Long skuId,
-            @Range(min = 1) @HttpParam(name = "num", type = HttpParamType.COMMON, description = "加入数量", valueDef = "1") Integer num,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId) throws ServiceException;
-
-    @HttpMethod(description = "减少购物车")
-    public Boolean subCartItem(
-            @NotNull @HttpParam(name = "skuId", type = HttpParamType.COMMON, description = "商品Id") Long skuId,
-            @Range(min = 1) @HttpParam(name = "num", type = HttpParamType.COMMON, description = "加入数量", valueDef = "1") Integer num,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId) throws ServiceException;
-
-    @HttpMethod(description = "将购物车商品删除")
-    public Boolean removeCartItem(
-            @NotNull @HttpParam(name = "cartId", type = HttpParamType.COMMON, description = "商品ID(传入值有问题,skuId)") Long cartId,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户ID") Long userId) throws ServiceException;
-
-    @HttpMethod(description = "批量删除购物车Item")
-    public Boolean removeCartItemBatch(
-            @NotNull @HttpParam(name = "cartIdList", type = HttpParamType.COMMON, description = "购物车id列表用,隔开") String cartIdList,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户ID") Long userId) throws ServiceException;
-
-    @HttpMethod(description = "清空购物车")
-    public Boolean removeCartAll(
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户ID") Long userId) throws ServiceException;
-
-    @HttpMethod(description = "调整购物车商品数量")
-    public Integer updateCartItemNum(
-            @NotNull @HttpParam(name = "cartId", type = HttpParamType.COMMON, description = "购物车ID") Long cartId,
-            @Range(min = 1) @NotNull @HttpParam(name = "num", type = HttpParamType.COMMON, description = "商品数量") Integer num,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户ID") Long userId) throws ServiceException;
-
-    @HttpMethod(description = "购物车商品数量")
-    public Integer countCart(
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户ID") Long userId) throws ServiceException;
-
-    @HttpMethod(description = "获取用户购物车列表")
-    public List<CartDTO> getCartList(
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId) throws ServiceException;
-
-
-}

+ 0 - 146
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/cart/CartServiceImpl.java

@@ -1,146 +0,0 @@
-package com.iotechn.unimall.app.api.cart;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.iotechn.unimall.biz.service.category.CategoryBizService;
-import com.iotechn.unimall.core.exception.AppServiceException;
-import com.iotechn.unimall.core.exception.ExceptionDefinition;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.CartDO;
-import com.iotechn.unimall.data.dto.CartDTO;
-import com.iotechn.unimall.data.mapper.CartMapper;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.CollectionUtils;
-import org.springframework.util.StringUtils;
-
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.List;
-
-/**
- * Created by rize on 2019/7/3.
- */
-@Service
-public class CartServiceImpl implements CartService {
-
-    @Autowired
-    private CartMapper cartMapper;
-
-    @Autowired
-    private CategoryBizService categoryBizService;
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean addCartItem(Long skuId, Integer num, Long userId) throws ServiceException {
-        List<CartDO> cartDOS = cartMapper.selectList(
-                new EntityWrapper<CartDO>()
-                        .eq("sku_id", skuId)
-                        .eq("user_id", userId));
-        CartDO cartDO = new CartDO();
-        Date now = new Date();
-        if (!CollectionUtils.isEmpty(cartDOS)) {
-            //若非空
-            cartDO.setId(cartDOS.get(0).getId());
-            cartDO.setNum(cartDOS.get(0).getNum() + num);
-            cartDO.setGmtUpdate(now);
-            return cartMapper.updateById(cartDO) > 0;
-        } else {
-            //不存在,则添加购物车
-            cartDO.setSkuId(skuId);
-            cartDO.setNum(num);
-            cartDO.setUserId(userId);
-            cartDO.setGmtUpdate(now);
-            cartDO.setGmtCreate(now);
-            return cartMapper.insert(cartDO) > 0;
-        }
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean subCartItem(Long skuId, Integer num, Long userId) throws ServiceException {
-        List<CartDO> cartDOS = cartMapper.selectList(
-                new EntityWrapper<CartDO>()
-                        .eq("sku_id", skuId)
-                        .eq("user_id", userId));
-
-        CartDO cartDO = new CartDO();
-        if (!CollectionUtils.isEmpty(cartDOS)) {
-            cartDO.setId(cartDOS.get(0).getId());
-            cartDO.setNum(cartDOS.get(0).getNum() - num);
-            if (cartDO.getNum() <= 0) {
-                //直接删除此商品
-                return cartMapper.deleteById(cartDO.getId()) > 0;
-            } else {
-                return cartMapper.updateById(cartDO) > 0;
-            }
-        }
-        return false;
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean removeCartItem(Long cartId, Long userId) throws ServiceException {
-        return cartMapper.delete(
-                new EntityWrapper<CartDO>()
-                        .eq("id", cartId)
-                        .eq("user_id", userId)) > 0;
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean removeCartItemBatch(String cartIdList, Long userId) throws ServiceException {
-        if (StringUtils.isEmpty(cartIdList)) {
-            throw new AppServiceException(ExceptionDefinition.PARAM_CHECK_FAILED);
-        }
-        String[] split = cartIdList.split(",");
-        if (split.length == 0) {
-            throw new AppServiceException(ExceptionDefinition.PARAM_CHECK_FAILED);
-        }
-        List<Long> array = new ArrayList<>(split.length);
-        for (String idRaw : split) {
-            array.add(new Long(idRaw));
-        }
-        return cartMapper.delete(
-                new EntityWrapper<CartDO>()
-                        .in("id", array)
-                        .eq("user_id", userId)) > 0;
-    }
-
-    @Override
-    @Transactional
-    public Boolean removeCartAll(Long userId) throws ServiceException {
-        return cartMapper.delete(
-                new EntityWrapper<CartDO>()
-                        .eq("user_id", userId)) > 0;
-    }
-
-    @Override
-    public Integer updateCartItemNum(Long cartId, Integer num, Long userId) throws ServiceException {
-        CartDO cartDO = new CartDO();
-        cartDO.setNum(num);
-        Integer update = cartMapper.update(cartDO,
-                new EntityWrapper<CartDO>()
-                        .eq("id", cartId)
-                        .eq("user_id", userId));
-        if (update > 0) {
-            return num;
-        }
-        throw new AppServiceException(ExceptionDefinition.CART_UPDATE_FAILED);
-    }
-
-    @Override
-    public Integer countCart(Long userId) throws ServiceException {
-        return cartMapper.countCart(userId);
-    }
-
-    @Override
-    public List<CartDTO> getCartList(Long userId) throws ServiceException {
-        List<CartDTO> cartList = cartMapper.getCartList(userId);
-        for (CartDTO cartDTO : cartList) {
-            List<Long> categoryFamily = categoryBizService.getCategoryFamily(cartDTO.getCategoryId());
-            cartDTO.setCategoryIdList(categoryFamily);
-        }
-        return cartList;
-    }
-}

+ 0 - 47
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/collect/CollectService.java

@@ -1,47 +0,0 @@
-package com.iotechn.unimall.app.api.collect;
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.dto.CollectDTO;
-import com.iotechn.unimall.data.model.Page;
-
-/*
-@author kbq
-@date  2019/7/5 - 10:13
-*/
-@HttpOpenApi(group = "collect", description = "收藏表单")
-public interface CollectService {
-
-    @HttpMethod(description = "增加收藏记录")
-    public Boolean addCollect(
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId,
-            @NotNull @HttpParam(name = "spuId", type = HttpParamType.COMMON, description = "商品ID") Long spuId) throws ServiceException;
-
-    @HttpMethod(description = "删除收藏记录")
-    public Boolean deleteCollect(
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId,
-            @NotNull @HttpParam(name = "spuId", type = HttpParamType.COMMON, description = "商品ID") Long spuId) throws ServiceException;
-
-    @HttpMethod(description = "查询某一用户收藏记录")
-    public Page<CollectDTO> getCollectAll(
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId,
-            @HttpParam(name = "pageNo", valueDef = "1", type = HttpParamType.COMMON, description = "分页查询偏移量") Integer pageNo,
-            @HttpParam(name = "pageSize", valueDef = "10", type = HttpParamType.COMMON, description = "分页查询长度") Integer pageSize) throws ServiceException;
-
-
-    @HttpMethod(description = "查询某一条收藏记录")
-    public CollectDTO getCollectById(
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId,
-            @NotNull @HttpParam(name = "collectId", type = HttpParamType.COMMON, description = "收藏记录id") Long collectId,
-            @HttpParam(name = "spuId", type = HttpParamType.COMMON, description = "商品ID") Long spuId) throws ServiceException;
-
-    @HttpMethod(description = "判断用户是否收藏")
-    public Boolean getCollectBySpuId(
-            @NotNull @HttpParam(name = "spuId", type = HttpParamType.COMMON, description = "商品Id") Long spuId,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId) throws ServiceException;
-
-}

+ 0 - 96
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/collect/CollectServiceImpl.java

@@ -1,96 +0,0 @@
-package com.iotechn.unimall.app.api.collect;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.iotechn.unimall.biz.service.collect.CollectBizService;
-import com.iotechn.unimall.biz.service.goods.GoodsBizService;
-import com.iotechn.unimall.core.exception.ExceptionDefinition;
-import com.iotechn.unimall.core.exception.AppServiceException;
-import com.iotechn.unimall.core.Const;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.component.CacheComponent;
-import com.iotechn.unimall.data.domain.CollectDO;
-import com.iotechn.unimall.data.dto.CollectDTO;
-import com.iotechn.unimall.data.mapper.CollectMapper;
-import com.iotechn.unimall.data.model.Page;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.CollectionUtils;
-
-import java.util.Date;
-import java.util.List;
-
-/*
-@author kbq
-@date  2019/7/5 - 10:48
-*/
-@Service
-public class CollectServiceImpl implements CollectService {
-
-
-    @Autowired
-    private CollectMapper collectMapper;
-
-    @Autowired
-    private CacheComponent cacheComponent;
-
-    @Autowired
-    private GoodsBizService goodsBizService;
-
-    @Autowired
-    private CollectBizService collectBizService;
-
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean addCollect(Long userId, Long spuId) throws ServiceException {
-        //校验SPU是否存在
-        goodsBizService.getSpuById(spuId);
-        List<CollectDO> collectDOS = collectMapper.selectList(new EntityWrapper<CollectDO>()
-                .eq("user_id", userId)
-                .eq("spu_id", spuId));
-        if (!CollectionUtils.isEmpty(collectDOS)) {
-            throw new AppServiceException(ExceptionDefinition.COLLECT_ALREADY_EXISTED);
-        }
-        CollectDO collectDO = new CollectDO(userId, spuId);
-        Date now = new Date();
-        collectDO.setGmtCreate(now);
-        collectDO.setGmtUpdate(collectDO.getGmtCreate());
-        cacheComponent.putSetRaw(CollectBizService.CA_USER_COLLECT_HASH + userId, spuId + "", Const.CACHE_ONE_DAY);
-        return collectMapper.insert(collectDO) > 0;
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean deleteCollect(Long userId, Long spuId) throws ServiceException {
-        Integer num = collectMapper.delete(new EntityWrapper<CollectDO>()
-                .eq("user_id", userId)
-                .eq("spu_id", spuId)
-        );
-        if (num > 0) {
-            cacheComponent.removeSetRaw(CollectBizService.CA_USER_COLLECT_HASH + userId, spuId + "");
-            return true;
-        }
-
-        throw new AppServiceException(ExceptionDefinition.PARAM_CHECK_FAILED);
-    }
-
-    @Override
-    public Page<CollectDTO> getCollectAll(Long userId, Integer pageNo, Integer pageSize) throws ServiceException {
-        Integer count = collectMapper.selectCount(new EntityWrapper<CollectDO>().eq("user_id", userId));
-        Integer offset = pageSize * (pageNo - 1);
-        List<CollectDTO> collectAll = collectMapper.getCollectAll(userId, offset, pageSize);
-        Page<CollectDTO> page = new Page<CollectDTO>(collectAll, pageNo, pageSize, count);
-        return page;
-    }
-
-    @Override
-    public CollectDTO getCollectById(Long userId, Long collectId, Long spuId) throws ServiceException {
-        return collectMapper.getCollectById(userId, collectId, spuId);
-    }
-
-    @Override
-    public Boolean getCollectBySpuId(Long spuId, Long userId) throws ServiceException {
-        return collectBizService.getCollectBySpuId(spuId, userId);
-    }
-}

+ 0 - 3
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/commonUser/CommonUserService.java

@@ -1,14 +1,11 @@
 package com.iotechn.unimall.app.api.commonUser;
 
-import com.iotechn.unimall.core.Const;
 import com.iotechn.unimall.core.annotation.HttpMethod;
 import com.iotechn.unimall.core.annotation.HttpOpenApi;
 import com.iotechn.unimall.core.annotation.HttpParam;
 import com.iotechn.unimall.core.annotation.HttpParamType;
 import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.annotation.param.TextFormat;
 import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.dto.UserDTO;
 import com.iotechn.unimall.data.domain.CommonUserInfo;
 
 import java.io.IOException;

+ 0 - 45
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/commonUser/CommonUserServiceImpl.java

@@ -2,47 +2,25 @@ package com.iotechn.unimall.app.api.commonUser;
 
 import com.alibaba.fastjson.JSONObject;
 import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.iotechn.unimall.biz.service.user.UserBizService;
 import com.iotechn.unimall.core.Const;
 import com.iotechn.unimall.core.exception.AppServiceException;
 import com.iotechn.unimall.core.exception.ExceptionDefinition;
 import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.core.exception.ThirdPartServiceException;
-import com.iotechn.unimall.core.notify.SMSClient;
-import com.iotechn.unimall.core.notify.SMSResult;
 import com.iotechn.unimall.core.util.GeneratorUtil;
-import com.iotechn.unimall.core.util.SHA1Util;
-import com.iotechn.unimall.data.component.CacheComponent;
-import com.iotechn.unimall.data.domain.CardClassifyInfo;
-import com.iotechn.unimall.data.domain.CardNewsInfo;
-import com.iotechn.unimall.data.domain.UserDO;
 import com.iotechn.unimall.data.domain.CommonUserInfo;
-import com.iotechn.unimall.data.dto.UserDTO;
-import com.iotechn.unimall.data.enums.UserLoginType;
-import com.iotechn.unimall.data.mapper.CardClassifyInfoMapper;
-import com.iotechn.unimall.data.mapper.CardNewsInfoMapper;
-import com.iotechn.unimall.data.mapper.UserMapper;
-import com.iotechn.unimall.data.util.SessionUtil;
 import okhttp3.OkHttpClient;
 import okhttp3.Request;
-import org.apache.commons.codec.digest.Md5Crypt;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
-import org.springframework.beans.BeanUtils;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Value;
 import org.springframework.data.redis.core.StringRedisTemplate;
 import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
 import org.springframework.util.CollectionUtils;
-import org.springframework.util.StringUtils;
 
 import java.io.IOException;
 import java.util.Date;
-import java.util.HashMap;
 import java.util.List;
-import java.util.Map;
-import java.util.concurrent.TimeUnit;
 
 import com.iotechn.unimall.data.mapper.CommonUserInfoMapper;
 /**
@@ -57,10 +35,6 @@ public class CommonUserServiceImpl implements CommonUserService {
 
     @Autowired
     private CommonUserInfoMapper commonUserInfoMapper;
-    @Autowired
-    private CardClassifyInfoMapper cardClassifyInfoMapper;
-    @Autowired
-    private CardNewsInfoMapper cardNewsInfoMapper;
 
 
     @Autowired
@@ -98,25 +72,6 @@ public class CommonUserServiceImpl implements CommonUserService {
                 commonUserInfoMapper.insert(newUserDO);
                 //更新数据库默认值
                 newUserDO = commonUserInfoMapper.selectById(newUserDO.getId());
-                List<CardClassifyInfo> cardClassifyInfoList = cardClassifyInfoMapper.selectList(new EntityWrapper<CardClassifyInfo>()
-                        .eq("common_id", newUserDO.getId())
-                        .eq("delete_flag", 0));
-                //新创建的用户添加默认分类
-                if (CollectionUtils.isEmpty(cardClassifyInfoList)) {
-                    CardClassifyInfo cardClassifyInfo=new CardClassifyInfo();
-                    cardClassifyInfo.setGmtCreate(now);
-                    cardClassifyInfo.setGmtUpdate(now);
-                    cardClassifyInfo.setCommonId(newUserDO.getId());
-                    cardClassifyInfo.setCircleName("默认分类");
-                    cardClassifyInfoMapper.insert(cardClassifyInfo);
-                }
-                CardNewsInfo cardNewsInfo=new CardNewsInfo();
-                cardNewsInfo.setNewsTitle("系统消息");
-                cardNewsInfo.setNewsContent("欢迎使用【名片box】,添加名片、加入圈子、扫码交换、一键转发、证件管理等多种实用功能等你来探索!");
-                cardNewsInfo.setReceiveId(newUserDO.getId());
-                cardNewsInfo.setGmtCreate(now);
-                cardNewsInfo.setGmtUpdate(now);
-                cardNewsInfoMapper.insert(cardNewsInfo);
             } else {
                 newUserDO = list.get(0);
             }

+ 0 - 34
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/coupon/CouponService.java

@@ -1,34 +0,0 @@
-package com.iotechn.unimall.app.api.coupon;
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.CouponDO;
-import com.iotechn.unimall.data.dto.CouponDTO;
-import com.iotechn.unimall.data.dto.UserCouponDTO;
-
-import java.util.List;
-
-/**
- * Created by rize on 2019/7/4.
- */
-@HttpOpenApi(group = "coupon", description = "优惠券服务")
-public interface CouponService {
-
-    @HttpMethod(description = "领取优惠券")
-    public String obtainCoupon(
-            @NotNull @HttpParam(name = "couponId", type = HttpParamType.COMMON, description = "优惠券Id") Long couponId,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId) throws ServiceException;
-
-    @HttpMethod(description = "获取用户可领取优惠券")
-    public List<CouponDTO> getObtainableCoupon(
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId) throws ServiceException;
-
-    @HttpMethod(description = "获取用户优惠券")
-    public List<UserCouponDTO> getUserCoupons(
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId) throws ServiceException;
-
-}

+ 0 - 157
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/coupon/CouponServiceImpl.java

@@ -1,157 +0,0 @@
-package com.iotechn.unimall.app.api.coupon;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.iotechn.unimall.core.exception.ExceptionDefinition;
-import com.iotechn.unimall.core.exception.AppServiceException;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.component.LockComponent;
-import com.iotechn.unimall.data.domain.CouponDO;
-import com.iotechn.unimall.data.domain.UserCouponDO;
-import com.iotechn.unimall.data.dto.CouponDTO;
-import com.iotechn.unimall.data.dto.UserCouponDTO;
-import com.iotechn.unimall.data.enums.StatusType;
-import com.iotechn.unimall.data.mapper.CouponMapper;
-import com.iotechn.unimall.data.mapper.UserCouponMapper;
-import com.iotechn.unimall.data.model.KVModel;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.springframework.beans.BeanUtils;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.CollectionUtils;
-
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.List;
-import java.util.stream.Collectors;
-
-/**
- * Created by rize on 2019/7/4.
- */
-@Service
-public class CouponServiceImpl implements CouponService {
-
-    @Autowired
-    private CouponMapper couponMapper;
-
-    @Autowired
-    private UserCouponMapper userCouponMapper;
-
-    @Autowired
-    private LockComponent lockComponent;
-
-    private static final String COUPON_LOCK = "COUPON_LOCK_";
-
-    private static final String COUPON_USER_LOCK = "COUPON_USER_LOCK_";
-
-    private static final Logger logger = LoggerFactory.getLogger(CouponServiceImpl.class);
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public String obtainCoupon(Long couponId, Long userId) throws ServiceException {
-        //防止用户一瞬间提交两次表单,导致超领
-        if (lockComponent.tryLock(COUPON_USER_LOCK + userId + "_" + couponId, 10)) {
-            try {
-                CouponDO couponDO = couponMapper.selectById(couponId);
-                if (couponDO.getStatus() == StatusType.LOCK.getCode()) {
-                    throw new AppServiceException(ExceptionDefinition.COUPON_HAS_LOCKED);
-                }
-                Date now = new Date();
-                if (couponDO.getGmtEnd() != null && couponDO.getGmtEnd().getTime() < now.getTime()) {
-                    throw new AppServiceException(ExceptionDefinition.COUPON_ACTIVITY_HAS_END);
-                }
-                if (couponDO.getGmtStart() != null && couponDO.getGmtStart().getTime() > now.getTime()) {
-                    throw new AppServiceException(ExceptionDefinition.COUPON_ACTIVITY_NOT_START);
-                }
-                if (couponDO.getTotal() != -1 && couponDO.getSurplus() <= 0) {
-                    throw new AppServiceException(ExceptionDefinition.COUPON_ISSUE_OVER);
-                } else {
-                    if (couponDO.getTotal() >= 0) {
-                        if (couponDO.getSurplus() == 1) {
-                            if (!lockComponent.tryLock(COUPON_LOCK + couponId, 10)) {
-                                throw new AppServiceException(ExceptionDefinition.COUPON_ISSUE_OVER);
-                            }
-                        }
-                        couponMapper.decCoupon(couponId);
-                    }
-                }
-
-
-                if (couponDO.getLimit() != -1) {
-                    //校验用户是否已经领了
-                    Integer count = userCouponMapper.selectCount(
-                            new EntityWrapper<UserCouponDO>()
-                                    .eq("user_id", userId)
-                                    .eq("coupon_id", couponId));
-
-                    if (count >= couponDO.getLimit()) {
-                        throw new AppServiceException(ExceptionDefinition.COUPON_YOU_HAVE_OBTAINED);
-                    }
-                }
-
-                //领取优惠券
-                UserCouponDO userCouponDO = new UserCouponDO();
-                userCouponDO.setUserId(userId);
-                userCouponDO.setCouponId(couponId);
-                if (couponDO.getGmtStart() != null && couponDO.getGmtEnd() != null) {
-                    //如果优惠券是按区间领取的
-                    userCouponDO.setGmtStart(couponDO.getGmtStart());
-                    userCouponDO.setGmtEnd(couponDO.getGmtEnd());
-                } else if (couponDO.getDays() != null) {
-                    //如果是任意领取的,则从当前时间 加上 可用天数
-                    userCouponDO.setGmtStart(now);
-                    userCouponDO.setGmtEnd(new Date(now.getTime() + 1000l * 60 * 60 * 24 * couponDO.getDays()));
-                } else {
-                    throw new AppServiceException(ExceptionDefinition.COUPON_STRATEGY_INCORRECT);
-                }
-
-                userCouponDO.setGmtUpdate(now);
-                userCouponDO.setGmtCreate(now);
-
-                userCouponMapper.insert(userCouponDO);
-                return "ok";
-            } catch (ServiceException e) {
-                throw e;
-            } catch (Exception e) {
-                logger.error("[领取优惠券] 异常", e);
-                throw new AppServiceException(ExceptionDefinition.APP_UNKNOWN_EXCEPTION);
-            } finally {
-                lockComponent.release(COUPON_USER_LOCK + userId + "_" + couponId);
-            }
-        } else {
-            throw new AppServiceException(ExceptionDefinition.SYSTEM_BUSY);
-        }
-
-    }
-
-    @Override
-    public List<CouponDTO> getObtainableCoupon(Long userId) throws ServiceException {
-        List<CouponDTO> couponDOS = couponMapper.getActiveCoupons();
-        //活动中的优惠券Id
-        List<Long> activeCouponIds = couponDOS.stream().map(couponDO -> couponDO.getId()).collect(Collectors.toList());
-
-        if (CollectionUtils.isEmpty(activeCouponIds)) {
-            return new ArrayList<>();
-        }
-
-        List<KVModel<Long, Long>> userCouponsCount = couponMapper.getUserCouponsCount(userId, activeCouponIds);
-
-        List<CouponDTO> couponDTOList = couponDOS.stream().map(item -> {
-            item.setNowCount(0);
-            for (int i = 0; i < userCouponsCount.size(); i++) {
-                KVModel<Long, Long> kv = userCouponsCount.get(i);
-                if (kv != null && kv.getKey().equals(item.getId())) {
-                    item.setNowCount(kv.getValue().intValue());
-                }
-            }
-            return item;
-        }).collect(Collectors.toList());
-        return couponDTOList;
-    }
-
-    @Override
-    public List<UserCouponDTO> getUserCoupons(Long userId) throws ServiceException {
-        return userCouponMapper.getUserCoupons(userId);
-    }
-}

+ 0 - 27
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/freight/FreightTemplateService.java

@@ -1,27 +0,0 @@
-package com.iotechn.unimall.app.api.freight;
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.dto.order.OrderRequestDTO;
-import com.iotechn.unimall.data.mapper.FreightTemplateCarriageMapper;
-import org.springframework.beans.factory.annotation.Autowired;
-
-/**
- * Created with IntelliJ IDEA.
- * Description:
- * User: kbq
- * Date: 2019-07-07
- * Time: 下午7:40
- */
-@HttpOpenApi(group = "freight", description = "运费计算api")
-public interface FreightTemplateService {
-
-    @HttpMethod(description = "得到订单的运费")
-    public Integer getFreightMoney(
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户ID") Long userId,
-            @NotNull @HttpParam(name = "orderRequestDTO", type = HttpParamType.COMMON, description = "订单传回数据") OrderRequestDTO orderRequestDTO) throws ServiceException;
-}

+ 0 - 26
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/freight/FreightTemplateServiceImpl.java

@@ -1,26 +0,0 @@
-package com.iotechn.unimall.app.api.freight;
-
-import com.iotechn.unimall.biz.service.freight.FreightBizService;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.dto.order.OrderRequestDTO;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-
-/**
- * Created with IntelliJ IDEA.
- * Description:
- * User: kbq
- * Date: 2019-07-07
- * Time: 下午7:50
- */
-@Service
-public class FreightTemplateServiceImpl implements FreightTemplateService {
-
-    @Autowired
-    private FreightBizService freightBizService;
-
-    @Override
-    public Integer getFreightMoney(Long userId, OrderRequestDTO orderRequestDTO) throws ServiceException {
-        return freightBizService.getFreightMoney(orderRequestDTO);
-    }
-}

+ 0 - 33
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/goods/GoodsService.java

@@ -1,33 +0,0 @@
-package com.iotechn.unimall.app.api.goods;
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.dto.goods.SpuDTO;
-import com.iotechn.unimall.data.model.Page;
-
-/**
- * Created by rize on 2019/7/1.
- */
-@HttpOpenApi(group = "goods", description = "商品服务")
-public interface GoodsService {
-
-    @HttpMethod(description = "搜索Goods列表")
-    public Page<SpuDTO> getGoodsPage(
-            @HttpParam(name = "pageNo", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer pageNo,
-            @HttpParam(name = "pageSize", type = HttpParamType.COMMON, description = "页码长度", valueDef = "10") Integer pageSize,
-            @HttpParam(name = "categoryId", type = HttpParamType.COMMON, description = "搜索分类") Long categoryId,
-            @HttpParam(name = "orderBy", type = HttpParamType.COMMON, description = "排序 id 或 sales", valueDef = "id") String orderBy,
-            @HttpParam(name = "isAsc", type = HttpParamType.COMMON, description = "是否升序", valueDef = "false") Boolean isAsc,
-            @HttpParam(name = "title", type = HttpParamType.COMMON, description = "搜索标题") String title) throws ServiceException;
-
-    @HttpMethod(description = "获取商品详情")
-    public SpuDTO getGoods(
-            @NotNull @HttpParam(name = "spuId", type = HttpParamType.COMMON, description = "商品Id") Long spuId,
-            @HttpParam(name = "groupShopId", type = HttpParamType.COMMON, description = "团购Id") Long groupShopId,
-            @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId) throws ServiceException;
-
-}

+ 0 - 41
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/goods/GoodsServiceImpl.java

@@ -1,41 +0,0 @@
-package com.iotechn.unimall.app.api.goods;
-
-import com.iotechn.unimall.biz.service.goods.GoodsBizService;
-import com.iotechn.unimall.biz.service.groupshop.GroupShopBizService;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.dto.goods.SpuDTO;
-import com.iotechn.unimall.data.mapper.GroupShopMapper;
-import com.iotechn.unimall.data.model.Page;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-
-import java.io.File;
-
-
-/**
- * Created by rize on 2019/7/2.
- */
-@Service
-public class GoodsServiceImpl implements GoodsService {
-
-    @Autowired
-    private GoodsBizService goodsBizService;
-
-    @Autowired
-    private GroupShopBizService groupShopBizService;
-
-    @Override
-    public Page<SpuDTO> getGoodsPage(Integer pageNo, Integer pageSize, Long categoryId, String orderBy,Boolean isAsc, String title) throws ServiceException {
-        return goodsBizService.getGoodsPage(pageNo, pageSize, categoryId, orderBy, isAsc, title);
-    }
-
-    @Override
-    public SpuDTO getGoods(Long spuId, Long groupShopId, Long userId) throws ServiceException {
-        //若团购Id不为空,则额外添加团购信息
-        SpuDTO goods = goodsBizService.getGoods(spuId, userId);
-        if (groupShopId != null) {
-            goods.setGroupShop(groupShopBizService.getGroupShopById(groupShopId));
-        }
-        return goods;
-    }
-}

+ 0 - 30
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/groupshop/GroupShopService.java

@@ -1,30 +0,0 @@
-package com.iotechn.unimall.app.api.groupshop;
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.dto.goods.GroupShopDTO;
-import com.iotechn.unimall.data.model.Page;
-
-import java.rmi.ServerException;
-import java.util.List;
-
-/**
- * Created with IntelliJ IDEA.
- * Description:
- * User: rize
- * Date: 2019/11/24
- * Time: 15:15
- */
-@HttpOpenApi(group = "groupshop", description = "团购服务")
-public interface GroupShopService {
-
-    @HttpMethod(description = "获取团购列表")
-    public Page<GroupShopDTO> getGroupShopPage(
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer pageNo,
-            @HttpParam(name = "pageSize", type = HttpParamType.COMMON, description = "页码长度", valueDef = "10") Integer pageSize) throws ServerException;
-
-
-}

+ 0 - 36
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/groupshop/GroupShopServiceImpl.java

@@ -1,36 +0,0 @@
-package com.iotechn.unimall.app.api.groupshop;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.dto.goods.GroupShopDTO;
-import com.iotechn.unimall.data.mapper.GroupShopMapper;
-import com.iotechn.unimall.data.mapper.GroupShopSkuMapper;
-import com.iotechn.unimall.data.model.Page;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-
-import java.rmi.ServerException;
-import java.util.List;
-
-/**
- * Created with IntelliJ IDEA.
- * Description:
- * User: rize
- * Date: 2019/11/24
- * Time: 15:26
- */
-@Service
-public class GroupShopServiceImpl implements GroupShopService {
-
-    @Autowired
-    private GroupShopMapper groupShopMapper;
-
-    @Override
-    public Page<GroupShopDTO> getGroupShopPage(Integer pageNo, Integer pageSize) throws ServerException {
-        Integer count = groupShopMapper.selectCount(null);
-        List<GroupShopDTO> groupShopPage = groupShopMapper.getGroupShopPage((pageNo - 1) * pageSize, pageSize);
-        return new Page<>(groupShopPage, pageNo, pageSize, count);
-    }
-
-
-}

+ 0 - 18
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/integral/IntegralService.java

@@ -1,18 +0,0 @@
-package com.iotechn.unimall.app.api.integral;
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.dto.IntegralIndexDataDTO;
-
-/**
- * 将多个接口聚合到一起,减少HTTP访问次数
- * Created by rize on 2019/7/14.
- */
-@HttpOpenApi(group = "integral", description = "聚合接口")
-public interface IntegralService {
-
-    @HttpMethod(description = "获取首页聚合数据")
-    public IntegralIndexDataDTO getIndexData() throws ServiceException;
-
-}

+ 0 - 79
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/integral/IntegralServiceImpl.java

@@ -1,79 +0,0 @@
-package com.iotechn.unimall.app.api.integral;
-
-import com.iotechn.unimall.app.api.advertisement.AdvertisementService;
-import com.iotechn.unimall.biz.service.recommend.RecommendBizService;
-import com.iotechn.unimall.biz.service.goods.GoodsBizService;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.AdvertisementDO;
-import com.iotechn.unimall.data.dto.AdvertisementDTO;
-import com.iotechn.unimall.data.dto.IntegralIndexDataDTO;
-import com.iotechn.unimall.data.dto.RecommendDTO;
-import com.iotechn.unimall.data.dto.goods.SpuDTO;
-import com.iotechn.unimall.data.enums.AdvertisementType;
-import com.iotechn.unimall.data.enums.RecommendType;
-import com.iotechn.unimall.data.model.Page;
-import org.springframework.beans.BeanUtils;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.CollectionUtils;
-
-import java.util.List;
-import java.util.Map;
-import java.util.stream.Collectors;
-
-/**
- * Created by rize on 2019/7/14.
- */
-@Service
-public class IntegralServiceImpl implements IntegralService {
-
-    @Autowired
-    private AdvertisementService advertisementService;
-
-    @Autowired
-    private GoodsBizService goodsBizService;
-
-    @Autowired
-    private RecommendBizService recommendBizService;
-
-    @Override
-    public IntegralIndexDataDTO getIndexData() throws ServiceException {
-        //分类
-        List<AdvertisementDO> activeAd = advertisementService.getActiveAd(null);
-        Map<String, List<AdvertisementDTO>> adDTOMap = activeAd.stream().map(item -> {
-            AdvertisementDTO advertisementDTO = new AdvertisementDTO();
-            BeanUtils.copyProperties(item, advertisementDTO);
-            return advertisementDTO;
-        }).collect(Collectors.groupingBy(item -> "t" + item.getAdType()));
-        List<AdvertisementDTO> categoryPickAd = adDTOMap.get("t" + AdvertisementType.CATEGORY_PICK.getCode());
-        //封装 分类精选 商品
-        if (!CollectionUtils.isEmpty(categoryPickAd)) {
-            for (AdvertisementDTO item : categoryPickAd) {
-                Page<SpuDTO> pickPage = goodsBizService.getGoodsPage(1, 10, new Long(item.getUrl().substring(item.getUrl().lastIndexOf("=") + 1)), "sales", false,null);
-                item.setData(pickPage.getItems());
-            }
-        }
-        IntegralIndexDataDTO integralIndexDataDTO = new IntegralIndexDataDTO();
-        integralIndexDataDTO.setAdvertisement(adDTOMap);
-
-        /**
-         * 橱窗推荐
-         */
-        List<RecommendDTO> windowRecommend = recommendBizService.getRecommendByType(RecommendType.WINDOW.getCode(), 1, 10);
-        integralIndexDataDTO.setWindowRecommend(windowRecommend);
-
-        /**
-         * 销量冠军
-         */
-        List<SpuDTO> salesTop = goodsBizService.getGoodsPage(1, 8, null, "sales", false, null).getItems();
-        integralIndexDataDTO.setSalesTop(salesTop);
-
-        /**
-         * 最近上新
-         */
-        List<SpuDTO> newTop = goodsBizService.getGoodsPage(1, 8, null, "id", false, null).getItems();
-        integralIndexDataDTO.setNewTop(newTop);
-        return integralIndexDataDTO;
-    }
-
-}

+ 0 - 66
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/IMarketAdvertisementInfoAppService.java

@@ -1,66 +0,0 @@
-package com.iotechn.unimall.app.api.market;
-
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketAdvertisementInfo;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-/**
- * 广告信息Service接口
- *
- * @author jlb
- * @date 2022-08-01
- */
-@HttpOpenApi(group = "marketAdvertisementInfoApp", description = "广告信息")
-public interface IMarketAdvertisementInfoAppService {
-    @HttpMethod(description = "新增", permission = "admin:market:marketAdvertisementInfo:add", permissionParentName = "宠物管理", permissionName = "广告信息管理")
-    public Boolean add(@NotNull @HttpParam(name = "marketAdvertisementInfo", type = HttpParamType.COMMON, description = "广告信息") MarketAdvertisementInfo marketAdvertisementInfo,
-                       @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "列表")
-    public Page<MarketAdvertisementInfo> list(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "advertisementName", type = HttpParamType.COMMON, description = "广告名称") String advertisementName,
-            @HttpParam(name = "url", type = HttpParamType.COMMON, description = "图片") String url,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-            throws ServiceException;
-
-    @HttpMethod(description = "删除", permission = "admin:market:marketAdvertisementInfo:delete", permissionParentName = "宠物管理", permissionName = "广告信息管理")
-    public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "") String id) throws ServiceException;
-
-    @HttpMethod(description = "修改", permission = "admin:market:marketAdvertisementInfo:update", permissionParentName = "宠物管理", permissionName = "广告信息管理")
-    public Boolean update(@NotNull @HttpParam(name = "marketAdvertisementInfo", type = HttpParamType.COMMON, description = "广告信息") MarketAdvertisementInfo marketAdvertisementInfo,
-                          @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "查询", permission = "admin:market:marketAdvertisementInfo:get", permissionParentName = "宠物管理", permissionName = "广告信息管理")
-    public MarketAdvertisementInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "") Long id) throws ServiceException;
-
-    @HttpMethod(description = "导出excl表", permission = "admin:market:marketAdvertisementInfo:export", permissionParentName = "宠物管理", permissionName = "广告信息管理")
-    public String export(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "advertisementName", type = HttpParamType.COMMON, description = "广告名称") String advertisementName,
-            @HttpParam(name = "url", type = HttpParamType.COMMON, description = "图片") String url,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit) throws ServiceException;
-
-}

+ 0 - 49
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/IMarketCaseAppService.java

@@ -1,49 +0,0 @@
-package com.iotechn.unimall.app.api.market;
-
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketCase;
-import com.iotechn.unimall.data.model.Page;
-
-/**
- * 关注Service接口
- * 
- * @author jlb
- * @date 2023-02-03
- */
-@HttpOpenApi(group = "marketCaseApp", description = "关注")
-public interface IMarketCaseAppService {
-	@HttpMethod(description = "新增")
-	public Boolean add(@NotNull @HttpParam(name = "marketCase", type = HttpParamType.COMMON, description = "关注") MarketCase marketCase,
-						   @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "adminId") Long adminId)throws ServiceException;
-
-	@HttpMethod(description = "列表")
-	public Page<MarketCase> list(
-								@HttpParam(name = "concernedId", type = HttpParamType.COMMON, description = "被关注人id") String concernedId,
-							@HttpParam(name = "followersId", type = HttpParamType.COMMON, description = "关注人id") String followersId,
-					@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-		@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-		throws ServiceException;
-
-	@HttpMethod(description = "删除")
-	public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = " ")String id)throws ServiceException;
-
-	@HttpMethod(description = "修改")
-	public Boolean update(@NotNull @HttpParam(name = "marketCase", type = HttpParamType.COMMON, description = "关注") MarketCase marketCase,
-						  @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId)throws ServiceException;
-
-	@HttpMethod(description = "查询")
-	public MarketCase get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = " ")Long id)throws ServiceException;
-	
-	@HttpMethod(description = "导出excl表", permission = "admin:unimall:marketCase:export",permissionParentName = "宠物管理", permissionName = "关注管理")
-	public String export(@HttpParam(name = "concernedId", type = HttpParamType.COMMON, description = "被关注人id") String concernedId,
-							@HttpParam(name = "followersId", type = HttpParamType.COMMON, description = "关注人id") String followersId,
-				@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-	@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)throws ServiceException;
-	
-}

+ 0 - 57
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/IMarketCircleInfoAppService.java

@@ -1,57 +0,0 @@
-package com.iotechn.unimall.app.api.market;
-
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketCircleInfo;
-import com.iotechn.unimall.data.domain.market.MarketOrderInfo;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-/**
- * 订单信息Service接口
- *
- * @author jlb
- * @date 2022-08-01
- */
-@HttpOpenApi(group = "marketCircleInfoApp", description = "订单信息")
-public interface IMarketCircleInfoAppService {
-    @HttpMethod(description = "新增")
-    public Boolean add(@NotNull @HttpParam(name = "marketCircleInfo", type = HttpParamType.COMMON, description = "生鲜圈") MarketCircleInfo marketCircleInfo,
-                       @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId)throws ServiceException;
-
-    @HttpMethod(description = "列表")
-    public Page<MarketCircleInfo> list(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "shopId", type = HttpParamType.COMMON, description = "店铺id") Long shopId,
-            @HttpParam(name = "content", type = HttpParamType.COMMON, description = "内容") String content,
-            @HttpParam(name = "region", type = HttpParamType.COMMON, description = "地点") String region,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "url", type = HttpParamType.COMMON, description = "附件") String url,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "fllowId", type = HttpParamType.COMMON, description = "") Long fllowId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-            throws ServiceException;
-
-    @HttpMethod(description = "删除", permission = "admin:market:marketCircleInfo:delete",permissionParentName = "宠物管理", permissionName = "生鲜圈管理")
-    public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")String id)throws ServiceException;
-
-    @HttpMethod(description = "修改", permission = "admin:market:marketCircleInfo:update",permissionParentName = "宠物管理", permissionName = "生鲜圈管理")
-    public Boolean update(@NotNull @HttpParam(name = "marketCircleInfo", type = HttpParamType.COMMON, description = "生鲜圈") MarketCircleInfo marketCircleInfo,
-                          @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId)throws ServiceException;
-
-    @HttpMethod(description = "查询", permission = "admin:market:marketCircleInfo:get",permissionParentName = "宠物管理", permissionName = "生鲜圈管理")
-    public MarketCircleInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")Long id)throws ServiceException;
-
-
-}

+ 0 - 70
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/IMarketOrderDetailAppService.java

@@ -1,70 +0,0 @@
-package com.iotechn.unimall.app.api.market;
-
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketOrderDetail;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-/**
- * 订单详情Service接口
- *
- * @author jlb
- * @date 2022-08-01
- */
-@HttpOpenApi(group = "marketOrderDetailApp", description = "订单详情")
-public interface IMarketOrderDetailAppService {
-    @HttpMethod(description = "新增", permission = "admin:unimall:marketOrderDetail:add", permissionParentName = "宠物管理", permissionName = "订单详情管理")
-    public Boolean add(@NotNull @HttpParam(name = "marketOrderDetail", type = HttpParamType.COMMON, description = "订单详情") MarketOrderDetail marketOrderDetail,
-                       @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "列表", permission = "admin:unimall:marketOrderDetail:list", permissionParentName = "宠物管理", permissionName = "订单详情管理")
-    public Page<MarketOrderDetail> list(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "orderId", type = HttpParamType.COMMON, description = "订单id") String orderId,
-            @HttpParam(name = "name", type = HttpParamType.COMMON, description = "商品名称") String name,
-            @HttpParam(name = "price", type = HttpParamType.COMMON, description = "单价") Double price,
-            @HttpParam(name = "num", type = HttpParamType.COMMON, description = "数量") Long num,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-            throws ServiceException;
-
-    @HttpMethod(description = "删除", permission = "admin:unimall:marketOrderDetail:delete", permissionParentName = "宠物管理", permissionName = "订单详情管理")
-    public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "") String id) throws ServiceException;
-
-    @HttpMethod(description = "修改", permission = "admin:unimall:marketOrderDetail:update", permissionParentName = "宠物管理", permissionName = "订单详情管理")
-    public Boolean update(@NotNull @HttpParam(name = "marketOrderDetail", type = HttpParamType.COMMON, description = "订单详情") MarketOrderDetail marketOrderDetail,
-                          @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "查询", permission = "admin:unimall:marketOrderDetail:get", permissionParentName = "宠物管理", permissionName = "订单详情管理")
-    public MarketOrderDetail get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "") Long id) throws ServiceException;
-
-    @HttpMethod(description = "导出excl表", permission = "admin:unimall:marketOrderDetail:export", permissionParentName = "宠物管理", permissionName = "订单详情管理")
-    public String export(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "orderId", type = HttpParamType.COMMON, description = "订单id") String orderId,
-            @HttpParam(name = "name", type = HttpParamType.COMMON, description = "商品名称") String name,
-            @HttpParam(name = "price", type = HttpParamType.COMMON, description = "单价") Double price,
-            @HttpParam(name = "num", type = HttpParamType.COMMON, description = "数量") Long num,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit) throws ServiceException;
-
-}

+ 0 - 68
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/IMarketOrderInfoAppService.java

@@ -1,68 +0,0 @@
-package com.iotechn.unimall.app.api.market;
-
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketOrderInfo;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-/**
- * 订单信息Service接口
- *
- * @author jlb
- * @date 2022-08-01
- */
-@HttpOpenApi(group = "marketOrderInfoApp", description = "订单信息")
-public interface IMarketOrderInfoAppService {
-    @HttpMethod(description = "新增", permission = "admin:unimall:marketOrderInfo:add", permissionParentName = "宠物管理", permissionName = "订单信息管理")
-    public Boolean add(@NotNull @HttpParam(name = "marketOrderInfo", type = HttpParamType.COMMON, description = "订单信息") MarketOrderInfo marketOrderInfo,
-                       @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "列表", permission = "admin:unimall:marketOrderInfo:list", permissionParentName = "宠物管理", permissionName = "订单信息管理")
-    public Page<MarketOrderInfo> list(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "orderNo", type = HttpParamType.COMMON, description = "订单编号") String orderNo,
-            @HttpParam(name = "customer", type = HttpParamType.COMMON, description = "客户") String customer,
-            @HttpParam(name = "pets", type = HttpParamType.COMMON, description = "收货地址") String pets,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-            throws ServiceException;
-
-    @HttpMethod(description = "删除", permission = "admin:unimall:marketOrderInfo:delete", permissionParentName = "宠物管理", permissionName = "订单信息管理")
-    public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "") String id) throws ServiceException;
-
-    @HttpMethod(description = "修改", permission = "admin:unimall:marketOrderInfo:update", permissionParentName = "宠物管理", permissionName = "订单信息管理")
-    public Boolean update(@NotNull @HttpParam(name = "marketOrderInfo", type = HttpParamType.COMMON, description = "订单信息") MarketOrderInfo marketOrderInfo,
-                          @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "查询", permission = "admin:unimall:marketOrderInfo:get", permissionParentName = "宠物管理", permissionName = "订单信息管理")
-    public MarketOrderInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "") Long id) throws ServiceException;
-
-    @HttpMethod(description = "导出excl表", permission = "admin:unimall:marketOrderInfo:export", permissionParentName = "宠物管理", permissionName = "订单信息管理")
-    public String export(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "orderNo", type = HttpParamType.COMMON, description = "订单编号") String orderNo,
-            @HttpParam(name = "customer", type = HttpParamType.COMMON, description = "客户") String customer,
-            @HttpParam(name = "pets", type = HttpParamType.COMMON, description = "收货地址") String pets,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit) throws ServiceException;
-
-}

+ 0 - 74
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/IMarketProdectInfoAppService.java

@@ -1,74 +0,0 @@
-package com.iotechn.unimall.app.api.market;
-
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketProdectInfo;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-/**
- * 商品信息Service接口
- *
- * @author jlb
- * @date 2022-08-01
- */
-@HttpOpenApi(group = "marketProdectInfoApp", description = "商品信息")
-public interface IMarketProdectInfoAppService {
-    @HttpMethod(description = "新增", permission = "admin:unimall:marketProdectInfo:add", permissionParentName = "宠物管理", permissionName = "商品信息管理")
-    public Boolean add(@NotNull @HttpParam(name = "marketProdectInfo", type = HttpParamType.COMMON, description = "商品信息") MarketProdectInfo marketProdectInfo,
-                       @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "列表", permission = "admin:unimall:marketProdectInfo:list", permissionParentName = "宠物管理", permissionName = "商品信息管理")
-    public Page<MarketProdectInfo> list(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "prodectName", type = HttpParamType.COMMON, description = "商品名称") String prodectName,
-            @HttpParam(name = "classificationKey", type = HttpParamType.COMMON, description = "商品分类key") String classificationKey,
-            @HttpParam(name = "classification", type = HttpParamType.COMMON, description = "商品分类") String classification,
-            @HttpParam(name = "url", type = HttpParamType.COMMON, description = "封面") String url,
-            @HttpParam(name = "productDetails", type = HttpParamType.COMMON, description = "商品详情") String productDetails,
-            @HttpParam(name = "commodity price", type = HttpParamType.COMMON, description = "商品售价") Double commodityPrice,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-            throws ServiceException;
-
-    @HttpMethod(description = "删除", permission = "admin:unimall:marketProdectInfo:delete", permissionParentName = "宠物管理", permissionName = "商品信息管理")
-    public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "") String id) throws ServiceException;
-
-    @HttpMethod(description = "修改", permission = "admin:unimall:marketProdectInfo:update", permissionParentName = "宠物管理", permissionName = "商品信息管理")
-    public Boolean update(@NotNull @HttpParam(name = "marketProdectInfo", type = HttpParamType.COMMON, description = "商品信息") MarketProdectInfo marketProdectInfo,
-                          @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "查询", permission = "admin:unimall:marketProdectInfo:get", permissionParentName = "宠物管理", permissionName = "商品信息管理")
-    public MarketProdectInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "") Long id) throws ServiceException;
-
-    @HttpMethod(description = "导出excl表", permission = "admin:unimall:marketProdectInfo:export", permissionParentName = "宠物管理", permissionName = "商品信息管理")
-    public String export(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "prodectName", type = HttpParamType.COMMON, description = "商品名称") String prodectName,
-            @HttpParam(name = "classificationKey", type = HttpParamType.COMMON, description = "商品分类key") String classificationKey,
-            @HttpParam(name = "classification", type = HttpParamType.COMMON, description = "商品分类") String classification,
-            @HttpParam(name = "url", type = HttpParamType.COMMON, description = "封面") String url,
-            @HttpParam(name = "productDetails", type = HttpParamType.COMMON, description = "商品详情") String productDetails,
-            @HttpParam(name = "commodity price", type = HttpParamType.COMMON, description = "商品售价") Double commodityPrice,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit) throws ServiceException;
-
-}

+ 0 - 72
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/IMarketReceivingAddressAppService.java

@@ -1,72 +0,0 @@
-package com.iotechn.unimall.app.api.market;
-
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketReceivingAddress;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-/**
- * 收货地址Service接口
- * 
- * @author jlb
- * @date 2022-08-01
- */
-@HttpOpenApi(group = "marketReceivingAddressApp", description = "收货地址")
-public interface IMarketReceivingAddressAppService {
-	@HttpMethod(description = "新增", permission = "admin:unimall:marketReceivingAddress:add", permissionParentName = "宠物管理", permissionName = "收货地址管理")
-	public Boolean add(@NotNull @HttpParam(name = "marketReceivingAddress", type = HttpParamType.COMMON, description = "收货地址") MarketReceivingAddress marketReceivingAddress,
-						   @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId)throws ServiceException;
-
-	@HttpMethod(description = "列表", permission = "admin:unimall:marketReceivingAddress:list",permissionParentName = "宠物管理", permissionName = "收货地址管理")
-	public Page<MarketReceivingAddress> list(
-								@HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-							@HttpParam(name = "cusId", type = HttpParamType.COMMON, description = "客户id") String cusId,
-							@HttpParam(name = "consigneeName", type = HttpParamType.COMMON, description = "收货人姓名") String consigneeName,
-							@HttpParam(name = "phone", type = HttpParamType.COMMON, description = "手机号") String phone,
-							@HttpParam(name = "location", type = HttpParamType.COMMON, description = "所在地区") String location,
-							@HttpParam(name = "address", type = HttpParamType.COMMON, description = "详细地址") String address,
-							@HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-							@HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-					@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-		@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-		throws ServiceException;
-
-	@HttpMethod(description = "删除", permission = "admin:unimall:marketReceivingAddress:delete",permissionParentName = "宠物管理", permissionName = "收货地址管理")
-	public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")String id)throws ServiceException;
-
-	@HttpMethod(description = "修改", permission = "admin:unimall:marketReceivingAddress:update",permissionParentName = "宠物管理", permissionName = "收货地址管理")
-	public Boolean update(@NotNull @HttpParam(name = "marketReceivingAddress", type = HttpParamType.COMMON, description = "收货地址") MarketReceivingAddress marketReceivingAddress,
-						  @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId)throws ServiceException;
-
-	@HttpMethod(description = "查询", permission = "admin:unimall:marketReceivingAddress:get",permissionParentName = "宠物管理", permissionName = "收货地址管理")
-	public MarketReceivingAddress get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "")Long id)throws ServiceException;
-	
-	@HttpMethod(description = "导出excl表", permission = "admin:unimall:marketReceivingAddress:export",permissionParentName = "宠物管理", permissionName = "收货地址管理")
-	public String export(
-								@HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-							@HttpParam(name = "cusId", type = HttpParamType.COMMON, description = "客户id") String cusId,
-							@HttpParam(name = "consigneeName", type = HttpParamType.COMMON, description = "收货人姓名") String consigneeName,
-							@HttpParam(name = "phone", type = HttpParamType.COMMON, description = "手机号") String phone,
-							@HttpParam(name = "location", type = HttpParamType.COMMON, description = "所在地区") String location,
-							@HttpParam(name = "address", type = HttpParamType.COMMON, description = "详细地址") String address,
-							@HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-							@HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-							@HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-							@HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-							@HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-							@HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-				@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-	@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)throws ServiceException;
-	
-}

+ 0 - 74
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/IMarketShopInfoAppService.java

@@ -1,74 +0,0 @@
-package com.iotechn.unimall.app.api.market;
-
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketShopInfo;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.Date;
-
-/**
- * 商店信息Service接口
- *
- * @author jlb
- * @date 2022-08-01
- */
-@HttpOpenApi(group = "marketShopInfoApp", description = "商店信息")
-public interface IMarketShopInfoAppService {
-    @HttpMethod(description = "新增")
-    public Boolean add(@NotNull @HttpParam(name = "marketShopInfo", type = HttpParamType.COMMON, description = "商店信息") MarketShopInfo marketShopInfo,
-                       @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "列表")
-    public Page<MarketShopInfo> list(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "name", type = HttpParamType.COMMON, description = "名称") String name,
-            @HttpParam(name = "postion", type = HttpParamType.COMMON, description = "位置") String postion,
-            @HttpParam(name = "url", type = HttpParamType.COMMON, description = "封面") String url,
-            @HttpParam(name = "phone", type = HttpParamType.COMMON, description = "手机") String phone,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "level", type = HttpParamType.COMMON, description = "信誉等级") String level,
-            @HttpParam(name = "caseWorld", type = HttpParamType.COMMON, description = "关键词") String caseWorld,
-            @HttpParam(name = "lon", type = HttpParamType.COMMON, description = "经度") String lon,
-            @HttpParam(name = "lat", type = HttpParamType.COMMON, description = "纬度") String lat,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
-            throws ServiceException;
-
-    @HttpMethod(description = "删除")
-    public Boolean delete(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "") String id) throws ServiceException;
-
-    @HttpMethod(description = "修改")
-    public Boolean update(@NotNull @HttpParam(name = "marketShopInfo", type = HttpParamType.COMMON, description = "商店信息") MarketShopInfo marketShopInfo,
-                          @HttpParam(name = "adminId", type = HttpParamType.ADMIN_ID, description = "adminId") Long adminId) throws ServiceException;
-
-    @HttpMethod(description = "查询")
-    public MarketShopInfo get(@NotNull @HttpParam(name = "id", type = HttpParamType.COMMON, description = "") Long id) throws ServiceException;
-
-    @HttpMethod(description = "导出excl表", permission = "admin:unimall:marketShopInfo:export", permissionParentName = "宠物管理", permissionName = "商店信息管理")
-    public String export(
-            @HttpParam(name = "companyId", type = HttpParamType.COMMON, description = "") Long companyId,
-            @HttpParam(name = "name", type = HttpParamType.COMMON, description = "名称") String name,
-            @HttpParam(name = "postion", type = HttpParamType.COMMON, description = "位置") String postion,
-            @HttpParam(name = "url", type = HttpParamType.COMMON, description = "封面") String url,
-            @HttpParam(name = "phone", type = HttpParamType.COMMON, description = "手机") String phone,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "状态") String status,
-            @HttpParam(name = "deleteFlag", type = HttpParamType.COMMON, description = "0:否(默认) 1:是") Integer deleteFlag,
-            @HttpParam(name = "gmtCreate", type = HttpParamType.COMMON, description = "") Date gmtCreate,
-            @HttpParam(name = "gmtUpdate", type = HttpParamType.COMMON, description = "") Date gmtUpdate,
-            @HttpParam(name = "userId", type = HttpParamType.COMMON, description = "") Long userId,
-            @HttpParam(name = "adminId", type = HttpParamType.COMMON, description = "") Long adminId,
-            @HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
-            @HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit) throws ServiceException;
-
-}

+ 0 - 136
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/MarketAdvertisementInfoAppServiceImpl.java

@@ -1,136 +0,0 @@
-package com.iotechn.unimall.app.api.market;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketAdvertisementInfo;
-import com.iotechn.unimall.data.mapper.market.MarketAdvertisementInfoMapper;
-import com.iotechn.unimall.data.model.Page;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.StringUtils;
-
-import java.util.Date;
-import java.util.List;
-
-/**
- * 广告信息Service业务层处理
- *
- * @author jlb
- * @date 2022-08-01
- */
-@Service
-public class MarketAdvertisementInfoAppServiceImpl implements IMarketAdvertisementInfoAppService {
-    @Autowired
-    private MarketAdvertisementInfoMapper marketAdvertisementInfoMapper;
-
-    @Override
-    public Boolean add(MarketAdvertisementInfo marketAdvertisementInfo, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketAdvertisementInfo.setGmtCreate(now);
-        marketAdvertisementInfo.setGmtUpdate(now);
-        marketAdvertisementInfo.setAdminId(adminId);
-        return marketAdvertisementInfoMapper.insert(marketAdvertisementInfo) > 0;
-    }
-
-    @Override
-    public Page<MarketAdvertisementInfo> list(Long companyId, String advertisementName, String url, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketAdvertisementInfo> wrapper = new EntityWrapper<MarketAdvertisementInfo>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(advertisementName)) {
-            wrapper.eq("advertisement_name", advertisementName);
-        }
-        if (!StringUtils.isEmpty(url)) {
-            wrapper.eq("url", url);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        wrapper.eq("delete_flag", 0);
-        List<MarketAdvertisementInfo> list = marketAdvertisementInfoMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-        Integer count = marketAdvertisementInfoMapper.selectCount(wrapper);
-        return new Page<MarketAdvertisementInfo>(list, page, limit, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt : ids) {
-            MarketAdvertisementInfo tmp = marketAdvertisementInfoMapper.selectById(Long.parseLong(tt));
-            if (tmp != null) {
-                tmp.setDeleteFlag(1);
-                marketAdvertisementInfoMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(MarketAdvertisementInfo marketAdvertisementInfo, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketAdvertisementInfo.setGmtUpdate(now);
-        marketAdvertisementInfo.setAdminId(adminId);
-        return marketAdvertisementInfoMapper.updateById(marketAdvertisementInfo) > 0;
-    }
-
-    @Override
-    public MarketAdvertisementInfo get(Long id) throws ServiceException {
-        return marketAdvertisementInfoMapper.selectById(id);
-    }
-
-    @Override
-    public String export(Long companyId, String advertisementName, String url, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketAdvertisementInfo> wrapper = new EntityWrapper<MarketAdvertisementInfo>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(advertisementName)) {
-            wrapper.eq("advertisement_name", advertisementName);
-        }
-        if (!StringUtils.isEmpty(url)) {
-            wrapper.eq("url", url);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        List<MarketAdvertisementInfo> list = marketAdvertisementInfoMapper.selectList(wrapper);
-        ExcelUtil<MarketAdvertisementInfo> util = new ExcelUtil<MarketAdvertisementInfo>(MarketAdvertisementInfo.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 93
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/MarketCaseAppServiceImpl.java

@@ -1,93 +0,0 @@
-package com.iotechn.unimall.app.api.market;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketCase;
-import com.iotechn.unimall.data.mapper.market.MarketCaseMapper;
-import com.iotechn.unimall.data.model.Page;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.StringUtils;
-
-import java.util.Date;
-import java.util.List;
-
-/**
- * 关注Service业务层处理
- * 
- * @author jlb
- * @date 2023-02-03
- */
-@Service
-public class MarketCaseAppServiceImpl implements IMarketCaseAppService {
-	@Autowired
-	private MarketCaseMapper marketCaseMapper;
-	
-	@Override
-	public Boolean add(MarketCase marketCase, Long adminId) throws ServiceException {
-		Date now = new Date();
-		marketCase.setGmtCreate(now);
-		marketCase.setGmtUpdate(now);
-		return marketCaseMapper.insert(marketCase)>0;
-	}
-
-	@Override
-	public Page<MarketCase> list(String concernedId,String followersId, Integer page, Integer limit)throws ServiceException {
-		Wrapper<MarketCase> wrapper = new EntityWrapper<MarketCase>();
-														if (!StringUtils.isEmpty(concernedId)) {
-					wrapper.eq("concerned_id", concernedId);
-				}
-												if (!StringUtils.isEmpty(followersId)) {
-					wrapper.eq("followers_id", followersId);
-				}
-							wrapper.eq("delete_flag", 0);
-		List<MarketCase> list = marketCaseMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-		Integer count = marketCaseMapper.selectCount(wrapper);
-		return new Page<MarketCase>(list, page, limit, count);
-	}
-
-	@Override
-	@Transactional(rollbackFor = Exception.class)
-	public Boolean delete(String id) {
-		String[] ids = String.valueOf(id).split(",");
-		for (String tt:ids) {
-			MarketCase tmp =  marketCaseMapper.selectById(Long.parseLong(tt));
-			if(tmp != null){
-				tmp.setDeleteFlag(1);
-				marketCaseMapper.updateById(tmp);
-			}
-		}
-		return true;
-	}
-
-	@Override
-	public Boolean update(MarketCase marketCase,Long adminId) throws ServiceException {
-		Date now = new Date();
-		marketCase.setGmtUpdate(now);
-		marketCase.setAdminId(adminId);
-		return marketCaseMapper.updateById(marketCase)>0;
-	}
-
-	@Override
-	public MarketCase get(Long id) throws ServiceException {
-		return marketCaseMapper.selectById(id);
-	}
-	
-	@Override
-	public String export(String concernedId,String followersId, Integer page, Integer limit)throws ServiceException {
-		Wrapper<MarketCase> wrapper = new EntityWrapper<MarketCase>();
-														if (!StringUtils.isEmpty(concernedId)) {
-					wrapper.eq("concerned_id", concernedId);
-				}
-												if (!StringUtils.isEmpty(followersId)) {
-					wrapper.eq("followers_id", followersId);
-				}
-							List<MarketCase> list = marketCaseMapper.selectList(wrapper);
-		ExcelUtil<MarketCase> util = new ExcelUtil<MarketCase>(MarketCase.class);
-		return util.exportExcel(list, "操作日志");
-	}
-}

+ 0 - 150
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/MarketCircleInfoAppServiceImpl.java

@@ -1,150 +0,0 @@
-package com.iotechn.unimall.app.api.market;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketCase;
-import com.iotechn.unimall.data.domain.market.MarketOrderInfo;
-import com.iotechn.unimall.data.mapper.market.MarketCaseMapper;
-import com.iotechn.unimall.data.mapper.market.MarketOrderInfoMapper;
-import com.iotechn.unimall.data.mapper.market.MarketShopInfoMapper;
-import com.iotechn.unimall.data.model.Page;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.StringUtils;
-
-import java.util.Date;
-import java.util.List;
-
-import java.util.List;
-
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.util.StringUtils;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import com.iotechn.unimall.data.mapper.market.MarketCircleInfoMapper;
-import com.iotechn.unimall.data.domain.market.MarketCircleInfo;
-import com.iotechn.unimall.data.model.Page;
-import java.util.Date;
-import org.springframework.transaction.annotation.Transactional;
-
-/**
- * 生鲜圈Service业务层处理
- *
- * @author jlb
- * @date 2023-01-03
- */
-@Service
-public class MarketCircleInfoAppServiceImpl implements IMarketCircleInfoAppService{
-    @Autowired
-    private MarketCircleInfoMapper marketCircleInfoMapper;
-    @Autowired
-    private MarketCaseMapper marketCaseMapper;
-    @Autowired
-    private MarketShopInfoMapper marketShopInfoMapper;
-    @Override
-    public Boolean add(MarketCircleInfo marketCircleInfo,Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketCircleInfo.setGmtCreate(now);
-        marketCircleInfo.setGmtUpdate(now);
-        marketCircleInfo.setAdminId(adminId);
-        return marketCircleInfoMapper.insert(marketCircleInfo)>0;
-    }
-
-    @Override
-    public Page<MarketCircleInfo> list(Long companyId, Long shopId, String content, String region, String status, String url, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId,Long fllowId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketCircleInfo> wrapper = new EntityWrapper<MarketCircleInfo>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(shopId)) {
-            wrapper.eq("shop_id", shopId);
-        }
-        if (!StringUtils.isEmpty(content)) {
-            wrapper.eq("content", content);
-        }
-        if (!StringUtils.isEmpty(region)) {
-            wrapper.like("region", region);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(url)) {
-            wrapper.eq("url", url);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-
-
-        //查询出当前关注的人列表
-        Wrapper<MarketCase> wrapper1 = new EntityWrapper<MarketCase>();
-        wrapper1.eq("followers_id", fllowId);
-        List<MarketCase> floowList = marketCaseMapper.selectList(wrapper1);
-
-        wrapper.eq("delete_flag", 0);
-        wrapper.orderBy("gmt_update",false);
-        List<MarketCircleInfo> list = marketCircleInfoMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-        for(MarketCircleInfo tmp : list){
-            for(MarketCase marketCase : floowList){
-                if(String.valueOf(tmp.getUserId()).equals(marketCase.getConcernedId())){
-                    tmp.setFlag(true);
-                    break;
-                }
-            }
-            tmp.setShopName(marketShopInfoMapper.selectById(tmp.getShopId()).getName());
-        }
-        Integer count = marketCircleInfoMapper.selectCount(wrapper);
-        return new Page<MarketCircleInfo>(list, page, limit, count);
-    }
-
-
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt:ids) {
-            MarketCircleInfo tmp =  marketCircleInfoMapper.selectById(Long.parseLong(tt));
-            if(tmp != null){
-                tmp.setDeleteFlag(1);
-                marketCircleInfoMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(MarketCircleInfo marketCircleInfo,Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketCircleInfo.setGmtUpdate(now);
-        marketCircleInfo.setAdminId(adminId);
-        return marketCircleInfoMapper.updateById(marketCircleInfo)>0;
-    }
-
-    @Override
-    public MarketCircleInfo get(Long id) throws ServiceException {
-        return marketCircleInfoMapper.selectById(id);
-    }
-
-   }

+ 0 - 148
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/MarketOrderDetailAppServiceImpl.java

@@ -1,148 +0,0 @@
-package com.iotechn.unimall.app.api.market;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketOrderDetail;
-import com.iotechn.unimall.data.mapper.market.MarketOrderDetailMapper;
-import com.iotechn.unimall.data.model.Page;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.StringUtils;
-
-import java.util.Date;
-import java.util.List;
-
-/**
- * 订单详情Service业务层处理
- *
- * @author jlb
- * @date 2022-08-01
- */
-@Service
-public class MarketOrderDetailAppServiceImpl implements IMarketOrderDetailAppService {
-    @Autowired
-    private MarketOrderDetailMapper marketOrderDetailMapper;
-
-    @Override
-    public Boolean add(MarketOrderDetail marketOrderDetail, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketOrderDetail.setGmtCreate(now);
-        marketOrderDetail.setGmtUpdate(now);
-        marketOrderDetail.setAdminId(adminId);
-        return marketOrderDetailMapper.insert(marketOrderDetail) > 0;
-    }
-
-    @Override
-    public Page<MarketOrderDetail> list(Long companyId, String orderId, String name, Double price, Long num, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketOrderDetail> wrapper = new EntityWrapper<MarketOrderDetail>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(orderId)) {
-            wrapper.eq("order_id", orderId);
-        }
-        if (!StringUtils.isEmpty(name)) {
-            wrapper.eq("name", name);
-        }
-        if (!StringUtils.isEmpty(price)) {
-            wrapper.eq("price", price);
-        }
-        if (!StringUtils.isEmpty(num)) {
-            wrapper.eq("num", num);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        wrapper.eq("delete_flag", 0);
-        List<MarketOrderDetail> list = marketOrderDetailMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-        Integer count = marketOrderDetailMapper.selectCount(wrapper);
-        return new Page<MarketOrderDetail>(list, page, limit, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt : ids) {
-            MarketOrderDetail tmp = marketOrderDetailMapper.selectById(Long.parseLong(tt));
-            if (tmp != null) {
-                tmp.setDeleteFlag(1);
-                marketOrderDetailMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(MarketOrderDetail marketOrderDetail, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketOrderDetail.setGmtUpdate(now);
-        marketOrderDetail.setAdminId(adminId);
-        return marketOrderDetailMapper.updateById(marketOrderDetail) > 0;
-    }
-
-    @Override
-    public MarketOrderDetail get(Long id) throws ServiceException {
-        return marketOrderDetailMapper.selectById(id);
-    }
-
-    @Override
-    public String export(Long companyId, String orderId, String name, Double price, Long num, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketOrderDetail> wrapper = new EntityWrapper<MarketOrderDetail>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(orderId)) {
-            wrapper.eq("order_id", orderId);
-        }
-        if (!StringUtils.isEmpty(name)) {
-            wrapper.eq("name", name);
-        }
-        if (!StringUtils.isEmpty(price)) {
-            wrapper.eq("price", price);
-        }
-        if (!StringUtils.isEmpty(num)) {
-            wrapper.eq("num", num);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        List<MarketOrderDetail> list = marketOrderDetailMapper.selectList(wrapper);
-        ExcelUtil<MarketOrderDetail> util = new ExcelUtil<MarketOrderDetail>(MarketOrderDetail.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 142
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/MarketOrderInfoAppServiceImpl.java

@@ -1,142 +0,0 @@
-package com.iotechn.unimall.app.api.market;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketOrderInfo;
-import com.iotechn.unimall.data.mapper.market.MarketOrderInfoMapper;
-import com.iotechn.unimall.data.model.Page;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.StringUtils;
-
-import java.util.Date;
-import java.util.List;
-
-/**
- * 订单信息Service业务层处理
- *
- * @author jlb
- * @date 2022-08-01
- */
-@Service
-public class MarketOrderInfoAppServiceImpl implements IMarketOrderInfoAppService {
-    @Autowired
-    private MarketOrderInfoMapper marketOrderInfoMapper;
-
-    @Override
-    public Boolean add(MarketOrderInfo marketOrderInfo, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketOrderInfo.setGmtCreate(now);
-        marketOrderInfo.setGmtUpdate(now);
-        marketOrderInfo.setAdminId(adminId);
-        return marketOrderInfoMapper.insert(marketOrderInfo) > 0;
-    }
-
-    @Override
-    public Page<MarketOrderInfo> list(Long companyId, String orderNo, String customer, String pets, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketOrderInfo> wrapper = new EntityWrapper<MarketOrderInfo>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(orderNo)) {
-            wrapper.eq("order_no", orderNo);
-        }
-        if (!StringUtils.isEmpty(customer)) {
-            wrapper.eq("customer", customer);
-        }
-        if (!StringUtils.isEmpty(pets)) {
-            wrapper.eq("pets", pets);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        wrapper.eq("delete_flag", 0);
-        List<MarketOrderInfo> list = marketOrderInfoMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-        Integer count = marketOrderInfoMapper.selectCount(wrapper);
-        return new Page<MarketOrderInfo>(list, page, limit, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt : ids) {
-            MarketOrderInfo tmp = marketOrderInfoMapper.selectById(Long.parseLong(tt));
-            if (tmp != null) {
-                tmp.setDeleteFlag(1);
-                marketOrderInfoMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(MarketOrderInfo marketOrderInfo, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketOrderInfo.setGmtUpdate(now);
-        marketOrderInfo.setAdminId(adminId);
-        return marketOrderInfoMapper.updateById(marketOrderInfo) > 0;
-    }
-
-    @Override
-    public MarketOrderInfo get(Long id) throws ServiceException {
-        return marketOrderInfoMapper.selectById(id);
-    }
-
-    @Override
-    public String export(Long companyId, String orderNo, String customer, String pets, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketOrderInfo> wrapper = new EntityWrapper<MarketOrderInfo>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(orderNo)) {
-            wrapper.eq("order_no", orderNo);
-        }
-        if (!StringUtils.isEmpty(customer)) {
-            wrapper.eq("customer", customer);
-        }
-        if (!StringUtils.isEmpty(pets)) {
-            wrapper.eq("pets", pets);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        List<MarketOrderInfo> list = marketOrderInfoMapper.selectList(wrapper);
-        ExcelUtil<MarketOrderInfo> util = new ExcelUtil<MarketOrderInfo>(MarketOrderInfo.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 160
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/MarketProdectInfoAppServiceImpl.java

@@ -1,160 +0,0 @@
-package com.iotechn.unimall.app.api.market;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketProdectInfo;
-import com.iotechn.unimall.data.mapper.market.MarketProdectInfoMapper;
-import com.iotechn.unimall.data.model.Page;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.StringUtils;
-
-import java.util.Date;
-import java.util.List;
-
-/**
- * 商品信息Service业务层处理
- *
- * @author jlb
- * @date 2022-08-01
- */
-@Service
-public class MarketProdectInfoAppServiceImpl implements IMarketProdectInfoAppService {
-    @Autowired
-    private MarketProdectInfoMapper marketProdectInfoMapper;
-
-    @Override
-    public Boolean add(MarketProdectInfo marketProdectInfo, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketProdectInfo.setGmtCreate(now);
-        marketProdectInfo.setGmtUpdate(now);
-        marketProdectInfo.setAdminId(adminId);
-        return marketProdectInfoMapper.insert(marketProdectInfo) > 0;
-    }
-
-    @Override
-    public Page<MarketProdectInfo> list(Long companyId, String prodectName, String classificationKey, String classification, String url, String productDetails, Double commodityPrice, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketProdectInfo> wrapper = new EntityWrapper<MarketProdectInfo>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(prodectName)) {
-            wrapper.eq("prodect_name", prodectName);
-        }
-        if (!StringUtils.isEmpty(classificationKey)) {
-            wrapper.eq("classification_key", classificationKey);
-        }
-        if (!StringUtils.isEmpty(classification)) {
-            wrapper.eq("classification", classification);
-        }
-        if (!StringUtils.isEmpty(url)) {
-            wrapper.eq("url", url);
-        }
-        if (!StringUtils.isEmpty(productDetails)) {
-            wrapper.eq("product_details", productDetails);
-        }
-        if (!StringUtils.isEmpty(commodityPrice)) {
-            wrapper.eq("commodity price", commodityPrice);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        wrapper.eq("delete_flag", 0);
-        List<MarketProdectInfo> list = marketProdectInfoMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-        Integer count = marketProdectInfoMapper.selectCount(wrapper);
-        return new Page<MarketProdectInfo>(list, page, limit, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt : ids) {
-            MarketProdectInfo tmp = marketProdectInfoMapper.selectById(Long.parseLong(tt));
-            if (tmp != null) {
-                tmp.setDeleteFlag(1);
-                marketProdectInfoMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(MarketProdectInfo marketProdectInfo, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketProdectInfo.setGmtUpdate(now);
-        marketProdectInfo.setAdminId(adminId);
-        return marketProdectInfoMapper.updateById(marketProdectInfo) > 0;
-    }
-
-    @Override
-    public MarketProdectInfo get(Long id) throws ServiceException {
-        return marketProdectInfoMapper.selectById(id);
-    }
-
-    @Override
-    public String export(Long companyId, String prodectName, String classificationKey, String classification, String url, String productDetails, Double commodityPrice, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketProdectInfo> wrapper = new EntityWrapper<MarketProdectInfo>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(prodectName)) {
-            wrapper.eq("prodect_name", prodectName);
-        }
-        if (!StringUtils.isEmpty(classificationKey)) {
-            wrapper.eq("classification_key", classificationKey);
-        }
-        if (!StringUtils.isEmpty(classification)) {
-            wrapper.eq("classification", classification);
-        }
-        if (!StringUtils.isEmpty(url)) {
-            wrapper.eq("url", url);
-        }
-        if (!StringUtils.isEmpty(productDetails)) {
-            wrapper.eq("product_details", productDetails);
-        }
-        if (!StringUtils.isEmpty(commodityPrice)) {
-            wrapper.eq("commodity price", commodityPrice);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        List<MarketProdectInfo> list = marketProdectInfoMapper.selectList(wrapper);
-        ExcelUtil<MarketProdectInfo> util = new ExcelUtil<MarketProdectInfo>(MarketProdectInfo.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 154
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/MarketReceivingAddressAppServiceImpl.java

@@ -1,154 +0,0 @@
-package com.iotechn.unimall.app.api.market;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketReceivingAddress;
-import com.iotechn.unimall.data.mapper.market.MarketReceivingAddressMapper;
-import com.iotechn.unimall.data.model.Page;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.StringUtils;
-
-import java.util.Date;
-import java.util.List;
-
-/**
- * 收货地址Service业务层处理
- *
- * @author jlb
- * @date 2022-08-01
- */
-@Service
-public class MarketReceivingAddressAppServiceImpl implements IMarketReceivingAddressAppService {
-    @Autowired
-    private MarketReceivingAddressMapper marketReceivingAddressMapper;
-
-    @Override
-    public Boolean add(MarketReceivingAddress marketReceivingAddress, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketReceivingAddress.setGmtCreate(now);
-        marketReceivingAddress.setGmtUpdate(now);
-        marketReceivingAddress.setAdminId(adminId);
-        return marketReceivingAddressMapper.insert(marketReceivingAddress) > 0;
-    }
-
-    @Override
-    public Page<MarketReceivingAddress> list(Long companyId, String cusId, String consigneeName, String phone, String location, String address, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketReceivingAddress> wrapper = new EntityWrapper<MarketReceivingAddress>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(cusId)) {
-            wrapper.eq("cus_id", cusId);
-        }
-        if (!StringUtils.isEmpty(consigneeName)) {
-            wrapper.eq("consignee_name", consigneeName);
-        }
-        if (!StringUtils.isEmpty(phone)) {
-            wrapper.eq("phone", phone);
-        }
-        if (!StringUtils.isEmpty(location)) {
-            wrapper.eq("location", location);
-        }
-        if (!StringUtils.isEmpty(address)) {
-            wrapper.eq("address", address);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        wrapper.eq("delete_flag", 0);
-        List<MarketReceivingAddress> list = marketReceivingAddressMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-        Integer count = marketReceivingAddressMapper.selectCount(wrapper);
-        return new Page<MarketReceivingAddress>(list, page, limit, count);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt : ids) {
-            MarketReceivingAddress tmp = marketReceivingAddressMapper.selectById(Long.parseLong(tt));
-            if (tmp != null) {
-                tmp.setDeleteFlag(1);
-                marketReceivingAddressMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(MarketReceivingAddress marketReceivingAddress, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketReceivingAddress.setGmtUpdate(now);
-        marketReceivingAddress.setAdminId(adminId);
-        return marketReceivingAddressMapper.updateById(marketReceivingAddress) > 0;
-    }
-
-    @Override
-    public MarketReceivingAddress get(Long id) throws ServiceException {
-        return marketReceivingAddressMapper.selectById(id);
-    }
-
-    @Override
-    public String export(Long companyId, String cusId, String consigneeName, String phone, String location, String address, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketReceivingAddress> wrapper = new EntityWrapper<MarketReceivingAddress>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(cusId)) {
-            wrapper.eq("cus_id", cusId);
-        }
-        if (!StringUtils.isEmpty(consigneeName)) {
-            wrapper.eq("consignee_name", consigneeName);
-        }
-        if (!StringUtils.isEmpty(phone)) {
-            wrapper.eq("phone", phone);
-        }
-        if (!StringUtils.isEmpty(location)) {
-            wrapper.eq("location", location);
-        }
-        if (!StringUtils.isEmpty(address)) {
-            wrapper.eq("address", address);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        List<MarketReceivingAddress> list = marketReceivingAddressMapper.selectList(wrapper);
-        ExcelUtil<MarketReceivingAddress> util = new ExcelUtil<MarketReceivingAddress>(MarketReceivingAddress.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 150
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/market/MarketShopInfoAppServiceImpl.java

@@ -1,150 +0,0 @@
-package com.iotechn.unimall.app.api.market;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.baomidou.mybatisplus.mapper.Wrapper;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.domain.market.MarketShopInfo;
-import com.iotechn.unimall.data.mapper.market.MarketShopInfoMapper;
-import com.iotechn.unimall.data.model.Page;
-import com.iotechn.unimall.data.util.ExcelUtil;
-import org.apache.ibatis.session.RowBounds;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.StringUtils;
-
-import java.util.Date;
-import java.util.List;
-
-/**
- * 商店信息Service业务层处理
- *
- * @author jlb
- * @date 2022-08-01
- */
-@Service
-public class MarketShopInfoAppServiceImpl implements IMarketShopInfoAppService {
-    @Autowired
-    private MarketShopInfoMapper marketShopInfoMapper;
-
-    @Override
-    public Boolean add(MarketShopInfo marketShopInfo, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketShopInfo.setGmtCreate(now);
-        marketShopInfo.setGmtUpdate(now);
-        marketShopInfo.setAdminId(adminId);
-        return marketShopInfoMapper.insert(marketShopInfo) > 0;
-    }
-
-    @Override
-    public Page<MarketShopInfo> list(Long companyId, String name, String postion, String url, String phone, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, String level, String caseWorld, String lon, String lat, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketShopInfo> wrapper = new EntityWrapper<MarketShopInfo>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(name)) {
-            wrapper.like("name", name);
-        }
-        if (!StringUtils.isEmpty(postion)) {
-            wrapper.eq("postion", postion);
-        }
-        if (!StringUtils.isEmpty(url)) {
-            wrapper.eq("url", url);
-        }
-        if (!StringUtils.isEmpty(phone)) {
-            wrapper.eq("phone", phone);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        wrapper.eq("delete_flag", 0);
-//        wrapper.orderBy("gmt_update",false);
-        List<MarketShopInfo> list = marketShopInfoMapper.selectPage(new RowBounds((page - 1) * limit, limit), wrapper);
-        Integer count = marketShopInfoMapper.selectCount(wrapper);
-        return new Page<MarketShopInfo>(list, page, limit, count);
-    }
-
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Boolean delete(String id) {
-        String[] ids = String.valueOf(id).split(",");
-        for (String tt : ids) {
-            MarketShopInfo tmp = marketShopInfoMapper.selectById(Long.parseLong(tt));
-            if (tmp != null) {
-                tmp.setDeleteFlag(1);
-                marketShopInfoMapper.updateById(tmp);
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public Boolean update(MarketShopInfo marketShopInfo, Long adminId) throws ServiceException {
-        Date now = new Date();
-        marketShopInfo.setGmtUpdate(now);
-        marketShopInfo.setAdminId(adminId);
-        return marketShopInfoMapper.updateById(marketShopInfo) > 0;
-    }
-
-    @Override
-    public MarketShopInfo get(Long id) throws ServiceException {
-        return marketShopInfoMapper.selectById(id);
-    }
-
-    @Override
-    public String export(Long companyId, String name, String postion, String url, String phone, String status, Integer deleteFlag, Date gmtCreate, Date gmtUpdate, Long userId, Long adminId, Integer page, Integer limit) throws ServiceException {
-        Wrapper<MarketShopInfo> wrapper = new EntityWrapper<MarketShopInfo>();
-        if (!StringUtils.isEmpty(companyId)) {
-            wrapper.eq("company_id", companyId);
-        }
-        if (!StringUtils.isEmpty(name)) {
-            wrapper.eq("name", name);
-        }
-        if (!StringUtils.isEmpty(postion)) {
-            wrapper.eq("postion", postion);
-        }
-        if (!StringUtils.isEmpty(url)) {
-            wrapper.eq("url", url);
-        }
-        if (!StringUtils.isEmpty(phone)) {
-            wrapper.eq("phone", phone);
-        }
-        if (!StringUtils.isEmpty(status)) {
-            wrapper.eq("status", status);
-        }
-        if (!StringUtils.isEmpty(deleteFlag)) {
-            wrapper.eq("delete_flag", deleteFlag);
-        }
-        if (!StringUtils.isEmpty(gmtCreate)) {
-            wrapper.eq("gmt_create", gmtCreate);
-        }
-        if (!StringUtils.isEmpty(gmtUpdate)) {
-            wrapper.eq("gmt_update", gmtUpdate);
-        }
-        if (!StringUtils.isEmpty(userId)) {
-            wrapper.eq("user_id", userId);
-        }
-        if (!StringUtils.isEmpty(adminId)) {
-            wrapper.eq("admin_id", adminId);
-        }
-        List<MarketShopInfo> list = marketShopInfoMapper.selectList(wrapper);
-        ExcelUtil<MarketShopInfo> util = new ExcelUtil<MarketShopInfo>(MarketShopInfo.class);
-        return util.exportExcel(list, "操作日志");
-    }
-}

+ 0 - 71
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/order/OrderService.java

@@ -1,71 +0,0 @@
-package com.iotechn.unimall.app.api.order;
-
-import com.iotechn.unimall.core.annotation.HttpMethod;
-import com.iotechn.unimall.core.annotation.HttpOpenApi;
-import com.iotechn.unimall.core.annotation.HttpParam;
-import com.iotechn.unimall.core.annotation.HttpParamType;
-import com.iotechn.unimall.core.annotation.param.NotNull;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.data.dto.freight.ShipTraceDTO;
-import com.iotechn.unimall.data.dto.order.OrderDTO;
-import com.iotechn.unimall.data.dto.order.OrderRequestDTO;
-import com.iotechn.unimall.data.model.Page;
-
-import java.util.List;
-
-/**
- * Created by rize on 2019/7/4.
- */
-@HttpOpenApi(group = "order", description = "订单服务")
-public interface OrderService {
-
-    @HttpMethod(description = "提交订单")
-    public String takeOrder(
-            @NotNull @HttpParam(name = "orderRequest", type = HttpParamType.COMMON, description = "订单请求实例") OrderRequestDTO orderRequest,
-            @NotNull @HttpParam(name = "channel", type = HttpParamType.COMMON, description = "订单提交渠道") String channel,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "userId") Long userId) throws ServiceException;
-
-    @HttpMethod(description = "获取订单分页")
-    public Page<OrderDTO> getOrderPage(
-            @HttpParam(name = "pageNo", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer pageNo,
-            @HttpParam(name = "pageSize", type = HttpParamType.COMMON, description = "页码长度", valueDef = "10") Integer pageSize,
-            @HttpParam(name = "status", type = HttpParamType.COMMON, description = "订单状态") Integer status,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId) throws ServiceException;
-
-    @HttpMethod(description = "获取订单详情")
-    public OrderDTO getOrderDetail(
-            @NotNull @HttpParam(name = "orderId", type = HttpParamType.COMMON, description = "订单号") Long orderId,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId) throws ServiceException;
-
-    @HttpMethod(description = "微信小程序预先支付")
-    public Object wxPrepay(
-            @NotNull @HttpParam(name = "orderNo", type = HttpParamType.COMMON, description = "订单串号") String orderNo,
-            @NotNull @HttpParam(name = "ip", type = HttpParamType.IP, description = "ip地址") String ip,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId) throws ServiceException;
-
-    @HttpMethod(description = "线下支付")
-    public Object offlinePrepay(
-            @NotNull @HttpParam(name = "orderNo", type = HttpParamType.COMMON, description = "订单串号") String orderNo,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId) throws ServiceException;
-
-    @HttpMethod(description = "用户申请退款")
-    public String refund(
-            @NotNull @HttpParam(name = "orderNo", type = HttpParamType.COMMON, description = "订单串号") String orderNo,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId) throws ServiceException;
-
-    @HttpMethod(description = "取消订单")
-    public String cancel(
-            @NotNull @HttpParam(name = "orderNo", type = HttpParamType.COMMON, description = "订单号") String orderNo,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId) throws ServiceException;
-
-    @HttpMethod(description = "确认订单")
-    public String confirm(
-            @NotNull @HttpParam(name = "orderNo", type = HttpParamType.COMMON, description = "订单号") String orderNo,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId) throws ServiceException;
-
-    @HttpMethod(description = "查询物流")
-    public ShipTraceDTO queryShip(
-            @NotNull @HttpParam(name = "orderNo", type = HttpParamType.COMMON, description = "订单号") String orderNo,
-            @NotNull @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId) throws ServiceException;
-
-}

+ 0 - 475
unimall-app-api/src/main/java/com/iotechn/unimall/app/api/order/OrderServiceImpl.java

@@ -1,475 +0,0 @@
-package com.iotechn.unimall.app.api.order;
-
-import com.baomidou.mybatisplus.mapper.EntityWrapper;
-import com.github.binarywang.wxpay.bean.order.WxPayAppOrderResult;
-import com.github.binarywang.wxpay.bean.order.WxPayMpOrderResult;
-import com.github.binarywang.wxpay.bean.request.WxPayUnifiedOrderRequest;
-import com.github.binarywang.wxpay.constant.WxPayConstants;
-import com.github.binarywang.wxpay.exception.WxPayException;
-import com.github.binarywang.wxpay.service.WxPayService;
-import com.iotechn.unimall.app.api.category.CategoryService;
-import com.iotechn.unimall.biz.service.freight.FreightBizService;
-import com.iotechn.unimall.biz.service.groupshop.GroupShopBizService;
-import com.iotechn.unimall.biz.service.order.OrderBizService;
-import com.iotechn.unimall.biz.service.user.UserBizService;
-import com.iotechn.unimall.core.exception.ExceptionDefinition;
-import com.iotechn.unimall.core.exception.AppServiceException;
-import com.iotechn.unimall.core.exception.ServiceException;
-import com.iotechn.unimall.core.exception.ThirdPartServiceException;
-import com.iotechn.unimall.core.util.GeneratorUtil;
-import com.iotechn.unimall.data.component.LockComponent;
-import com.iotechn.unimall.data.domain.*;
-import com.iotechn.unimall.data.dto.goods.GroupShopDTO;
-import com.iotechn.unimall.data.dto.goods.SkuDTO;
-import com.iotechn.unimall.data.dto.UserCouponDTO;
-import com.iotechn.unimall.data.dto.freight.ShipTraceDTO;
-import com.iotechn.unimall.data.dto.order.OrderDTO;
-import com.iotechn.unimall.data.dto.order.OrderRequestDTO;
-import com.iotechn.unimall.data.dto.order.OrderRequestSkuDTO;
-import com.iotechn.unimall.data.enums.*;
-import com.iotechn.unimall.data.mapper.*;
-import com.iotechn.unimall.data.model.Page;
-import com.iotechn.unimall.data.util.SessionUtil;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.beans.factory.annotation.Value;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.CollectionUtils;
-import org.springframework.util.StringUtils;
-
-import java.util.*;
-import java.util.stream.Collectors;
-
-/**
- * Created by rize on 2019/7/4.
- */
-@Service
-public class OrderServiceImpl implements OrderService {
-
-    private static final Logger logger = LoggerFactory.getLogger(OrderServiceImpl.class);
-
-    private static final String TAKE_ORDER_LOCK = "TAKE_ORDER_";
-
-    @Autowired
-    private SkuMapper skuMapper;
-
-    @Autowired
-    private UserCouponMapper userCouponMapper;
-
-    @Autowired
-    private OrderMapper orderMapper;
-
-    @Autowired
-    private OrderSkuMapper orderSkuMapper;
-
-    @Autowired
-    private AddressMapper addressMapper;
-
-    @Autowired
-    private CartMapper cartMapper;
-
-    @Autowired
-    private CategoryService categoryService;
-
-    @Autowired
-    private WxPayService wxPayService;
-
-    @Autowired
-    private LockComponent lockComponent;
-
-    @Autowired
-    private OrderBizService orderBizService;
-
-    @Autowired
-    private FreightBizService freightBizService;
-
-    @Autowired
-    private UserBizService userBizService;
-
-    @Autowired
-    private GroupShopBizService groupShopBizService;
-
-    @Value("${com.iotechn.unimall.machine-no}")
-    private String MACHINE_NO;
-
-    @Value("${com.iotechn.unimall.env}")
-    private String ENV;
-
-    @Value("${com.iotechn.unimall.wx.mini.app-id}")
-    private String wxMiNiAppid;
-
-    @Value("${com.iotechn.unimall.wx.app.app-id}")
-    private String wxAppAppid;
-
-    @Value("${com.iotechn.unimall.wx.h5.app-id}")
-    private String wxH5Appid;
-
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public String takeOrder(OrderRequestDTO orderRequest, String channel, Long userId) throws ServiceException {
-        if (lockComponent.tryLock(TAKE_ORDER_LOCK + userId, 20)) {
-            //加上乐观锁,防止用户重复提交订单
-            try {
-                //用户会员等级
-                Integer userLevel = SessionUtil.getUser().getLevel();
-                //参数强校验 START
-                List<OrderRequestSkuDTO> skuList = orderRequest.getSkuList();
-                if (CollectionUtils.isEmpty(skuList) || orderRequest.getTotalPrice() == null) {
-                    throw new AppServiceException(ExceptionDefinition.PARAM_CHECK_FAILED);
-                }
-                if (orderRequest.getTotalPrice() <= 0) {
-                    throw new AppServiceException(ExceptionDefinition.ORDER_PRICE_MUST_GT_ZERO);
-                }
-                Long groupShopId = orderRequest.getGroupShopId();
-                Integer groupShopPrice = null;
-                if (groupShopId != null) {
-                    //校验团购参数
-                    if (skuList.size() > 1) {
-                        throw new AppServiceException(ExceptionDefinition.ORDER_GROUP_SPU_CAN_SINGLE_TAKE);
-                    }
-                    GroupShopDTO groupShopDTO = groupShopBizService.getGroupShopById(groupShopId);
-                    if (groupShopDTO == null || groupShopDTO.getStatus() == StatusType.LOCK.getCode()) {
-                        throw new AppServiceException(ExceptionDefinition.ORDER_GROUP_SHOP_NOT_EXIST_OR_EXPIRED);
-                    }
-                    List<GroupShopSkuDO> groupShopSkuList = groupShopDTO.getGroupShopSkuList();
-                    for (GroupShopSkuDO groupShopSkuDO : groupShopSkuList) {
-                        if (groupShopSkuDO.getSkuId().equals(groupShopSkuList.get(0).getSkuId())) {
-                            //若找到交集
-                            groupShopPrice = groupShopSkuDO.getSkuGroupShopPrice();
-                        }
-                    }
-                }
-                //商品价格
-                int skuPrice = 0;
-                int skuOriginalPrice = 0;
-                //稍后用于优惠券作用范围校验
-                Map<Long, Integer> categoryPriceMap = new HashMap<>();
-                //稍后用于插入OrderSku
-                Map<Long, SkuDTO> skuIdDTOMap = new HashMap<>();
-                for (OrderRequestSkuDTO orderRequestSkuDTO : skuList) {
-                    SkuDTO skuDTO = skuMapper.getSkuDTOById(orderRequestSkuDTO.getSkuId());
-                    skuIdDTOMap.put(skuDTO.getId(), skuDTO);
-                    if (skuDTO == null) {
-                        throw new AppServiceException(ExceptionDefinition.ORDER_SKU_NOT_EXIST);
-                    }
-                    if (skuDTO.getStock() < orderRequestSkuDTO.getNum()) {
-                        throw new AppServiceException(ExceptionDefinition.ORDER_SKU_STOCK_NOT_ENOUGH);
-                    }
-                    int p;
-                    if (groupShopId != null && groupShopPrice != null) {
-                        p = groupShopPrice;
-                    } else if (userLevel == UserLevelType.VIP.getCode()) {
-                        p = skuDTO.getVipPrice() * orderRequestSkuDTO.getNum();
-                    } else {
-                        p = skuDTO.getPrice() * orderRequestSkuDTO.getNum();
-                    }
-                    skuPrice += p;
-                    skuOriginalPrice += skuDTO.getOriginalPrice();
-                    List<Long> categoryFamily = categoryService.getCategoryFamily(skuDTO.getCategoryId());
-                    for (Long cid : categoryFamily) {
-                        Integer price = categoryPriceMap.get(cid);
-                        if (price == null) {
-                            price = p;
-                        } else {
-                            price += p;
-                        }
-                        categoryPriceMap.put(cid, price);
-                    }
-                }
-
-                if (skuPrice != orderRequest.getTotalPrice()) {
-                    throw new AppServiceException(ExceptionDefinition.ORDER_PRICE_CHECK_FAILED);
-                }
-
-                //优惠券折扣价格
-                int couponPrice = 0;
-                //优惠券校验
-                UserCouponDTO userCouponFromFront = orderRequest.getCoupon();
-                if (userCouponFromFront != null) {
-                    if (userCouponFromFront.getId() == null || userCouponFromFront.getDiscount() == null) {
-                        throw new AppServiceException(ExceptionDefinition.PARAM_CHECK_FAILED);
-                    }
-
-                    UserCouponDTO userCouponFromDB = userCouponMapper.getUserCouponById(userCouponFromFront.getId(), userId);
-
-                    if (userCouponFromDB == null) {
-                        throw new AppServiceException(ExceptionDefinition.ORDER_COUPON_NOT_EXIST);
-                    }
-
-                    if (!userCouponFromDB.getDiscount().equals(userCouponFromFront.getDiscount())) {
-                        throw new AppServiceException(ExceptionDefinition.ORDER_COUPON_DISCOUNT_CHECK_FAILED);
-                    }
-
-                    //校验优惠券策略是否满足
-                    Long categoryId = userCouponFromDB.getCategoryId();
-                    if (categoryId != null) {
-                        Integer p = categoryPriceMap.get(categoryId);
-                        if (p < userCouponFromDB.getMin()) {
-                            throw new AppServiceException(ExceptionDefinition.ORDER_COUPON_PRICE_NOT_ENOUGH);
-                        }
-                    } else {
-                        if (skuPrice < userCouponFromDB.getMin()) {
-                            throw new AppServiceException(ExceptionDefinition.ORDER_COUPON_PRICE_NOT_ENOUGH);
-                        }
-                    }
-                    couponPrice = userCouponFromDB.getDiscount();
-                }
-
-                Integer freightPrice = freightBizService.getFreightMoney(orderRequest);
-                //参数强校验 END
-                //???是否校验actualPrice??强迫校验?
-                int actualPrice = skuPrice - couponPrice + freightPrice;
-                Date now = new Date();
-                OrderDO orderDO = new OrderDO();
-                orderDO.setSkuTotalPrice(skuPrice);
-                orderDO.setSkuOriginalTotalPrice(skuOriginalPrice);
-                orderDO.setChannel(channel);
-                orderDO.setActualPrice(actualPrice);
-                orderDO.setGroupShopId(groupShopId);
-                if (couponPrice != 0) {
-                    orderDO.setCouponId(orderRequest.getCoupon().getCouponId());
-                    orderDO.setCouponPrice(couponPrice);
-                }
-                orderDO.setMono(orderRequest.getMono());
-                orderDO.setFreightPrice(freightPrice);
-                orderDO.setOrderNo(GeneratorUtil.genOrderId(MACHINE_NO, ENV));
-                orderDO.setUserId(userId);
-                orderDO.setStatus(OrderStatusType.UNPAY.getCode());
-                orderDO.setGmtUpdate(now);
-                orderDO.setGmtCreate(now);
-
-                if (orderRequest.getAddressId() != null) {
-                    AddressDO addressDO = addressMapper.selectById(orderRequest.getAddressId());
-                    if (!userId.equals(addressDO.getUserId())) {
-                        throw new AppServiceException(ExceptionDefinition.ORDER_ADDRESS_NOT_BELONGS_TO_YOU);
-                    }
-                    orderDO.setConsignee(addressDO.getConsignee());
-                    orderDO.setPhone(addressDO.getPhone());
-                    orderDO.setProvince(addressDO.getProvince());
-                    orderDO.setCity(addressDO.getCity());
-                    orderDO.setCounty(addressDO.getCounty());
-                    orderDO.setAddress(addressDO.getAddress());
-                }
-                orderMapper.insert(orderDO);
-
-                //扣除用户优惠券
-                if (orderDO.getCouponId() != null) {
-                    UserCouponDO updateUserCouponDO = new UserCouponDO();
-                    updateUserCouponDO.setId(orderDO.getCouponId());
-                    updateUserCouponDO.setGmtUsed(now);
-                    updateUserCouponDO.setOrderId(orderDO.getId());
-                    userCouponMapper.updateById(updateUserCouponDO);
-                }
-
-                //插入OrderSku
-                skuList.forEach(item -> {
-                    SkuDTO skuDTO = skuIdDTOMap.get(item.getSkuId());
-                    OrderSkuDO orderSkuDO = new OrderSkuDO();
-                    orderSkuDO.setBarCode(skuDTO.getBarCode());
-                    orderSkuDO.setTitle(skuDTO.getTitle());
-                    orderSkuDO.setUnit(skuDTO.getUnit());
-                    orderSkuDO.setSpuTitle(skuDTO.getSpuTitle());
-                    orderSkuDO.setImg(skuDTO.getImg() == null ? skuDTO.getSpuImg() : skuDTO.getImg());
-                    orderSkuDO.setNum(item.getNum());
-                    orderSkuDO.setOriginalPrice(skuDTO.getOriginalPrice());
-                    orderSkuDO.setPrice(skuDTO.getPrice());
-                    if (userLevel == UserLevelType.VIP.getCode()) {
-                        orderSkuDO.setPrice(skuDTO.getVipPrice());
-                    } else {
-                        orderSkuDO.setPrice(skuDTO.getPrice());
-                    }
-                    orderSkuDO.setSkuId(skuDTO.getId());
-                    orderSkuDO.setSpuId(skuDTO.getSpuId());
-                    orderSkuDO.setOrderNo(orderDO.getOrderNo());
-                    orderSkuDO.setOrderId(orderDO.getId());
-                    orderSkuDO.setGmtCreate(now);
-                    orderSkuDO.setGmtUpdate(now);
-                    orderSkuMapper.insert(orderSkuDO);
-
-                    //扣除库存
-                    skuMapper.decSkuStock(item.getSkuId(), item.getNum());
-                });
-
-                if (!StringUtils.isEmpty(orderRequest.getTakeWay())) {
-                    String takeWay = orderRequest.getTakeWay();
-                    if ("cart".equals(takeWay)) {
-                        //扣除购物车
-                        List<Long> skuIds = skuList.stream().map(item -> item.getSkuId()).collect(Collectors.toList());
-                        cartMapper.delete(new EntityWrapper<CartDO>().in("sku_id", skuIds).eq("user_id", userId));
-                    }
-                    //直接购买传值为 "buy"
-                }
-
-                return orderDO.getOrderNo();
-
-            } catch (ServiceException e) {
-                throw e;
-            } catch (Exception e) {
-                logger.error("[提交订单] 异常", e);
-                throw new AppServiceException(ExceptionDefinition.ORDER_UNKNOWN_EXCEPTION);
-            } finally {
-                lockComponent.release(TAKE_ORDER_LOCK + userId);
-            }
-        }
-        throw new AppServiceException(ExceptionDefinition.ORDER_SYSTEM_BUSY);
-    }
-
-    @Override
-    public Page<OrderDTO> getOrderPage(Integer pageNo, Integer pageSize, Integer status, Long userId) throws ServiceException {
-        List<OrderDTO> orderDTOList = orderMapper.selectOrderPage(status, (pageNo - 1) * pageSize, pageSize, userId);
-        Long count = orderMapper.countOrder(status, (pageNo - 1) * pageSize, pageSize, userId);
-        //封装SKU
-        orderDTOList.forEach(item -> {
-            item.setSkuList(orderSkuMapper.selectList(new EntityWrapper<OrderSkuDO>().eq("order_id", item.getId())));
-        });
-        return new Page<>(orderDTOList, pageNo, pageSize, count);
-    }
-
-    @Override
-    public OrderDTO getOrderDetail(Long orderId, Long userId) throws ServiceException {
-        return orderBizService.getOrderDetail(orderId, userId);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Object wxPrepay(String orderNo, String ip, Long userId) throws ServiceException {
-        Date now = new Date();
-        OrderDO orderDO = orderBizService.checkOrderExist(orderNo, userId);
-        // 检测订单状态
-        Integer status = orderDO.getStatus();
-        if (status != OrderStatusType.UNPAY.getCode()) {
-            throw new AppServiceException(ExceptionDefinition.ORDER_STATUS_NOT_SUPPORT_PAY);
-        }
-
-        Integer loginType = SessionUtil.getUser().getLoginType();
-        String appId;
-        String tradeType;
-        if (UserLoginType.MP_WEIXIN.getCode() == loginType) {
-            appId = wxMiNiAppid;
-            tradeType = WxPayConstants.TradeType.JSAPI;
-        } else if (UserLoginType.APP_WEIXIN.getCode() == loginType || UserLoginType.REGISTER.getCode() == loginType) {
-            appId = wxAppAppid;
-            tradeType = WxPayConstants.TradeType.APP;
-        } else if (UserLoginType.H5_WEIXIN.getCode() == loginType) {
-            appId = wxH5Appid;
-            tradeType = WxPayConstants.TradeType.JSAPI;
-        } else {
-            throw new AppServiceException(ExceptionDefinition.ORDER_LOGIN_TYPE_NOT_SUPPORT_WXPAY);
-        }
-
-        Object result = null;
-        try {
-            WxPayUnifiedOrderRequest orderRequest = new WxPayUnifiedOrderRequest();
-            orderRequest.setAppid(appId);
-            orderRequest.setOutTradeNo(orderNo);
-            orderRequest.setOpenid(SessionUtil.getUser().getOpenId());
-            orderRequest.setBody("订单:" + orderNo);
-            orderRequest.setTotalFee(orderDO.getActualPrice());
-            orderRequest.setSpbillCreateIp(ip);
-            orderRequest.setTradeType(tradeType);
-            result = wxPayService.createOrder(orderRequest);
-            if (result instanceof  WxPayMpOrderResult) {
-                String prepayId = ((WxPayMpOrderResult)result).getPackageValue();
-                prepayId = prepayId.replace("prepay_id=", "");
-                UserFormIdDO userFormIdDO = new UserFormIdDO();
-                userFormIdDO.setFormId(prepayId);
-                userFormIdDO.setUserId(userId);
-                userFormIdDO.setOpenid(SessionUtil.getUser().getOpenId());
-                userFormIdDO.setGmtUpdate(now);
-                userFormIdDO.setGmtCreate(now);
-                userBizService.setValidFormId(userFormIdDO);
-            }
-        } catch (WxPayException e) {
-            logger.error("[微信支付] 异常", e);
-            throw new ThirdPartServiceException(e.getErrCodeDes(), ExceptionDefinition.THIRD_PART_SERVICE_EXCEPTION.getCode());
-        } catch (Exception e) {
-            logger.error("[预付款异常]", e);
-            throw new AppServiceException(ExceptionDefinition.ORDER_UNKNOWN_EXCEPTION);
-        }
-        return result;
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public Object offlinePrepay(String orderNo, Long userId) throws ServiceException {
-        OrderDO orderDO = orderBizService.checkOrderExist(orderNo, userId);
-        // 检测订单状态
-        Integer status = orderDO.getStatus();
-        if (status != OrderStatusType.UNPAY.getCode()) {
-            throw new AppServiceException(ExceptionDefinition.ORDER_STATUS_NOT_SUPPORT_PAY);
-        }
-        OrderDO updateOrderDO = new OrderDO();
-        updateOrderDO.setPayChannel(PayChannelType.OFFLINE.getCode());
-        updateOrderDO.setStatus(OrderStatusType.WAIT_STOCK.getCode());
-        updateOrderDO.setGmtUpdate(new Date());
-        boolean succ = orderBizService.changeOrderStatus(orderNo, OrderStatusType.UNPAY.getCode(), updateOrderDO);
-        if (succ) {
-            return "ok";
-        }
-        throw new AppServiceException(ExceptionDefinition.ORDER_STATUS_CHANGE_FAILED);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public String refund(String orderNo, Long userId) throws ServiceException {
-        OrderDO orderDO = orderBizService.checkOrderExist(orderNo, userId);
-        if (PayChannelType.OFFLINE.getCode().equals(orderDO.getPayChannel())) {
-            throw new AppServiceException(ExceptionDefinition.ORDER_PAY_CHANNEL_NOT_SUPPORT_REFUND);
-        }
-        if (OrderStatusType.refundable(orderDO.getStatus())) {
-            OrderDO updateOrderDO = new OrderDO();
-            updateOrderDO.setStatus(OrderStatusType.REFUNDING.getCode());
-            orderBizService.changeOrderStatus(orderNo, orderDO.getStatus() , updateOrderDO);
-            return "ok";
-        }
-        throw new AppServiceException(ExceptionDefinition.ORDER_STATUS_NOT_SUPPORT_REFUND);
-    }
-
-    @Override
-    @Transactional(rollbackFor = Exception.class)
-    public String cancel(String orderNo, Long userId) throws ServiceException {
-        OrderDO orderDO = orderBizService.checkOrderExist(orderNo, userId);
-        if (orderDO.getStatus() != OrderStatusType.UNPAY.getCode()) {
-            throw new AppServiceException(ExceptionDefinition.ORDER_STATUS_NOT_SUPPORT_CANCEL);
-        }
-        OrderDO updateOrderDO = new OrderDO();
-        updateOrderDO.setStatus(OrderStatusType.CANCELED.getCode());
-        updateOrderDO.setGmtUpdate(new Date());
-        orderBizService.changeOrderStatus(orderNo, OrderStatusType.UNPAY.getCode(), updateOrderDO);
-        return "ok";
-    }
-
-    @Override
-    public String confirm(String orderNo, Long userId) throws ServiceException {
-        OrderDO orderDO = orderBizService.checkOrderExist(orderNo, userId);
-        if (orderDO.getStatus() != OrderStatusType.WAIT_CONFIRM.getCode()) {
-            throw new AppServiceException(ExceptionDefinition.ORDER_STATUS_NOT_SUPPORT_CONFIRM);
-        }
-        OrderDO updateOrderDO = new OrderDO();
-        updateOrderDO.setStatus(OrderStatusType.WAIT_APPRAISE.getCode());
-        updateOrderDO.setGmtUpdate(new Date());
-        orderBizService.changeOrderStatus(orderNo, OrderStatusType.WAIT_CONFIRM.getCode(), updateOrderDO);
-        return "ok";
-    }
-
-    @Override
-    public ShipTraceDTO queryShip(String orderNo, Long userId) throws ServiceException {
-        OrderDO orderDO = orderBizService.checkOrderExist(orderNo, userId);
-        if (orderDO.getStatus() < OrderStatusType.WAIT_CONFIRM.getCode()) {
-            throw new AppServiceException(ExceptionDefinition.ORDER_HAS_NOT_SHIP);
-        }
-        if (StringUtils.isEmpty(orderDO.getShipCode()) || StringUtils.isEmpty(orderDO.getShipNo())) {
-            throw new AppServiceException(ExceptionDefinition.ORDER_DID_NOT_SET_SHIP);
-        }
-        ShipTraceDTO shipTraceList = freightBizService.getShipTraceList(orderDO.getShipNo(), orderDO.getShipCode());
-        if (CollectionUtils.isEmpty(shipTraceList.getTraces())) {
-            throw new AppServiceException(ExceptionDefinition.ORDER_DO_NOT_EXIST_SHIP_TRACE);
-        }
-        return shipTraceList;
-    }
-
-
-}

Some files were not shown because too many files changed in this diff