|
@ -37,7 +37,44 @@ public class PrescriptionLogController extends BaseController {
|
|
|
public String addReply(
|
|
|
@RequestParam(required = true) @ApiParam(value = "处方code", name = "prescriptionCode") String prescriptionCode) {
|
|
|
try {
|
|
|
Integer[] types = new Integer[]{20, 30, 31,100};
|
|
|
// (-3 支付过期 -2 患者自己取消 -1 审核不通过 , 0 待审核, 2调整中 10 审核通过/开方中 , 20开方完成/待支付, 21 支付失败 , 30 支付成功/待配药 ,
|
|
|
// 40配药成功/待配送 41配送失败 42配送中 43配送到服务站 100配送到患者手中/已完成)
|
|
|
Integer[] types = new Integer[]{
|
|
|
PrescriptionLog.PrescriptionLogStatus.pay_success.getValue(),
|
|
|
PrescriptionLog.PrescriptionLogStatus.wait_expressage.getValue(),
|
|
|
PrescriptionLog.PrescriptionLogStatus.expressageing.getValue(),
|
|
|
PrescriptionLog.PrescriptionLogStatus.expressage2hospital.getValue(),
|
|
|
PrescriptionLog.PrescriptionLogStatus.finish.getValue()};
|
|
|
List<PrescriptionLog> prescriptionLogs = prescriptionLogService.findPrescriptionLogsByPrescriptionCode(prescriptionCode, types);
|
|
|
if (prescriptionLogs != null) {
|
|
|
return write(200, "获取处方流程成功", "data", prescriptionLogs);
|
|
|
} else {
|
|
|
return error(-1, "获取失败");
|
|
|
}
|
|
|
} catch (Exception e) {
|
|
|
return error(-1, "获取失败");
|
|
|
}
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* 根据处方code获取处方流程
|
|
|
*
|
|
|
* @param prescriptionCode
|
|
|
* @return
|
|
|
*/
|
|
|
@RequestMapping(value = "/orderFollow", method = RequestMethod.GET)
|
|
|
@ApiOperation(value = "订单状态跟踪")
|
|
|
public String orderFollow(
|
|
|
@RequestParam(required = true) @ApiParam(value = "处方code", name = "prescriptionCode") String prescriptionCode) {
|
|
|
try {
|
|
|
// (-3 支付过期 -2 患者自己取消 -1 审核不通过 , 0 待审核, 2调整中 10 审核通过/开方中 , 20开方完成/待支付, 21 支付失败 , 30 支付成功/待配药 ,
|
|
|
// 40配药成功/待配送 41配送失败 42配送中 43配送到服务站 100配送到患者手中/已完成)
|
|
|
Integer[] types = new Integer[]{
|
|
|
PrescriptionLog.PrescriptionLogStatus.pay_success.getValue(),
|
|
|
PrescriptionLog.PrescriptionLogStatus.wait_expressage.getValue(),
|
|
|
PrescriptionLog.PrescriptionLogStatus.expressageing.getValue(),
|
|
|
PrescriptionLog.PrescriptionLogStatus.expressage2hospital.getValue(),
|
|
|
PrescriptionLog.PrescriptionLogStatus.finish.getValue()};
|
|
|
List<PrescriptionLog> prescriptionLogs = prescriptionLogService.findPrescriptionLogsByPrescriptionCode(prescriptionCode, types);
|
|
|
if (prescriptionLogs != null) {
|
|
|
return write(200, "获取处方流程成功", "data", prescriptionLogs);
|