https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41674

            Bug ID: 41674
           Summary: Add template plugin for linking to system preferences
                    based on user permission
   Initiative type: ---
        Sponsorship ---
            status:
           Product: Koha
           Version: Main
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P5 - low
         Component: Architecture, internals, and plumbing
          Assignee: [email protected]
          Reporter: [email protected]
        QA Contact: [email protected]

There are many places in templates where we link to a system preference and we
are inconsistent about whether these links are dependent on the permission of
the logged-in user. I propose to add a template plugin which handles the
permission check.

[% "RequireChoosingExistingAuthority" | html | $LinkPref %]

For a user with 'CAN_user_parameters_manage_sysprefs' permission it outputs:

<a class="link_preference"
href="admin/preferences.pl?op=search&amp;ok=Search&amp;searchfield=RequireChoosingExistingAuthority">RequireChoosingExistingAuthority</a>

For a user without permission it outputs:

<span class="link_preference">RequireChoosingExistingAuthority</span>

-- 
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[email protected]
https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to