Add cosmetic price field to studio & logic

- Price field added to Advanced Settings
- Function that decides which price to display
- Test added to check that the function outputs correct price
- Added feature flag and conditional to decide whether to display course price or not
- Feature Flag to show or hide course price on Course About page sidebar when not using shopping cart
This commit is contained in:
Giulio Gratta
2014-10-10 11:43:55 -07:00
parent f6d0918555
commit c18ee8cc09
5 changed files with 60 additions and 10 deletions

View File

@@ -183,6 +183,15 @@ class CourseFields(object):
default=DEFAULT_START_DATE,
scope=Scope.settings)
end = Date(help="Date that this class ends", scope=Scope.settings)
cosmetic_display_price = Integer(
display_name=_("Cosmetic Course Display Price"),
help=_(
"The cost displayed to students for enrolling in the course. If a paid course registration price is "
"set by an administrator in the database, that price will be displayed instead of this one."
),
default=0,
scope=Scope.settings,
)
advertised_start = String(
display_name=_("Course Advertised Start Date"),
help=_(