39 lines
1.5 KiB
HTML
39 lines
1.5 KiB
HTML
{% extends "oauth2_provider/base.html" %}
|
|
{% load i18n %}
|
|
{% block content %}
|
|
<form method="post"
|
|
action="{% block app-form-action-url %}{% url 'oauth2_provider:update' application.id %}{% endblock app-form-action-url %}">
|
|
<h3>
|
|
{% block app-form-title %}
|
|
{% trans "Edit application" %} {{ application.name }}
|
|
{% endblock app-form-title %}
|
|
</h3>
|
|
{% csrf_token %}
|
|
<fieldset>
|
|
{% for field in form %}
|
|
<label {% if field.errors %}aria-invalid="true"{% endif %}>
|
|
{{ field.label }}
|
|
{% if field.name == 'client_secret' %}
|
|
<small><b>(please save it properly as it will NOT be editable or shown again)</b></small>
|
|
{% elif field.name == 'description' %}
|
|
<small>(markdown syntax supported)</small>
|
|
{% endif %}
|
|
{{ field }}
|
|
{% for error in field.errors %}<small>{{ error }}</small>{% endfor %}
|
|
</label>
|
|
{% endfor %}
|
|
</fieldset>
|
|
<div class="control-group {% if form.non_field_errors %}error{% endif %}">
|
|
{% for error in form.non_field_errors %}<span class="help-inline">{{ error }}</span>{% endfor %}
|
|
</div>
|
|
<div class="control-group">
|
|
<div class="controls">
|
|
<a class="btn"
|
|
href="{% block app-form-back-url %}{% url "oauth2_provider:detail" application.id %}{% endblock app-form-back-url %}">
|
|
{% trans "Go Back" %}
|
|
</a>
|
|
<button type="submit" class="btn btn-primary">{% trans "Save" %}</button>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
{% endblock %}
|