layout and clean activity reason crud

This commit is contained in:
2015-10-02 13:57:23 +02:00
parent 0bee5e46db
commit bebee4fbeb
8 changed files with 46 additions and 89 deletions

View File

@@ -17,16 +17,19 @@
{% extends "ChillActivityBundle::Admin/layout_activity.html.twig" %}
{% block admin_content %}
<h1>ActivityReasonCategory edit</h1>
<h1>{{ 'ActivityReasonCategory edit'|trans }}</h1>
{{ form(edit_form) }}
{{ form_start(edit_form) }}
{{ form_row(edit_form.name) }}
{{ form_row(edit_form.active) }}
{{ form_row(edit_form.submit, { 'attr': { 'class': 'sc-button orange' } } ) }}
{{ form_end(edit_form) }}
<ul class="record_actions">
<li>
<a href="{{ path('chill_activity_activityreasoncategory') }}">
Back to the list
{{ 'Back to the list'|trans }}
</a>
</li>
<li>{{ form(delete_form) }}</li>
</ul>
{% endblock %}

View File

@@ -17,40 +17,28 @@
{% extends "ChillActivityBundle::Admin/layout_activity.html.twig" %}
{% block admin_content %}
<h1>ActivityReasonCategory list</h1>
<h1>{{ 'ActivityReasonCategory list'|trans }}</h1>
<table class="records_list">
<thead>
<tr>
<th>{{ 'Name'|trans }}</th>
<th>{{ 'Active'|trans }}Active</th>
<th>{{ 'Actions'|trans }}</th>
</tr>
</thead>
<tbody>
{% for entity in entities %}
<tr>
<td><a href="{{ path('chill_activity_activityreasoncategory_show', { 'id': entity.id }) }}">{{ entity.name|localize_translatable_string }}</a></td>
<td>
<a href="{{ path('chill_activity_activityreasoncategory_show', { 'id': entity.id }) }}">
{{ entity.name|localize_translatable_string }}
</a>
</td>
<td>
{% if entity.active %}
<p>{{ 'Active'|trans }}</p>
{% else %}
<p>{{ "Inactive"|trans }}</p>
{% endif %}
</td>
<td>
<ul>
<li>
<a href="{{ path('chill_activity_activityreasoncategory_show', { 'id': entity.id }) }}">{{'show'|trans}}</a>
</li>
<li>
<a href="{{ path('chill_activity_activityreasoncategory_edit', { 'id': entity.id }) }}">{{'edit'|trans}}</a>
</li>
</ul>
<ul>
<li>
<a href="{{ path('chill_activity_activityreasoncategory_show', { 'id': entity.id }) }}">{{ 'show'|trans }}</a>
</li>
<li>
<a href="{{ path('chill_activity_activityreasoncategory_edit', { 'id': entity.id }) }}">{{ 'edit'|trans }}</a>
</li>
</ul>
</td>
</tr>
{% endfor %}
@@ -60,7 +48,7 @@
<ul>
<li>
<a href="{{ path('chill_activity_activityreasoncategory_new') }}">
{{'Create a new entry'|trans}}
{{ 'Create a new activity category reason'|trans }}
</a>
</li>
</ul>

View File

@@ -17,14 +17,18 @@
{% extends "ChillActivityBundle::Admin/layout_activity.html.twig" %}
{% block admin_content %}
<h1>ActivityReasonCategory creation</h1>
<h1>{{ 'ActivityReasonCategory creation'|trans }}</h1>
{{ form(form) }}
{{ form_start(form) }}
{{ form_row(form.name) }}
{{ form_row(form.active) }}
{{ form_widget(form.submit, { 'attr': { 'class' : 'sc-button blue' } } ) }}
<p>{{ form_end(form) }}</p>
<ul class="record_actions">
<li>
<a href="{{ path('chill_activity_activityreasoncategory') }}">
Back to the list
{{ 'Back to the list'|trans }}
</a>
</li>
</ul>

View File

@@ -17,7 +17,7 @@
{% extends "ChillActivityBundle::Admin/layout_activity.html.twig" %}
{% block admin_content %}
<h1>ActivityReasonCategory</h1>
<h1>{{ 'ActivityReasonCategory'|trans }}</h1>
<table class="record_properties">
<tbody>
@@ -28,11 +28,11 @@
<tr>
<th>{{ 'Active'|trans }}</th>
<td>
{% if entity.active %}
<p>{{ 'The entity is active and will be proposed'|trans }}</p>
{% else %}
<p>{{ "The entity is inactive and won't be proposed"|trans }}</p>
{% endif %}
{%- if entity.active -%}
{{ 'ActivityReasonCategory is active and will be proposed'|trans }}
{%- else -%}
{{ "ActivityReasonCategory is inactive and won't be proposed"|trans }}
{%- endif -%}
</td>
</tr>
</tbody>
@@ -41,14 +41,13 @@
<ul class="record_actions">
<li>
<a href="{{ path('chill_activity_activityreasoncategory') }}">
Back to the list
{{ 'Back to the list'|trans }}
</a>
</li>
<li>
<a href="{{ path('chill_activity_activityreasoncategory_edit', { 'id': entity.id }) }}">
Edit
{{ 'Edit'|trans }}
</a>
</li>
<li>{{ form(delete_form) }}</li>
</ul>
{% endblock %}