From c80135e5c3f7bfab96ba558a910a06f1e587c53c Mon Sep 17 00:00:00 2001
From: liusheng <337615773@qq.com>
Date: 星期三, 07 一月 2026 16:14:04 +0800
Subject: [PATCH] 1.新增@AddOrgId(field = "orgid", paramIndex = 0, campusField = "campusid") 2.将新增orgid的拦截器关掉 3.登陆新增campusid
---
ruoyi-admin/src/main/java/com/ruoyi/web/controller/smartor/ServiceTaskoperController.java | 32 ++++++++++++++++----------------
1 files changed, 16 insertions(+), 16 deletions(-)
diff --git a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/smartor/ServiceTaskoperController.java b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/smartor/ServiceTaskoperController.java
index 7f719d3..b3a5392 100644
--- a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/smartor/ServiceTaskoperController.java
+++ b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/smartor/ServiceTaskoperController.java
@@ -1,9 +1,13 @@
package com.ruoyi.web.controller.smartor;
import java.util.List;
+
+import com.ruoyi.common.annotation.AddOrgId;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
+
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;
@@ -32,8 +36,7 @@
@Api("鎵嬫湳妯℃澘绉戝鍏宠仈")
@RestController
@RequestMapping("/smartor/taskoper")
-public class ServiceTaskoperController extends BaseController
-{
+public class ServiceTaskoperController extends BaseController {
@Autowired
private IServiceTaskoperService serviceTaskoperService;
@@ -42,9 +45,9 @@
*/
@ApiOperation("鏌ヨ妯℃澘绉戝鍏宠仈鍒楄〃")
//@PreAuthorize("@ss.hasPermi('smartor:taskoper:list')")
- @PostMapping("/list")
- public TableDataInfo list(@RequestBody ServiceTaskoper serviceTaskoper)
- {
+ @AddOrgId(field = "orgid", paramIndex = 0, campusField = "campusid")
+ @PostMapping("list")
+ public TableDataInfo list(@RequestBody ServiceTaskoper serviceTaskoper) {
startPage();
List<ServiceTaskoper> list = serviceTaskoperService.selectServiceTaskoperList(serviceTaskoper);
return getDataTable(list);
@@ -57,8 +60,7 @@
//@PreAuthorize("@ss.hasPermi('smartor:taskoper:export')")
@Log(title = "妯℃澘绉戝鍏宠仈", businessType = BusinessType.EXPORT)
@PostMapping("/export")
- public void export(HttpServletResponse response, ServiceTaskoper serviceTaskoper)
- {
+ public void export(HttpServletResponse response, ServiceTaskoper serviceTaskoper) {
List<ServiceTaskoper> list = serviceTaskoperService.selectServiceTaskoperList(serviceTaskoper);
ExcelUtil<ServiceTaskoper> util = new ExcelUtil<ServiceTaskoper>(ServiceTaskoper.class);
util.exportExcel(response, list, "妯℃澘绉戝鍏宠仈鏁版嵁");
@@ -70,8 +72,7 @@
@ApiOperation("鑾峰彇妯℃澘绉戝鍏宠仈璇︾粏淇℃伅")
//@PreAuthorize("@ss.hasPermi('smartor:taskoper:query')")
@GetMapping(value = "/getInfo/{id}")
- public AjaxResult getInfo(@PathVariable("id") Long id)
- {
+ public AjaxResult getInfo(@PathVariable("id") Long id) {
return success(serviceTaskoperService.selectServiceTaskoperById(id));
}
@@ -81,9 +82,9 @@
@ApiOperation("鏂板妯℃澘绉戝鍏宠仈")
//@PreAuthorize("@ss.hasPermi('smartor:taskoper:add')")
@Log(title = "妯℃澘绉戝鍏宠仈", businessType = BusinessType.INSERT)
+ @AddOrgId(field = "orgid", paramIndex = 0, campusField = "campusid")
@PostMapping("/add")
- public AjaxResult add(@RequestBody ServiceTaskoper serviceTaskoper)
- {
+ public AjaxResult add(@RequestBody ServiceTaskoper serviceTaskoper) {
return toAjax(serviceTaskoperService.insertServiceTaskoper(serviceTaskoper));
}
@@ -93,9 +94,9 @@
@ApiOperation("淇敼妯℃澘绉戝鍏宠仈")
//@PreAuthorize("@ss.hasPermi('smartor:taskoper:edit')")
@Log(title = "妯℃澘绉戝鍏宠仈", businessType = BusinessType.UPDATE)
+ @AddOrgId(field = "orgid", paramIndex = 0, campusField = "campusid")
@PostMapping("/edit")
- public AjaxResult edit(@RequestBody ServiceTaskoper serviceTaskoper)
- {
+ public AjaxResult edit(@RequestBody ServiceTaskoper serviceTaskoper) {
return toAjax(serviceTaskoperService.updateServiceTaskoper(serviceTaskoper));
}
@@ -105,9 +106,8 @@
@ApiOperation("鍒犻櫎妯℃澘绉戝鍏宠仈")
//@PreAuthorize("@ss.hasPermi('smartor:taskoper:remove')")
@Log(title = "妯℃澘绉戝鍏宠仈", businessType = BusinessType.DELETE)
- @GetMapping("/remove/{id}")
- public AjaxResult remove(@PathVariable Long id)
- {
+ @GetMapping("/remove/{id}")
+ public AjaxResult remove(@PathVariable Long id) {
return toAjax(serviceTaskoperService.deleteServiceTaskoperById(id));
}
}
--
Gitblit v1.9.3