colors for visual grouping of customer, projects and activities (#751)

This commit is contained in:
Kevin Papst
2019-05-04 01:45:52 +02:00
committed by GitHub
parent e92c2d168e
commit 65df1ff909
40 changed files with 523 additions and 124 deletions

View File

@@ -34,19 +34,17 @@
{% for entry in entries %}
<tr{% if is_granted('edit', entry) %} class="modal-ajax-form open-edit" data-href="{{ path('admin_activity_edit', {'id': entry.id}) }}"{% endif %}>
<td>{{ entry.name }}</td>
<td>{{ widgets.label_color_dot('activity', true, entry.name, null, entry.color) }}</td>
<td class="{{ tables.data_table_column_class(tableName, columns, 'customer') }}">
{% if entry.project and entry.project.customer %}
<a href="{{ path('admin_customer_edit', {'id' : entry.project.customer.id}) }}">{{ widgets.label_customer(entry.project.customer) }}</a>
{% else %}
{# GLOBAL ACTIVTITY DOES NOT HAVE A CUSTOMER #}
{# only none-global activities have a project and customer assigned #}
{{ widgets.label_customer(entry.project.customer, path('admin_customer_edit', {'id' : entry.project.customer.id})) }}
{% endif %}
</td>
<td class="{{ tables.data_table_column_class(tableName, columns, 'project') }}">
{% if entry.project %}
<a href="{{ path('admin_project_edit', {'id' : entry.project.id}) }}">{{ widgets.label_project(entry.project) }}</a>
{% else %}
{# GLOBAL ACTIVTITY DOES NOT HAVE A PROJECT #}
{# only none-global activities have a project and customer assigned #}
{{ widgets.label_project(entry.project, path('admin_project_edit', {'id' : entry.project.id})) }}
{% endif %}
</td>
<td class="{{ tables.data_table_column_class(tableName, columns, 'comment') }}">{{ entry.comment }}</td>