Ignore:
Timestamp:
25 Oct 2005, 16:18:40 (19 years ago)
Author:
joachim
Message:

=Roles and Facultymanagement, new themes used

Location:
waeup_product/trunk/skins
Files:
1 deleted
7 edited
1 moved

Legend:

Unmodified
Added
Removed
  • waeup_product/trunk/skins/waeup_default/getWAeUPLayouts.py

    r78 r84  
    8585    },
    8686    'layout': {
    87         'style_prefix': 'layout_default_',
     87        'style_prefix': 'layout_waeup_',
    8888        'rows': [
    89             [{'widget_id': 'LanguageSelector'}],
     89            #[{'widget_id': 'LanguageSelector'}],
    9090            [{'widget_id': 'Title'},],
    9191            [{'widget_id': 'Description'},],
    92             [{'widget_id': 'LanguageSelectorCreation'}],
     92            #[{'widget_id': 'LanguageSelectorCreation'}],
    9393            ],
    9494        },
     
    790790###)
    791791
     792department = { ###(
     793   'widgets': {},
     794   'layout': {
     795        'style_prefix': 'layout_waeup_',
     796        'flexible_widgets': (),
     797        'ncols': 1,
     798        'rows': [],
     799    },
     800}
     801###)
     802waeup_default = { ###(
     803   'widgets': {},
     804   'layout': {
     805        'style_prefix': 'layout_waeup_',
     806        'flexible_widgets': (),
     807        'ncols': 1,
     808        'rows': [],
     809    },
     810}
     811###)
     812
    792813course = { ###(
    793814    'widgets': {
     
    888909    },
    889910   'layout': {
    890         'style_prefix': 'layout_default_',
     911        'style_prefix': 'layout_waeup_',
    891912        'flexible_widgets': (),
    892913        'ncols': 1,
     
    904925
    905926layouts = {}
     927layouts['university'] = waeup_default
    906928layouts['waeup_common'] = common_layout
    907929layouts['student'] = student_layout
     
    911933layouts['jambcreate'] = jamb_layoutcreate
    912934layouts['jamb'] = jamb_layout
     935layouts['faculty'] = waeup_default
     936layouts['department'] = waeup_default
    913937layouts['course'] = course
    914938layouts['admission_status'] = admission_status
  • waeup_product/trunk/skins/waeup_default/getWAeUPTypes.py

    r78 r84  
    66from Products.CMFCore.permissions import ModifyPortalContent
    77from Products.CMFCore.permissions import AddPortalContent
     8from Products.WAeUP.WAeUPPermissions import UniversityManage, StudentManage,FacultyManage,\
     9                                            DepartmentManage,CourseManage
    810ChangePermissions = 'Change permissions'
    911
     
    2426    'cps_proxy_type': 'folder',
    2527    'schemas': ['metadata', 'common', 'folder'],
    26     'layouts': ['waeup_common', 'folder'],
    27     'layout_clusters': ['metadata:metadata'],
    28     'cps_section_wf': 'waeup_section_wf',
    29     'actions': ({'id': 'view',
     28    'layouts': ['common', 'university'],
     29    'layout_clusters': ['metadata:metadata'],
     30    'cps_section_wf': 'waeup_section_wf',
     31    'actions_add': ({'id': 'view',
    3032                 'name': 'action_view',
    3133                 'action': 'university_view',
    32                  'permissions': (View,)},
    33                 {'id': 'new_content',
    34                  'name': 'action_new_content',
     34                 'permissions': (UniversityManage,)},
     35                {'id': 'addFaculty',
     36                 'name': 'Add a Faculty',
    3537                 'action': 'folder_factories',
    36                  'permissions': (AddPortalContent,)},
     38                 'permissions': (UniversityManage,)},
    3739                {'id': 'contents',
    3840                 'name': 'action_folder_contents',
    3941                 'action': 'folder_contents',
    40                  'permissions': (ModifyPortalContent,)},
     42                 'permissions': (UniversityManage,)},
    4143                {'id': 'edit',
    4244                 'name': 'action_edit',
    4345                 'action': 'cpsdocument_edit_form',
    44                  'permissions': (ModifyPortalContent,)},
     46                 #'action': 'cpsdocument_edit_form',
     47                 'permissions': (UniversityManage,)},
    4548                {'id': 'metadata',
    4649                 'name': 'action_metadata',
     
    7982                 'name': 'Students',
    8083                 'action': 'students_folder_view',
    81                  'permissions': (View,)},
     84                 'permissions': (UniversityManage,)},
    8285                {
    8386                'id'        : 'add_content',
    8487                'name'      : 'Add Content',
    8588                'action'    : 'string:${object/absolute_url}/folder_factories',
    86                 'condition' : 'python: member and "Manager" in member.getRoles()',
    87                 'permissions': (AddPortalContent,)},
     89                'permissions': (StudentManage,)},
    8890                {
    8991                'id'        : 'add_jamb',
    9092                'name'      : 'Add Student JAMB',
    9193                'action'    : 'string:${object/absolute_url}/create_jamb',
    92                 'condition' : 'python: member and "StudentManager" in member.getGroups()',
    93                 'permissions': (AddPortalContent,)},
     94                'permissions': (UniversityManage,)},
    9495                {'id': 'contents',
    9596                 'name': 'action_folder_contents',
    9697                 'action': 'folder_contents',
    97                  'permissions': (ModifyPortalContent,)},
     98                 'permissions': (UniversityManage,)},
    9899                {'id': 'edit',
    99100                 'name': 'action_edit',
    100101                 'action': 'cpsdocument_edit_form',
    101                  'permissions': (ModifyPortalContent,)},
     102                 'permissions': (UniversityManage,)},
    102103                {'id': 'metadata',
    103104                 'name': 'action_metadata',
    104105                 'action': 'cpsdocument_metadata',
    105                  'permissions': (ModifyPortalContent,)},
     106                 'permissions': (UniversityManage,)},
    106107                {'id': 'localroles',
    107108                 'name': 'action_local_roles',
    108109                 'action': 'folder_localrole_form',
    109                  'permissions': (ChangePermissions,)},
     110                 'permissions': (UniversityManage,)},
    110111    )
    111112}
     
    139140          #'action': 'string:${object_url}/cpsdocument_view',
    140141          'condition': '',
    141           'permission': ('View',),
     142          'permission': (View,),
    142143          'category': 'object',
    143144          'visible': True,},
     
    294295    'cps_display_as_document_in_listing': True,
    295296    'schemas': ['metadata','common','faculty'],
    296     'layouts': ['waeup_common',],
     297    'layouts': ['common','faculty'],
    297298    'flexible_layouts': (),
    298299    'layout_clusters': ['metadata:metadata'],
     
    304305          'action': 'string:${object_url}/faculty_index_html',
    305306          'condition': '',
    306           'permission': ('View',),
     307          'permission': (View,),
     308          'category': 'object',
     309          'visible': True,},
     310         {'id': 'edit',
     311          'name': 'action_edit',
     312          'action': 'string:${object_url}/waeup_edit_form',
     313          'condition': '',
     314          'permission': (UniversityManage,),
    307315          'category': 'object',
    308316          'visible': True,},
     
    327335    'cps_display_as_document_in_listing': True,
    328336    'schemas': ['metadata','common','department'],
    329     'layouts': ['waeup_common',],
     337    'layouts': ['department','common',],
    330338    'flexible_layouts': (),
    331339    'layout_clusters': ['metadata:metadata'],
     
    338346          'condition': '',
    339347          'permission': ('View',),
     348          'category': 'object',
     349          'visible': True,},
     350         {'id': 'edit',
     351          'name': 'action_edit',
     352          'action': 'string:${object_url}/waeup_edit_form',
     353          'condition': '',
     354          'permission': (FacultyManage,),
    340355          'category': 'object',
    341356          'visible': True,},
     
    360375    'cps_display_as_document_in_listing': True,
    361376    'schemas': ['metadata','common','course'],
    362     'layouts': ['waeup_common','course'],
     377    'layouts': ['common','course'],
    363378    'flexible_layouts': (),
    364379    'layout_clusters': ['metadata:metadata'],
     
    371386          'condition': '',
    372387          'permission': ('View',),
     388          'category': 'object',
     389          'visible': True,},
     390         {'id': 'edit',
     391          'name': 'action_edit',
     392          'action': 'string:${object_url}/waeup_edit_form',
     393          'condition': '',
     394          'permission': (CourseManage,),
    373395          'category': 'object',
    374396          'visible': True,},
  • waeup_product/trunk/skins/waeup_default/portlet_main_navigation.pt

    r82 r84  
    1212    <a href="" i18n:translate=""
    1313       tal:attributes="href string:${here/portal_url}/sections/waeup/students"
    14        >Student Administration</a>
     14       >Studentadministration</a> |
     15    <a href="" i18n:translate=""
     16       tal:attributes="href string:${here/portal_url}/sections/waeup/faculties"
     17       >Faculties</a>
    1518  </tal:block>
    1619  <tal:block condition="anonymous">
  • waeup_product/trunk/skins/waeup_default/portlet_session_info.pt

    r81 r84  
    66    <span i18n:translate="">You are currently logged in as
    77      <em i18n:name="member"
    8           tal:content="member" /><br />
     8          tal:content="member" /><br />with Basic Roles <span tal:content="member/getRoles" /><br />
     9      <span tal:condition="python: 0" tal:content="python:mtool.getCPSCandidateLocalRoles(context)" />
    910      <a href="" tal:condition="python: 'Students' in member.getGroups()"
    1011         tal:attributes="href string:${here/portal_url}/sections/waeup/students/${member}">goto your personal area</a>
  • waeup_product/trunk/skins/waeup_default/university_view.py

    r78 r84  
    1212        return context.students.students_folder_view_student(psm=psm,groups=groups)
    1313    elif 'StudentManager' in member.getGroups():
    14         return context.students.student_folder_view_manager(psm=psm,groups=groups)
     14        return context.waeup_view_manager(psm=psm,groups=groups)
    1515return context.students.students_folder_view_anon(psm=psm,groups=groups)
  • waeup_product/trunk/skins/waeup_faculty/department_index_html.py

    r80 r84  
    88#return context.student_view_manager()
    99if member:
    10     if 'Manager' in member.getRoles():
     10    if 'StudentManager' in member.getGroups():
     11    #if 'Manager' in member.getRoles():
    1112        return context.department_view_manager()
    1213    elif 'Students' in member.getGroups():
  • waeup_product/trunk/skins/waeup_faculty/department_index_html.py~

    r80 r84  
    11##parameters=post_id=None, REQUEST=None
    22
    3 # $Id: student_index_html.py 48 2005-10-16 15:47:22Z joachim $
     3# $Id: department_index_html.py 80 2005-10-22 13:43:45Z joachim $
    44
    55"""Default view for a Faculty."""
     
    99if member:
    1010    if 'Manager' in member.getRoles():
    11         return context.faculty_view_manager()
     11        return context.department_view_manager()
    1212    elif 'Students' in member.getGroups():
    13         return context.faculty_view_student()
     13        return context.department_view_student()
  • waeup_product/trunk/skins/waeup_faculty/faculty_index_html.py

    r80 r84  
    77
    88#return context.student_view_manager()
    9 if 'Manager' in member.getRoles():
     9#if 'Manager' in member.getRoles():
     10if 'StudentManager' in member.getGroups():
    1011    return context.faculty_view_manager()
    1112elif 'Students' in member.getGroups():
Note: See TracChangeset for help on using the changeset viewer.