| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354 |
- package cn.com.goldenwater.dcproj.controller.fjwtenf;
- import cn.com.goldenwater.core.web.BaseController;
- import cn.com.goldenwater.core.web.BaseResponse;
- import cn.com.goldenwater.dcproj.model.BisInspFjwtenfKey;
- import cn.com.goldenwater.dcproj.service.BisInspFjwtenfKeyService;
- import io.swagger.annotations.Api;
- import io.swagger.annotations.ApiOperation;
- import io.swagger.annotations.ApiParam;
- import org.apache.commons.lang3.StringUtils;
- import org.springframework.beans.factory.annotation.Autowired;
- import org.springframework.web.bind.annotation.*;
- /**
- * @author lhc
- * @date 2021-10-9
- */
- @Api(value = "福建县水行政执法监督检查-监督工作要点管理", tags = "福建县水行政执法监督检查-监督工作要点管理")
- @RestController
- @RequestMapping("/bis/insp/fjwtenf/key")
- public class BisInspFjwtenfKeyController extends BaseController {
- @Autowired
- private BisInspFjwtenfKeyService bisInspFjwtenfKeyService;
- @ApiOperation(value = "修改福建县水行政执法监督检查-监督工作要点")
- @RequestMapping(value = "", method = RequestMethod.POST)
- public BaseResponse<BisInspFjwtenfKey> insert(@ApiParam(name = "bisInspFjwtenfKey", value = "BisInspFjwtenfKey", required = true)
- @RequestBody BisInspFjwtenfKey bisInspFjwtenfKey) {
- int ret = 0;
- if (StringUtils.isBlank(bisInspFjwtenfKey.getId())) {
- ret = bisInspFjwtenfKeyService.insert(bisInspFjwtenfKey);
- } else {
- ret = bisInspFjwtenfKeyService.update(bisInspFjwtenfKey);
- }
- return buildSuccessResponse(bisInspFjwtenfKey);
- }
- @ApiOperation(value = "根据ID删除福建县水行政执法监督检查-监督工作要点")
- @RequestMapping(value = "delete/{id}", method = RequestMethod.POST)
- public BaseResponse delete(@ApiParam(name = "id", value = "id", required = true) @PathVariable String id) {
- int ret = bisInspFjwtenfKeyService.delete(id);
- return buildSuccessResponse();
- }
- @ApiOperation(value = "根据ID获取福建县水行政执法监督检查-监督工作要点(单表)")
- @RequestMapping(value = "/{id}", method = RequestMethod.GET)
- public BaseResponse<BisInspFjwtenfKey> get(@ApiParam(name = "id", value = "id", required = true) @PathVariable String id) {
- BisInspFjwtenfKey bisInspFjwtenfKey = bisInspFjwtenfKeyService.get(id);
- return buildSuccessResponse(bisInspFjwtenfKey);
- }
- }
|