Commit Graph

5 Commits

Author SHA1 Message Date
Nizar Mahmoud
4e16b92971 Documents maintenance banner setting and toggle and adds necessary unit tests 2021-02-02 23:04:53 +03:00
Régis Behmo
a16cd71046 Start waffle namespace deprecation
By explicitly importing the legacy namespace classes, we make it clear
that we are using soon-to-be-deprecated classes. We will then be able to
start removing the legacy classes, one module at a time.
2020-12-03 16:06:14 +01:00
Régis Behmo
4586002956 Import waffle classes from edx_toggles instead of waffle_utils
Those classes were ported to edx_toggles. The imports remain in
waffle_utils.__init__ for backward compatibility.
2020-11-03 19:25:37 +01:00
Feanil Patel
9cf2f9f298 Run 2to3 -f future . -w
This will remove imports from __future__ that are no longer needed.

https://docs.python.org/3.5/library/2to3.html#2to3fixer-future
2019-12-30 10:35:30 -05:00
Troy Sankey
1773107db4 Maintenance banner functionality, including a new waffle switch and setting
This adds the following new waffle switch (and namespace):

open_edx_util.display_maintenance_warning

and a new setting:

settings.MAINTENANCE_BANNER_TEXT

The provided view decorator allows developers to select which views
receive the static banner, and the banner can be globally toggled via
the waffle switch.  The text of the banner is determined by the setting,
which is currently not translated.
2018-03-20 17:54:48 -04:00