CustomPointController.java 1.2 KB

123456789101112131415161718192021222324252627282930313233343536
  1. package com.tofly.dyrq.custom.controller;
  2. import com.tofly.common.core.entity.ResultRespone;
  3. import com.tofly.common.log.annotation.ToFlyAppLog;
  4. import com.tofly.dyrq.custom.entity.PointList;
  5. import com.tofly.dyrq.custom.entity.UpdatePoint;
  6. import com.tofly.dyrq.custom.service.CustomPointService;
  7. import io.swagger.annotations.ApiOperation;
  8. import lombok.AllArgsConstructor;
  9. import lombok.extern.slf4j.Slf4j;
  10. import org.springframework.web.bind.annotation.*;
  11. import java.util.Map;
  12. @RestController
  13. @AllArgsConstructor
  14. @Slf4j
  15. public class CustomPointController {
  16. private CustomPointService customPointService;
  17. /**
  18. * 更新点到位或线所属点的到位状态
  19. *
  20. * @param
  21. * @return
  22. */
  23. @PostMapping("updatepointorpathisover")
  24. @ApiOperation(tags="巡检计划表接口",value = "更新点到位或线所属点的到位状态")
  25. @ToFlyAppLog(title="更新点到位或线所属点的到位状态")
  26. public ResultRespone updatePointIsover(@RequestBody PointList pointList) {
  27. Map<String,Long> tempIds = customPointService.updatePointOrPathIsover(pointList.getUpdatePointList());
  28. return tempIds.size() > 0 ? ResultRespone.success(tempIds) : ResultRespone.success("更新成功");
  29. }
  30. }