更新
This commit is contained in:
@@ -65,4 +65,21 @@ class PrescriptionController extends BaseAdminController
|
||||
$prescription = PrescriptionLogic::getByAppointment($appointmentId);
|
||||
return $this->data($prescription ?? []);
|
||||
}
|
||||
|
||||
/**
|
||||
* @notes 作废处方
|
||||
*/
|
||||
public function void()
|
||||
{
|
||||
$id = (int)($this->request->post('id') ?? 0);
|
||||
if (!$id) {
|
||||
return $this->fail('处方ID不能为空');
|
||||
}
|
||||
$admin = $this->adminInfo;
|
||||
$ok = PrescriptionLogic::void($id, (int)$this->adminId, $admin['name'] ?? '');
|
||||
if (!$ok) {
|
||||
return $this->fail(PrescriptionLogic::getError());
|
||||
}
|
||||
return $this->success('作废成功');
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user