This commit is contained in:
BLRTTX 2024-12-18 12:04:04 +08:00
parent d81742c873
commit d618f890a0
4 changed files with 43 additions and 7 deletions

View File

@ -4,13 +4,11 @@ import com.atjy.common.result.Result;
import com.atjy.web.app.service.AppointmentInfoService;
import com.atjy.web.app.vo.appointment.AppointmentInfoVo;
import com.atjy.web.app.vo.appointment.AppointmentOrderVo;
import com.atjy.web.app.vo.appointment.AppointmentSetOrderVo;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.bind.annotation.*;
@Tag(name = "预约信息")
@RestController
@ -29,6 +27,13 @@ public class Appointment {
@Operation(summary = "获取预约订单")
@PostMapping("getAppointmentOrderByIdAndTime")
public Result<AppointmentOrderVo> getAppointmentOrderByIdAndTime(@RequestParam Long id, @RequestParam String date) {
return Result.ok(service.getAppointmentOrderByIdAndTime(id,date));
return Result.ok(service.getAppointmentOrderByIdAndTime(id, date));
}
@Operation(summary = "生成预约订单")
@PostMapping("setAppointmentOrder")
public Result<AppointmentOrderVo> setAppointmentOrder(@RequestBody AppointmentSetOrderVo appointmentSetOrderVo) {
service.setAppointmentOrder(appointmentSetOrderVo);
return null;
}
}

View File

@ -4,10 +4,13 @@ import com.atjy.common.result.Result;
import com.atjy.model.entity.AppointmentInfo;
import com.atjy.web.app.vo.appointment.AppointmentInfoVo;
import com.atjy.web.app.vo.appointment.AppointmentOrderVo;
import com.atjy.web.app.vo.appointment.AppointmentSetOrderVo;
import com.baomidou.mybatisplus.extension.service.IService;
public interface AppointmentInfoService extends IService<AppointmentInfo> {
AppointmentInfoVo getAppointmentByIdAndTime(Long id, String date);
AppointmentOrderVo getAppointmentOrderByIdAndTime(Long id, String date);
void setAppointmentOrder(AppointmentSetOrderVo appointmentSetOrderVo);
}

View File

@ -1,13 +1,12 @@
package com.atjy.web.app.service.impl;
import com.atjy.common.login.LoginUser;
import com.atjy.common.login.LoginUserHolder;
import com.atjy.model.entity.*;
import com.atjy.web.app.controller.appointment.Appointment;
import com.atjy.web.app.mapper.*;
import com.atjy.web.app.service.AppointmentInfoService;
import com.atjy.web.app.vo.appointment.AppointmentInfoVo;
import com.atjy.web.app.vo.appointment.AppointmentOrderVo;
import com.atjy.web.app.vo.appointment.AppointmentSetOrderVo;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
@ -84,4 +83,9 @@ public class AppointmentInfoServiceImpl extends ServiceImpl<AppointmentInfoMappe
return appointmentOrderVo;
}
@Override
public void setAppointmentOrder(AppointmentSetOrderVo appointmentSetOrderVo) {
// todo
}
}

View File

@ -0,0 +1,24 @@
package com.atjy.web.app.vo.appointment;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
@Data
@Schema(description = "接收预约信息实体")
public class AppointmentSetOrderVo {
@Schema(description = "医生id")
private Long id;
@Schema(description = "预约日期")
private String appointmentDate;
@Schema(description = "就诊人姓名")
private String name;
@Schema(description = "就诊人手机号")
private String phone;
@Schema(description = "备注")
private String memo;
}