Add ResyncAction for Maildispatcher when updating memberships
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
This commit is contained in:
parent
65aeb4aeaf
commit
891e4deac1
|
@ -2,6 +2,7 @@
|
|||
|
||||
namespace App\Membership\Actions;
|
||||
|
||||
use App\Maildispatcher\Actions\ResyncAction;
|
||||
use App\Member\Member;
|
||||
use App\Member\Membership;
|
||||
use App\Setting\NamiSettings;
|
||||
|
@ -16,7 +17,7 @@ class MembershipDestroyAction
|
|||
public function handle(Member $member, Membership $membership, NamiSettings $settings): void
|
||||
{
|
||||
$api = $settings->login();
|
||||
|
||||
|
||||
if ($membership->hasNami) {
|
||||
$settings->login()->deleteMembership(
|
||||
$member->nami_id,
|
||||
|
@ -39,6 +40,8 @@ class MembershipDestroyAction
|
|||
$settings,
|
||||
);
|
||||
|
||||
ResyncAction::dispatch();
|
||||
|
||||
return redirect()->back();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -4,6 +4,7 @@ namespace App\Membership\Actions;
|
|||
|
||||
use App\Activity;
|
||||
use App\Group;
|
||||
use App\Maildispatcher\Actions\ResyncAction;
|
||||
use App\Member\Member;
|
||||
use App\Member\Membership;
|
||||
use App\Setting\NamiSettings;
|
||||
|
@ -95,6 +96,8 @@ class MembershipStoreAction
|
|||
$settings,
|
||||
);
|
||||
|
||||
ResyncAction::dispatch();
|
||||
|
||||
return redirect()->back();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -3,6 +3,7 @@
|
|||
namespace App\Membership\Actions;
|
||||
|
||||
use App\Activity;
|
||||
use App\Maildispatcher\Actions\ResyncAction;
|
||||
use App\Member\Member;
|
||||
use App\Member\Membership;
|
||||
use App\Subactivity;
|
||||
|
@ -64,6 +65,8 @@ class MembershipUpdateAction
|
|||
$request->promised_at ? Carbon::parse($request->promised_at) : null,
|
||||
);
|
||||
|
||||
ResyncAction::dispatch();
|
||||
|
||||
return redirect()->back();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue