等保单位权限修改

dongdingding
董丁丁 2 years ago
parent 6e49025c7b
commit b5af576c31

@ -0,0 +1,29 @@
package com.ruoyi.screen.controller;
import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.screen.domain.ZongzhiSourceResponse;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
/**
*
*/
@RestController
@RequestMapping("/zongzhi/screen")
@Api(tags = " 太仓综治大屏接口")
public class ZongzhiScreenController {
/**
*
*/
@ApiOperation(value = "数据来源", response = ZongzhiSourceResponse.class)
@GetMapping("/source")
private AjaxResult getSource(){
return AjaxResult.success();
}
}

@ -0,0 +1,12 @@
package com.ruoyi.screen.domain;
import io.swagger.annotations.ApiModel;
import lombok.Data;
/**
*
*/
@Data
@ApiModel("大屏数据来源响应类")
public class ZongzhiSourceResponse {
}

@ -39,7 +39,7 @@ public class TcCommentatorController extends BaseController
/** /**
* *
*/ */
@PreAuthorize("@ss.hasPermi('zongzhi:commentator:list')")
@GetMapping("/list") @GetMapping("/list")
public TableDataInfo list(TcCommentator tcCommentator) public TableDataInfo list(TcCommentator tcCommentator)
{ {
@ -51,8 +51,8 @@ public class TcCommentatorController extends BaseController
/** /**
* *
*/ */
@PreAuthorize("@ss.hasPermi('zongzhi:commentator:export')")
@Log(title = "网评员", businessType = BusinessType.EXPORT)
@PostMapping("/export") @PostMapping("/export")
public void export(HttpServletResponse response, TcCommentator tcCommentator) public void export(HttpServletResponse response, TcCommentator tcCommentator)
{ {
@ -64,7 +64,7 @@ public class TcCommentatorController extends BaseController
/** /**
* *
*/ */
@PreAuthorize("@ss.hasPermi('zongzhi:commentator:query')")
@GetMapping(value = "/{id}") @GetMapping(value = "/{id}")
public AjaxResult getInfo(@PathVariable("id") Long id) public AjaxResult getInfo(@PathVariable("id") Long id)
{ {
@ -74,8 +74,8 @@ public class TcCommentatorController extends BaseController
/** /**
* *
*/ */
@PreAuthorize("@ss.hasPermi('zongzhi:commentator:add')")
@Log(title = "网评员", businessType = BusinessType.INSERT)
@PostMapping @PostMapping
public AjaxResult add(@RequestBody TcCommentator tcCommentator) public AjaxResult add(@RequestBody TcCommentator tcCommentator)
{ {
@ -85,8 +85,7 @@ public class TcCommentatorController extends BaseController
/** /**
* *
*/ */
@PreAuthorize("@ss.hasPermi('zongzhi:commentator:edit')")
@Log(title = "网评员", businessType = BusinessType.UPDATE)
@PutMapping @PutMapping
public AjaxResult edit(@RequestBody TcCommentator tcCommentator) public AjaxResult edit(@RequestBody TcCommentator tcCommentator)
{ {
@ -96,8 +95,7 @@ public class TcCommentatorController extends BaseController
/** /**
* *
*/ */
@PreAuthorize("@ss.hasPermi('zongzhi:commentator:remove')")
@Log(title = "网评员", businessType = BusinessType.DELETE)
@DeleteMapping("/{ids}") @DeleteMapping("/{ids}")
public AjaxResult remove(@PathVariable Long[] ids) public AjaxResult remove(@PathVariable Long[] ids)
{ {

@ -1,8 +1,11 @@
package com.ruoyi.zongzhi.controller; package com.ruoyi.zongzhi.controller;
import java.util.List; import java.util.List;
import io.swagger.annotations.Api; import io.swagger.annotations.Api;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import org.springframework.security.access.prepost.PreAuthorize; import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.GetMapping;
@ -24,25 +27,22 @@ import com.ruoyi.common.core.page.TableDataInfo;
/** /**
* Controller * Controller
* *
* @author ruoyi * @author ruoyi
* @date 2023-08-10 * @date 2023-08-10
*/ */
@RestController @RestController
@RequestMapping("/zongzhi/dengbaounit") @RequestMapping("/zongzhi/dengbaounit")
@Api(tags = " 等保单位") @Api(tags = " 等保单位")
public class TcDengbaoUnitController extends BaseController public class TcDengbaoUnitController extends BaseController {
{
@Autowired @Autowired
private ITcDengbaoUnitService tcDengbaoUnitService; private ITcDengbaoUnitService tcDengbaoUnitService;
/** /**
* *
*/ */
@PreAuthorize("@ss.hasPermi('zongzhi:unit:list')")
@GetMapping("/list") @GetMapping("/list")
public TableDataInfo list(TcDengbaoUnit tcDengbaoUnit) public TableDataInfo list(TcDengbaoUnit tcDengbaoUnit) {
{
startPage(); startPage();
List<TcDengbaoUnit> list = tcDengbaoUnitService.selectTcDengbaoUnitList(tcDengbaoUnit); List<TcDengbaoUnit> list = tcDengbaoUnitService.selectTcDengbaoUnitList(tcDengbaoUnit);
return getDataTable(list); return getDataTable(list);
@ -51,11 +51,9 @@ public class TcDengbaoUnitController extends BaseController
/** /**
* *
*/ */
@PreAuthorize("@ss.hasPermi('zongzhi:unit:export')")
@Log(title = "等保单位", businessType = BusinessType.EXPORT)
@PostMapping("/export") @PostMapping("/export")
public void export(HttpServletResponse response, TcDengbaoUnit tcDengbaoUnit) public void export(HttpServletResponse response, TcDengbaoUnit tcDengbaoUnit) {
{
List<TcDengbaoUnit> list = tcDengbaoUnitService.selectTcDengbaoUnitList(tcDengbaoUnit); List<TcDengbaoUnit> list = tcDengbaoUnitService.selectTcDengbaoUnitList(tcDengbaoUnit);
ExcelUtil<TcDengbaoUnit> util = new ExcelUtil<TcDengbaoUnit>(TcDengbaoUnit.class); ExcelUtil<TcDengbaoUnit> util = new ExcelUtil<TcDengbaoUnit>(TcDengbaoUnit.class);
util.exportExcel(response, list, "等保单位数据"); util.exportExcel(response, list, "等保单位数据");
@ -64,43 +62,32 @@ public class TcDengbaoUnitController extends BaseController
/** /**
* *
*/ */
@PreAuthorize("@ss.hasPermi('zongzhi:unit:query')")
@GetMapping(value = "/{id}") @GetMapping(value = "/{id}")
public AjaxResult getInfo(@PathVariable("id") Long id) public AjaxResult getInfo(@PathVariable("id") Long id) {
{
return success(tcDengbaoUnitService.selectTcDengbaoUnitById(id)); return success(tcDengbaoUnitService.selectTcDengbaoUnitById(id));
} }
/** /**
* *
*/ */
@PreAuthorize("@ss.hasPermi('zongzhi:unit:add')")
@Log(title = "等保单位", businessType = BusinessType.INSERT)
@PostMapping @PostMapping
public AjaxResult add(@RequestBody TcDengbaoUnit tcDengbaoUnit) public AjaxResult add(@RequestBody TcDengbaoUnit tcDengbaoUnit) {
{
return toAjax(tcDengbaoUnitService.insertTcDengbaoUnit(tcDengbaoUnit)); return toAjax(tcDengbaoUnitService.insertTcDengbaoUnit(tcDengbaoUnit));
} }
/** /**
* *
*/ */
@PreAuthorize("@ss.hasPermi('zongzhi:unit:edit')")
@Log(title = "等保单位", businessType = BusinessType.UPDATE)
@PutMapping @PutMapping
public AjaxResult edit(@RequestBody TcDengbaoUnit tcDengbaoUnit) public AjaxResult edit(@RequestBody TcDengbaoUnit tcDengbaoUnit) {
{
return toAjax(tcDengbaoUnitService.updateTcDengbaoUnit(tcDengbaoUnit)); return toAjax(tcDengbaoUnitService.updateTcDengbaoUnit(tcDengbaoUnit));
} }
/** /**
* *
*/ */
@PreAuthorize("@ss.hasPermi('zongzhi:unit:remove')") @DeleteMapping("/{ids}")
@Log(title = "等保单位", businessType = BusinessType.DELETE) public AjaxResult remove(@PathVariable Long[] ids) {
@DeleteMapping("/{ids}")
public AjaxResult remove(@PathVariable Long[] ids)
{
return toAjax(tcDengbaoUnitService.deleteTcDengbaoUnitByIds(ids)); return toAjax(tcDengbaoUnitService.deleteTcDengbaoUnitByIds(ids));
} }
} }

Loading…
Cancel
Save