mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-24 10:23:17 +00:00
Fix method calls in templates
This commit is contained in:
@@ -13,12 +13,14 @@
|
|||||||
<h3>{{ "Vous avez autorise ces applications a acceder a votre compte" | trans }}</h3>
|
<h3>{{ "Vous avez autorise ces applications a acceder a votre compte" | trans }}</h3>
|
||||||
{% if applications|length > 0 %}
|
{% if applications|length > 0 %}
|
||||||
<ul class="unstyled app-list">
|
<ul class="unstyled app-list">
|
||||||
{% for application in applications %}
|
{% for data in applications if data["user-account"] is not none %}
|
||||||
|
{% set application = data["application"] %}
|
||||||
|
{% set account = data["user-account"] %}
|
||||||
<li id="app_{{ application.getId() }}">
|
<li id="app_{{ application.getId() }}">
|
||||||
<div>
|
<div>
|
||||||
{% set account = application.getAccount() %}
|
|
||||||
<a href="{{ path("grant_app_access", {"application_id" : application.getId()}) }}" class="revoke app-btn btn btn-small pull-right {% if account.is_revoked() %}hidden{% endif %}" value="{{application.getId()}}">{{ "Revoquer l\'access" | trans }}</a>
|
<a href="{{ path("grant_app_access", {"application" : application.getId()}) }}" class="revoke app-btn btn btn-small pull-right {% if account.isRevoked() %}hidden{% endif %}" value="{{application.getId()}}">{{ "Revoquer l\'access" | trans }}</a>
|
||||||
<a href="{{ path("grant_app_access", {"application_id" : application.getId()}) }}" class="authorize app-btn btn btn-small pull-right {% if not account.is_revoked() %}hidden{% endif %}" value="{{application.getId()}}">{{ "Authoriser l\'access" | trans }}</a>
|
<a href="{{ path("grant_app_access", {"application" : application.getId()}) }}" class="authorize app-btn btn btn-small pull-right {% if not account.isRevoked() %}hidden{% endif %}" value="{{application.getId()}}">{{ "Authoriser l\'access" | trans }}</a>
|
||||||
<p class="app-row">
|
<p class="app-row">
|
||||||
<a href="{{ application.getWebsite() }}" target="_blank">
|
<a href="{{ application.getWebsite() }}" target="_blank">
|
||||||
<strong>{{ application.getName() }}</strong>
|
<strong>{{ application.getName() }}</strong>
|
||||||
|
|||||||
@@ -13,7 +13,7 @@
|
|||||||
<input type="hidden" value="{{ application.getId() }}" name="app_id"/>
|
<input type="hidden" value="{{ application.getId() }}" name="app_id"/>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<div><strong><a class="link" href="{{ path("developers_application", {"id" : application.getId()}) }}">{{ application.getName() }}</a></strong></div>
|
<div><strong><a class="link" href="{{ path("developers_application", {"application" : application.getId()}) }}">{{ application.getName() }}</a></strong></div>
|
||||||
<div>{{ application.getDescription() }}</div>
|
<div>{{ application.getDescription() }}</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -32,14 +32,14 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>{{ "URL de callback" | trans }}</td>
|
<td>{{ "URL de callback" | trans }}</td>
|
||||||
{% if application.getType() == constant("Alchemy\Phrasea\Model\Entities\ApiApplication::DESKTOP_TYPE") %}
|
{% if application.getType() == constant("DESKTOP_TYPE", application) %}
|
||||||
<td>
|
<td>
|
||||||
<span>{{ application.getRedirectUri() }}</span>
|
<span>{{ application.getRedirectUri() }}</span>
|
||||||
</td>
|
</td>
|
||||||
{% else %}
|
{% else %}
|
||||||
<td class="url_callback">
|
<td class="url_callback">
|
||||||
<span class="url_callback_input">{{ application.getRedirectUri() }}</span>
|
<span class="url_callback_input">{{ application.getRedirectUri() }}</span>
|
||||||
<a href="{{ path("submit_application_callback", {"id" : application.getId()}) }}" class="save_callback btn btn-small btn-info" style="display:none;">
|
<a href="{{ path("submit_application_callback", {"application" : application.getId()}) }}" class="save_callback btn btn-small btn-info" style="display:none;">
|
||||||
{{ "Save" | trans }}
|
{{ "Save" | trans }}
|
||||||
</a>
|
</a>
|
||||||
<button type="button" class="modifier_callback btn btn-small">
|
<button type="button" class="modifier_callback btn btn-small">
|
||||||
@@ -63,7 +63,7 @@
|
|||||||
type="checkbox"
|
type="checkbox"
|
||||||
{{ application.isPasswordGranted() ? "checked='checked'" : "" }}
|
{{ application.isPasswordGranted() ? "checked='checked'" : "" }}
|
||||||
name="grant"
|
name="grant"
|
||||||
value="{{ path("submit_developers_application_authorize_grant_password", {"id" : application.getId()}) }}"
|
value="{{ path("submit_developers_application_authorize_grant_password", {"application" : application.getId()}) }}"
|
||||||
>
|
>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
@@ -87,7 +87,7 @@
|
|||||||
{{ "Le token n\'a pas encore ete genere" | trans }}
|
{{ "Le token n\'a pas encore ete genere" | trans }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</span>
|
</span>
|
||||||
<a id="generate_access" href="{{ path("submit_developers_application_token",{ "id" : application.getId()}) }}" class="btn btn-small btn-info">{{ "boutton::generer" | trans }}</a>
|
<a id="generate_access" href="{{ path("submit_developers_application_token",{ "application" : application.getId()}) }}" class="btn btn-small btn-info">{{ "boutton::generer" | trans }}</a>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</tbody>
|
</tbody>
|
||||||
|
|||||||
@@ -15,7 +15,7 @@
|
|||||||
{% if applications|length > 0 %}
|
{% if applications|length > 0 %}
|
||||||
<ul class="app-list unstyled">
|
<ul class="app-list unstyled">
|
||||||
{% for application in applications %}
|
{% for application in applications %}
|
||||||
<li id="app_{{ application.get_id() }}">
|
<li id="app_{{ application.getId() }}">
|
||||||
<a href="#appModal-{{ loop.index }}" role="button" data-toggle="modal" class="pull-right btn btn-danger btn-small" type="button">
|
<a href="#appModal-{{ loop.index }}" role="button" data-toggle="modal" class="pull-right btn btn-danger btn-small" type="button">
|
||||||
{{ "button::supprimer" | trans }}
|
{{ "button::supprimer" | trans }}
|
||||||
</a>
|
</a>
|
||||||
@@ -23,24 +23,24 @@
|
|||||||
<div id="appModal-{{ loop.index }}" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
|
<div id="appModal-{{ loop.index }}" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
|
||||||
<div class="modal-header">
|
<div class="modal-header">
|
||||||
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
|
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
|
||||||
<h3 id="myModalLabel">{{ application.get_name() }}</h3>
|
<h3 id="myModalLabel">{{ application.getName() }}</h3>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-body">
|
<div class="modal-body">
|
||||||
<p>{{ "Are you sure you want to delete this application?" | trans }} </p>
|
<p>{{ "Are you sure you want to delete this application?" | trans }} </p>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-footer">
|
<div class="modal-footer">
|
||||||
<button class="btn" data-dismiss="modal" aria-hidden="true">{{ "No" | trans }}</button>
|
<button class="btn" data-dismiss="modal" aria-hidden="true">{{ "No" | trans }}</button>
|
||||||
<a href="{{ path("delete_developers_application", {"id" : application.get_id()}) }}" class="delete-app btn btn-info">{{ "Yes" | trans }}</a>
|
<a href="{{ path("delete_developers_application", {"application" : application.getId()}) }}" class="delete-app btn btn-info">{{ "Yes" | trans }}</a>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<p class="app-row">
|
<p class="app-row">
|
||||||
<strong>
|
<strong>
|
||||||
<a class="link" href="{{ path("developers_application", {"id" : application.get_id}) }}">
|
<a class="link" href="{{ path("developers_application", {"application" : application.getId}) }}">
|
||||||
{{ application.get_name() }}
|
{{ application.getName() }}
|
||||||
</a>
|
</a>
|
||||||
</strong>
|
</strong>
|
||||||
</p>
|
</p>
|
||||||
<p class="app-row">{{ application.get_description()|truncate(120, true, "...") }}</p>
|
<p class="app-row">{{ application.getDescription()|truncate(120, true, "...") }}</p>
|
||||||
</li>
|
</li>
|
||||||
{%endfor%}
|
{%endfor%}
|
||||||
</ul>
|
</ul>
|
||||||
|
|||||||
Reference in New Issue
Block a user