Exemple #1
0
def display_people():
    '''Configure and display a list of faculty members.'''
    return display_content(
        breadcrumbs=get_breadcrumbs('people'),
        image=Images.read_tagged_unit('people'),
        title='Faculty and Staff',
        primaryList=create_people_list(People.read_units()),
        primaryListHr=True,
        editable=False
    )
Exemple #2
0
def display_honors():
    '''Display information on the honors program.'''
    department = check_unit(Departments.read_unit('cs'))
    return display_content(
        breadcrumbs=get_breadcrumbs('academics', 'honors'),
        image=Images.read_tagged_unit('academics.honors'),
        title='Graduating with Honors',
        primary=department.get('honors'),
        editable=True,
        editableUrl=url_for('web.update_department', name='cs')
    )
Exemple #3
0
def display_research():
    '''Configure and display the research overview page.'''
    department = check_unit(Departments.read_unit('cs'))
    return display_content(
        breadcrumbs=get_breadcrumbs('research'),
        image=Images.read_tagged_unit('research'),
        title='Research',
        primary=department.get('research'),
        editable=True,
        editableUrl=url_for('web.update_department', name='cs')
    )
Exemple #4
0
def display_resources():
    '''Configure and display the resources overview page.'''
    return display_content(
        breadcrumbs=get_breadcrumbs('resources'),
        image=Images.read_tagged_unit('resources'),
        title='Department Resources',
        primary='''The Department of Computer Science offers the following
                   resources.''',
        primaryList=create_resources_list(Resources.read_units()),
        primaryListHr=False,
        editable=False
    )
Exemple #5
0
def display_courses():
    '''Configure and display the courses list page.'''
    department = check_unit(Departments.read_unit('cs'))
    courses = check_unit(Courses.read_units())
    return display_content(
        breadcrumbs=get_breadcrumbs('academics', 'courses'),
        image=Images.read_tagged_unit('courses'),
        title='Courses & Materials',
        tabList=create_course_tab_list(courses, department),
        editable=True,
        editableUrl=url_for('web.update_department', name='cs')
    )
Exemple #6
0
def display_program(name=None):
    '''Configure and display a program page.'''
    program = check_unit(Programs.read_unit(name))
    return display_content(
        breadcrumbs=get_breadcrumbs('academics', program.get('name')),
        image=Images.read_tagged_unit(name),
        title=program.get('title'),
        primary=program.get('majorDescription'),
        tabList=create_program_tab_list(program),
        editable=True,
        editableUrl=url_for('web.update_program', name=name)
    )
Exemple #7
0
def display_about():
    '''Configure and display the about page, with an appropriate image and the
    department long description.
    '''
    department = check_unit(Departments.read_unit('cs'))
    return display_content(
        breadcrumbs=get_breadcrumbs('about'),
        image=Images.read_tagged_unit('about'),
        title='About Us',
        primary=department.get('longDescription'),
        editable=True,
        editableUrl=url_for('web.update_department', name='cs')
    )
Exemple #8
0
def display_programs():
    '''Configure and display the academics overview page.'''
    return display_content(
        breadcrumbs=get_breadcrumbs('academics'),
        image=Images.read_tagged_unit('about'),
        title='Academics',
        primary='''The Department of Computer Science offers the following
                   academic programs. To learn more about our academics goals,
                   see our <a href="/administration/assessment/plan">program
                   outcomes</a>.''',
        primaryList=create_programs_list(Programs.read_units()),
        primaryListHr=False,
        editable=False
    )
Exemple #9
0
def display_index():
    '''Configure and display the main index page, with an appropriate image,
    the department short description and a list of current news articles.
    '''
    department = check_unit(Departments.read_unit('cs'))
    return display_content(
        image=Images.read_tagged_unit('departments.cs'),
        title=department.get('title'),
        subtitle=department.get('tagline'),
        primary=department.get('shortDescription'),
        sideTitle='Computing News',
        sideList=create_brief_news_list(News.read_units(limit=2 + TechNews.TECH_NEWS_LIMIT)),
        editable=True,
        editableUrl=url_for('web.update_department', name='cs')
    )