yz
2021-02-19 e0d74a95d51fe3182f0205007ee0a39f37e58886
febs-server/febs-server-hr/src/main/java/cc/mrbird/febs/server/hr/controller/EmpPhysicalExamController.java
@@ -6,6 +6,8 @@
import cc.mrbird.febs.common.core.entity.QueryRequest;
import cc.mrbird.febs.common.core.exception.FebsException;
import cc.mrbird.febs.common.core.utils.FebsUtil;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import lombok.RequiredArgsConstructor;
import org.springframework.security.access.prepost.PreAuthorize;
@@ -13,6 +15,7 @@
import org.springframework.web.bind.annotation.*;
import javax.validation.Valid;
import javax.validation.constraints.NotBlank;
import java.util.Map;
/**
@@ -24,6 +27,7 @@
 * @date 2021-01-31 09:11:00
 * @since JDK1.8
 */
@Api(tags = "人员体检信息录入接口")
@Slf4j
@Validated
@RestController
@@ -93,4 +97,17 @@
            throw new FebsException(message);
        }
    }
    @ApiOperation(value = "体检信息提交")
    @DeleteMapping("toNormal/{ids}")
    @PreAuthorize("hasAuthority('empPhysicalexam:delete')")
    public void momentToNormal(@NotBlank(message = "{required}")  @PathVariable("ids") String ids) throws FebsException {
        try {
            this.empPhysicalExamService.momentToNormal(ids);
        } catch (Exception e) {
            String message = "体检信息提交失败";
            log.error(message, e);
            throw new FebsException(message);
        }
    }
}