Ignore:
Timestamp:
24 Nov 2021, 06:52:16 (3 years ago)
Author:
Henrik Bettermann
Message:

Disable payment ticket deletion option for applicants and students.

Location:
main/kofacustom.skeleton/trunk/src/kofacustom/skeleton
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • main/kofacustom.skeleton/trunk/src/kofacustom/skeleton/applicants/browser.py

    r16717 r16718  
    2323from kofacustom.nigeria.applicants.browser import (
    2424    NigeriaApplicantDisplayFormPage,
     25    NigeriaApplicantManageFormPage,
     26    NigeriaApplicantEditFormPage,
    2527    NigeriaPDFApplicationSlip)
     28
     29from kofacustom.nigeria.applicants.interfaces import (
     30    INigeriaPGApplicant, INigeriaUGApplicant,
     31    INigeriaPGApplicantEdit, INigeriaUGApplicantEdit,
     32    INigeriaApplicantOnlinePayment,
     33    UG_OMIT_DISPLAY_FIELDS,
     34    UG_OMIT_PDF_FIELDS,
     35    UG_OMIT_MANAGE_FIELDS,
     36    UG_OMIT_EDIT_FIELDS,
     37    PG_OMIT_DISPLAY_FIELDS,
     38    PG_OMIT_PDF_FIELDS,
     39    PG_OMIT_MANAGE_FIELDS,
     40    PG_OMIT_EDIT_FIELDS,
     41    )
     42from kofacustom.skeleton.applicants.interfaces import (
     43    ICustomPGApplicant, ICustomUGApplicant, ICustomApplicant,
     44    ICustomPGApplicantEdit, ICustomUGApplicantEdit,
     45    ICustomApplicantOnlinePayment,
     46    )
    2647
    2748from kofacustom.skeleton.interfaces import MessageFactory as _
    2849
     50class CustomApplicantEditFormPage(NigeriaApplicantEditFormPage):
     51    """An applicant-centered edit view for applicant data.
     52    """
     53
     54    def unremovable(self, ticket):
     55        return True
     56
  • main/kofacustom.skeleton/trunk/src/kofacustom/skeleton/students/browser.py

    r16717 r16718  
    2020from zope.schema.interfaces import ConstraintNotSatisfied
    2121from zope.component import getUtility
     22from zope.security import checkPermission
    2223from hurry.workflow.interfaces import IWorkflowInfo
    2324from waeup.kofa.interfaces import REQUESTED, IExtFileStore, IKofaUtils
     
    2930    StudentBasePDFFormPage, ExportPDFCourseRegistrationSlip,
    3031    CourseTicketDisplayFormPage, StudentTriggerTransitionFormPage,
    31     msave, emit_lock_message)
     32    PaymentsManageFormPage, msave, emit_lock_message)
    3233from waeup.kofa.students.interfaces import IStudentsUtils, ICourseTicket
    3334from waeup.kofa.students.workflow import FORBIDDEN_POSTGRAD_TRANS
     
    4647from kofacustom.skeleton.interfaces import MessageFactory as _
    4748
     49class CustomPaymentsManageFormPage(PaymentsManageFormPage):
     50    """ Page to manage the student payments. This manage form page is for
     51    both students and students officers. SKELETON does not allow students
     52    to remove any payment ticket.
     53    """
     54    @property
     55    def manage_payments_allowed(self):
     56        return checkPermission('waeup.manageStudent', self.context)
Note: See TracChangeset for help on using the changeset viewer.