diff --git a/portal/templates/admin/patients_by_org.html b/portal/templates/admin/patients_by_org.html index 376c83318a..01a518658f 100644 --- a/portal/templates/admin/patients_by_org.html +++ b/portal/templates/admin/patients_by_org.html @@ -32,6 +32,8 @@

{{_("Patient List")}}

{{deletedUsersFilter()}} {% endif %} + {# variable for checking if user is a researcher #} + {% set isResearcher = user.has_role(ROLE.RESEARCHER.value) and not(user.has_role(ROLE.ADMIN.value)) %} {{_("Patient List")}} data-unique-id="id" data-id-field="id" data-filter-control="true" - data-show-export="true" + {%- if not isResearcher -%} data-show-export="true" {%- endif -%} data-export-data-type="all" > {{testUsersCheckbox(postUrl=url_for('patients.patients_root'))}} diff --git a/portal/templates/admin/patients_substudy.html b/portal/templates/admin/patients_substudy.html index c4cfe7e8c6..dd43f32444 100644 --- a/portal/templates/admin/patients_substudy.html +++ b/portal/templates/admin/patients_substudy.html @@ -33,6 +33,8 @@

{{list_title}}

+ {# variable for checking if user is a researcher #} + {% set isResearcher = user.has_role(ROLE.RESEARCHER.value) and not(user.has_role(ROLE.ADMIN.value)) %}
{{list_title}} data-unique-id="id" data-id-field="id" data-filter-control="true" - data-show-export="true" + {%- if not isResearcher -%} data-show-export="true" {%- endif -%} data-export-data-type="all" > {{testUsersCheckbox(postUrl=url_for('patients.patients_substudy'))}}