123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115 |
- package com.bizmatics.controller.web;
- import com.bizmatics.common.core.bean.ApiResult;
- import com.bizmatics.model.PatrolContentEntry;
- import com.bizmatics.model.vo.PatrolInspectionContentListVo;
- import com.bizmatics.model.vo.PatrolInspectionContentVo;
- import com.bizmatics.model.vo.SiteDeviceCountVo;
- import com.bizmatics.service.PatrolInspectionContentService;
- import org.springframework.beans.factory.annotation.Autowired;
- import org.springframework.web.bind.annotation.*;
- import java.util.List;
- /**
- * 巡检管理-巡检内容
- *
- * @author ya
- * @since 2021-10-16
- */
- @RestController
- @RequestMapping("/patrolInspectionContent")
- public class PatrolInspectionContentController {
- @Autowired
- private PatrolInspectionContentService patrolInspectionContentService;
- /**
- * 巡检管理-巡检内容-新增
- *
- * @param patrolInspectionContentVo
- * @return
- */
- @PostMapping("patrolInspectionContentAdd")
- public ApiResult<Void> patrolInspectionContentAdd(@RequestBody PatrolInspectionContentVo patrolInspectionContentVo
- ) {
- patrolInspectionContentService.patrolInspectionContentAdd(patrolInspectionContentVo);
- return ApiResult.success();
- }
- /**
- * 巡检管理-巡检内容-修改
- *
- * @param patrolInspectionContentVo
- * @return
- */
- @PostMapping("patrolInspectionContentUpdate")
- public ApiResult<Void> patrolInspectionContentUpdate(@RequestBody PatrolInspectionContentVo patrolInspectionContentVo
- ) {
- patrolInspectionContentService.patrolInspectionContentUpdate(patrolInspectionContentVo);
- return ApiResult.success();
- }
- /**
- * 巡检管理-巡检内容-注销
- *
- * @param id 巡检内容id
- * @return
- */
- @GetMapping("patrolInspectionContentDel")
- public ApiResult<Void> patrolInspectionContentDel(@RequestParam Integer id
- ) {
- patrolInspectionContentService.patrolInspectionContentDel(id);
- return ApiResult.success();
- }
- /**
- * 巡检管理-巡检内容-巡检设备列表
- *
- * @param inspectionContentName
- * @return
- */
- @GetMapping("patrolInspectionContentList")
- public ApiResult<List<PatrolInspectionContentListVo>> patrolInspectionContentList(@RequestParam(required = false) String inspectionContentName
- ) {
- return ApiResult.success(patrolInspectionContentService.patrolInspectionContentList(inspectionContentName));
- }
- /**
- * 巡检管理-巡检内容-巡检内容查看详情与回显
- *
- * @param id 巡检内容ID
- * @return
- */
- @GetMapping("patrolInspectionContentDetailsList")
- public ApiResult<List<PatrolInspectionContentListVo>> patrolInspectionContentDetailsList(@RequestParam Integer id
- ) {
- return ApiResult.success(patrolInspectionContentService.patrolInspectionContentDetailsList(id));
- }
- /**
- * 巡检管理-巡检内容-巡检内容检查项查询
- *
- * @param id 巡检内容ID
- * @return
- */
- @GetMapping("patrolContentEntryList")
- public ApiResult<List<PatrolContentEntry>> patrolContentEntryList(@RequestParam Integer id
- ) {
- return ApiResult.success(patrolInspectionContentService.patrolContentEntryList(id));
- }
- /**
- * 巡检管理-巡检内容-左侧站点目录
- *
- * @param siteName 站点名称
- * @return
- */
- @GetMapping("patrolInspectionContentSiteList")
- public ApiResult<List<SiteDeviceCountVo>> patrolInspectionContentSiteList(@RequestParam(required = false) String siteName
- ) {
- return ApiResult.success(patrolInspectionContentService.patrolInspectionContentSiteList(siteName));
- }
- }
|