Форматирование
This commit is contained in:
@@ -36,6 +36,9 @@ class FormattedPatientResource extends JsonResource
|
||||
'outcome_type' => $this->outcomeType,
|
||||
'outcome_date' => $this->outcomeDate,
|
||||
'comment' => $this->comment,
|
||||
'reanimation_indicator' => $this->reanimation_indicator ?? null,
|
||||
'reanimation_comment' => $this->reanimation_comment ?? null,
|
||||
'reanimation_is_complete' => $this->reanimationIsComplete,
|
||||
'is_recipient_today' => $this->isRecipientToday,
|
||||
'is_manual' => $this->isManual,
|
||||
'can_manage_manual' => $this->canManageManual,
|
||||
@@ -46,7 +49,7 @@ class FormattedPatientResource extends JsonResource
|
||||
'id' => $this->MedicalHistoryID,
|
||||
'mkb' => [
|
||||
'ds' => $this->outcomeMigration->first()->mainDiagnosis?->mkb?->DS,
|
||||
'name' => $this->outcomeMigration->first()->mainDiagnosis?->mkb?->NAME
|
||||
'name' => $this->outcomeMigration->first()->mainDiagnosis?->mkb?->NAME,
|
||||
],
|
||||
'operations' => $this->surgicalOperations->map(function ($operation) {
|
||||
return [
|
||||
@@ -61,6 +64,9 @@ class FormattedPatientResource extends JsonResource
|
||||
'outcome_type' => $this->when($this->outcome_type, $this->outcome_type),
|
||||
'outcome_date' => $this->when($this->outcome_date, $this->outcome_date),
|
||||
'comment' => $this->when($this->comment, $this->comment),
|
||||
'reanimation_indicator' => $this->when($this->reanimation_indicator, $this->reanimation_indicator),
|
||||
'reanimation_comment' => $this->when($this->reanimation_comment, $this->reanimation_comment),
|
||||
'reanimation_is_complete' => (bool) ($this->reanimation_is_complete ?? false),
|
||||
'is_recipient_today' => (bool) ($this->is_recipient_today ?? false),
|
||||
'is_manual' => false,
|
||||
'can_manage_manual' => false,
|
||||
|
||||
Reference in New Issue
Block a user