Add statistics route, permissions, and sidebar entry
- /statistics route and PagePaths.statistics - Permission sets: viewer and admin can access /statistics - Sidebar link with can_access_page check - Plug and sidebar tests updated
This commit is contained in:
parent
fd10fe5cf6
commit
919a8e4ebd
7 changed files with 61 additions and 6 deletions
|
|
@ -9,6 +9,7 @@ defmodule MvWeb.PagePaths do
|
|||
# Sidebar top-level menu paths
|
||||
@members "/members"
|
||||
@membership_fee_types "/membership_fee_types"
|
||||
@statistics "/statistics"
|
||||
|
||||
# Administration submenu paths (all must match router)
|
||||
@users "/users"
|
||||
|
|
@ -31,6 +32,9 @@ defmodule MvWeb.PagePaths do
|
|||
@doc "Path for Membership Fee Types index (sidebar and page permission check)."
|
||||
def membership_fee_types, do: @membership_fee_types
|
||||
|
||||
@doc "Path for Statistics page (sidebar and page permission check)."
|
||||
def statistics, do: @statistics
|
||||
|
||||
@doc "Paths for Administration menu; show group if user can access any of these."
|
||||
def admin_menu_paths, do: @admin_page_paths
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue