Merge pull request #24421 from cpennington/ora2-dates
AA-223 - Add ORA2 dates to the dates page
This commit is contained in:
@@ -41,10 +41,20 @@ class TestIcsGeneration(TestCase):
|
||||
|
||||
def make_assigment(
|
||||
self, block_key=None, title=None, url=None, date=None, contains_gated_content=False, complete=False,
|
||||
past_due=False, assignment_type=None
|
||||
past_due=False, assignment_type=None, extra_info=None
|
||||
):
|
||||
""" Bundles given info into a namedtupled like get_course_assignments returns """
|
||||
return _Assignment(block_key, title, url, date, contains_gated_content, complete, past_due, assignment_type)
|
||||
return _Assignment(
|
||||
block_key,
|
||||
title,
|
||||
url,
|
||||
date,
|
||||
contains_gated_content,
|
||||
complete,
|
||||
past_due,
|
||||
assignment_type,
|
||||
extra_info
|
||||
)
|
||||
|
||||
def expected_ics(self, *assignments):
|
||||
""" Returns hardcoded expected ics strings for given assignments """
|
||||
|
||||
@@ -41,10 +41,11 @@ class ContentTypeGateTransformer(BlockStructureTransformer):
|
||||
inside of it is content gated. `contains_gated_content` can then be used to indicate something
|
||||
in the blocks subtree is gated.
|
||||
"""
|
||||
if block_structure.get_xblock_field(block_key, 'contains_gated_content'):
|
||||
return
|
||||
block_structure.override_xblock_field(block_key, 'contains_gated_content', True)
|
||||
|
||||
for parent_block_key in block_structure.get_parents(block_key):
|
||||
if block_structure.get_xblock_field(parent_block_key, 'contains_gated_content'):
|
||||
continue
|
||||
block_structure.override_xblock_field(parent_block_key, 'contains_gated_content', True)
|
||||
self._set_contains_gated_content_on_parents(block_structure, parent_block_key)
|
||||
|
||||
def transform(self, usage_info, block_structure):
|
||||
|
||||
@@ -21,6 +21,9 @@ from django.utils.translation import ugettext as _
|
||||
% if course_date.description:
|
||||
<p class="description">${course_date.description}</p>
|
||||
% endif
|
||||
% if course_date.extra_info:
|
||||
<div class="extra-info">${course_date.extra_info}</div>
|
||||
% endif
|
||||
% if course_date.link and course_date.link_text:
|
||||
<div class="date-summary-link">
|
||||
<a href="${course_date.link}">${course_date.link_text}</a>
|
||||
|
||||
Reference in New Issue
Block a user