This commit is contained in:
Your Name
2026-04-21 18:02:27 +08:00
parent a1d2ab4649
commit d899e0fe0a
301 changed files with 1937 additions and 344 deletions
@@ -9,7 +9,9 @@ use app\common\service\doctor\RosterSegmentService;
use app\common\model\tcm\Diagnosis;
use app\common\model\auth\Admin;
use app\api\logic\ChatNotifyLogic;
use app\adminapi\logic\tcm\PrescriptionLogic;
use think\facade\Db;
use think\facade\Log;
/**
* 医生预约逻辑
@@ -429,6 +431,13 @@ class AppointmentLogic extends BaseLogic
\think\facade\Log::warning('面诊结束通知医助失败: ' . $e->getMessage());
}
// 完成就诊后系统代开处方(无药材、标记 is_system_auto;失败不影响「完成」成功)
try {
PrescriptionLogic::createSystemAutoFromCompletedAppointment((int) $appointment->id);
} catch (\Throwable $e) {
Log::warning('完成挂号后系统代开处方失败: ' . $e->getMessage());
}
return true;
} catch (\Exception $e) {
self::setError($e->getMessage());