diff --git a/dl-module-base/pom.xml b/dl-module-base/pom.xml
index 7146ee3c..49b21e0f 100644
--- a/dl-module-base/pom.xml
+++ b/dl-module-base/pom.xml
@@ -113,4 +113,4 @@
3.1.837
-
\ No newline at end of file
+
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/appBase/controller/AppSwiperController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/appBase/controller/AppSwiperController.java
index 35141fa7..1344e3c5 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/appBase/controller/AppSwiperController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/appBase/controller/AppSwiperController.java
@@ -1,16 +1,27 @@
package cn.iocoder.yudao.module.appBase.controller;
+import cn.hutool.core.util.ObjectUtil;
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
+import cn.iocoder.yudao.framework.security.core.LoginUser;
+import cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils;
import cn.iocoder.yudao.module.appBase.entity.AppSwiper;
import cn.iocoder.yudao.module.appBase.service.IAppSwiperService;
import cn.iocoder.yudao.module.core.controller.BaseController;
import cn.iocoder.yudao.module.core.page.TableDataInfo;
+import cn.iocoder.yudao.module.shop.entity.ShopMallPartners;
+import cn.iocoder.yudao.module.shop.service.IShopMallPartnersService;
+import cn.iocoder.yudao.module.system.dal.dataobject.user.AdminUserDO;
+import cn.iocoder.yudao.module.system.service.user.AdminUserService;
import cn.iocoder.yudao.util.ExcelUtil;
+import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
+import com.thoughtworks.xstream.core.SecurityUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.*;
import javax.servlet.http.HttpServletResponse;
+import java.util.HashMap;
import java.util.List;
+import java.util.Map;
/**
* 【请填写功能名称】Controller
@@ -19,17 +30,21 @@ import java.util.List;
* @date 2023-08-01
*/
@RestController
-@RequestMapping("/system/appSwiper")
+@RequestMapping("/admin-api")
public class AppSwiperController extends BaseController
{
@Autowired
private IAppSwiperService appSwiperService;
+ @Autowired
+ private IShopMallPartnersService partnersService;
+ @Autowired
+ private AdminUserService userService;
/**
* 查询【请填写功能名称】列表
*/
@PreAuthorize("@ss.hasPermi('system:swiper:list')")
- @GetMapping("/list")
+ @GetMapping("/system/appSwiper/list")
public TableDataInfo list(AppSwiper appSwiper)
{
startPage();
@@ -41,7 +56,7 @@ public class AppSwiperController extends BaseController
* 导出【请填写功能名称】列表
*/
@PreAuthorize("@ss.hasPermi('system:swiper:export')")
- @PostMapping("/export")
+ @PostMapping("/system/appSwiper/export")
public void export(HttpServletResponse response, AppSwiper appSwiper)
{
List list = appSwiperService.selectAppSwiperList(appSwiper);
@@ -53,7 +68,7 @@ public class AppSwiperController extends BaseController
* 获取【请填写功能名称】详细信息
*/
@PreAuthorize("@ss.hasPermi('system:swiper:query')")
- @GetMapping(value = "/{swiperId}")
+ @GetMapping(value = "/system/appSwiper/{swiperId}")
public CommonResult getInfo(@PathVariable("swiperId") Long swiperId)
{
return success(appSwiperService.selectAppSwiperBySwiperId(swiperId));
@@ -63,7 +78,7 @@ public class AppSwiperController extends BaseController
* 新增【请填写功能名称】
*/
@PreAuthorize("@ss.hasPermi('system:swiper:add')")
- @PostMapping("/add")
+ @PostMapping("/system/appSwiper/add")
public CommonResult add(@RequestBody AppSwiper appSwiper)
{
return toAjax(appSwiperService.insertAppSwiper(appSwiper));
@@ -72,7 +87,7 @@ public class AppSwiperController extends BaseController
/**
* 修改【请填写功能名称】
*/
- @PostMapping("/edit")
+ @PostMapping("/system/appSwiper/edit")
public CommonResult edit(@RequestBody AppSwiper appSwiper)
{
return toAjax(appSwiperService.updateAppSwiper(appSwiper));
@@ -81,9 +96,26 @@ public class AppSwiperController extends BaseController
/**
* 删除【请填写功能名称】
*/
- @PostMapping("/del")
+ @PostMapping("/system/appSwiper/del")
public CommonResult remove(@RequestParam("idList") Long[] idList)
{
return toAjax(appSwiperService.deleteAppSwiperBySwiperIds(idList));
}
+
+
+ @GetMapping("/getJcPartnerInfo")
+ public CommonResult getJcPartnerInfo()
+ {
+ LambdaQueryWrapper queryWrapper =new LambdaQueryWrapper<>();
+ LoginUser user = SecurityFrameworkUtils.getLoginUser();
+ queryWrapper.eq(ShopMallPartners::getUserId,user.getId()).eq(ShopMallPartners::getType,"jc").eq(ShopMallPartners::getIsBanned,"0");
+ ShopMallPartners partner = partnersService.getOne(queryWrapper);
+ if (ObjectUtil.isEmpty(partner)){
+ return error("信息有误");
+ }
+ AdminUserDO sysUser = userService.getUser(user.getId());
+ Map map = new HashMap<>();
+ map.put("user", sysUser);
+ return CommonResult.success(map);
+ }
}
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppGoodsController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppGoodsController.java
index 4958c458..c72aa702 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppGoodsController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppGoodsController.java
@@ -16,7 +16,7 @@ import cn.iocoder.yudao.module.core.controller.BaseController;
import java.util.List;
@RestController
-@RequestMapping("/appInspection/goods")
+@RequestMapping("/admin-api/appInspection/goods")
public class AppGoodsController extends BaseController {
@Autowired
private AppInspectionGoodsService appInspectionGoodsService;
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppHomeController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppHomeController.java
index d72d465e..ba25b269 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppHomeController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppHomeController.java
@@ -22,7 +22,7 @@ import java.util.List;
* @since 2023-08-01 16:04:12
*/
@RestController("AppShopInspectionGoods")
-@RequestMapping("/appInspection/appHome")
+@RequestMapping("/admin-api/appInspection/appHome")
public class AppHomeController extends BaseController {
/**
* 服务对象
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppNewsController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppNewsController.java
index bbbc12ff..09a5009e 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppNewsController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppNewsController.java
@@ -16,6 +16,7 @@ import cn.iocoder.yudao.module.system.service.dict.DictDataService;
import cn.iocoder.yudao.module.system.service.permission.RoleService;
import cn.iocoder.yudao.util.StringUtils;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.github.pagehelper.PageHelper;
import cn.iocoder.yudao.module.core.controller.BaseController;
import cn.iocoder.yudao.module.core.page.TableDataInfo;
@@ -34,7 +35,7 @@ import java.util.List;
import java.util.stream.Collectors;
@RestController
-@RequestMapping("/appInspection/news")
+@RequestMapping("/admin-api/appInspection/news")
public class AppNewsController extends BaseController {
@Autowired
private IInspectionNewsService inspectionNewsService;
@@ -104,21 +105,21 @@ public class AppNewsController extends BaseController {
return success(list);
}
@GetMapping("/list")
- public TableDataInfo list(InspectionNews inspectionNews)
+ public TableDataInfo list(InspectionNews inspectionNews,@RequestParam("pageNum") Integer pageNum,@RequestParam("pageSize") Integer pageSize)
{
- startPage();
- List list = inspectionNewsService.selectInspectionNewsList(inspectionNews);
+ Page page = new Page<>(pageNum, pageSize);
+ List list = inspectionNewsService.selectInspectionNewsList(page,inspectionNews);
return getDataTable(list);
}
@GetMapping("/ownList")
- public TableDataInfo ownList(InspectionNews inspectionNews)
+ public TableDataInfo ownList(InspectionNews inspectionNews,@RequestParam("pageNum") Integer pageNum,@RequestParam("pageSize") Integer pageSize)
{
//当前登录用户
LoginUser loginUser = SecurityFrameworkUtils.getLoginUser();
inspectionNews.setCreator(loginUser.getId().toString());
- startPage();
- List list = inspectionNewsService.selectInspectionNewsList(inspectionNews);
+ Page page = new Page<>(pageNum, pageSize);
+ List list = inspectionNewsService.selectInspectionNewsList(page,inspectionNews);
return getDataTable(list);
}
@PostMapping("/add")
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppOrderController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppOrderController.java
index 612fbc10..422e80f2 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppOrderController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppOrderController.java
@@ -17,7 +17,7 @@ import org.springframework.web.bind.annotation.RestController;
import java.util.List;
@RestController
-@RequestMapping("/appInspection/order")
+@RequestMapping("/admin-api/appInspection/order")
public class AppOrderController extends BaseController {
@Autowired
private AppInspectionOrderService appInspectionOrderService;
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppPartnerController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppPartnerController.java
index f0ab5d03..dc93a082 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppPartnerController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppPartnerController.java
@@ -16,7 +16,7 @@ import org.springframework.web.bind.annotation.*;
import java.util.List;
@RestController
-@RequestMapping("/appInspection/partner")
+@RequestMapping("/admin-api/appInspection/partner")
public class AppPartnerController extends BaseController {
@Autowired
private AppInspectionPartnerService partnerList;
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppUserOwnController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppUserOwnController.java
index 5a99009b..769b511b 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppUserOwnController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/AppUserOwnController.java
@@ -13,7 +13,7 @@ import org.springframework.web.bind.annotation.*;
import java.util.List;
@RestController
-@RequestMapping("/appInspection/userOwn")
+@RequestMapping("/admin-api/appInspection/userOwn")
public class AppUserOwnController extends BaseController {
@Autowired
private AppUserOwnService ownService;
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/DelInspectionInfoController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/DelInspectionInfoController.java
index ff986dfe..c7262f8c 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/DelInspectionInfoController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/DelInspectionInfoController.java
@@ -27,7 +27,7 @@ import cn.iocoder.yudao.module.core.page.TableDataInfo;
* @date 2024-05-08
*/
@RestController
-@RequestMapping("/system/delInfo")
+@RequestMapping("/admin-api/system/delInfo")
public class DelInspectionInfoController extends BaseController
{
@Autowired
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionAppointmentController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionAppointmentController.java
index af2ca109..9ed115ed 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionAppointmentController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionAppointmentController.java
@@ -20,7 +20,7 @@ import cn.iocoder.yudao.module.core.page.TableDataInfo;
* @date 2023-08-24
*/
@RestController
-@RequestMapping("/inspection/appointment")
+@RequestMapping("/admin-api/inspection/appointment")
public class InspectionAppointmentController extends BaseController
{
@Autowired
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionCategoryTemplateController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionCategoryTemplateController.java
index cd61186d..d251bac4 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionCategoryTemplateController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionCategoryTemplateController.java
@@ -28,7 +28,7 @@ import cn.iocoder.yudao.module.core.page.TableDataInfo;
* @date 2023-09-07
*/
@RestController
-@RequestMapping("/inspection/template")
+@RequestMapping("/admin-api/inspection/template")
public class InspectionCategoryTemplateController extends BaseController
{
@Autowired
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionEquInfoController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionEquInfoController.java
index fb2c6435..f3f877b3 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionEquInfoController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionEquInfoController.java
@@ -27,7 +27,7 @@ import cn.iocoder.yudao.module.core.page.TableDataInfo;
* @date 2023-10-13
*/
@RestController
-@RequestMapping("/system/equInfo")
+@RequestMapping("/admin-api/system/equInfo")
public class InspectionEquInfoController extends BaseController
{
@Autowired
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionFileController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionFileController.java
index ce39d58f..4cc714ba 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionFileController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionFileController.java
@@ -26,7 +26,7 @@ import cn.iocoder.yudao.module.core.page.TableDataInfo;
* @date 2023-10-13
*/
@RestController
-@RequestMapping("/inspectionFile/inspectionFile")
+@RequestMapping("/admin-api/inspectionFile/inspectionFile")
public class InspectionFileController extends BaseController
{
@Autowired
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionGoodsSkuController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionGoodsSkuController.java
index 8735135c..3780ca18 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionGoodsSkuController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionGoodsSkuController.java
@@ -17,7 +17,7 @@ import java.util.List;
* @since 2023-08-08 16:59:29
*/
@RestController
-@RequestMapping("/system/inspectionGoodsSku")
+@RequestMapping("/admin-api/system/inspectionGoodsSku")
public class InspectionGoodsSkuController extends BaseController {
/**
* 服务对象
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionHomePartnerController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionHomePartnerController.java
index 69cd5189..ee689a57 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionHomePartnerController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionHomePartnerController.java
@@ -14,7 +14,7 @@ import cn.iocoder.yudao.module.core.controller.BaseController;
* @date 2023-08-02
*/
@RestController
-@RequestMapping("/system/homePartner")
+@RequestMapping("/admin-api/system/homePartner")
public class InspectionHomePartnerController extends BaseController
{
@Autowired
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionInfoController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionInfoController.java
index 119dc5f9..f9fe9000 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionInfoController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionInfoController.java
@@ -20,7 +20,7 @@ import cn.iocoder.yudao.module.core.page.TableDataInfo;
* @date 2023-08-13
*/
@RestController
-@RequestMapping("/system/info")
+@RequestMapping("/admin-api/system/info")
public class InspectionInfoController extends BaseController
{
@Autowired
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionMallPartnersController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionMallPartnersController.java
index 48291e9c..e76c76ee 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionMallPartnersController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionMallPartnersController.java
@@ -19,6 +19,7 @@ import cn.iocoder.yudao.module.system.service.permission.PermissionService;
import cn.iocoder.yudao.module.system.service.permission.RoleService;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.github.pagehelper.PageHelper;
import cn.iocoder.yudao.module.core.controller.BaseController;
import cn.iocoder.yudao.module.core.page.TableDataInfo;
@@ -38,7 +39,7 @@ import java.util.stream.Collectors;
@RestController
-@RequestMapping("/system/inspectionMallPartners")
+@RequestMapping("/admin-api/system/inspectionMallPartners")
public class InspectionMallPartnersController extends BaseController {
@Autowired
private IShopMallPartnersService shopMallPartnersService;
@@ -57,11 +58,11 @@ public class InspectionMallPartnersController extends BaseController {
* 查询合作商管理列表
*/
@GetMapping("/list")
- public TableDataInfo list(ShopMallPartners shopMallPartners)
+ public TableDataInfo list(ShopMallPartners shopMallPartners,@RequestParam("pageNum") Integer pageNum,@RequestParam("pageSize") Integer pageSize)
{
shopMallPartners.setType("jc");
- startPage();
- List list = shopMallPartnersService.selectShopMallPartnersList(shopMallPartners);
+ Page page = new Page<>(pageNum, pageSize);
+ List list = shopMallPartnersService.selectShopMallPartnersList(page,shopMallPartners);
return getDataTable(list);
}
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionNewsAssociationController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionNewsAssociationController.java
index 23418cc5..e7f80bc2 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionNewsAssociationController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionNewsAssociationController.java
@@ -27,7 +27,7 @@ import cn.iocoder.yudao.module.core.page.TableDataInfo;
* @date 2023-08-07
*/
@RestController
-@RequestMapping("/system/association")
+@RequestMapping("/admin-api/system/association")
public class InspectionNewsAssociationController extends BaseController
{
@Autowired
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionNewsCommentController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionNewsCommentController.java
index 65c20742..ce920d09 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionNewsCommentController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionNewsCommentController.java
@@ -27,7 +27,7 @@ import cn.iocoder.yudao.module.core.page.TableDataInfo;
* @date 2023-08-07
*/
@RestController
-@RequestMapping("/system/comment")
+@RequestMapping("/admin-api/system/comment")
public class InspectionNewsCommentController extends BaseController
{
@Autowired
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionNewsController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionNewsController.java
index 6dba452f..d383bd02 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionNewsController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionNewsController.java
@@ -5,6 +5,8 @@ import java.util.List;
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
import cn.iocoder.yudao.module.inspection.entity.InspectionNews;
import cn.iocoder.yudao.module.inspection.service.IInspectionNewsService;
+import cn.iocoder.yudao.module.shop.entity.ShopMallPartners;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
@@ -18,7 +20,7 @@ import cn.iocoder.yudao.module.core.page.TableDataInfo;
* @date 2023-08-03
*/
@RestController
-@RequestMapping("/system/inspectionNews")
+@RequestMapping("/admin-api/system/inspectionNews")
public class InspectionNewsController extends BaseController
{
@Autowired
@@ -27,12 +29,12 @@ public class InspectionNewsController extends BaseController
/**
* 查询【请填写功能名称】列表
*/
- @PreAuthorize("@ss.hasPermi('system:news:list')")
+// @PreAuthorize("@ss.hasPermi('system:news:list')")
@GetMapping("/list")
- public TableDataInfo list(InspectionNews inspectionNews)
+ public TableDataInfo list(InspectionNews inspectionNews,@RequestParam("pageNum") Integer pageNum,@RequestParam("pageSize") Integer pageSize)
{
- startPage();
- List list = inspectionNewsService.selectInspectionNewsList(inspectionNews);
+ Page page = new Page<>(pageNum, pageSize);
+ List list = inspectionNewsService.selectInspectionNewsList(page,inspectionNews);
return getDataTable(list);
}
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionPickCarController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionPickCarController.java
index ef07d468..d8641587 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionPickCarController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/InspectionPickCarController.java
@@ -27,7 +27,7 @@ import cn.iocoder.yudao.module.core.page.TableDataInfo;
* @date 2023-09-02
*/
@RestController
-@RequestMapping("/inspection/pickCar")
+@RequestMapping("/admin-api/inspection/pickCar")
public class InspectionPickCarController extends BaseController
{
@Autowired
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/PartnerOwnController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/PartnerOwnController.java
index a2e792ac..578a6311 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/PartnerOwnController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/PartnerOwnController.java
@@ -36,7 +36,7 @@ import java.util.List;
import java.util.stream.Collectors;
@RestController
-@RequestMapping("/partnerOwn/partner")
+@RequestMapping("/admin-api/partnerOwn/partner")
public class PartnerOwnController extends BaseController {
@Autowired
private AppInspectionPartnerService partnerList;
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/ShopInspectionCategoryController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/ShopInspectionCategoryController.java
index 52030068..ca1fbd34 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/ShopInspectionCategoryController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/ShopInspectionCategoryController.java
@@ -1,6 +1,8 @@
package cn.iocoder.yudao.module.inspection.controller;
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
+import cn.iocoder.yudao.framework.common.pojo.PageParam;
+import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.module.core.controller.BaseController;
import cn.iocoder.yudao.module.core.page.TableDataInfo;
import cn.iocoder.yudao.module.inspection.entity.ShopInspectionCategory;
@@ -17,7 +19,7 @@ import java.util.List;
* @since 2023-08-01 19:59:23
*/
@RestController
-@RequestMapping("/system/shopInspectionCategory")
+@RequestMapping("/admin-api/system/shopInspectionCategory")
public class ShopInspectionCategoryController extends BaseController {
/**
* 服务对象
@@ -31,11 +33,13 @@ public class ShopInspectionCategoryController extends BaseController {
* @return 所有数据
*/
@GetMapping("/list")
- public TableDataInfo list(ShopInspectionCategory shopInspectionCategory)
+ public CommonResult list(ShopInspectionCategory shopInspectionCategory,@RequestParam("pageNum")Integer pageNum,@RequestParam("pageSize")Integer pageSize)
{
- startPage();
- List list = this.shopInspectionCategoryService.listVo(shopInspectionCategory);
- return getDataTable(list);
+ PageParam pageParam = new PageParam();
+ pageParam.setPageNo(pageNum);
+ pageParam.setPageSize(pageSize);
+ PageResult res = this.shopInspectionCategoryService.listVo(shopInspectionCategory,pageParam);
+ return CommonResult.success(res);
}
/**
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/ShopInspectionGoodsController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/ShopInspectionGoodsController.java
index 789a2ed2..53cb401a 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/ShopInspectionGoodsController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/ShopInspectionGoodsController.java
@@ -19,6 +19,7 @@ import cn.iocoder.yudao.module.inspection.service.AppInspectionPartnerService;
import cn.iocoder.yudao.module.partner.entity.PartnerWorker;
import cn.iocoder.yudao.module.payment.entity.OrderInfo;
import cn.iocoder.yudao.module.shop.entity.ShopMallPartners;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.commons.lang3.ObjectUtils;
import org.springframework.context.annotation.Lazy;
import org.springframework.security.access.prepost.PreAuthorize;
@@ -36,7 +37,7 @@ import cn.iocoder.yudao.module.core.page.TableDataInfo;
* @date 2023-07-08
*/
@RestController
-@RequestMapping("/system/inspectionGoods")
+@RequestMapping("/admin-api/system/inspectionGoods")
public class ShopInspectionGoodsController extends BaseController
{
@Autowired
@@ -56,12 +57,12 @@ public class ShopInspectionGoodsController extends BaseController
/**
* 查询检测商品列表
*/
- @PreAuthorize("@ss.hasPermi('system:inspectionGoods:list')")
+// @PreAuthorize("@ss.hasPermi('system:inspectionGoods:list')")
@GetMapping("/listSystem")
- public TableDataInfo listSystem(ShopInspectionGoods shopInspectionGoods)
+ public TableDataInfo listSystem(ShopInspectionGoods shopInspectionGoods,@RequestParam("pageNum") Integer pageNum,@RequestParam("pageSize") Integer pageSize)
{
- startPage();
- List list = shopInspectionGoodsService.listSystem(shopInspectionGoods);
+ Page page = new Page<>(pageNum, pageSize);
+ List list = shopInspectionGoodsService.listSystem(page,shopInspectionGoods);
return getDataTable(list);
}
@@ -219,7 +220,7 @@ public class ShopInspectionGoodsController extends BaseController
/**
* 新增检测商品
*/
- @PreAuthorize("@ss.hasPermi('system:inspectionGoods:add')")
+// @PreAuthorize("@ss.hasPermi('system:inspectionGoods:add')")
@PostMapping("/add")
public CommonResult add(@RequestBody ShopInspectionGoods shopInspectionGoods)
{
@@ -230,7 +231,7 @@ public class ShopInspectionGoodsController extends BaseController
/**
* 修改检测商品
*/
- @PreAuthorize("@ss.hasPermi('system:inspectionGoods:edit')")
+// @PreAuthorize("@ss.hasPermi('system:inspectionGoods:edit')")
@PostMapping("/edit")
public CommonResult edit(@RequestBody ShopInspectionGoods shopInspectionGoods)
{
@@ -240,7 +241,7 @@ public class ShopInspectionGoodsController extends BaseController
/**
* 审核检测商品
*/
- @PreAuthorize("@ss.hasPermi('system:inspectionGoods:edit')")
+// @PreAuthorize("@ss.hasPermi('system:inspectionGoods:edit')")
@PostMapping("/examine")
public CommonResult examine(@RequestBody ShopInspectionGoods shopInspectionGoods)
{
@@ -250,7 +251,7 @@ public class ShopInspectionGoodsController extends BaseController
/**
* 删除检测商品
*/
- @PreAuthorize("@ss.hasPermi('system:inspectionGoods:remove')")
+// @PreAuthorize("@ss.hasPermi('system:inspectionGoods:remove')")
@PostMapping("/del")
public CommonResult remove(@RequestParam("idList") Long[] ids)
{
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/ShopInspectionOrderController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/ShopInspectionOrderController.java
index 16eed52a..1a022887 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/ShopInspectionOrderController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/ShopInspectionOrderController.java
@@ -14,7 +14,7 @@ import cn.iocoder.yudao.module.core.controller.BaseController;
* @date 2023-07-08
*/
@RestController
-@RequestMapping("/system/inspectionOrder")
+@RequestMapping("/admin-api/system/inspectionOrder")
public class ShopInspectionOrderController extends BaseController
{
@Autowired
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/SiteInfoController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/SiteInfoController.java
index 35c3dafd..e016441c 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/SiteInfoController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/SiteInfoController.java
@@ -5,16 +5,10 @@ import javax.servlet.http.HttpServletResponse;
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
import cn.iocoder.yudao.util.ExcelUtil;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.web.bind.annotation.GetMapping;
-import org.springframework.web.bind.annotation.PostMapping;
-import org.springframework.web.bind.annotation.PutMapping;
-import org.springframework.web.bind.annotation.DeleteMapping;
-import org.springframework.web.bind.annotation.PathVariable;
-import org.springframework.web.bind.annotation.RequestBody;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.RestController;
+import org.springframework.web.bind.annotation.*;
import cn.iocoder.yudao.module.core.controller.BaseController;
import cn.iocoder.yudao.module.inspection.entity.SiteInfo;
import cn.iocoder.yudao.module.inspection.service.ISiteInfoService;
@@ -27,7 +21,7 @@ import cn.iocoder.yudao.module.core.page.TableDataInfo;
* @date 2023-09-01
*/
@RestController
-@RequestMapping("/inspection/info")
+@RequestMapping("/admin-api/inspection/info")
public class SiteInfoController extends BaseController
{
@Autowired
@@ -37,10 +31,10 @@ public class SiteInfoController extends BaseController
* 查询inspection列表
*/
@GetMapping("/list")
- public TableDataInfo list(SiteInfo siteInfo)
+ public TableDataInfo list(SiteInfo siteInfo, @RequestParam("pageNum") Integer pageNum, @RequestParam("pageSize") Integer pageSize)
{
- startPage();
- List list = siteInfoService.selectSiteInfoList(siteInfo);
+ Page page = new Page<>(pageNum, pageSize);
+ List list = siteInfoService.selectSiteInfoList(page,siteInfo);
return getDataTable(list);
}
@@ -51,7 +45,8 @@ public class SiteInfoController extends BaseController
@PostMapping("/export")
public void export(HttpServletResponse response, SiteInfo siteInfo)
{
- List list = siteInfoService.selectSiteInfoList(siteInfo);
+ Page page = new Page<>();
+ List list = siteInfoService.selectSiteInfoList(page,siteInfo);
ExcelUtil util = new ExcelUtil(SiteInfo.class);
util.exportExcel(response, list, "inspection数据");
}
@@ -59,7 +54,7 @@ public class SiteInfoController extends BaseController
/**
* 获取inspection详细信息
*/
- @PreAuthorize("@ss.hasPermi('inspection:info:query')")
+// @PreAuthorize("@ss.hasPermi('inspection:info:query')")
@GetMapping(value = "/{id}")
public CommonResult getInfo(@PathVariable("id") Long id)
{
@@ -69,7 +64,7 @@ public class SiteInfoController extends BaseController
/**
* 新增inspection
*/
- @PreAuthorize("@ss.hasPermi('inspection:info:add')")
+// @PreAuthorize("@ss.hasPermi('inspection:info:add')")
@PostMapping
public CommonResult add(@RequestBody SiteInfo siteInfo)
{
@@ -79,7 +74,7 @@ public class SiteInfoController extends BaseController
/**
* 修改inspection
*/
- @PreAuthorize("@ss.hasPermi('inspection:info:edit')")
+// @PreAuthorize("@ss.hasPermi('inspection:info:edit')")
@PutMapping
public CommonResult edit(@RequestBody SiteInfo siteInfo)
{
@@ -89,7 +84,7 @@ public class SiteInfoController extends BaseController
/**
* 删除inspection
*/
- @PreAuthorize("@ss.hasPermi('inspection:info:remove')")
+// @PreAuthorize("@ss.hasPermi('inspection:info:remove')")
@DeleteMapping("/{ids}")
public CommonResult remove(@PathVariable Long[] ids)
{
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/WarnMessageController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/WarnMessageController.java
index f0606214..00c2020c 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/WarnMessageController.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/controller/WarnMessageController.java
@@ -24,7 +24,7 @@ import cn.iocoder.yudao.module.inspection.service.IWarnMessageService;
* @date 2023-10-13
*/
@RestController
-@RequestMapping("/warnMsg/warnMsg")
+@RequestMapping("/admin-api/warnMsg/warnMsg")
public class WarnMessageController extends BaseController
{
@Autowired
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/mapper/InspectionCategoryTemplateMapper.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/mapper/InspectionCategoryTemplateMapper.java
index 2b554c21..9dbac8a8 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/mapper/InspectionCategoryTemplateMapper.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/mapper/InspectionCategoryTemplateMapper.java
@@ -2,6 +2,7 @@ package cn.iocoder.yudao.module.inspection.mapper;
import java.util.List;
+import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import cn.iocoder.yudao.module.inspection.entity.InspectionCategoryTemplate;
import org.apache.ibatis.annotations.Mapper;
@@ -13,7 +14,7 @@ import org.apache.ibatis.annotations.Mapper;
* @date 2023-09-07
*/
@Mapper
-public interface InspectionCategoryTemplateMapper extends BaseMapper
+public interface InspectionCategoryTemplateMapper extends BaseMapperX
{
/**
* 查询分类模版
@@ -62,4 +63,6 @@ public interface InspectionCategoryTemplateMapper extends BaseMapper
* @param inspectionNews 【请填写功能名称】
* @return 【请填写功能名称】集合
*/
- public List selectInspectionNewsList(InspectionNews inspectionNews);
+ public List selectInspectionNewsList(Page page, @Param("vo") InspectionNews inspectionNews);
/**
* 新增【请填写功能名称】
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/mapper/ShopInspectionCategoryMapper.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/mapper/ShopInspectionCategoryMapper.java
index cf70583d..c4b43fbd 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/mapper/ShopInspectionCategoryMapper.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/mapper/ShopInspectionCategoryMapper.java
@@ -1,5 +1,6 @@
package cn.iocoder.yudao.module.inspection.mapper;
+import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import cn.iocoder.yudao.module.inspection.entity.ShopInspectionCategory;
import org.apache.ibatis.annotations.Mapper;
@@ -11,7 +12,7 @@ import org.apache.ibatis.annotations.Mapper;
* @since 2023-08-01 19:59:23
*/
@Mapper
-public interface ShopInspectionCategoryMapper extends BaseMapper {
+public interface ShopInspectionCategoryMapper extends BaseMapperX {
}
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/mapper/ShopInspectionGoodsMapper.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/mapper/ShopInspectionGoodsMapper.java
index 3bfea70b..d6af7b5a 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/mapper/ShopInspectionGoodsMapper.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/mapper/ShopInspectionGoodsMapper.java
@@ -4,7 +4,9 @@ import java.util.List;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import cn.iocoder.yudao.module.inspection.entity.ShopInspectionGoods;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
/**
* 检测商品Mapper接口
@@ -31,8 +33,9 @@ public interface ShopInspectionGoodsMapper extends BaseMapper selectShopInspectionGoodsListWx(ShopInspectionGoods shopInspectionGoods);
- List listSystem(ShopInspectionGoods shopInspectionGoods);
+ List listSystem(Page page,@Param("vo") ShopInspectionGoods shopInspectionGoods);
List listPartnerGoods(ShopInspectionGoods shopInspectionGoods);
+ int deleteByList(List list);
}
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/mapper/SiteInfoMapper.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/mapper/SiteInfoMapper.java
index 3349a0a2..27387db5 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/mapper/SiteInfoMapper.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/mapper/SiteInfoMapper.java
@@ -2,7 +2,9 @@ package cn.iocoder.yudao.module.inspection.mapper;
import java.util.List;
import cn.iocoder.yudao.module.inspection.entity.SiteInfo;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
/**
* inspectionMapper接口
@@ -27,7 +29,7 @@ public interface SiteInfoMapper
* @param siteInfo inspection
* @return inspection集合
*/
- public List selectSiteInfoList(SiteInfo siteInfo);
+ public List selectSiteInfoList(Page page,@Param("vo") SiteInfo siteInfo);
/**
* 新增inspection
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/IInspectionCategoryTemplateService.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/IInspectionCategoryTemplateService.java
index 73a081bf..c0936c06 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/IInspectionCategoryTemplateService.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/IInspectionCategoryTemplateService.java
@@ -60,4 +60,6 @@ public interface IInspectionCategoryTemplateService extends IService
* @param inspectionNews 【请填写功能名称】
* @return 【请填写功能名称】集合
*/
- public List selectInspectionNewsList(InspectionNews inspectionNews);
+ public List selectInspectionNewsList(Page page,InspectionNews inspectionNews);
List appHomeNewsList();
List listGfClass(String type);
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/IShopInspectionGoodsService.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/IShopInspectionGoodsService.java
index fe29f879..4561d6c2 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/IShopInspectionGoodsService.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/IShopInspectionGoodsService.java
@@ -3,6 +3,7 @@ package cn.iocoder.yudao.module.inspection.service;
import java.util.List;
import com.alibaba.fastjson.JSONObject;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import cn.iocoder.yudao.module.inspection.entity.ShopInspectionCategory;
import cn.iocoder.yudao.module.inspection.entity.ShopInspectionGoods;
@@ -78,7 +79,7 @@ public interface IShopInspectionGoodsService extends IService listSystem(ShopInspectionGoods shopInspectionGoods);
+ public List listSystem(Page page,ShopInspectionGoods shopInspectionGoods);
public List listPartnerGoods(ShopInspectionGoods shopInspectionGoods) throws Exception;
List categoryList() throws Exception;
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/ISiteInfoService.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/ISiteInfoService.java
index d337a2d2..8f41636f 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/ISiteInfoService.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/ISiteInfoService.java
@@ -2,6 +2,7 @@ package cn.iocoder.yudao.module.inspection.service;
import java.util.List;
import cn.iocoder.yudao.module.inspection.entity.SiteInfo;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
/**
* inspectionService接口
@@ -25,7 +26,7 @@ public interface ISiteInfoService
* @param siteInfo inspection
* @return inspection集合
*/
- public List selectSiteInfoList(SiteInfo siteInfo);
+ public List selectSiteInfoList(Page page,SiteInfo siteInfo);
/**
* 新增inspection
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/ShopInspectionCategoryService.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/ShopInspectionCategoryService.java
index 870fb7ab..a84f54bd 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/ShopInspectionCategoryService.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/ShopInspectionCategoryService.java
@@ -1,5 +1,7 @@
package cn.iocoder.yudao.module.inspection.service;
+import cn.iocoder.yudao.framework.common.pojo.PageParam;
+import cn.iocoder.yudao.framework.common.pojo.PageResult;
import com.baomidou.mybatisplus.extension.service.IService;
import cn.iocoder.yudao.module.inspection.entity.ShopInspectionCategory;
@@ -15,7 +17,7 @@ public interface ShopInspectionCategoryService extends IService idList) throws Exception;
- List listVo(ShopInspectionCategory shopInspectionCategory);
+ PageResult listVo(ShopInspectionCategory shopInspectionCategory, PageParam pageParam);
ShopInspectionCategory getByIdVo(Long id);
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/impl/InspectionCategoryTemplateServiceImpl.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/impl/InspectionCategoryTemplateServiceImpl.java
index aa50b538..dfb6a5f9 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/impl/InspectionCategoryTemplateServiceImpl.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/impl/InspectionCategoryTemplateServiceImpl.java
@@ -91,4 +91,9 @@ public class InspectionCategoryTemplateServiceImpl extends ServiceImpl selectInspectionNewsList(InspectionNews inspectionNews)
+ public List selectInspectionNewsList(Page page, InspectionNews inspectionNews)
{
- if (inspectionNews.getPublishUnit().equals("检测站公告")){
+ if (null!=inspectionNews.getPublishUnit() && inspectionNews.getPublishUnit().equals("检测站公告")){
inspectionNews.setCategory("jczgg");
inspectionNews.setPublishUnit(null);
}
- List list = baseMapper.selectInspectionNewsList(inspectionNews);
+ List list = baseMapper.selectInspectionNewsList(page,inspectionNews);
list.forEach(it->{
it.setNewsContent(HtmlFilter.dealFunction(it.getNewsContent()));
});
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/impl/ShopInspectionCategoryServiceImpl.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/impl/ShopInspectionCategoryServiceImpl.java
index a25a27a2..7db30031 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/impl/ShopInspectionCategoryServiceImpl.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/impl/ShopInspectionCategoryServiceImpl.java
@@ -1,6 +1,9 @@
package cn.iocoder.yudao.module.inspection.service.impl;
+import cn.iocoder.yudao.framework.common.pojo.PageParam;
+import cn.iocoder.yudao.framework.common.pojo.PageResult;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import cn.iocoder.yudao.module.core.page.TableDataInfo;
@@ -48,9 +51,7 @@ public class ShopInspectionCategoryServiceImpl extends ServiceImpl wrapper =new LambdaUpdateWrapper<>();
- wrapper.eq(InspectionCategoryTemplate::getCategoryId,category.getId());
- templateService.remove(wrapper);
+ templateService.deleteByCategoryId(category.getId());
List templates = category.getTemplates();
for (InspectionCategoryTemplate template : templates) {
template.setCategoryId(category.getId());
@@ -78,11 +79,14 @@ public class ShopInspectionCategoryServiceImpl extends ServiceImpl listVo(ShopInspectionCategory shopInspectionCategory) {
- LambdaQueryWrapper queryWrapper =new LambdaQueryWrapper<>();
- queryWrapper.like(StringUtils.isNotEmpty(shopInspectionCategory.getCategoryName()),ShopInspectionCategory::getCategoryName,shopInspectionCategory.getCategoryName()).orderByAsc(ShopInspectionCategory::getOrderNum);
- List list = this.list(queryWrapper);
- return list;
+ public PageResult listVo(ShopInspectionCategory shopInspectionCategory, PageParam pageParam) {
+
+ QueryWrapper queryWrapper = new QueryWrapper<>();
+ if(null!=shopInspectionCategory.getCategoryName()){
+ queryWrapper.like("category_name",shopInspectionCategory.getCategoryName());
+ }
+ queryWrapper.orderByAsc("order_num");
+ return baseMapper.selectPage(pageParam,queryWrapper);
}
@Override
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/impl/ShopInspectionGoodsServiceImpl.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/impl/ShopInspectionGoodsServiceImpl.java
index 127874e5..883ea61d 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/impl/ShopInspectionGoodsServiceImpl.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/impl/ShopInspectionGoodsServiceImpl.java
@@ -14,6 +14,7 @@ import cn.iocoder.yudao.module.system.dal.dataobject.user.AdminUserDO;
import cn.iocoder.yudao.module.system.service.user.AdminUserService;
import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import cn.iocoder.yudao.util.StringUtils;
import cn.iocoder.yudao.module.inspection.entity.InspectionCategoryTemplate;
@@ -213,7 +214,7 @@ public class ShopInspectionGoodsServiceImpl extends ServiceImpl listSystem(ShopInspectionGoods shopInspectionGoods) {
- return baseMapper.listSystem(shopInspectionGoods);
+ public List listSystem(Page page,ShopInspectionGoods shopInspectionGoods) {
+ return baseMapper.listSystem(page,shopInspectionGoods);
}
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/impl/SiteInfoServiceImpl.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/impl/SiteInfoServiceImpl.java
index 56f035d7..f431f082 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/impl/SiteInfoServiceImpl.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/inspection/service/impl/SiteInfoServiceImpl.java
@@ -3,6 +3,7 @@ package cn.iocoder.yudao.module.inspection.service.impl;
import java.util.List;
import cn.iocoder.yudao.util.DateUtils;
import cn.iocoder.yudao.util.StringUtils;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import cn.iocoder.yudao.module.inspection.mapper.SiteInfoMapper;
@@ -40,9 +41,9 @@ public class SiteInfoServiceImpl implements ISiteInfoService
* @return inspection
*/
@Override
- public List selectSiteInfoList(SiteInfo siteInfo)
+ public List selectSiteInfoList(Page page,SiteInfo siteInfo)
{
- List siteInfos = siteInfoMapper.selectSiteInfoList(siteInfo);
+ List siteInfos = siteInfoMapper.selectSiteInfoList(page,siteInfo);
for (SiteInfo info : siteInfos) {
if (null!=info.getSiteLongitude()&&null!=info.getSiteLatitude()){
info.setLongitude(info.getSiteLongitude().toString());
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/payment/controller/FzRecordController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/payment/controller/FzRecordController.java
new file mode 100644
index 00000000..beb4abea
--- /dev/null
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/payment/controller/FzRecordController.java
@@ -0,0 +1,84 @@
+package cn.iocoder.yudao.module.payment.controller;
+
+import cn.iocoder.yudao.framework.common.pojo.CommonResult;
+import cn.iocoder.yudao.module.core.controller.BaseController;
+import cn.iocoder.yudao.module.core.page.TableDataInfo;
+import cn.iocoder.yudao.module.payment.entity.FzRecord;
+import cn.iocoder.yudao.module.payment.service.IFzRecordService;
+import cn.iocoder.yudao.util.ExcelUtil;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.web.bind.annotation.*;
+import javax.servlet.http.HttpServletResponse;
+import java.util.List;
+
+/**
+ * 分账记录Controller
+ *
+ * @author zcy
+ * @date 2023-10-18
+ */
+@RestController
+@RequestMapping("/admin-api/fzRecord/fzRecord")
+public class FzRecordController extends BaseController
+{
+ @Autowired
+ private IFzRecordService fzRecordService;
+
+ /**
+ * 查询分账记录列表
+ */
+// @PreAuthorize("@ss.hasPermi('fzRecord:fzRecord:list')")
+ @GetMapping("/list")
+ public TableDataInfo list(FzRecord fzRecord,@RequestParam("pageNum") Integer pageNum,@RequestParam("pageSize") Integer pageSize)
+ {
+ Page page = new Page<>(pageNum, pageSize);
+ List list = fzRecordService.selectFzRecordList(page,fzRecord);
+ return getDataTable(list);
+ }
+
+ /**
+ * 导出分账记录列表
+ */
+// @PreAuthorize("@ss.hasPermi('fzRecord:fzRecord:export')")
+ @PostMapping("/export")
+ public void export(HttpServletResponse response, FzRecord fzRecord)
+ {
+ Page page = new Page<>();
+ List list = fzRecordService.selectFzRecordList(page,fzRecord);
+ ExcelUtil util = new ExcelUtil(FzRecord.class);
+ util.exportExcel(response, list, "分账记录数据");
+ }
+
+ /**
+ * 获取分账记录详细信息
+ */
+// @PreAuthorize("@ss.hasPermi('fzRecord:fzRecord:query')")
+ @GetMapping(value = "/{id}")
+ public CommonResult getInfo(@PathVariable("id") Long id)
+ {
+ return success(fzRecordService.selectFzRecordById(id));
+ }
+
+ /**
+ * 新增分账记录
+ */
+// @PreAuthorize("@ss.hasPermi('fzRecord:fzRecord:add')")
+ @PostMapping
+ public CommonResult add(@RequestBody FzRecord fzRecord)
+ {
+ return toAjax(fzRecordService.insertFzRecord(fzRecord));
+ }
+
+ /**
+ * 修改分账记录
+ */
+// @PreAuthorize("@ss.hasPermi('fzRecord:fzRecord:edit')")
+ @PutMapping
+ public CommonResult edit(@RequestBody FzRecord fzRecord)
+ {
+ return toAjax(fzRecordService.updateFzRecord(fzRecord));
+ }
+
+}
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/payment/entity/FzRecord.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/payment/entity/FzRecord.java
new file mode 100644
index 00000000..ba798726
--- /dev/null
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/payment/entity/FzRecord.java
@@ -0,0 +1,54 @@
+package cn.iocoder.yudao.module.payment.entity;
+
+import cn.iocoder.yudao.annotation.Excel;
+import cn.iocoder.yudao.framework.tenant.core.db.TenantBaseDO;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import lombok.Data;
+
+/**
+ * 分账记录对象 fz_record
+ *
+ * @author zcy
+ * @date 2023-10-18
+ */
+@Data
+public class FzRecord extends TenantBaseDO
+{
+ private static final long serialVersionUID = 1L;
+
+ /** 主键 */
+ @TableId(type = IdType.AUTO)
+ private Long id;
+
+ /** 商户主键 */
+ private Long partnerId;
+
+ /** 商户名称 */
+ @Excel(name = "商户名称")
+ private String partnerName;
+
+ /** 订单主键 */
+ private Long orderId;
+
+ /** 单号 */
+ @Excel(name = "单号")
+ private String orderNo;
+
+ /** 入账金额单位分 */
+ @Excel(name = "入账金额单位分")
+ private Long amount;
+
+ /** 总金额 */
+ @Excel(name = "总金额")
+ private Long totalAmount;
+
+ /** 是否成功1成功0失败 */
+ @Excel(name = "是否成功1成功0失败")
+ private String isSuccess;
+
+ /** 失败原因 */
+ @Excel(name = "失败原因")
+ private String reason;
+
+}
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/payment/mapper/FzRecordMapper.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/payment/mapper/FzRecordMapper.java
new file mode 100644
index 00000000..0fe04bf7
--- /dev/null
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/payment/mapper/FzRecordMapper.java
@@ -0,0 +1,36 @@
+package cn.iocoder.yudao.module.payment.mapper;
+
+import cn.iocoder.yudao.module.payment.entity.FzRecord;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
+
+/**
+ * 分账记录Mapper接口
+ *
+ * @author zcy
+ * @date 2023-10-18
+ */
+@Mapper
+public interface FzRecordMapper extends BaseMapper
+{
+ /**
+ * 查询分账记录
+ *
+ * @param id 分账记录主键
+ * @return 分账记录
+ */
+ public FzRecord selectFzRecordById(Long id);
+
+ /**
+ * 查询分账记录列表
+ *
+ * @param fzRecord 分账记录
+ * @return 分账记录集合
+ */
+ public List selectFzRecordList(Page page,@Param("vo") FzRecord fzRecord);
+
+}
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/payment/service/IFzRecordService.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/payment/service/IFzRecordService.java
new file mode 100644
index 00000000..522523cb
--- /dev/null
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/payment/service/IFzRecordService.java
@@ -0,0 +1,48 @@
+package cn.iocoder.yudao.module.payment.service;
+
+import cn.iocoder.yudao.module.payment.entity.FzRecord;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.baomidou.mybatisplus.extension.service.IService;
+import java.util.List;
+
+/**
+ * 分账记录Service接口
+ *
+ * @author zcy
+ * @date 2023-10-18
+ */
+public interface IFzRecordService extends IService
+{
+ /**
+ * 查询分账记录
+ *
+ * @param id 分账记录主键
+ * @return 分账记录
+ */
+ public FzRecord selectFzRecordById(Long id);
+
+ /**
+ * 查询分账记录列表
+ *
+ * @param fzRecord 分账记录
+ * @return 分账记录集合
+ */
+ public List selectFzRecordList(Page page,FzRecord fzRecord);
+
+ /**
+ * 新增分账记录
+ *
+ * @param fzRecord 分账记录
+ * @return 结果
+ */
+ public int insertFzRecord(FzRecord fzRecord);
+
+ /**
+ * 修改分账记录
+ *
+ * @param fzRecord 分账记录
+ * @return 结果
+ */
+ public int updateFzRecord(FzRecord fzRecord);
+
+}
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/payment/service/impl/FzRecordServiceImpl.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/payment/service/impl/FzRecordServiceImpl.java
new file mode 100644
index 00000000..0d6db046
--- /dev/null
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/payment/service/impl/FzRecordServiceImpl.java
@@ -0,0 +1,73 @@
+package cn.iocoder.yudao.module.payment.service.impl;
+
+import cn.iocoder.yudao.module.payment.entity.FzRecord;
+import cn.iocoder.yudao.module.payment.mapper.FzRecordMapper;
+import cn.iocoder.yudao.module.payment.service.IFzRecordService;
+import cn.iocoder.yudao.util.DateUtils;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+/**
+ * 分账记录Service业务层处理
+ *
+ * @author zcy
+ * @date 2023-10-18
+ */
+@Service
+public class FzRecordServiceImpl extends ServiceImpl implements IFzRecordService
+{
+
+
+ /**
+ * 查询分账记录
+ *
+ * @param id 分账记录主键
+ * @return 分账记录
+ */
+ @Override
+ public FzRecord selectFzRecordById(Long id)
+ {
+ return baseMapper.selectFzRecordById(id);
+ }
+
+ /**
+ * 查询分账记录列表
+ *
+ * @param fzRecord 分账记录
+ * @return 分账记录
+ */
+ @Override
+ public List selectFzRecordList(Page page,FzRecord fzRecord)
+ {
+ return baseMapper.selectFzRecordList(page,fzRecord);
+ }
+
+ /**
+ * 新增分账记录
+ *
+ * @param fzRecord 分账记录
+ * @return 结果
+ */
+ @Override
+ public int insertFzRecord(FzRecord fzRecord)
+ {
+ return baseMapper.insert(fzRecord);
+ }
+
+ /**
+ * 修改分账记录
+ *
+ * @param fzRecord 分账记录
+ * @return 结果
+ */
+ @Override
+ public int updateFzRecord(FzRecord fzRecord)
+ {
+ fzRecord.setUpdateTime(DateUtils.getNowDate());
+ return baseMapper.updateById(fzRecord);
+ }
+
+}
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/controller/PartnerDetailController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/controller/PartnerDetailController.java
new file mode 100644
index 00000000..729bed22
--- /dev/null
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/controller/PartnerDetailController.java
@@ -0,0 +1,102 @@
+package cn.iocoder.yudao.module.shop.controller;
+
+import cn.iocoder.yudao.framework.common.pojo.CommonResult;
+import cn.iocoder.yudao.module.core.controller.BaseController;
+import cn.iocoder.yudao.module.core.page.TableDataInfo;
+import cn.iocoder.yudao.module.shop.entity.PartnerDetail;
+import cn.iocoder.yudao.module.shop.service.IPartnerDetailService;
+import cn.iocoder.yudao.util.ExcelUtil;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.web.bind.annotation.*;
+import javax.servlet.http.HttpServletResponse;
+import java.util.List;
+
+/**
+ * 【请填写功能名称】Controller
+ *
+ * @author ruoyi
+ * @date 2023-08-13
+ */
+@RestController
+@RequestMapping("/admin-api/partner/detail")
+public class PartnerDetailController extends BaseController
+{
+ @Autowired
+ private IPartnerDetailService partnerDetailService;
+
+ /**
+ * 查询【请填写功能名称】列表
+ */
+// @PreAuthorize("@ss.hasPermi('system:detail:list')")
+ @GetMapping("/list")
+ public TableDataInfo list(PartnerDetail partnerDetail,@RequestParam("pageNum") Integer pageNum,@RequestParam("pageSize") Integer pageSize)
+ {
+ Page page = new Page<>(pageNum, pageSize);
+ List list = partnerDetailService.selectPartnerDetailList(page,partnerDetail);
+ return getDataTable(list);
+ }
+
+ /**
+ * 导出【请填写功能名称】列表
+ */
+ @PreAuthorize("@ss.hasPermi('system:detail:export')")
+ @PostMapping("/export")
+ public void export(HttpServletResponse response, PartnerDetail partnerDetail)
+ {
+ Page page = new Page<>();
+ List list = partnerDetailService.selectPartnerDetailList(page,partnerDetail);
+ ExcelUtil util = new ExcelUtil(PartnerDetail.class);
+ util.exportExcel(response, list, "【请填写功能名称】数据");
+ }
+
+ /**
+ * 获取【请填写功能名称】详细信息
+ */
+// @PreAuthorize("@ss.hasPermi('system:detail:query')")
+ @GetMapping(value = "/{id}")
+ public CommonResult getInfo(@PathVariable("id") Long id)
+ {
+ return success(partnerDetailService.selectPartnerDetailById(id));
+ }
+
+ /**
+ * 新增【请填写功能名称】
+ */
+ @PostMapping("/add")
+ public CommonResult add(@RequestBody PartnerDetail partnerDetail)
+ {
+ return toAjax(partnerDetailService.insertPartnerDetail(partnerDetail));
+ }
+
+ /**
+ * 修改【请填写功能名称】
+ */
+// @PreAuthorize("@ss.hasPermi('system:detail:edit')")
+ @PutMapping
+ public CommonResult edit(@RequestBody PartnerDetail partnerDetail)
+ {
+ return toAjax(partnerDetailService.updatePartnerDetail(partnerDetail));
+ }
+
+ /**
+ * 修改【审核接口】
+ */
+// @PreAuthorize("@ss.hasPermi('system:detail:edit')")
+ @PostMapping("/examine")
+ public CommonResult examine(@RequestBody PartnerDetail partnerDetail) throws Exception {
+ partnerDetailService.examine(partnerDetail);
+ return success();
+ }
+
+ /**
+ * 删除【请填写功能名称】
+ */
+// @PreAuthorize("@ss.hasPermi('system:detail:remove')")
+ @DeleteMapping("/{ids}")
+ public CommonResult remove(@PathVariable Long[] ids)
+ {
+ return toAjax(partnerDetailService.deletePartnerDetailByIds(ids));
+ }
+}
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/controller/ShopCouponTemplateController.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/controller/ShopCouponTemplateController.java
new file mode 100644
index 00000000..6af2a29d
--- /dev/null
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/controller/ShopCouponTemplateController.java
@@ -0,0 +1,93 @@
+package cn.iocoder.yudao.module.shop.controller;
+
+import cn.iocoder.yudao.framework.common.pojo.CommonResult;
+import cn.iocoder.yudao.module.core.controller.BaseController;
+import cn.iocoder.yudao.module.core.page.TableDataInfo;
+import cn.iocoder.yudao.module.shop.entity.ShopCouponTemplate;
+import cn.iocoder.yudao.module.shop.service.IShopCouponTemplateService;
+import cn.iocoder.yudao.util.ExcelUtil;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.web.bind.annotation.*;
+import javax.servlet.http.HttpServletResponse;
+import java.util.List;
+
+/**
+ * 优惠券模板Controller
+ *
+ * @author ruoyi
+ * @date 2023-08-29
+ */
+@RestController
+@RequestMapping("/admin-api/shop/couponTemplate")
+public class ShopCouponTemplateController extends BaseController
+{
+ @Autowired
+ private IShopCouponTemplateService shopCouponTemplateService;
+
+ /**
+ * 查询优惠券模板列表
+ */
+// @PreAuthorize("@ss.hasPermi('shop:couponTemplate:list')")
+ @GetMapping("/list")
+ public TableDataInfo list(ShopCouponTemplate shopCouponTemplate,@RequestParam("pageNum") Integer pageNum,@RequestParam("pageSize") Integer pageSize)
+ {
+ Page page = new Page<>(pageNum, pageSize);
+ List list = shopCouponTemplateService.selectShopCouponTemplateList(page,shopCouponTemplate);
+ return getDataTable(list);
+ }
+
+ /**
+ * 导出优惠券模板列表
+ */
+// @PreAuthorize("@ss.hasPermi('shop:couponTemplate:export')")
+ @PostMapping("/export")
+ public void export(HttpServletResponse response, ShopCouponTemplate shopCouponTemplate)
+ {
+ Page page = new Page<>();
+ List list = shopCouponTemplateService.selectShopCouponTemplateList(page,shopCouponTemplate);
+ ExcelUtil util = new ExcelUtil(ShopCouponTemplate.class);
+ util.exportExcel(response, list, "优惠券模板数据");
+ }
+
+ /**
+ * 获取优惠券模板详细信息
+ */
+// @PreAuthorize("@ss.hasPermi('shop:couponTemplate:query')")
+ @GetMapping(value = "/{id}")
+ public CommonResult getInfo(@PathVariable("id") Long id)
+ {
+ return success(shopCouponTemplateService.selectShopCouponTemplateById(id));
+ }
+
+ /**
+ * 新增优惠券模板
+ */
+// @PreAuthorize("@ss.hasPermi('shop:couponTemplate:add')")
+ @PostMapping
+ public CommonResult add(@RequestBody ShopCouponTemplate shopCouponTemplate)
+ {
+ return toAjax(shopCouponTemplateService.insertShopCouponTemplate(shopCouponTemplate));
+ }
+
+ /**
+ * 修改优惠券模板
+ */
+// @PreAuthorize("@ss.hasPermi('shop:couponTemplate:edit')")
+ @PutMapping
+ public CommonResult edit(@RequestBody ShopCouponTemplate shopCouponTemplate)
+ {
+ return toAjax(shopCouponTemplateService.updateShopCouponTemplate(shopCouponTemplate));
+ }
+
+ /**
+ * 删除优惠券模板
+ */
+// @PreAuthorize("@ss.hasPermi('shop:couponTemplate:remove')")
+ @DeleteMapping("/{ids}")
+ public CommonResult remove(@PathVariable Long[] ids)
+ {
+ return toAjax(shopCouponTemplateService.deleteShopCouponTemplateByIds(ids));
+ }
+}
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/mapper/PartnerDetailMapper.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/mapper/PartnerDetailMapper.java
index 5e72c57e..7d3b2108 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/mapper/PartnerDetailMapper.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/mapper/PartnerDetailMapper.java
@@ -1,6 +1,7 @@
package cn.iocoder.yudao.module.shop.mapper;
import cn.iocoder.yudao.module.shop.entity.PartnerDetail;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
@@ -31,7 +32,7 @@ public interface PartnerDetailMapper
* @param partnerDetail 【请填写功能名称】
* @return 【请填写功能名称】集合
*/
- public List selectPartnerDetailList(PartnerDetail partnerDetail);
+ public List selectPartnerDetailList(Page page,@Param("vo") PartnerDetail partnerDetail);
/**
* 新增【请填写功能名称】
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/mapper/ShopCouponTemplateMapper.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/mapper/ShopCouponTemplateMapper.java
index 8cc4da96..65ff1c04 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/mapper/ShopCouponTemplateMapper.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/mapper/ShopCouponTemplateMapper.java
@@ -2,6 +2,7 @@ package cn.iocoder.yudao.module.shop.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import cn.iocoder.yudao.module.shop.entity.ShopCouponTemplate;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
@@ -30,7 +31,7 @@ public interface ShopCouponTemplateMapper extends BaseMapper
* @param shopCouponTemplate 优惠券模板
* @return 优惠券模板集合
*/
- public List selectShopCouponTemplateList(ShopCouponTemplate shopCouponTemplate);
+ public List selectShopCouponTemplateList(Page page,@Param("vo") ShopCouponTemplate shopCouponTemplate);
/**
* 新增优惠券模板
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/mapper/ShopMallPartnersMapper.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/mapper/ShopMallPartnersMapper.java
index f469753c..029377fb 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/mapper/ShopMallPartnersMapper.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/mapper/ShopMallPartnersMapper.java
@@ -2,6 +2,7 @@ package cn.iocoder.yudao.module.shop.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import cn.iocoder.yudao.module.shop.entity.ShopMallPartners;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
@@ -30,7 +31,7 @@ public interface ShopMallPartnersMapper extends BaseMapper
* @param shopMallPartners 合作商管理
* @return 合作商管理集合
*/
- public List selectShopMallPartnersList(ShopMallPartners shopMallPartners);
+ public List selectShopMallPartnersList(Page page, @Param("shop") ShopMallPartners shopMallPartners);
/**
* 新增合作商管理
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/IPartnerDetailService.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/IPartnerDetailService.java
index beb36241..c687e378 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/IPartnerDetailService.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/IPartnerDetailService.java
@@ -1,6 +1,7 @@
package cn.iocoder.yudao.module.shop.service;
import cn.iocoder.yudao.module.shop.entity.PartnerDetail;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import java.util.List;
@@ -28,7 +29,7 @@ public interface IPartnerDetailService
* @param partnerDetail 【请填写功能名称】
* @return 【请填写功能名称】集合
*/
- public List selectPartnerDetailList(PartnerDetail partnerDetail);
+ public List selectPartnerDetailList(Page page,PartnerDetail partnerDetail);
/**
* 新增【请填写功能名称】
@@ -60,4 +61,6 @@ public interface IPartnerDetailService
* @return 结果
*/
public int deletePartnerDetailById(Long id);
+
+ public int examine(PartnerDetail partnerDetail) throws Exception;
}
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/IShopCouponTemplateService.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/IShopCouponTemplateService.java
index 72ae2e59..c5dd7793 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/IShopCouponTemplateService.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/IShopCouponTemplateService.java
@@ -1,5 +1,6 @@
package cn.iocoder.yudao.module.shop.service;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import cn.iocoder.yudao.module.shop.entity.ShopCouponTemplate;
@@ -27,7 +28,7 @@ public interface IShopCouponTemplateService extends IService selectShopCouponTemplateList(ShopCouponTemplate shopCouponTemplate);
+ public List selectShopCouponTemplateList(Page page,ShopCouponTemplate shopCouponTemplate);
/**
* 新增优惠券模板
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/IShopMallPartnersService.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/IShopMallPartnersService.java
index e00ba32a..069d1c53 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/IShopMallPartnersService.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/IShopMallPartnersService.java
@@ -1,5 +1,6 @@
package cn.iocoder.yudao.module.shop.service;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import cn.iocoder.yudao.module.shop.entity.ShopMallPartners;
@@ -27,7 +28,7 @@ public interface IShopMallPartnersService extends IService
* @param shopMallPartners 合作商管理
* @return 合作商管理集合
*/
- public List selectShopMallPartnersList(ShopMallPartners shopMallPartners);
+ public List selectShopMallPartnersList(Page page, ShopMallPartners shopMallPartners);
/**
* 新增合作商管理
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/impl/PartnerDetailServiceImpl.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/impl/PartnerDetailServiceImpl.java
index db404c69..0244d0f5 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/impl/PartnerDetailServiceImpl.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/impl/PartnerDetailServiceImpl.java
@@ -1,7 +1,13 @@
package cn.iocoder.yudao.module.shop.service.impl;
+import cn.iocoder.yudao.module.partner.entity.PartnerBalance;
+import cn.iocoder.yudao.module.partner.entity.PartnerBankInfo;
+import cn.iocoder.yudao.module.partner.entity.PartnerWorker;
import cn.iocoder.yudao.module.partner.service.IPartnerBalanceService;
import cn.iocoder.yudao.module.partner.service.IPartnerWorkerService;
+import cn.iocoder.yudao.module.shop.entity.ShopMallPartners;
+import cn.iocoder.yudao.module.system.dal.dataobject.user.AdminUserDO;
+import cn.iocoder.yudao.module.system.service.permission.PermissionService;
import cn.iocoder.yudao.module.system.service.user.AdminUserService;
import cn.iocoder.yudao.util.InspWechatPayConfig;
import cn.iocoder.yudao.util.DateUtils;
@@ -9,6 +15,8 @@ import cn.iocoder.yudao.module.shop.entity.PartnerDetail;
import cn.iocoder.yudao.module.shop.mapper.PartnerDetailMapper;
import cn.iocoder.yudao.module.shop.service.IPartnerDetailService;
import cn.iocoder.yudao.module.shop.service.IShopMallPartnersService;
+import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.wechat.pay.java.core.Config;
import com.wechat.pay.java.core.RSAAutoCertificateConfig;
import com.wechat.pay.java.service.profitsharing.ProfitsharingService;
@@ -20,8 +28,14 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
+import java.util.HashSet;
import java.util.List;
+import java.util.Set;
+
import com.ruoyi.partner.service.IPartnerBankInfoService;
+import org.springframework.transaction.annotation.Transactional;
+
+import static cn.iocoder.yudao.util.AddressSplitter.splitAddress;
/**
@@ -47,6 +61,8 @@ public class PartnerDetailServiceImpl implements IPartnerDetailService
private IPartnerBankInfoService partnerBankInfoService;
@Resource
private InspWechatPayConfig inspWechatPayConfig;
+ @Autowired
+ private PermissionService permissionService;
/**
* 查询【请填写功能名称】
@@ -73,9 +89,9 @@ public class PartnerDetailServiceImpl implements IPartnerDetailService
* @return 【请填写功能名称】
*/
@Override
- public List selectPartnerDetailList(PartnerDetail partnerDetail)
+ public List selectPartnerDetailList(Page page,PartnerDetail partnerDetail)
{
- return partnerDetailMapper.selectPartnerDetailList(partnerDetail);
+ return partnerDetailMapper.selectPartnerDetailList(page,partnerDetail);
}
/**
@@ -149,4 +165,66 @@ public class PartnerDetailServiceImpl implements IPartnerDetailService
}
+
+ //审核接口
+ @Override
+ @Transactional(rollbackFor = Exception.class)
+ public int examine(PartnerDetail partnerDetail) throws Exception {
+ if (partnerDetail.getStatus().equals("2")){
+ //开设店铺
+ ShopMallPartners shopMallPartners =new ShopMallPartners();
+ shopMallPartners.setUserId(partnerDetail.getUserId());
+ shopMallPartners.setType(partnerDetail.getType());
+ shopMallPartners.setAverageScore(4.5);
+ List strings = splitAddress(partnerDetail.getPosition());
+ shopMallPartners.setProvince(strings.get(0));
+ shopMallPartners.setCity(strings.get(1));
+ shopMallPartners.setArea(strings.get(2));
+ shopMallPartners.setIsWorking("0");
+ shopMallPartners.setIsBanned("0");
+ shopMallPartners.setContactNumber(partnerDetail.getPhone());
+ shopMallPartners.setOpenComment("0");
+ shopMallPartners.setPartnerName(partnerDetail.getPartnerName());
+ partnersService.save(shopMallPartners);
+ partnerDetail.setPartnerId(shopMallPartners.getPartnerId());
+ //审核通过
+ partnerDetailMapper.updatePartnerDetail(partnerDetail);
+ AdminUserDO user = userService.getUser(partnerDetail.getUserId());
+ Set role = new HashSet<>();
+ role.add(113L);
+ permissionService.assignUserRole(user.getId(),role);
+
+ //创建账户
+ PartnerBalance partnerBalance =new PartnerBalance();
+ partnerBalance.setPartnerId(shopMallPartners.getPartnerId());
+ partnerBalance.setTotalRevenue(0L);
+ partnerBalance.setAmount(0L);
+ partnerBalance.setFrozenAmount(0L);
+ partnerBalance.setWithdrawAmount(0L);
+ partnerBalanceService.save(partnerBalance);
+ //将店主加入员工
+ PartnerWorker partnerWorker =new PartnerWorker();
+ partnerWorker.setUserId(user.getId());
+ partnerWorker.setPartnerId(shopMallPartners.getPartnerId());
+ partnerWorker.setAvatar(user.getAvatar());
+ partnerWorker.setWorkName(user.getNickname());
+ partnerWorker.setWorkPhone(user.getMobile());
+ workerService.save(partnerWorker);
+ //添加平台为收帐放
+ LambdaQueryWrapper queryWrapper =new LambdaQueryWrapper<>();
+ queryWrapper.eq(PartnerBankInfo::getPartnerId,shopMallPartners.getPartnerId());
+ PartnerBankInfo bankInfo = partnerBankInfoService.getOne(queryWrapper);
+ try {
+ receiversAdd(inspWechatPayConfig.getAppId(), bankInfo.getMchId(),bankInfo.getApiclientKey(),
+ bankInfo.getSerialNo(),bankInfo.getApiV3Key());
+ }catch (Exception e){
+ throw new Exception("商户信息不正确,请联系管理员");
+ }
+
+ }else if (partnerDetail.getStatus().equals("3")){
+ //拒绝通过
+ partnerDetailMapper.updatePartnerDetail(partnerDetail);
+ }
+ return 0;
+ }
}
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/impl/ShopCouponTemplateServiceImpl.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/impl/ShopCouponTemplateServiceImpl.java
index 7bc2e8d7..8fd74661 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/impl/ShopCouponTemplateServiceImpl.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/impl/ShopCouponTemplateServiceImpl.java
@@ -1,5 +1,6 @@
package cn.iocoder.yudao.module.shop.service.impl;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import cn.iocoder.yudao.util.DateUtils;
import cn.iocoder.yudao.module.shop.entity.ShopCouponTemplate;
@@ -39,9 +40,9 @@ public class ShopCouponTemplateServiceImpl extends ServiceImpl selectShopCouponTemplateList(ShopCouponTemplate shopCouponTemplate)
+ public List selectShopCouponTemplateList(Page page,ShopCouponTemplate shopCouponTemplate)
{
- return baseMapper.selectShopCouponTemplateList(shopCouponTemplate);
+ return baseMapper.selectShopCouponTemplateList(page,shopCouponTemplate);
}
/**
diff --git a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/impl/ShopMallPartnersServiceImpl.java b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/impl/ShopMallPartnersServiceImpl.java
index e5538422..d43bf18a 100644
--- a/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/impl/ShopMallPartnersServiceImpl.java
+++ b/dl-module-inspection/src/main/java/cn/iocoder/yudao/module/shop/service/impl/ShopMallPartnersServiceImpl.java
@@ -7,6 +7,7 @@ import cn.iocoder.yudao.module.system.dal.dataobject.permission.UserRoleDO;
import cn.iocoder.yudao.module.system.dal.dataobject.user.AdminUserDO;
import cn.iocoder.yudao.module.system.dal.mysql.permission.UserRoleMapper;
import cn.iocoder.yudao.module.system.service.user.AdminUserService;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import cn.iocoder.yudao.module.partner.entity.PartnerWorker;
import cn.iocoder.yudao.module.shop.entity.ShopMallPartners;
@@ -54,9 +55,10 @@ public class ShopMallPartnersServiceImpl extends ServiceImpl selectShopMallPartnersList(ShopMallPartners shopMallPartners)
+ public List selectShopMallPartnersList(Page page, ShopMallPartners shopMallPartners)
{
- return baseMapper.selectShopMallPartnersList(shopMallPartners);
+
+ return baseMapper.selectShopMallPartnersList(page,shopMallPartners);
}
/**
diff --git a/dl-module-inspection/src/main/resources/mapper/contract/ContractHistoryMapper.xml b/dl-module-inspection/src/main/resources/mapper/contract/ContractHistoryMapper.xml
index 604c12cf..a7e69f5a 100644
--- a/dl-module-inspection/src/main/resources/mapper/contract/ContractHistoryMapper.xml
+++ b/dl-module-inspection/src/main/resources/mapper/contract/ContractHistoryMapper.xml
@@ -10,13 +10,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
-
+
-
+
- select id, user_id, contract_id, sign_contract, create_time, create_by, update_time, update_by from contract_history
+ select id, user_id, contract_id, sign_contract, create_time, creator, update_time, updater from contract_history