mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-23 18:03:17 +00:00
101 lines
4.6 KiB
Twig
101 lines
4.6 KiB
Twig
{% extends "account/base.html.twig" %}
|
|
|
|
{% block title %}
|
|
{{ "Client application" | trans }}
|
|
{% endblock %}
|
|
|
|
{% set selected = "" %}
|
|
|
|
{% block content_account %}
|
|
<div class="row-fluid">
|
|
<div class="span12">
|
|
<h1>{{ "Application" | trans }}</h1>
|
|
<input type="hidden" value="{{ application.getId() }}" name="app_id"/>
|
|
|
|
<div>
|
|
<div><strong><a class="link" href="{{ path("developers_application", {"application" : application.getId()}) }}">{{ application.getName() }}</a></strong></div>
|
|
<div>{{ application.getDescription() }}</div>
|
|
</div>
|
|
|
|
<h1>{{ "settings OAuth" | trans }}</h1>
|
|
<p>{{ "Les parametres oauth de votre application." | trans }}</p>
|
|
|
|
<table id="app-oauth-setting" class="table table-condensed table-bordered">
|
|
<tbody>
|
|
<tr>
|
|
<td>Client ID</td>
|
|
<td>{{ application.getClientId() }}</td>
|
|
</tr>
|
|
<tr>
|
|
<td>Client Secret</td>
|
|
<td>{{ application.getClientSecret() }}</td>
|
|
</tr>
|
|
<tr>
|
|
<td>{{ "URL de callback" | trans }}</td>
|
|
{% if application.getType() == constant("DESKTOP_TYPE", application) %}
|
|
<td>
|
|
<span>{{ application.getRedirectUri() }}</span>
|
|
</td>
|
|
{% else %}
|
|
<td class="url_callback">
|
|
<span class="url_callback_input">{{ application.getRedirectUri() }}</span>
|
|
<a href="{{ path("submit_application_callback", {"application" : application.getId()}) }}" class="save_callback btn btn-small btn-info" style="display:none;">
|
|
{{ "Save" | trans }}
|
|
</a>
|
|
<button type="button" class="modifier_callback btn btn-small">
|
|
{{ "Modify" | trans }}
|
|
</button>
|
|
</td>
|
|
{%endif%}
|
|
</tr>
|
|
<tr>
|
|
<td>Authorize endpoint</td>
|
|
<td>{{ app["conf"].get("servername") }}api/oauthv2/authorize</td>
|
|
</tr>
|
|
<tr>
|
|
<td>Access endpoint</td>
|
|
<td>{{ app["conf"].get("servername") }}api/oauthv2/token</td>
|
|
</tr>
|
|
<tr>
|
|
<td>{{ "Activer le grant_type de type password pour votre application" | trans }}</td>
|
|
<td>
|
|
<input class="grant-type"
|
|
type="checkbox"
|
|
{{ application.isPasswordGranted() ? "checked='checked'" : "" }}
|
|
name="grant"
|
|
value="{{ path("submit_developers_application_authorize_grant_password", {"application" : application.getId()}) }}"
|
|
>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
|
|
<h1>{{ "Votre token d\'access" | trans }}</h1>
|
|
<p> {{ "Les paramétres oauth de votre application." | trans }}</p>
|
|
|
|
<table id="app-access-token-setting table" class="table table-condensed table-bordered">
|
|
<tbody>
|
|
<tr>
|
|
<td>
|
|
{{ "Token" | trans }}
|
|
</td>
|
|
<td>
|
|
<span id="my_access_token">
|
|
{% if not token is none %}
|
|
{{ token|default("") }}
|
|
{% else %}
|
|
{{ "Le token n\'a pas encore ete genere" | trans }}
|
|
{% endif %}
|
|
</span>
|
|
<a id="generate_access" href="{{ path("submit_developers_application_token",{ "application" : application.getId()}) }}" class="btn btn-small btn-info">{{ "boutton::generer" | trans }}</a>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
<div>
|
|
<a class="btn btn-primary" href="{{ path("developers_applications") }}">{{ "boutton::retour" | trans }}</a>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{% endblock %}
|