diff --git a/templates/components/empty_state.html b/templates/components/empty_state.html index b0aaa038..a9d9ff5e 100644 --- a/templates/components/empty_state.html +++ b/templates/components/empty_state.html @@ -1,6 +1,6 @@ {% from "components/icon.html" import Icon %} -{% macro EmptyState(message, action_label, action_href, icon=None, sub_message=None) -%} +{% macro EmptyState(message, action_label, action_href, icon=None, sub_message=None, add_perms=True) -%}

{{ message }}

@@ -12,7 +12,7 @@

{{ sub_message }}

{% endif %} - {% if action_href and action_label %} + {% if add_perms and (action_href and action_label) %} {{ action_label }} {% endif %} diff --git a/templates/portfolios/task_orders/index.html b/templates/portfolios/task_orders/index.html index f4d62f27..15cc074b 100644 --- a/templates/portfolios/task_orders/index.html +++ b/templates/portfolios/task_orders/index.html @@ -113,6 +113,7 @@ action_label='Add a New Task Order', action_href=url_for('task_orders.edit', portfolio_id=portfolio.id), icon='cloud', + add_perms=user_can(permissions.CREATE_TASK_ORDER) ) }} {% endif %}