| | |
| | | import cn.lihu.jh.framework.common.util.date.DateUtils; |
| | | import cn.lihu.jh.module.ecg.controller.admin.devrent.vo.DevRentSaveReqVO; |
| | | import cn.lihu.jh.module.ecg.controller.admin.queue.vo.QueueSaveReqVO; |
| | | import cn.lihu.jh.module.ecg.enums.QueueStatusEnum; |
| | | import cn.lihu.jh.module.ecg.feign.RemoteDataService; |
| | | import cn.lihu.jh.module.ecg.feign.RestApiReqBodyVo; |
| | | import cn.lihu.jh.module.ecg.feign.RestApiResult; |
| | |
| | | return success(BeanUtils.toBean(appointment, AppointmentRespVO.class)); |
| | | } |
| | | |
| | | @GetMapping("/get-by-patient") |
| | | @Operation(summary = "根据患者编号.获得预约") |
| | | @Parameter(name = "id", description = "编号", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('ecg:appointment:query')") |
| | | public CommonResult<AppointmentRespVO> getAppointmentByPatient(@RequestParam("patId") String patId) { |
| | | AppointmentDO appointment = appointmentService.getAppointmentByPatId( patId ); |
| | | return success(BeanUtils.toBean(appointment, AppointmentRespVO.class)); |
| | | } |
| | | |
| | | @GetMapping("/page") |
| | | @Operation(summary = "获得预约分页") |
| | | @PreAuthorize("@ss.hasPermission('ecg:appointment:query')") |
| | |
| | | queueSaveReqVO.setBookCheckType( 10 ); |
| | | |
| | | queueSaveReqVO.setSeqNum(1); |
| | | queueSaveReqVO.setStatus((byte)10); |
| | | queueSaveReqVO.setStatus(QueueStatusEnum.WAITING.getStatus()); |
| | | queueSaveReqVO.setPassed((byte)0); |
| | | queueSaveReqVO.setExpired((byte)0); |
| | | |
| | |
| | | queueSaveReqVO.setBookCheckType(appointment.getBookCheckType()); |
| | | queueSaveReqVO.setPassed((byte) 0); |
| | | queueSaveReqVO.setExpired((byte) 0); |
| | | queueSaveReqVO.setPatDetails( appointment.getPatDeptDesc() + "-" + appointment.getPatWardDesc() + "-" + appointment.getPatBedNo()); |
| | | queueService.queue(queueSaveReqVO); |
| | | } catch (DuplicateKeyException duplicateKeyException) { |
| | | return success("您已经在排队中了"); |