Fixed: Create member

This commit is contained in:
philipp lang 2021-06-23 01:58:03 +02:00
parent 50d2f31b7b
commit f07d4bb5b5
2 changed files with 3 additions and 1 deletions

View File

@ -67,7 +67,8 @@ class CreateJob implements ShouldQueue
'first_subactivity_id' => $this->member->firstSubactivity->nami_id, 'first_subactivity_id' => $this->member->firstSubactivity->nami_id,
]); ]);
Member::withoutEvents(function() use ($response) { Member::withoutEvents(function() use ($response) {
$this->member->update(['version' => $response['version']]); $version = Nami::login($this->user->mglnr)->member($this->member->group->nami_id, $response['id'])['version'];
$this->member->update(['version' => $version, 'nami_id' => $response['id']]);
}); });
} }
} }

View File

@ -26,6 +26,7 @@ class MemberResource extends JsonResource
'joined_at' => $this->joined_at->format('Y-m-d'), 'joined_at' => $this->joined_at->format('Y-m-d'),
'joined_at_human' => $this->joined_at->format('d.m.Y'), 'joined_at_human' => $this->joined_at->format('d.m.Y'),
'id' => $this->id, 'id' => $this->id,
'fee_id' => $this->fee_id,
'gender_id' => $this->gender_id, 'gender_id' => $this->gender_id,
'further_address' => $this->further_address, 'further_address' => $this->further_address,
'work_phone' => $this->work_phone, 'work_phone' => $this->work_phone,