Ignore:
Timestamp:
9 Nov 2011, 15:32:53 (13 years ago)
Author:
Henrik Bettermann
Message:

Add current_session to students_catalog indexes.

Location:
main/waeup.sirp/trunk/src/waeup/sirp/students
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.sirp/trunk/src/waeup/sirp/students/catalog.py

    r6818 r7062  
    2323    state = index.Field(attribute='state')
    2424    certificate = index.Field(attribute='certificate')
     25    current_session = index.Field(attribute='current_session')
    2526
    2627class StudentQueryResultItem(object):
  • main/waeup.sirp/trunk/src/waeup/sirp/students/interfaces.py

    r7014 r7062  
    9191    """Representation of student base data.
    9292    """
    93     history = Attribute('Object history, a list of messages.')
     93    history = Attribute('Object history, a list of messages')
    9494    state = Attribute('Returns the registration state of a student')
    9595    password = Attribute('Encrypted password of a student')
    9696    certificate = Attribute('The certificate of any chosen study course')
     97    current_session = Attribute('The current session of the student')
    9798
    9899    def loggerInfo(ob_class, comment):
  • main/waeup.sirp/trunk/src/waeup/sirp/students/student.py

    r6859 r7062  
    7575        return cert
    7676
     77    @property
     78    def current_session(self):
     79        cert = getattr(self.get('studycourse', None), 'current_session', None)
     80        return cert
     81
    7782# Set all attributes of Student required in IStudent as field
    7883# properties. Doing this, we do not have to set initial attributes
Note: See TracChangeset for help on using the changeset viewer.