allow to restrict usage of global activities for projects (#3437)

This commit is contained in:
Kevin Papst
2022-07-23 01:17:24 +02:00
committed by GitHub
parent 8d695d03df
commit ed7f89cfe1
12 changed files with 140 additions and 11 deletions

View File

@@ -116,6 +116,14 @@
</td>
</tr>
{% endif %}
{% if not project.globalActivities %}
<tr>
<th>{{ 'label.globalActivities'|trans }}</th>
<td colspan="3">
{{ widgets.label_boolean(project.globalActivities) }}
</td>
</tr>
{% endif %}
{% for metaField in project.visibleMetaFields|sort((a, b) => a.order <=> b.order) %}
<tr>
<th>{{ metaField.label|trans }}</th>

View File

@@ -60,12 +60,15 @@
{{ form_row(form.invoiceText) }}
{% endif %}
<div class="row">
<div class="col-md-6">
<div class="col-md-4">
{{ form_row(form.visible) }}
</div>
<div class="col-md-6">
<div class="col-md-4 text-center">
{{ form_row(form.billable) }}
</div>
<div class="col-md-4 text-right">
{{ form_row(form.globalActivities) }}
</div>
</div>
{% if form.metaFields is defined and form.metaFields is not empty %}
{% for meta in form.metaFields|sort((a, b) => a.vars.data.order <=> b.vars.data.order) %}