Utils documentation

ACL

coopeV3.acl.acl_and(*perms)

Test if a user has all perms

coopeV3.acl.acl_or(*perms)

Test if a user has one of perms

coopeV3.acl.active_required(view)

Test if the site is active (preferences.models.GeneralPreferences.is_active).

coopeV3.acl.admin_required(view)

Test if the user is staff.

coopeV3.acl.self_or_has_perm(pkName, perm)

Test if the user is the request user (pk) or has perm permission.

coopeV3.acl.superuser_required(view)

Test if the user is superuser.

CoopeV3 templatetags

coopeV3.templatetags.vip.brewer()

A tag which returns preferences.models.GeneralPreferences.brewer.

coopeV3.templatetags.vip.global_message()

A tag which returns preferences.models.GeneralPreferences.global_message.

coopeV3.templatetags.vip.grocer()

A tag which returns preferences.models.GeneralPreferences.grocer.

coopeV3.templatetags.vip.logout_time()

A tag which returns preferences.models.GeneralPreferences.automatic_logout_time.

coopeV3.templatetags.vip.menu()

A tag which returns preferences.models.GeneralPreferences.menu.

coopeV3.templatetags.vip.president()

A tag which returns preferences.models.GeneralPreferences.president.

coopeV3.templatetags.vip.rules()

A tag which returns preferences.models.GeneralPreferences.rules.

coopeV3.templatetags.vip.secretary()

A tag which returns preferences.models.GeneralPreferences.secretary.

coopeV3.templatetags.vip.statutes()

A tag which returns preferences.models.GeneralPreferences.statutes.

coopeV3.templatetags.vip.treasurer()

A tag which returns preferences.models.GeneralPreferences.treasurer.

coopeV3.templatetags.vip.vice_president()

A tag which returns preferences.models.GeneralPreferences.vice_president.

Users templatetags

users.templatetags.users_extra.random_filter(a, b)