external-accounts.html 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131
  1. {% extends '../layout/admin.html' %}
  2. {% block html_title %}外部アカウント管理 · {% endblock %}
  3. {% block content_header %}
  4. <div class="header-wrap">
  5. <header id="page-header">
  6. <h1 class="title" id="">ユーザー管理/外部アカウント管理</h1>
  7. </header>
  8. </div>
  9. {% endblock %}
  10. {% block content_main %}
  11. <div class="content-main">
  12. {% set wmessage = req.flash('warningMessage') %}
  13. {% if wmessage.length %}
  14. <div class="alert alert-warning">
  15. {{ wmessage }}
  16. </div>
  17. {% endif %}
  18. {% set smessage = req.flash('successMessage') %}
  19. {% if smessage.length %}
  20. <div class="alert alert-success">
  21. {{ smessage }}
  22. </div>
  23. {% endif %}
  24. {% set emessage = req.flash('errorMessage') %}
  25. {% if emessage.length %}
  26. <div class="alert alert-danger">
  27. {{ emessage }}
  28. </div>
  29. {% endif %}
  30. <div class="row">
  31. <div class="col-md-3">
  32. {% include './widget/menu.html' with {current: 'external-account'} %}
  33. </div>
  34. <div class="col-md-9">
  35. <p>
  36. <a class="btn btn-default" href="/admin/users">
  37. <i class="ti-arrow-left" aria-hidden="true"></i>
  38. ユーザー管理に戻る
  39. </a>
  40. </p>
  41. <h2>外部アカウント一覧</h2>
  42. <table class="table table-hover table-striped table-bordered table-user-list">
  43. <thead>
  44. <tr>
  45. <th width="120px">Authentication Provider</th>
  46. <th><code>accountId</code></th>
  47. <th>関連付けられているユーザーの <code>username</code></th>
  48. <th>
  49. パスワード設定
  50. <a class="text-muted"
  51. data-toggle="popover" data-placement="top"
  52. data-trigger="hover focus" tabindex="0" role="button" {# dismiss settings #}
  53. data-animation="false" data-html="true"
  54. data-content="<small>関連付けられているユーザーがパスワードを設定しているかどうかを表示します</small>">
  55. <small>
  56. <i class="icon-question" aria-hidden="true"></i>
  57. </small>
  58. </a>
  59. </th>
  60. <th width="100px">作成日</th>
  61. <th width="90px">操作</th>
  62. </tr>
  63. </thead>
  64. <tbody>
  65. {% for account in accounts %}
  66. <tr>
  67. <td>{{ account.providerType }}</td>
  68. <td>
  69. <strong>{{ account.accountId }}</strong>
  70. </td>
  71. <td>
  72. <strong>{{ account.user.username }}</strong>
  73. </td>
  74. <td>
  75. {% if account.user.password != null %}
  76. <span class="label label-info">
  77. 設定済み
  78. </span>
  79. {% else %}
  80. <span class="label label-warning">
  81. 未設定
  82. </span>
  83. {% endif %}
  84. </td>
  85. <td>{{ account.createdAt|date('Y-m-d', account.createdAt.getTimezoneOffset()) }}</td>
  86. <td>
  87. <div class="btn-group admin-user-menu">
  88. <button type="button" class="btn btn-default btn-sm dropdown-toggle" data-toggle="dropdown">
  89. 編集
  90. <span class="caret"></span>
  91. </button>
  92. <ul class="dropdown-menu" role="menu">
  93. <li class="dropdown-header">編集メニュー</li>
  94. <li class="dropdown-button">
  95. <form action="/admin/users/external-accounts/{{ account.accountId }}/remove" method="post">
  96. <input type="hidden" name="_csrf" value="{{ csrf() }}">
  97. <button type="submit" class="btn btn-block btn-danger">削除する</button>
  98. </form>
  99. </li>
  100. </ul>{# end of .dropdown-menu #}
  101. </div>{# end of .btn-group #}
  102. </td>
  103. </tr>
  104. {% endfor %}
  105. </tbody>
  106. </table>
  107. {% include '../widget/pager.html' with {path: "/admin/users/external-accounts", pager: pager} %}
  108. </div>
  109. </div>
  110. </div>
  111. {% endblock content_main %}
  112. {% block content_footer %}
  113. {% endblock content_footer %}