From 7965c2ae65b8ae7a283dc6b2a065959eafb6ba7e Mon Sep 17 00:00:00 2001
From: Administrator <1144154118@qq.com>
Date: 星期一, 14 八月 2023 16:49:06 +0800
Subject: [PATCH] 单兵端巡检计划
---
/dev/null | 104 ----------------------------------
ard-work/src/main/java/com/ruoyi/app/patrolplan/mapper/ArdAppPatrolplanMapper.java | 2
ard-work/src/main/resources/mapper/app/ArdAppPatrolplanMapper.xml | 21 +++++++
ard-work/src/main/java/com/ruoyi/app/patrolplan/service/impl/ArdAppPatrolplanServiceImpl.java | 5 +
ard-work/src/main/java/com/ruoyi/app/patrolplan/controller/ArdAppPatrolplanController.java | 45 +++++++++++----
ard-work/src/main/java/com/ruoyi/app/patrolplan/service/IArdAppPatrolplanService.java | 2
6 files changed, 63 insertions(+), 116 deletions(-)
diff --git a/ard-work/src/main/java/com/ruoyi/app/patrolplan/controller/ArdAppPatrolplanController.java b/ard-work/src/main/java/com/ruoyi/app/patrolplan/controller/ArdAppPatrolplanController.java
index 9ad4413..cb0da57 100644
--- a/ard-work/src/main/java/com/ruoyi/app/patrolplan/controller/ArdAppPatrolplanController.java
+++ b/ard-work/src/main/java/com/ruoyi/app/patrolplan/controller/ArdAppPatrolplanController.java
@@ -79,11 +79,11 @@
IArdAppPatrolpointRecordService recordService;
/**
- * 鏌ヨapp宸℃璁″垝鍒楄〃
+ * 绠$悊绔�--鏌ヨapp宸℃璁″垝鍒楄〃
*/
@PreAuthorize("@ss.hasPermi('app:appPatrolplan:list')")
@GetMapping("/list")
- @ApiOperation("鏌ヨ鍏ㄩ儴宸℃鍒楄〃鍙婃悳绱㈢瓫閫�")
+ @ApiOperation("绠$悊绔�--鏌ヨ鍏ㄩ儴宸℃鍒楄〃鍙婃悳绱㈢瓫閫�")
public Results list(ArdAppPatrolplan ardAppPatrolplan)
{
String userId = SecurityUtils.getUserId();
@@ -100,12 +100,12 @@
}
/**
- * 瀵煎嚭app宸℃璁″垝鍒楄〃
+ * 绠$悊绔�--瀵煎嚭app宸℃璁″垝鍒楄〃
*/
@PreAuthorize("@ss.hasPermi('app:appPatrolplan:export')")
@Log(title = "app宸℃璁″垝", businessType = BusinessType.EXPORT)
@PostMapping("/export")
- @ApiOperation("瀵煎嚭鍏ㄩ儴宸℃鍒楄〃")
+ @ApiOperation("绠$悊绔�--瀵煎嚭鍏ㄩ儴宸℃鍒楄〃")
public void export(HttpServletResponse response, ArdAppPatrolplan ardAppPatrolplan)
{
List<ArdAppPatrolplan> list = ardAppPatrolplanService.selectArdAppPatrolplanList(ardAppPatrolplan);
@@ -136,12 +136,12 @@
}
/**
- * 鍒犻櫎app宸℃璁″垝
+ * 绠$悊绔�--鍒犻櫎app宸℃璁″垝
*/
@PreAuthorize("@ss.hasPermi('app:appPatrolplan:remove')")
@Log(title = "app宸℃璁″垝", businessType = BusinessType.DELETE)
@DeleteMapping("/{id}")
- @ApiOperation("鍒犻櫎app宸℃璁″垝")
+ @ApiOperation("绠$悊绔�--鍒犻櫎app宸℃璁″垝")
//public Results remove(@PathVariable String id)
public AjaxResult remove(@PathVariable String id)
{
@@ -170,34 +170,34 @@
}
/**
- * 鏂板app宸℃璁″垝鍙婁汉鍛樼偣浣�
+ * 绠$悊绔�--鏂板app宸℃璁″垝鍙婁汉鍛樼偣浣�
*/
@PreAuthorize("@ss.hasPermi('app:appPatrolplan:insertArdAppPatrolplan')")
@Log(title = "app宸℃璁″垝", businessType = BusinessType.INSERT)
@PostMapping("/insertArdAppPatrolplan")
- @ApiOperation("鏂板app宸℃璁″垝鍙婁汉鍛樼偣浣�")
+ @ApiOperation("绠$悊绔�--鏂板app宸℃璁″垝鍙婁汉鍛樼偣浣�")
public AjaxResult addArdAppPatrolplan(@RequestBody Map<String,Object> para)
{
return toAjax(ardAppPatrolplanService.insertArdAppPatrolplan(para));
}
/**
- * 鏌ヨ鍗曟潯鏁版嵁
+ * 绠$悊绔�--鏌ヨ鍗曟潯鏁版嵁
*/
@PreAuthorize("@ss.hasPermi('app:appPatrolplan:oneById')")
@PostMapping("/oneById/{id}")
- @ApiOperation("鏌ヨ鍗曟潯鏁版嵁")
+ @ApiOperation("绠$悊绔�--鏌ヨ鍗曟潯鏁版嵁")
public Results oneById(@PathVariable String id)
{
return ardAppPatrolplanService.oneById(id);
}
/**
- * 淇敼app宸℃璁″垝
+ * 绠$悊绔�--淇敼app宸℃璁″垝
*/
@PreAuthorize("@ss.hasPermi('app:appPatrolplan:edit')")
@Log(title = "app宸℃璁″垝", businessType = BusinessType.UPDATE)
- @ApiOperation("淇敼鍗曟潯鏁版嵁")
+ @ApiOperation("绠$悊绔�--淇敼鍗曟潯鏁版嵁")
@PutMapping("upd")
public Results edit(@RequestBody Map<String,Object> para)
{
@@ -243,4 +243,25 @@
public Results recordSolo(@RequestBody ArdAppPatrolpointRecordParam ardAppPatrolpointRecordParam) throws ParseException {
return recordService.recordSolo(ardAppPatrolpointRecordParam);
}
+
+ /**
+ * 鍗曞叺绔�--鏌ヨapp宸℃璁″垝鍒楄〃
+ */
+ @PreAuthorize("@ss.hasPermi('app:appPatrolplan:executeList')")
+ @GetMapping("/executeList")
+ @ApiOperation("鍗曞叺绔�--鏌ヨ璇ョ敤鎴蜂笅鎵�鏈夋墽琛岃鍒掑強鎼滅储绛涢��")
+ public Results executeList(ArdAppPatrolplan ardAppPatrolplan)
+ {
+ String userId = SecurityUtils.getUserId();
+ ardAppPatrolplan.setUserId(userId);
+ if(ardAppPatrolplan.getPageNum()==null || ardAppPatrolplan.getPageNum() == 0){
+ ardAppPatrolplan.setPageNum(1);
+ }
+ if(ardAppPatrolplan.getPageSize()==null || ardAppPatrolplan.getPageSize() == 0){
+ ardAppPatrolplan.setPageSize(10);
+ }
+ PageHelper.startPage(ardAppPatrolplan.getPageNum(),ardAppPatrolplan.getPageSize());
+ List<ArdAppPatrolplan> list = ardAppPatrolplanService.executeList(ardAppPatrolplan);
+ return Results.succeed(new PageInfo<>(list));
+ }
}
diff --git a/ard-work/src/main/java/com/ruoyi/app/patrolplan/controller/ArdAppPatrolpointController.java b/ard-work/src/main/java/com/ruoyi/app/patrolplan/controller/ArdAppPatrolpointController.java
deleted file mode 100644
index 35e5e35..0000000
--- a/ard-work/src/main/java/com/ruoyi/app/patrolplan/controller/ArdAppPatrolpointController.java
+++ /dev/null
@@ -1,94 +0,0 @@
-package com.ruoyi.app.patrolplan.controller;
-
-import java.util.List;
-import javax.servlet.http.HttpServletResponse;
-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 com.ruoyi.common.annotation.Log;
-import com.ruoyi.common.core.controller.BaseController;
-import com.ruoyi.common.core.domain.AjaxResult;
-import com.ruoyi.common.enums.BusinessType;
-import com.ruoyi.app.patrolplan.domain.ArdAppPatrolpoint;
-import com.ruoyi.app.patrolplan.service.IArdAppPatrolpointService;
-import com.ruoyi.common.utils.poi.ExcelUtil;
-import com.ruoyi.common.core.page.TableDataInfo;
-
-/**
- * app宸℃璁″垝鐐逛綅Controller
- *
- * @author ard
- * @date 2023-08-02
- */
-@RestController
-@RequestMapping("/app/patrolpoint")
-public class ArdAppPatrolpointController extends BaseController
-{
- @Autowired
- private IArdAppPatrolpointService ardAppPatrolpointService;
-
- /**
- * 鏌ヨapp宸℃璁″垝鐐逛綅鍒楄〃
- */
- @PreAuthorize("@ss.hasPermi('app:patrolpoint:list')")
- @GetMapping("/list")
- public TableDataInfo list(ArdAppPatrolpoint ardAppPatrolpoint)
- {
- startPage();
- List<ArdAppPatrolpoint> list = ardAppPatrolpointService.selectArdAppPatrolpointList(ardAppPatrolpoint);
- return getDataTable(list);
- }
-
- /**
- * 瀵煎嚭app宸℃璁″垝鐐逛綅鍒楄〃
- */
- @PreAuthorize("@ss.hasPermi('app:patrolpoint:export')")
- @Log(title = "app宸℃璁″垝鐐逛綅", businessType = BusinessType.EXPORT)
- @PostMapping("/export")
- public void export(HttpServletResponse response, ArdAppPatrolpoint ardAppPatrolpoint)
- {
- List<ArdAppPatrolpoint> list = ardAppPatrolpointService.selectArdAppPatrolpointList(ardAppPatrolpoint);
- ExcelUtil<ArdAppPatrolpoint> util = new ExcelUtil<ArdAppPatrolpoint>(ArdAppPatrolpoint.class);
- util.exportExcel(response, list, "app宸℃璁″垝鐐逛綅鏁版嵁");
- }
-
- /**
- * 鑾峰彇app宸℃璁″垝鐐逛綅璇︾粏淇℃伅
- */
- @PreAuthorize("@ss.hasPermi('app:patrolpoint:query')")
- @GetMapping(value = "/{id}")
- public AjaxResult getInfo(@PathVariable("id") String id)
- {
- return success(ardAppPatrolpointService.selectArdAppPatrolpointById(id));
- }
-
- /**
- * 鏂板app宸℃璁″垝鐐逛綅
- */
- @PreAuthorize("@ss.hasPermi('app:patrolpoint:add')")
- @Log(title = "app宸℃璁″垝鐐逛綅", businessType = BusinessType.INSERT)
- @PostMapping
- public AjaxResult add(@RequestBody ArdAppPatrolpoint ardAppPatrolpoint)
- {
- return toAjax(ardAppPatrolpointService.insertArdAppPatrolpoint(ardAppPatrolpoint));
- }
-
- /**
- * 淇敼app宸℃璁″垝鐐逛綅
- */
- @PreAuthorize("@ss.hasPermi('app:patrolpoint:edit')")
- @Log(title = "app宸℃璁″垝鐐逛綅", businessType = BusinessType.UPDATE)
- @PutMapping
- public AjaxResult edit(@RequestBody ArdAppPatrolpoint ardAppPatrolpoint)
- {
- return toAjax(ardAppPatrolpointService.updateArdAppPatrolpoint(ardAppPatrolpoint));
- }
-
-}
diff --git a/ard-work/src/main/java/com/ruoyi/app/patrolplan/controller/ArdAppPatrolpointRecordController.java b/ard-work/src/main/java/com/ruoyi/app/patrolplan/controller/ArdAppPatrolpointRecordController.java
deleted file mode 100644
index 0b24bb8..0000000
--- a/ard-work/src/main/java/com/ruoyi/app/patrolplan/controller/ArdAppPatrolpointRecordController.java
+++ /dev/null
@@ -1,104 +0,0 @@
-package com.ruoyi.app.patrolplan.controller;
-
-import java.util.List;
-import javax.servlet.http.HttpServletResponse;
-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 com.ruoyi.common.annotation.Log;
-import com.ruoyi.common.core.controller.BaseController;
-import com.ruoyi.common.core.domain.AjaxResult;
-import com.ruoyi.common.enums.BusinessType;
-import com.ruoyi.app.patrolplan.domain.ArdAppPatrolpointRecord;
-import com.ruoyi.app.patrolplan.service.IArdAppPatrolpointRecordService;
-import com.ruoyi.common.utils.poi.ExcelUtil;
-import com.ruoyi.common.core.page.TableDataInfo;
-
-/**
- * app宸℃璁″垝璁板綍Controller
- *
- * @author ard
- * @date 2023-08-02
- */
-@RestController
-@RequestMapping("/app/patrolpointRecord")
-public class ArdAppPatrolpointRecordController extends BaseController
-{
- @Autowired
- private IArdAppPatrolpointRecordService ardAppPatrolpointRecordService;
-
- /**
- * 鏌ヨapp宸℃璁″垝璁板綍鍒楄〃
- */
- @PreAuthorize("@ss.hasPermi('app:patrolpointRecord:list')")
- @GetMapping("/list")
- public TableDataInfo list(ArdAppPatrolpointRecord ardAppPatrolpointRecord)
- {
- startPage();
- List<ArdAppPatrolpointRecord> list = ardAppPatrolpointRecordService.selectArdAppPatrolpointRecordList(ardAppPatrolpointRecord);
- return getDataTable(list);
- }
-
- /**
- * 瀵煎嚭app宸℃璁″垝璁板綍鍒楄〃
- */
- @PreAuthorize("@ss.hasPermi('app:patrolpointRecord:export')")
- @Log(title = "app宸℃璁″垝璁板綍", businessType = BusinessType.EXPORT)
- @PostMapping("/export")
- public void export(HttpServletResponse response, ArdAppPatrolpointRecord ardAppPatrolpointRecord)
- {
- List<ArdAppPatrolpointRecord> list = ardAppPatrolpointRecordService.selectArdAppPatrolpointRecordList(ardAppPatrolpointRecord);
- ExcelUtil<ArdAppPatrolpointRecord> util = new ExcelUtil<ArdAppPatrolpointRecord>(ArdAppPatrolpointRecord.class);
- util.exportExcel(response, list, "app宸℃璁″垝璁板綍鏁版嵁");
- }
-
- /**
- * 鑾峰彇app宸℃璁″垝璁板綍璇︾粏淇℃伅
- */
- @PreAuthorize("@ss.hasPermi('app:patrolpointRecord:query')")
- @GetMapping(value = "/{id}")
- public AjaxResult getInfo(@PathVariable("id") String id)
- {
- return success(ardAppPatrolpointRecordService.selectArdAppPatrolpointRecordById(id));
- }
-
- /**
- * 鏂板app宸℃璁″垝璁板綍
- */
- @PreAuthorize("@ss.hasPermi('app:patrolpointRecord:add')")
- @Log(title = "app宸℃璁″垝璁板綍", businessType = BusinessType.INSERT)
- @PostMapping
- public AjaxResult add(@RequestBody ArdAppPatrolpointRecord ardAppPatrolpointRecord)
- {
- return toAjax(ardAppPatrolpointRecordService.insertArdAppPatrolpointRecord(ardAppPatrolpointRecord));
- }
-
- /**
- * 淇敼app宸℃璁″垝璁板綍
- */
- @PreAuthorize("@ss.hasPermi('app:patrolpointRecord:edit')")
- @Log(title = "app宸℃璁″垝璁板綍", businessType = BusinessType.UPDATE)
- @PutMapping
- public AjaxResult edit(@RequestBody ArdAppPatrolpointRecord ardAppPatrolpointRecord)
- {
- return toAjax(ardAppPatrolpointRecordService.updateArdAppPatrolpointRecord(ardAppPatrolpointRecord));
- }
-
- /**
- * 鍒犻櫎app宸℃璁″垝璁板綍
- */
- @PreAuthorize("@ss.hasPermi('app:patrolpointRecord:remove')")
- @Log(title = "app宸℃璁″垝璁板綍", businessType = BusinessType.DELETE)
- @DeleteMapping("/{ids}")
- public AjaxResult remove(@PathVariable String[] ids)
- {
- return toAjax(ardAppPatrolpointRecordService.deleteArdAppPatrolpointRecordByIds(ids));
- }
-}
diff --git a/ard-work/src/main/java/com/ruoyi/app/patrolplan/controller/ArdAppPatrolpointRecordImgController.java b/ard-work/src/main/java/com/ruoyi/app/patrolplan/controller/ArdAppPatrolpointRecordImgController.java
deleted file mode 100644
index 26fd71b..0000000
--- a/ard-work/src/main/java/com/ruoyi/app/patrolplan/controller/ArdAppPatrolpointRecordImgController.java
+++ /dev/null
@@ -1,104 +0,0 @@
-package com.ruoyi.app.patrolplan.controller;
-
-import java.util.List;
-import javax.servlet.http.HttpServletResponse;
-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 com.ruoyi.common.annotation.Log;
-import com.ruoyi.common.core.controller.BaseController;
-import com.ruoyi.common.core.domain.AjaxResult;
-import com.ruoyi.common.enums.BusinessType;
-import com.ruoyi.app.patrolplan.domain.ArdAppPatrolpointRecordImg;
-import com.ruoyi.app.patrolplan.service.IArdAppPatrolpointRecordImgService;
-import com.ruoyi.common.utils.poi.ExcelUtil;
-import com.ruoyi.common.core.page.TableDataInfo;
-
-/**
- * app宸℃璁″垝璁板綍鍥剧墖Controller
- *
- * @author ard
- * @date 2023-08-02
- */
-@RestController
-@RequestMapping("/app/patrolpointRecordImg")
-public class ArdAppPatrolpointRecordImgController extends BaseController
-{
- @Autowired
- private IArdAppPatrolpointRecordImgService ardAppPatrolpointRecordImgService;
-
- /**
- * 鏌ヨapp宸℃璁″垝璁板綍鍥剧墖鍒楄〃
- */
- @PreAuthorize("@ss.hasPermi('app:patrolpointRecordImg:list')")
- @GetMapping("/list")
- public TableDataInfo list(ArdAppPatrolpointRecordImg ardAppPatrolpointRecordImg)
- {
- startPage();
- List<ArdAppPatrolpointRecordImg> list = ardAppPatrolpointRecordImgService.selectArdAppPatrolpointRecordImgList(ardAppPatrolpointRecordImg);
- return getDataTable(list);
- }
-
- /**
- * 瀵煎嚭app宸℃璁″垝璁板綍鍥剧墖鍒楄〃
- */
- @PreAuthorize("@ss.hasPermi('app:patrolpointRecordImg:export')")
- @Log(title = "app宸℃璁″垝璁板綍鍥剧墖", businessType = BusinessType.EXPORT)
- @PostMapping("/export")
- public void export(HttpServletResponse response, ArdAppPatrolpointRecordImg ardAppPatrolpointRecordImg)
- {
- List<ArdAppPatrolpointRecordImg> list = ardAppPatrolpointRecordImgService.selectArdAppPatrolpointRecordImgList(ardAppPatrolpointRecordImg);
- ExcelUtil<ArdAppPatrolpointRecordImg> util = new ExcelUtil<ArdAppPatrolpointRecordImg>(ArdAppPatrolpointRecordImg.class);
- util.exportExcel(response, list, "app宸℃璁″垝璁板綍鍥剧墖鏁版嵁");
- }
-
- /**
- * 鑾峰彇app宸℃璁″垝璁板綍鍥剧墖璇︾粏淇℃伅
- */
- @PreAuthorize("@ss.hasPermi('app:patrolpointRecordImg:query')")
- @GetMapping(value = "/{id}")
- public AjaxResult getInfo(@PathVariable("id") String id)
- {
- return success(ardAppPatrolpointRecordImgService.selectArdAppPatrolpointRecordImgById(id));
- }
-
- /**
- * 鏂板app宸℃璁″垝璁板綍鍥剧墖
- */
- @PreAuthorize("@ss.hasPermi('app:patrolpointRecordImg:add')")
- @Log(title = "app宸℃璁″垝璁板綍鍥剧墖", businessType = BusinessType.INSERT)
- @PostMapping
- public AjaxResult add(@RequestBody ArdAppPatrolpointRecordImg ardAppPatrolpointRecordImg)
- {
- return toAjax(ardAppPatrolpointRecordImgService.insertArdAppPatrolpointRecordImg(ardAppPatrolpointRecordImg));
- }
-
- /**
- * 淇敼app宸℃璁″垝璁板綍鍥剧墖
- */
- @PreAuthorize("@ss.hasPermi('app:patrolpointRecordImg:edit')")
- @Log(title = "app宸℃璁″垝璁板綍鍥剧墖", businessType = BusinessType.UPDATE)
- @PutMapping
- public AjaxResult edit(@RequestBody ArdAppPatrolpointRecordImg ardAppPatrolpointRecordImg)
- {
- return toAjax(ardAppPatrolpointRecordImgService.updateArdAppPatrolpointRecordImg(ardAppPatrolpointRecordImg));
- }
-
- /**
- * 鍒犻櫎app宸℃璁″垝璁板綍鍥剧墖
- */
- @PreAuthorize("@ss.hasPermi('app:patrolpointRecordImg:remove')")
- @Log(title = "app宸℃璁″垝璁板綍鍥剧墖", businessType = BusinessType.DELETE)
- @DeleteMapping("/{ids}")
- public AjaxResult remove(@PathVariable String[] ids)
- {
- return toAjax(ardAppPatrolpointRecordImgService.deleteArdAppPatrolpointRecordImgByIds(ids));
- }
-}
diff --git a/ard-work/src/main/java/com/ruoyi/app/patrolplan/controller/ArdAppPatroluserController.java b/ard-work/src/main/java/com/ruoyi/app/patrolplan/controller/ArdAppPatroluserController.java
deleted file mode 100644
index 071fa1b..0000000
--- a/ard-work/src/main/java/com/ruoyi/app/patrolplan/controller/ArdAppPatroluserController.java
+++ /dev/null
@@ -1,104 +0,0 @@
-package com.ruoyi.app.patrolplan.controller;
-
-import java.util.List;
-import javax.servlet.http.HttpServletResponse;
-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 com.ruoyi.common.annotation.Log;
-import com.ruoyi.common.core.controller.BaseController;
-import com.ruoyi.common.core.domain.AjaxResult;
-import com.ruoyi.common.enums.BusinessType;
-import com.ruoyi.app.patrolplan.domain.ArdAppPatroluser;
-import com.ruoyi.app.patrolplan.service.IArdAppPatroluserService;
-import com.ruoyi.common.utils.poi.ExcelUtil;
-import com.ruoyi.common.core.page.TableDataInfo;
-
-/**
- * app宸℃璁″垝浜哄憳Controller
- *
- * @author ard
- * @date 2023-08-04
- */
-@RestController
-@RequestMapping("/app/patroluser")
-public class ArdAppPatroluserController extends BaseController
-{
- @Autowired
- private IArdAppPatroluserService ardAppPatroluserService;
-
- /**
- * 鏌ヨapp宸℃璁″垝浜哄憳鍒楄〃
- */
- @PreAuthorize("@ss.hasPermi('app:patroluser:list')")
- @GetMapping("/list")
- public TableDataInfo list(ArdAppPatroluser ardAppPatroluser)
- {
- startPage();
- List<ArdAppPatroluser> list = ardAppPatroluserService.selectArdAppPatroluserList(ardAppPatroluser);
- return getDataTable(list);
- }
-
- /**
- * 瀵煎嚭app宸℃璁″垝浜哄憳鍒楄〃
- */
- @PreAuthorize("@ss.hasPermi('app:patroluser:export')")
- @Log(title = "app宸℃璁″垝浜哄憳", businessType = BusinessType.EXPORT)
- @PostMapping("/export")
- public void export(HttpServletResponse response, ArdAppPatroluser ardAppPatroluser)
- {
- List<ArdAppPatroluser> list = ardAppPatroluserService.selectArdAppPatroluserList(ardAppPatroluser);
- ExcelUtil<ArdAppPatroluser> util = new ExcelUtil<ArdAppPatroluser>(ArdAppPatroluser.class);
- util.exportExcel(response, list, "app宸℃璁″垝浜哄憳鏁版嵁");
- }
-
- /**
- * 鑾峰彇app宸℃璁″垝浜哄憳璇︾粏淇℃伅
- */
- @PreAuthorize("@ss.hasPermi('app:patroluser:query')")
- @GetMapping(value = "/{id}")
- public AjaxResult getInfo(@PathVariable("id") String id)
- {
- return success(ardAppPatroluserService.selectArdAppPatroluserById(id));
- }
-
- /**
- * 鏂板app宸℃璁″垝浜哄憳
- */
- @PreAuthorize("@ss.hasPermi('app:patroluser:add')")
- @Log(title = "app宸℃璁″垝浜哄憳", businessType = BusinessType.INSERT)
- @PostMapping
- public AjaxResult add(@RequestBody ArdAppPatroluser ardAppPatroluser)
- {
- return toAjax(ardAppPatroluserService.insertArdAppPatroluser(ardAppPatroluser));
- }
-
- /**
- * 淇敼app宸℃璁″垝浜哄憳
- */
- @PreAuthorize("@ss.hasPermi('app:patroluser:edit')")
- @Log(title = "app宸℃璁″垝浜哄憳", businessType = BusinessType.UPDATE)
- @PutMapping
- public AjaxResult edit(@RequestBody ArdAppPatroluser ardAppPatroluser)
- {
- return toAjax(ardAppPatroluserService.updateArdAppPatroluser(ardAppPatroluser));
- }
-
- /**
- * 鍒犻櫎app宸℃璁″垝浜哄憳
- */
- @PreAuthorize("@ss.hasPermi('app:patroluser:remove')")
- @Log(title = "app宸℃璁″垝浜哄憳", businessType = BusinessType.DELETE)
- @DeleteMapping("/{ids}")
- public AjaxResult remove(@PathVariable String[] ids)
- {
- return toAjax(ardAppPatroluserService.deleteArdAppPatroluserByIds(ids));
- }
-}
diff --git a/ard-work/src/main/java/com/ruoyi/app/patrolplan/mapper/ArdAppPatrolplanMapper.java b/ard-work/src/main/java/com/ruoyi/app/patrolplan/mapper/ArdAppPatrolplanMapper.java
index 91cd123..7bbc133 100644
--- a/ard-work/src/main/java/com/ruoyi/app/patrolplan/mapper/ArdAppPatrolplanMapper.java
+++ b/ard-work/src/main/java/com/ruoyi/app/patrolplan/mapper/ArdAppPatrolplanMapper.java
@@ -53,4 +53,6 @@
List<ArdAppPatrolplan> shouldRecord(String id);
+ List<ArdAppPatrolplan> executeList(ArdAppPatrolplan ardAppPatrolplan);
+
}
diff --git a/ard-work/src/main/java/com/ruoyi/app/patrolplan/service/IArdAppPatrolplanService.java b/ard-work/src/main/java/com/ruoyi/app/patrolplan/service/IArdAppPatrolplanService.java
index 89cac2e..d7f0b4a 100644
--- a/ard-work/src/main/java/com/ruoyi/app/patrolplan/service/IArdAppPatrolplanService.java
+++ b/ard-work/src/main/java/com/ruoyi/app/patrolplan/service/IArdAppPatrolplanService.java
@@ -61,4 +61,6 @@
Results oneById(String id);
+ List<ArdAppPatrolplan> executeList(ArdAppPatrolplan ardAppPatrolplan);
+
}
diff --git a/ard-work/src/main/java/com/ruoyi/app/patrolplan/service/impl/ArdAppPatrolplanServiceImpl.java b/ard-work/src/main/java/com/ruoyi/app/patrolplan/service/impl/ArdAppPatrolplanServiceImpl.java
index 22c8933..3ab109a 100644
--- a/ard-work/src/main/java/com/ruoyi/app/patrolplan/service/impl/ArdAppPatrolplanServiceImpl.java
+++ b/ard-work/src/main/java/com/ruoyi/app/patrolplan/service/impl/ArdAppPatrolplanServiceImpl.java
@@ -302,4 +302,9 @@
}
}
+ @Override
+ public List<ArdAppPatrolplan> executeList(ArdAppPatrolplan ardAppPatrolplan) {
+ return ardAppPatrolplanMapper.executeList(ardAppPatrolplan);
+ }
+
}
diff --git a/ard-work/src/main/resources/mapper/app/ArdAppPatrolplanMapper.xml b/ard-work/src/main/resources/mapper/app/ArdAppPatrolplanMapper.xml
index 2e0a218..568b736 100644
--- a/ard-work/src/main/resources/mapper/app/ArdAppPatrolplanMapper.xml
+++ b/ard-work/src/main/resources/mapper/app/ArdAppPatrolplanMapper.xml
@@ -123,4 +123,25 @@
left join sys_user on users.app_user_id = sys_user.user_id
where ard_app_patrolplan.id = #{id} and del_name is null and del_time is null
</select>
+
+ <select id="executeList" parameterType="ArdAppPatrolplan" resultMap="ArdAppPatrolplanResult">
+ <include refid="selectArdAppPatrolplanVo"/>
+ left join ard_app_patrolpoint as well on ard_app_patrolplan.id = well.patrolplan_id
+ left join ard_app_patroluser as users on ard_app_patrolplan.id = users.patrolplan_id
+ left join sys_user on ard_app_patrolplan.user_id = sys_user.user_id
+ <where>
+ users.app_user_id = #{userId} and del_name is null and del_time is null
+ <if test="cycle != null and cycle != ''"> and cycle = #{cycle}</if>
+ <if test="planName != null and planName != ''"> and plan_name like '%'||#{planName}||'%'</if>
+ <if test="patroBeginTime != null and patroBeginTime != ''"> and patro_begin_time >= #{patroBeginTime}</if>
+ <if test="patroEndTime != null and patroEndTime != ''"> and patro_end_time <= #{patroEndTime}</if>
+ <if test="wellId != null and wellId != ''">
+ and well.alarmpoints_id = #{wellId}
+ </if>
+ <if test="pUser != null and pUser != ''">
+ and users.app_user_id = #{pUser}
+ </if>
+ </where>
+ group by ard_app_patrolplan.id
+ </select>
</mapper>
\ No newline at end of file
--
Gitblit v1.9.3