{% extends 'base.html' %}
{% import 'fomanticui.j2' as sui %}

{% block content %}
<div class="loginform">
    <h3 class="ui top attached header">
        {% trans %}Edit a client{% endtrans %}
    </h3>
    {% with messages = get_flashed_messages(with_categories=true) %}
    {% for category, message in messages %}
    <div class="ui attached message {{ category }}">
        {{ message }}
    </div>
    {% endfor %}
    {% endwith %}
    <div class="ui attached clearing segment">
        <div class="ui form">
            <form id="readonly">
                <div class="field">
                    <label>{% trans %}ID{% endtrans %}</label>
                    <input type="text" value="{{ client.oauthClientID }}" readonly name="oauthClientID">
                </div>
                <div class="field">
                    <label>{% trans %}Secret{% endtrans %}</label>
                    <input type="text" value="{{ client.oauthClientSecret }}" readonly name="oauthClientSecret">
                </div>
                <div class="field">
                    <label>{% trans %}Issued at{% endtrans %}</label>
                    <input type="text" value="{{ client.issue_date }}" readonly name="oauthIssueDate">
                </div>
            </form>
        </div>

        {{ sui.render_form(form, _("Confirm")) }}
    </div>
</div>
{% endblock %}
