Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions microsetta_interface/templates/sample.jinja2
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

<script>
function verifyDissociateSample() {
let confirmMsg = "{{ _('Do you really want to remove this sample from this source?') }} " +
let confirmMsg = "{{ _('Do you really want to remove this sample from this profile?') }} " +
"{{ _('Doing so will remove any collection info saved for this sample and will') }} " +
"{{ _('unlink it from all surveys.') }}";
if (confirm(confirmMsg)) {
Expand Down Expand Up @@ -352,7 +352,7 @@
</div>
<div class="row">
<div class="col-12 mt-4 text-end">
{% if not sample.sample_remove_locked and not admin_mode %}
{% if not sample.sample_remove_locked %}
Copy link
Collaborator

@AmandaBirmingham AmandaBirmingham Jan 8, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wait, so before this, regular users could remove a sample from (their own) profile but admins could NOT remove a sample from a user's profile? Was there a reason for that?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The decision to previously block admins from removing samples was driven by a few factors, mostly a combination of organizational composition and a desire/plan to build out tiered administrative privileges (in contrast to the current model where someone is either a normal user or has full administrative privileges). Since then, the former has changed and the latter has been shelved indefinitely, meaning it makes sense to restore this function for the foreseeable future.

<button class="btn btn-white-red-border m-2" name="remove_button" onClick="return verifyDissociateSample();">{{ _('Remove') }}</button>
{% endif %}
{% if sample.sample_edit_locked and not admin_mode %}
Expand Down
Loading