|
|
|
@ -5,9 +5,13 @@ import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
|
|
|
|
|
import com.hnac.hzims.common.logs.annotation.OperationAnnotation; |
|
|
|
|
import com.hnac.hzims.common.logs.enums.BusinessType; |
|
|
|
|
import com.hnac.hzims.common.logs.enums.OperatorType; |
|
|
|
|
import com.hnac.hzims.operational.OperationalConstants; |
|
|
|
|
import com.hnac.hzims.operational.access.dto.OperAccessStatisticsDTO; |
|
|
|
|
import com.hnac.hzims.operational.access.service.IOperAccessStatisticsService; |
|
|
|
|
import com.hnac.hzims.operational.access.vo.OperAccessStatisticsVO; |
|
|
|
|
import com.hnac.hzinfo.log.annotation.Business; |
|
|
|
|
import com.hnac.hzinfo.log.annotation.Operate; |
|
|
|
|
import com.hnac.hzinfo.log.contants.Risk; |
|
|
|
|
import io.swagger.annotations.Api; |
|
|
|
|
import io.swagger.annotations.ApiOperation; |
|
|
|
|
import io.swagger.annotations.ApiParam; |
|
|
|
@ -32,6 +36,7 @@ import javax.validation.Valid;
|
|
|
|
|
@AllArgsConstructor |
|
|
|
|
@RequestMapping("/access/statistics") |
|
|
|
|
@Api(tags = "检修台账") |
|
|
|
|
@Business(module = OperationalConstants.APP_NAME,value = "检修台账",ignore = false) |
|
|
|
|
public class OperAccessStatisticsController extends BladeController { |
|
|
|
|
|
|
|
|
|
private final IOperAccessStatisticsService service; |
|
|
|
@ -42,6 +47,7 @@ public class OperAccessStatisticsController extends BladeController {
|
|
|
|
|
@PostMapping("/remove") |
|
|
|
|
@ApiOperationSupport(order = 10) |
|
|
|
|
@ApiOperation(value = "逻辑删除") |
|
|
|
|
@Operate(label = "检修台账删除",type = com.hnac.hzinfo.log.contants.BusinessType.DELETE,risk = Risk.MEDIUM,ignore = false) |
|
|
|
|
public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) { |
|
|
|
|
return R.status(service.deleteLogic(Func.toLongList(ids))); |
|
|
|
|
} |
|
|
|
@ -52,6 +58,7 @@ public class OperAccessStatisticsController extends BladeController {
|
|
|
|
|
@PostMapping("/save") |
|
|
|
|
@ApiOperationSupport(order = 20) |
|
|
|
|
@ApiOperation(value = "新增") |
|
|
|
|
@Operate(label = "检修台账新增",type = com.hnac.hzinfo.log.contants.BusinessType.INSERT,risk = Risk.LOW,ignore = false) |
|
|
|
|
public R save(@Valid @RequestBody OperAccessStatisticsDTO req) { |
|
|
|
|
return service.doSave(req); |
|
|
|
|
} |
|
|
|
@ -62,6 +69,7 @@ public class OperAccessStatisticsController extends BladeController {
|
|
|
|
|
@PostMapping("/update") |
|
|
|
|
@ApiOperationSupport(order = 30) |
|
|
|
|
@ApiOperation(value = "修改") |
|
|
|
|
@Operate(label = "检修台账修改",type = com.hnac.hzinfo.log.contants.BusinessType.UPDATE,risk = Risk.LOW,ignore = false) |
|
|
|
|
public R update(@Valid @RequestBody OperAccessStatisticsDTO req) { |
|
|
|
|
return R.status(service.updateById(req)); |
|
|
|
|
} |
|
|
|
@ -72,6 +80,7 @@ public class OperAccessStatisticsController extends BladeController {
|
|
|
|
|
@GetMapping("/detail") |
|
|
|
|
@ApiOperationSupport(order = 40) |
|
|
|
|
@ApiOperation(value = "详情") |
|
|
|
|
@Operate(label = "检修台账详情",type = com.hnac.hzinfo.log.contants.BusinessType.QUERY,risk = Risk.LOW,ignore = false) |
|
|
|
|
public R<OperAccessStatisticsVO> detail(@RequestParam Long id) { |
|
|
|
|
return service.detail(id); |
|
|
|
|
} |
|
|
|
@ -86,6 +95,7 @@ public class OperAccessStatisticsController extends BladeController {
|
|
|
|
|
@OperationAnnotation(moduleName = "检修管理",title = "检修记录",operatorType = OperatorType.MOBILE,businessType = |
|
|
|
|
BusinessType.GENCODE, |
|
|
|
|
action = "分页查询检修记录列表") |
|
|
|
|
@Operate(label = "分页查询检修记录列表",type = com.hnac.hzinfo.log.contants.BusinessType.QUERY,risk = Risk.LOW,ignore = false) |
|
|
|
|
public R<IPage<OperAccessStatisticsVO>> list(OperAccessStatisticsDTO req, Query query) { |
|
|
|
|
return service.list(req, Condition.getPage(query)); |
|
|
|
|
} |
|
|
|
@ -96,6 +106,7 @@ public class OperAccessStatisticsController extends BladeController {
|
|
|
|
|
@ApiOperation(value = "导出Excel,查询条件参考list接口") |
|
|
|
|
@ApiOperationSupport(order = 60) |
|
|
|
|
@GetMapping(value = "/exportExcel") |
|
|
|
|
@Operate(label = "检修记录导出",type = com.hnac.hzinfo.log.contants.BusinessType.EXPORT,risk = Risk.LOW,ignore = false) |
|
|
|
|
public void exportExcel(OperAccessStatisticsDTO req) { |
|
|
|
|
service.exportExcel(req); |
|
|
|
|
} |
|
|
|
|