mirror of
https://github.com/kevinpapst/kimai2.git
synced 2024-12-22 12:18:29 +00:00
a636683dee
* added configurable activity number * added configurable project number * fix deprecations * added some tests for entity exporter * better configuration of dropdown pattern for customer, project and activity
48 lines
1.9 KiB
Twig
48 lines
1.9 KiB
Twig
{% extends 'datatable.html.twig' %}
|
|
{% import "macros/widgets.html.twig" as widgets %}
|
|
{% import "project/actions.html.twig" as actions %}
|
|
|
|
{% block datatable_row_attr %} {{ widgets.project_row_attr(entry, now) }}{% endblock %}
|
|
|
|
{% block datatable_column_value %}
|
|
{% if column == 'name' %}
|
|
{{ widgets.label_name(entry.name, entry.color|colorize(entry.name)) }}
|
|
{% elseif column == 'customer' %}
|
|
{{ widgets.label_customer(entry.customer) }}
|
|
{% elseif column == 'comment' %}
|
|
{{ entry.comment|comment1line }}
|
|
{% elseif column == 'orderNumber' %}
|
|
{{ entry.orderNumber }}
|
|
{% elseif column == 'number' %}
|
|
{{ entry.number }}
|
|
{% elseif column == 'orderDate' %}
|
|
{% if entry.orderDate is not null %}{{ entry.orderDate|date_short }}{% endif %}
|
|
{% elseif column == 'project_start' %}
|
|
{% if entry.start is not null %}{{ entry.start|date_short }}{% endif %}
|
|
{% elseif column == 'project_end' %}
|
|
{% if entry.end is not null %}{{ entry.end|date_short }}{% endif %}
|
|
{% elseif column == 'budget' %}
|
|
{% if entry.hasBudget() and is_granted('budget', entry) %}
|
|
{{ entry.budget|money(entry.customer.currency) }}
|
|
{% else %}
|
|
–
|
|
{% endif %}
|
|
{% elseif column == 'timeBudget' %}
|
|
{% if entry.hasTimeBudget() and is_granted('time', entry) %}
|
|
{{ entry.timeBudget|duration }}
|
|
{% else %}
|
|
–
|
|
{% endif %}
|
|
{% elseif column == 'billable' %}
|
|
{{ widgets.label_boolean(entry.billable) }}
|
|
{% elseif column == 'team' %}
|
|
{{ widgets.badge_team_access(entry.teams) }}
|
|
{% elseif column == 'visible' %}
|
|
{{ widgets.label_visible(entry.visible) }}
|
|
{% elseif column == 'actions' %}
|
|
{{ actions.project(entry, 'index') }}
|
|
{% elseif column starts with 'mf_' %}
|
|
{{ widgets.meta_field_value(entry, data) }}
|
|
{% endif %}
|
|
{% endblock %}
|