03bf8dea3727d5037aaafd4f2ac768ab91ccb487.svn-base 6.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118
  1. package cn.com.goldenwater.dcproj.controller.pblm;
  2. import cn.com.goldenwater.core.web.BaseController;
  3. import cn.com.goldenwater.core.web.BaseResponse;
  4. import cn.com.goldenwater.dcproj.model.*;
  5. import cn.com.goldenwater.dcproj.param.*;
  6. import cn.com.goldenwater.dcproj.service.GwPblmShrService;
  7. import com.github.pagehelper.PageHelper;
  8. import com.github.pagehelper.PageInfo;
  9. import io.swagger.annotations.Api;
  10. import io.swagger.annotations.ApiOperation;
  11. import io.swagger.annotations.ApiParam;
  12. import org.slf4j.Logger;
  13. import org.slf4j.LoggerFactory;
  14. import org.springframework.web.bind.annotation.*;
  15. import javax.annotation.Resource;
  16. import java.util.List;
  17. @Api(value = "督查问题共享", tags = "督查问题共享")
  18. @RestController
  19. @RequestMapping("/gw/pblm/shr")
  20. public class GwPblmShrController extends BaseController {
  21. private Logger logger = LoggerFactory.getLogger(getClass());
  22. @Resource
  23. private GwPblmShrService gwPblmShrService;
  24. @ApiOperation(value = "查询共享整改问题")
  25. @RequestMapping(value = "/selectGwPblmShrByCondition", method = RequestMethod.POST)
  26. public BaseResponse selectGwPblmShrByCondition(@ApiParam(name = "gwPblmShrParam", value = "gwPblmShrParam", required = true)
  27. @RequestBody GwPblmShrParam gwPblmShrParam) {
  28. List<GwPblmShr> dataList = gwPblmShrService.selectGwPblmShrByCondition(gwPblmShrParam);
  29. PageHelper.startPage(gwPblmShrParam);// 分页
  30. PageInfo<GwPblmShr> pageInfo = new PageInfo(dataList);
  31. return buildSuccessResponse(pageInfo);
  32. }
  33. @ApiOperation(value = "查询问题附件")
  34. @RequestMapping(value = "/selectGwPblmShrFileByCondition", method = RequestMethod.POST)
  35. public BaseResponse selectGwPblmShrFileByCondition(@ApiParam(name = "gwPblmShrFileParam", value = "gwPblmShrFileParam", required = true)
  36. @RequestBody GwPblmShrFileParam gwPblmShrFileParam) {
  37. List<GwPblmShrFile> dataList = gwPblmShrService.selectGwPblmShrFileByCondition(gwPblmShrFileParam);
  38. PageHelper.startPage(gwPblmShrFileParam);// 分页
  39. PageInfo<GwPblmShrFile> pageInfo = new PageInfo(dataList);
  40. return buildSuccessResponse(pageInfo);
  41. }
  42. @ApiOperation(value = "查询问题反馈")
  43. @RequestMapping(value = "/selectGwPblmRectByCondition", method = RequestMethod.POST)
  44. public BaseResponse selectGwPblmRectByCondition(@ApiParam(name = "gwPblmRectParam", value = "gwPblmRectParam", required = true)
  45. @RequestBody GwPblmRectParam gwPblmRectParam) {
  46. List<GwPblmRect> dataList = gwPblmShrService.selectGwPblmRectByCondition(gwPblmRectParam);
  47. PageHelper.startPage(gwPblmRectParam);// 分页
  48. PageInfo<GwPblmRect> pageInfo = new PageInfo(dataList);
  49. return buildSuccessResponse(pageInfo);
  50. }
  51. @ApiOperation(value = "查询反馈问题过程记录")
  52. @RequestMapping(value = "/selectGwPblmRectRecordByCondition", method = RequestMethod.POST)
  53. public BaseResponse selectGwPblmRectRecordByCondition(@ApiParam(name = "gwPblmRectRecordParam", value = "gwPblmRectRecordParam", required = true)
  54. @RequestBody GwPblmRectRecordParam gwPblmRectRecordParam) {
  55. List<GwPblmRectRecord> dataList = gwPblmShrService.selectGwPblmRectRecordByCondition(gwPblmRectRecordParam);
  56. PageHelper.startPage(gwPblmRectRecordParam);// 分页
  57. PageInfo<GwPblmRectRecord> pageInfo = new PageInfo(dataList);
  58. return buildSuccessResponse(pageInfo);
  59. }
  60. @ApiOperation(value = "查询问题反馈附件")
  61. @RequestMapping(value = "/selectGwPblmRectFileByCondition", method = RequestMethod.POST)
  62. public BaseResponse selectGwPblmRectFileByCondition(@ApiParam(name = "gwPblmRectFileParam", value = "gwPblmRectFileParam", required = true)
  63. @RequestBody GwPblmRectFileParam gwPblmRectFileParam) {
  64. List<GwPblmRectFile> dataList = gwPblmShrService.selectGwPblmRectFileByCondition(gwPblmRectFileParam);
  65. PageHelper.startPage(gwPblmRectFileParam);// 分页
  66. PageInfo<GwPblmRectFile> pageInfo = new PageInfo(dataList);
  67. return buildSuccessResponse(pageInfo);
  68. }
  69. @ApiOperation(value = "根据ID获取共享整改问题")
  70. @RequestMapping(value = "/getGwPblmShr/{id}", method = RequestMethod.GET)
  71. public BaseResponse<GwPblmShr> getGwPblmShr(@ApiParam(name = "id", value = "id", required = true) @PathVariable String id) {
  72. GwPblmShr gwPblmShr = gwPblmShrService.getGwPblmShr(id);
  73. return buildSuccessResponse(gwPblmShr);
  74. }
  75. @ApiOperation(value = "根据ID获取问题附件")
  76. @RequestMapping(value = "/getGwPblmShrFile/{id}", method = RequestMethod.GET)
  77. public BaseResponse<List<GwPblmShrFile>> getGwPblmShrFile(@ApiParam(name = "id", value = "id", required = true) @PathVariable String id) {
  78. List<GwPblmShrFile> gwPblmShrFiles = gwPblmShrService.getGwPblmShrFile(id);
  79. return buildSuccessResponse(gwPblmShrFiles);
  80. }
  81. @ApiOperation(value = "根据ID获取问题反馈")
  82. @RequestMapping(value = "/getGwPblmRect/{id}", method = RequestMethod.GET)
  83. public BaseResponse<GwPblmRect> getGwPblmRect(@ApiParam(name = "id", value = "id", required = true) @PathVariable String id) {
  84. GwPblmRect gwPblmRect = gwPblmShrService.getGwPblmRect(id);
  85. return buildSuccessResponse(gwPblmRect);
  86. }
  87. @ApiOperation(value = "根据ID获取反馈问题过程记录")
  88. @RequestMapping(value = "/getGwPblmRectRecord/{id}", method = RequestMethod.GET)
  89. public BaseResponse<List<GwPblmRectRecord>> getGwPblmRectRecord(@ApiParam(name = "id", value = "id", required = true) @PathVariable String id) {
  90. // 根据问题反馈ID,查找问题
  91. GwPblmRect vo = gwPblmShrService.getGwPblmRectById(id);
  92. List<GwPblmRectRecord> gwPblmRectRecords = gwPblmShrService.getGwPblmRectRecord(vo.getPblmId());
  93. return buildSuccessResponse(gwPblmRectRecords);
  94. }
  95. @ApiOperation(value = "根据ID获取问题反馈附件")
  96. @RequestMapping(value = "/getGwPblmRectFile/{id}", method = RequestMethod.GET)
  97. public BaseResponse<List<GwPblmRectFile>> getGwPblmRectFile(@ApiParam(name = "id", value = "id", required = true) @PathVariable String id) {
  98. // 根据问题反馈ID,查找问题
  99. GwPblmRect vo = gwPblmShrService.getGwPblmRectById(id);
  100. List<GwPblmRectFile> gwPblmRectFiles = gwPblmShrService.getGwPblmRectFile(vo.getPblmId());
  101. return buildSuccessResponse(gwPblmRectFiles);
  102. }
  103. }