|
|
@@ -1,111 +1,127 @@
|
|
|
-{% extends 'layout-growi/base/layout.html' %}
|
|
|
+{% extends 'layout/layout.html' %}
|
|
|
+
|
|
|
+{% block html_base_css %}invited nologin{% endblock %}
|
|
|
|
|
|
{% block html_title %}Registration · {% endblock %}
|
|
|
|
|
|
-{% block content_main %}
|
|
|
|
|
|
-<h1 class="login-page">
|
|
|
- {% if config.crowi['app:title'] == 'Crowi' %}
|
|
|
- <img src="/images/logo/135x32.png" alt="Crowi">
|
|
|
- {% else %}
|
|
|
- {{ config.crowi['app:title'] }}<br>
|
|
|
- <img src="/images/logo/100x11_w.png" alt="powered by Crowi">
|
|
|
- {% endif %}
|
|
|
-</h1>
|
|
|
|
|
|
-<div class="login-dialog-container col-md-5">
|
|
|
+{#
|
|
|
+ # Remove default contents
|
|
|
+ #}
|
|
|
+ {% block html_head_loading_legacy %}
|
|
|
+ {% endblock %}
|
|
|
+ {% block html_head_loading_app %}
|
|
|
+ {% endblock %}
|
|
|
+ {% block layout_head_nav %}
|
|
|
+ {% endblock %}
|
|
|
+ {% block sidebar %}
|
|
|
+ {% endblock %}
|
|
|
|
|
|
-<div class="login-dialog" id="login-dialog">
|
|
|
|
|
|
- <div class="login-dialog-inner front">
|
|
|
- <h2>ユーザー情報入力</h2>
|
|
|
|
|
|
- <p>
|
|
|
- ようこそ!<br>
|
|
|
- はじめに、あなたのことを教えて下さい。
|
|
|
- </p>
|
|
|
+ {% block layout_main %}
|
|
|
|
|
|
- <div id="login-form-errors">
|
|
|
- {% set message = req.flash('warningMessage') %}
|
|
|
- {% if message.length %}
|
|
|
- <div class="alert alert-danger">
|
|
|
- {{ message }}
|
|
|
- </div>
|
|
|
- {% endif %}
|
|
|
-
|
|
|
- {% if req.form.errors.length > 0 %}
|
|
|
- <div class="alert alert-danger">
|
|
|
- <ul>
|
|
|
- {% for error in req.form.errors %}
|
|
|
- <li>{{ error }}</li>
|
|
|
- {% endfor %}
|
|
|
- </ul>
|
|
|
- </div>
|
|
|
- {% endif %}
|
|
|
- </div>
|
|
|
- <form role="form" id="invited-form" action="/login/activateInvited" method="post">
|
|
|
+<div class="main container-fluid">
|
|
|
|
|
|
- <label>メールアドレス</label>
|
|
|
- <div class="input-group">
|
|
|
- <span class="input-group-addon"><i class="fa fa-envelope"></i></span>
|
|
|
- <input type="text" class="form-control" disabled value="{{ user.email }}">
|
|
|
- </div>
|
|
|
- <p class="help-block">
|
|
|
- このメールアドレスで招待を受け取っています。
|
|
|
- </p>
|
|
|
+ <div class="row">
|
|
|
|
|
|
- <label>ユーザーID</label>
|
|
|
- <div class="input-group" id="input-group-username">
|
|
|
- <span class="input-group-addon"><strong>@</strong></span>
|
|
|
- <input type="text" class="form-control" placeholder="記入例: taroyama" name="invitedForm[username]" value="{{ req.body.invitedForm.username }}" required>
|
|
|
- </div>
|
|
|
- <p class="help-block">
|
|
|
- <span id="help-block-username" class="text-danger"></span>
|
|
|
- ユーザーIDは、ユーザーページのURLなどに利用されます。半角英数字と一部の記号のみ利用できます。
|
|
|
- </p>
|
|
|
+ <div class="login-header col-sm-offset-4 col-sm-4">
|
|
|
+ <div class="logo">{% include 'widget/logo.html' %}</div>
|
|
|
+ <h1>GROWI</h1>
|
|
|
|
|
|
- <label>名前</label>
|
|
|
- <div class="input-group">
|
|
|
- <span class="input-group-addon"><i class="fa fa-user"></i></span>
|
|
|
- <input type="text" class="form-control" placeholder="記入例: 山田 太郎" name="invitedForm[name]" value="{{ req.body.invitedForm.name }}" required>
|
|
|
- </div>
|
|
|
+ <div id="login-form-errors">
|
|
|
+ {% set message = req.flash('warningMessage') %}
|
|
|
+ {% if message.length %}
|
|
|
+ <div class="alert alert-danger">
|
|
|
+ {{ message }}
|
|
|
+ </div>
|
|
|
+ {% endif %}
|
|
|
|
|
|
- <label>パスワード</label>
|
|
|
- <div class="input-group">
|
|
|
- <span class="input-group-addon"><i class="fa fa-key"></i></span>
|
|
|
- <input type="password" class="form-control" placeholder="Password" name="invitedForm[password]" required>
|
|
|
+ {% if req.form.errors.length > 0 %}
|
|
|
+ <div class="alert alert-danger">
|
|
|
+ <ul>
|
|
|
+ {% for error in req.form.errors %}
|
|
|
+ <li>{{ error }}</li>
|
|
|
+ {% endfor %}
|
|
|
+ </ul>
|
|
|
+ </div>
|
|
|
+ {% endif %}
|
|
|
</div>
|
|
|
- <p class="help-block">
|
|
|
- 現在、仮パスワードでログインしています。新しいパスワードを決定してください。<br>
|
|
|
- パスワードは6文字以上の半角英数字または記号
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div class="login-dialog p-t-10 p-b-10 col-sm-offset-4 col-sm-4" id="login-dialog">
|
|
|
+ <p class="alert alert-success">
|
|
|
+ <strong>アカウントの作成</strong><br>
|
|
|
+ <small>招待を受け取ったメールアドレスでアカウントを作成します</small>
|
|
|
</p>
|
|
|
|
|
|
- <input type="hidden" name="_csrf" value="{{ csrf() }}">
|
|
|
- <input type="submit" class="btn btn-primary btn-lg btn-block" value="登録を完了">
|
|
|
- </form>
|
|
|
+ <form role="form" action="/installer/activateInvited" method="post" id="invited-form">
|
|
|
+
|
|
|
+ <div class="input-group">
|
|
|
+ <span class="input-group-addon"><i class="icon-envelope"></i></span>
|
|
|
+ <input type="text" class="form-control" disabled value="{{ user.email }}">
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div class="input-group" id="input-group-username">
|
|
|
+ <span class="input-group-addon"><i class="icon-user"></i></span>
|
|
|
+ <input type="text" class="form-control" placeholder="{{ t('User ID') }}" name="invitedForm[username]" value="{{ req.body.invitedForm.username }}" required>
|
|
|
+ </div>
|
|
|
+ <p class="help-block">
|
|
|
+ <span id="help-block-username"></span>
|
|
|
+ </p>
|
|
|
+
|
|
|
+ <div class="input-group">
|
|
|
+ <span class="input-group-addon"><i class="icon-tag"></i></span>
|
|
|
+ <input type="text" class="form-control" placeholder="{{ t('Name') }}" name="invitedForm[name]" value="{{ googleName|default(req.body.invitedForm.name) }}" required>
|
|
|
+ </div>
|
|
|
+
|
|
|
+
|
|
|
+ <div class="input-group">
|
|
|
+ <span class="input-group-addon"><i class="icon-lock"></i></span>
|
|
|
+ <input type="password" class="form-control" placeholder="{{ t('Password') }}" name="invitedForm[password]" required>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <input type="hidden" name="_csrf" value="{{ csrf() }}">
|
|
|
+ <div class="input-group m-t-30 m-b-20 d-flex justify-content-center">
|
|
|
+ <button type="submit" class="fcbtn btn btn-success btn-1b btn-register">
|
|
|
+ <span class="btn-label"><i class="icon-user-follow"></i></span>
|
|
|
+ {{ t('Create') }}
|
|
|
+ </button>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div class="input-group m-t-30 d-flex justify-content-center">
|
|
|
+ <a href="https://growi.org" class="link-growi-org">
|
|
|
+ <span class="growi">GROWI</span>.<span class="org">ORG
|
|
|
+ </a>
|
|
|
+ </div>
|
|
|
+ </form>
|
|
|
+ </div>
|
|
|
|
|
|
- <hr>
|
|
|
+ </div>{# /.row #}
|
|
|
|
|
|
- </div>
|
|
|
-</div>
|
|
|
+</div>{# /.main #}
|
|
|
|
|
|
<script>
|
|
|
$(function() {
|
|
|
$('#invited-form input[name="invitedForm[username]"]').change(function(e) {
|
|
|
var username = $(this).val();
|
|
|
+ $('#login-dialog').removeClass('has-error');
|
|
|
$('#input-group-username').removeClass('has-error');
|
|
|
$('#help-block-username').html("");
|
|
|
|
|
|
$.getJSON('/_api/check_username', {username: username}, function(json) {
|
|
|
if (!json.valid) {
|
|
|
- $('#help-block-username').html('<i class="fa fa-warning"></i>このユーザーIDは利用できません。<br>');
|
|
|
+ $('#help-block-username').html(
|
|
|
+ '<i class="icon-fw icon-ban"></i>このユーザーIDは利用できません。'
|
|
|
+ );
|
|
|
+ $('#login-dialog').addClass('has-error');
|
|
|
$('#input-group-username').addClass('has-error');
|
|
|
}
|
|
|
});
|
|
|
});
|
|
|
});
|
|
|
</script>
|
|
|
-</div>
|
|
|
|
|
|
{% endblock %}
|
|
|
|