Documentation
¶
Overview ¶
Package middleware handles authentication and access right to the app.
User is checked on every endpoint or page load to make sure the user's password has not changed, the user's account is active, and if the user's session is still active. This then extends a user's session if the user is valid so that the user is "auto logged in" to the app upon loading it.
Access rights determine what elements of the GUI the user can see and interact with as well as limits usage of certain endpoints.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Administrator ¶
Administrator checks if the user is an administrator to the app this allows for adding/removing/changing other users also allows for changing the data that shows up on the receipt
func Auth ¶
Auth checks if a user is logged in and is allowed access to the app this is done on every page load and every endpoint
func ChargeCards ¶
ChargeCards checks if the user is allowed to charge credit cards
func RemoveCards ¶
RemoveCards checks if the user is allowed to remove credit cards from the app
Types ¶
This section is empty.