| | |
| | | import com.ruoyi.common.core.web.page.TableDataInfo;
|
| | | import com.ruoyi.common.log.annotation.Log;
|
| | | import com.ruoyi.common.log.enums.BusinessType;
|
| | | import com.ruoyi.common.security.annotation.PreAuthorize;
|
| | | import com.ruoyi.common.security.annotation.RequiresPermissions;
|
| | | import com.ruoyi.common.security.utils.SecurityUtils;
|
| | | import com.ruoyi.system.domain.SysNotice;
|
| | | import com.ruoyi.system.service.ISysNoticeService;
|
| | |
| | | /**
|
| | | * 获取通知公告列表
|
| | | */
|
| | | @PreAuthorize(hasPermi = "system:notice:list")
|
| | | @RequiresPermissions("system:notice:list")
|
| | | @GetMapping("/list")
|
| | | public TableDataInfo list(SysNotice notice)
|
| | | {
|
| | |
| | | /**
|
| | | * 根据通知公告编号获取详细信息
|
| | | */
|
| | | @PreAuthorize(hasPermi = "system:notice:query")
|
| | | @RequiresPermissions("system:notice:query")
|
| | | @GetMapping(value = "/{noticeId}")
|
| | | public AjaxResult getInfo(@PathVariable Long noticeId)
|
| | | {
|
| | |
| | | /**
|
| | | * 新增通知公告
|
| | | */
|
| | | @PreAuthorize(hasPermi = "system:notice:add")
|
| | | @Log(title = "通知公告", businessType = BusinessType.UPDATE)
|
| | | @RequiresPermissions("system:notice:add")
|
| | | @Log(title = "通知公告", businessType = BusinessType.INSERT)
|
| | | @PostMapping
|
| | | public AjaxResult add(@Validated @RequestBody SysNotice notice)
|
| | | {
|
| | |
| | | /**
|
| | | * 修改通知公告
|
| | | */
|
| | | @PreAuthorize(hasPermi = "system:notice:edit")
|
| | | @RequiresPermissions("system:notice:edit")
|
| | | @Log(title = "通知公告", businessType = BusinessType.UPDATE)
|
| | | @PutMapping
|
| | | public AjaxResult edit(@Validated @RequestBody SysNotice notice)
|
| | |
| | | /**
|
| | | * 删除通知公告
|
| | | */
|
| | | @PreAuthorize(hasPermi = "system:notice:remove")
|
| | | @RequiresPermissions("system:notice:remove")
|
| | | @Log(title = "通知公告", businessType = BusinessType.DELETE)
|
| | | @DeleteMapping("/{noticeIds}")
|
| | | public AjaxResult remove(@PathVariable Long[] noticeIds)
|