Merge branch 'master' into ai-8-13
This commit is contained in:
@@ -94,6 +94,7 @@ class DiagnosisValidate extends BaseValidate
|
||||
|
||||
public function sceneAdd()
|
||||
{
|
||||
<<<<<<< HEAD
|
||||
// 与 sceneEdit 一样用 only() 白名单,避免全局规则里的 AI 助手 / 跟踪备注字段泄漏到新增诊单
|
||||
return $this->only([
|
||||
'patient_name', 'id_card', 'phone', 'gender', 'age', 'diagnosis_date', 'diagnosis_type',
|
||||
@@ -104,6 +105,18 @@ class DiagnosisValidate extends BaseValidate
|
||||
'remark', 'current_medications', 'status', 'show_card', 'create_source',
|
||||
'tongue_images', 'report_files',
|
||||
]);
|
||||
=======
|
||||
// 全局规则里混有跟踪备注、AI 助手字段;新增诊单只去掉这些无关校验。
|
||||
// 不要改成 only([...]):add 还会写入现病史等多选字段,only 会把它们从请求里丢掉。
|
||||
return $this->remove('id', true)
|
||||
->remove('diagnosis_id', true)
|
||||
->remove('tracking_content', true)
|
||||
->remove('task', true)
|
||||
->remove('prompt', true)
|
||||
->remove('model', true)
|
||||
->remove('report_id', true)
|
||||
->remove('content', true);
|
||||
>>>>>>> master
|
||||
}
|
||||
|
||||
public function sceneEdit()
|
||||
|
||||
Reference in New Issue
Block a user