Ignore:
Timestamp:
19 Dec 2018, 22:50:36 (6 years ago)
Author:
Henrik Bettermann
Message:

Add AccommodationPaymentsExporter which can be used by accommodation officers.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.kofa/trunk/src/waeup/kofa/hostels/permissions.py

    r7195 r15277  
    2424
    2525class ViewHostels(grok.Permission):
     26    """The ViewHostels permission is applied to all views of the
     27    Accommodation Section. Users with this permission can view but not edit
     28    data in the Accommodation Section.
     29    """
    2630    grok.name('waeup.viewHostels')
    2731
    2832class ManageHostels(grok.Permission):
     33    """The ManageHostels permission is applied to manage pages in the
     34    Accommodation Section.
     35    """
    2936    grok.name('waeup.manageHostels')
     37
     38class ExportAccommodationData(grok.Permission):
     39    """Accommodation Officers don't have the general exportData
     40    permission and are only allowed to export accommodation data
     41    (accommodation payment tickets and bed tickets).
     42    The ExportAccommodationData permission is only used to filter the
     43    respective exporters in the ExportJobContainerJobConfig view.
     44    """
     45    grok.name('waeup.exportAccommodationData')
    3046
    3147# Site Roles
    3248class AccommodationOfficer(grok.Role):
     49    """Accommodation Officers can view and manage hostels. They can also export
     50    accommodation data (filtered payment tickets and beds).
     51    They can't access the Data Center but see student data export buttons
     52    in the Academic Section.
     53    """
    3354    grok.name('waeup.AccommodationOfficer')
    3455    grok.title(u'Accommodation Officer')
    35     grok.permissions('waeup.viewHostels', 'waeup.manageHostels')
     56    grok.permissions('waeup.viewHostels',
     57                     'waeup.manageHostels',
     58                     'waeup.showStudents',
     59                     'waeup.viewAcademics',
     60                     'waeup.exportAccommodationData')
Note: See TracChangeset for help on using the changeset viewer.