11.10采集规则+日志

dev
xiaohuo 8 months ago
parent e676262542
commit 4aedf1dc27
  1. 8
      ALOps_sys_backend/alops-admin/src/main/java/com/alops/web/controller/equManagement/EquBaseController.java
  2. 3
      ALOps_sys_backend/alops-admin/src/main/java/com/alops/web/controller/equManagement/ScheduleRulesController.java
  3. 6
      ALOps_sys_backend/alops-admin/src/main/java/com/alops/web/controller/exceptionController/AlertMessageController.java
  4. 10
      ALOps_sys_backend/alops-admin/src/main/java/com/alops/web/controller/exceptionController/AlertRuleController.java
  5. 2
      ALOps_sys_backend/alops-admin/src/main/java/com/alops/web/controller/exceptionController/equAssessment.java
  6. 2
      ALOps_sys_backend/alops-admin/src/main/java/com/alops/web/controller/message/messageController.java
  7. 1
      ALOps_sys_backend/alops-system/src/main/java/com/alops/system/job/GatherJob.java

@ -50,6 +50,7 @@ public class EquBaseController extends BaseController
@PreAuthorize("@ss.hasPermi('device:files:list')")
@GetMapping("/list")
@ApiOperation("查询多个设备信息")
@Log(title = "设备档案查询", businessType = BusinessType.OTHER)
public TableDataInfo list( EquBaseQueryDto equBase)
{
startPage();
@ -147,6 +148,7 @@ public class EquBaseController extends BaseController
@PreAuthorize("@ss.hasPermi('device:files:query1')")
@GetMapping(value = "/{id}")
@ApiOperation("查询单个设备信息")
@Log(title = "单个设备查询", businessType = BusinessType.OTHER)
public AjaxResult getInfo(@PathVariable("id") String id)
{
return success(equBaseService.selectEquBaseById(id));
@ -221,7 +223,7 @@ public class EquBaseController extends BaseController
* MultipartFile file
*/
@PreAuthorize("@ss.hasPermi('device:files:add')")
@Log(title = "设备基本信息", businessType = BusinessType.INSERT)
@Log(title = "增加设备档案信息", businessType = BusinessType.INSERT)
@PostMapping(value = "/add")
@ApiOperation("增加设备档案信息")
public AjaxResult add(@RequestBody EquBase equBase) {
@ -244,7 +246,7 @@ public class EquBaseController extends BaseController
* 修改设备基本信息
*/
@PreAuthorize("@ss.hasPermi('device:files:edit')")
@Log(title = "设备基本信息", businessType = BusinessType.UPDATE)
@Log(title = "更新设备档案基本信息", businessType = BusinessType.UPDATE)
@PutMapping("/modify")
@ApiOperation("修改设备档案信息")
public AjaxResult edit(@RequestBody EquBase equBase){
@ -263,7 +265,7 @@ public class EquBaseController extends BaseController
* 删除设备基本信息
*/
@PreAuthorize("@ss.hasPermi('device:files:remove')")
@Log(title = "设备基本信息", businessType = BusinessType.DELETE)
@Log(title = "删除设备档案基本信息", businessType = BusinessType.DELETE)
@DeleteMapping("/{ids}")
@ApiOperation("删除设备档案信息")
public AjaxResult remove(@PathVariable String[] ids)

@ -61,7 +61,7 @@ public class ScheduleRulesController extends BaseController
@PreAuthorize("@ss.hasPermi('device:deviceInformation:protoCollect')")
@PostMapping("/addRule")
@ApiOperation("立即确定")
@Log(title = "设备信息采集", businessType = BusinessType.OTHER)
public AjaxResult run(@RequestBody ScheduleRules newRule) throws SchedulerException, ExecutionException, InterruptedException {
// 先检查是否有任务正在执行
@ -99,6 +99,7 @@ public class ScheduleRulesController extends BaseController
*/
@PreAuthorize("@ss.hasPermi('equipment:rules:list')")
@GetMapping("/list")
@Log(title = "设备信息采集基本信息", businessType = BusinessType.OTHER)
public TableDataInfo list(ScheduleRules scheduleRules)
{
startPage();

@ -80,7 +80,7 @@ public class AlertMessageController extends BaseController
@PreAuthorize("@ss.hasPermi('inMonitoring:alertMessage:statistic:list')")
@GetMapping ("/statistic/list")
@ApiOperation("首页查询预警信息")
@Log(title = "查询预警信息", businessType = BusinessType.UPDATE)
@Log(title = "查询预警信息", businessType = BusinessType.OTHER)
public TableDataInfo homeList()
{
startPage();
@ -95,7 +95,7 @@ public class AlertMessageController extends BaseController
@PreAuthorize("@ss.hasPermi('inMonitoring:alertMessage:list')")
@GetMapping ("/list")
@ApiOperation("查询预警信息")
@Log(title = "查询预警信息", businessType = BusinessType.UPDATE)
@Log(title = "查询预警信息", businessType = BusinessType.OTHER)
public TableDataInfo list( AlertDto alertMessage)
{
startPage();
@ -134,7 +134,7 @@ public class AlertMessageController extends BaseController
*/
@PreAuthorize("@ss.hasPermi('inMonitoring:alertMessage:remove')")
@ApiOperation("删除预警信息")
@Log(title = "删除预警信息", businessType = BusinessType.UPDATE)
@Log(title = "删除预警信息", businessType = BusinessType.DELETE)
@DeleteMapping("/{ids}")
public AjaxResult remove(@PathVariable Long[] ids)
{

@ -50,7 +50,7 @@ public class AlertRuleController extends BaseController {
*/
@PreAuthorize("@ss.hasPermi('inMonitoring:alertRule:add')")
@ApiOperation("增加预警规则")
@Log(title = "【增加预警规则】", businessType = BusinessType.DELETE)
@Log(title = "【增加预警规则】", businessType = BusinessType.INSERT)
@PostMapping("/addRule")
public AjaxResult addRule(@RequestBody AlertRuleAddDto dto) {
try {
@ -69,7 +69,7 @@ public class AlertRuleController extends BaseController {
*/
@PreAuthorize("@ss.hasPermi('inMonitoring:alertRule:edit')")
@ApiOperation("修改预警规则")
@Log(title = "【修改预警规则】", businessType = BusinessType.DELETE)
@Log(title = "【修改预警规则】", businessType = BusinessType.UPDATE)
@PutMapping("/editRule")
public AjaxResult editRule(@RequestBody AlertRuleAddDto dto) {
try {
@ -86,7 +86,7 @@ public class AlertRuleController extends BaseController {
*/
@PreAuthorize("@ss.hasPermi('inMonitoring:alertRule:list')")
@GetMapping("/list")
@Log(title = "【查询预警规则】", businessType = BusinessType.DELETE)
@Log(title = "【查询预警规则】", businessType = BusinessType.OTHER)
@ApiOperation("查询预警规则")
public TableDataInfo list(AlertRule alertRule) {
startPage();
@ -102,7 +102,7 @@ public class AlertRuleController extends BaseController {
@PreAuthorize("@ss.hasPermi('inMonitoring:alertRule:query')")
@GetMapping(value = "/{id}")
@ApiOperation("查询预警详细规则")
@Log(title = "【查询预警详细规则】", businessType = BusinessType.DELETE)
@Log(title = "【查询预警详细规则】", businessType = BusinessType.OTHER)
public AjaxResult getInfo(@PathVariable("id") Long id) {
return success(alertRuleService.selectDetailAlertRuleById(id));
}
@ -139,7 +139,7 @@ public class AlertRuleController extends BaseController {
@ApiOperation("获取预警参数")
@PreAuthorize("@ss.hasPermi('inMonitoring:alertRule:byTable')")
@GetMapping("/byTable")
@Log(title = "【获取预警参数】", businessType = BusinessType.EXPORT)
@Log(title = "【获取预警参数】", businessType = BusinessType.OTHER)
public AjaxResult getParamsByTableName() {
return AjaxResult.success("获取预警参数成功",dictAlarmParamService.getParamsByTableName());
}

@ -30,7 +30,7 @@ public class equAssessment extends BaseController {
@PreAuthorize("@ss.hasPermi('inMonitoring:equAssessment:list')")
@GetMapping("/list")
@ApiOperation("设备评估信息")
@Log(title = "设备评估与预测", businessType = BusinessType.UPDATE)
@Log(title = "设备评估与预测", businessType = BusinessType.OTHER)
public TableDataInfo homeList()
{
startPage();

@ -64,7 +64,7 @@ public class messageController extends BaseController {
@PreAuthorize("@ss.hasPermi('message:view')")
@ApiOperation("获取用户消息列表")
@Log(title = "消息列表")
@Log(title = "消息列表", businessType = BusinessType.OTHER)
@GetMapping("/list")
public TableDataInfo getMessageList() {
startPage();

@ -43,6 +43,7 @@ public class GatherJob implements Job {
// 1.状态为5时取消调度任务
if (rule.getStatus() == 5) {
rule.setStatus(4);
scheduleRulesMapper.updateScheduleRules(rule);
Scheduler scheduler = context.getScheduler();
JobKey jobKey = context.getJobDetail().getKey();
// scheduler.deleteJob(jobKey);

Loading…
Cancel
Save