package com.lantone.external.web;

import com.lantone.common.api.CommonResult;
import com.lantone.external.dto.GetLostBehospitalDTO;
import com.lantone.external.facade.BehospitalManagementFacade;
import com.lantone.external.vo.GetLostBehospitalVO;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.validation.Valid;

/**
 * @Description: 住院病历信息同步简单示例API
 * @author: rengb
 * @time: 2022/3/16 16:28
 */
@RestController
@Api(value = "住院病历信息同步简单示例API", tags = { "住院病历信息同步简单示例API" })
@RequestMapping("/behospitalManage")
public class BehospitalManagementController {

    @Autowired
    private BehospitalManagementFacade behospitalManagementFacade;

    @ApiOperation(value = "获取丢失的住院病历信息 [by:rengb]", notes = "获取丢失的住院病历信息")
    @PostMapping("/getLostBehospital")
    public CommonResult<GetLostBehospitalDTO> getLostBehospital(@RequestBody @Valid GetLostBehospitalVO getLostBehospitalVO) {
        return CommonResult.success(behospitalManagementFacade.getLostBehospital(getLostBehospitalVO));
    }

}