From f07d4bb5b5e3b9ab7d93828143ecb9301090b57c Mon Sep 17 00:00:00 2001 From: philipp lang Date: Wed, 23 Jun 2021 01:58:03 +0200 Subject: [PATCH] Fixed: Create member --- app/Member/CreateJob.php | 3 ++- app/Member/MemberResource.php | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/app/Member/CreateJob.php b/app/Member/CreateJob.php index b55c4f1d..79020e1d 100644 --- a/app/Member/CreateJob.php +++ b/app/Member/CreateJob.php @@ -67,7 +67,8 @@ class CreateJob implements ShouldQueue 'first_subactivity_id' => $this->member->firstSubactivity->nami_id, ]); 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']]); }); } } diff --git a/app/Member/MemberResource.php b/app/Member/MemberResource.php index 9dc9763e..1e2681f9 100644 --- a/app/Member/MemberResource.php +++ b/app/Member/MemberResource.php @@ -26,6 +26,7 @@ class MemberResource extends JsonResource 'joined_at' => $this->joined_at->format('Y-m-d'), 'joined_at_human' => $this->joined_at->format('d.m.Y'), 'id' => $this->id, + 'fee_id' => $this->fee_id, 'gender_id' => $this->gender_id, 'further_address' => $this->further_address, 'work_phone' => $this->work_phone,