Skip to content

[ユーザ管理] ログイン状態のユーザーを利用不可・仮削除に変えたら、強制ログアウト#2384

Open
akagane99 wants to merge 1 commit intoopensource-workshop:masterfrom
akagane99:connect-cms-ideas/issues/185
Open

[ユーザ管理] ログイン状態のユーザーを利用不可・仮削除に変えたら、強制ログアウト#2384
akagane99 wants to merge 1 commit intoopensource-workshop:masterfrom
akagane99:connect-cms-ideas/issues/185

Conversation

@akagane99
Copy link
Contributor

概要

前述のアイデアissueの対応です。

レビュー完了希望日

急ぎません

関連Pull requests/Issues

概要に記載

参考

なし

DB変更の有無

なし

チェックリスト

Copy link
Contributor

@masaton0216 masaton0216 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ご対応ありがとうございます。
コメントレベルで「いかがでしょうか?」が1件です。

Comment on lines +968 to +970
if ($request->status == UserStatus::not_active || $request->status == UserStatus::temporary_delete) {
$update_array['is_force_logout'] = 1;
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • 一度「利用不可」にしてフラグを立てる
  • (ユーザーがまだログアウトしていない状態で)管理者が「利用可能」に戻す
  • 「利用可能に戻したのに強制ログアウトされた」と問い合わせが来る

起きうるケースとしてはかなり低めかと思いますが、下記のようなコードにしておくと、より文句は来ないかもしれません。

  if ((int)$request->status === UserStatus::not_active || (int)$request->status === UserStatus::temporary_delete) {
      $update_array['is_force_logout'] = 1;                                                                                                                      
  } else {
      $update_array['is_force_logout'] = 0;                                                                                                                      
  } 

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement 機能強化

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants