app/soc/models/student_project.py
changeset 2124 ac484d0e4304
parent 2122 b709f9d1566a
child 2183 4e036dcc79ba
equal deleted inserted replaced
2123:31a1e8e7eb18 2124:ac484d0e4304
    39   #: Required field indicating the "title" of the project
    39   #: Required field indicating the "title" of the project
    40   title = db.StringProperty(required=True,
    40   title = db.StringProperty(required=True,
    41       verbose_name=ugettext('Title'))
    41       verbose_name=ugettext('Title'))
    42   title.help_text = ugettext('Title of the project')
    42   title.help_text = ugettext('Title of the project')
    43 
    43 
    44   #: required, text field describing the project
    44   #: Required, text field describing the project
    45   abstract = db.TextProperty(required=True)
    45   abstract = db.TextProperty(required=True)
    46   abstract.help_text = ugettext(
    46   abstract.help_text = ugettext(
    47       'Short abstract, summary, or snippet;'
    47       'Short abstract, summary, or snippet;'
    48       ' 500 characters or less, plain text displayed publicly')
    48       ' 500 characters or less, plain text displayed publicly')
    49 
    49 
    50   #: optional, URL which can give more information about this project
    50   #: Optional, text field containing all kinds of information about this project
       
    51   public_info = db.TextProperty(required=False, default ='')
       
    52   public_info.help_text = ugettext(
       
    53       'Additional information about this project to be shown publicly')
       
    54 
       
    55   #: Optional, URL which can give more information about this project
    51   additional_info = db.URLProperty(required=False)
    56   additional_info = db.URLProperty(required=False)
    52   additional_info.help_text = ugettext(
    57   additional_info.help_text = ugettext(
    53       'Link to a resource containing more information about this project.')
    58       'Link to a resource containing more information about this project.')
    54 
    59 
    55   #: Optional field storing a feed URL; displayed publicly.
    60   #: Optional field storing a feed URL; displayed publicly.
    56   feed_url = db.LinkProperty(
    61   feed_url = db.LinkProperty(
    57       verbose_name=ugettext('Project Feed URL'))
    62       verbose_name=ugettext('Project Feed URL'))
    58   feed_url.help_text = ugettext(
    63   feed_url.help_text = ugettext(
    59       'The URL should be a valid ATOM or RSS feed. '
    64       'The URL should be a valid ATOM or RSS feed. '
    60       'Feed entries are shown on the home page.')
    65       'Feed entries are shown on the public page.')
    61 
    66 
    62   #: A property containing which mentor has been assigned to this project.
    67   #: A property containing which mentor has been assigned to this project.
    63   #: A project must have a mentor at all times
    68   #: A project must have a mentor at all times
    64   mentor = db.ReferenceProperty(reference_class=soc.models.mentor.Mentor,
    69   mentor = db.ReferenceProperty(reference_class=soc.models.mentor.Mentor,
    65                                 required=True,
    70                                 required=True,
    66                                 collection_name='student_projects')
    71                                 collection_name='student_projects')
    67 
    72 
    68   #: the status of this project
    73   #: The status of this project
    69   #: accepted: This project has been accepted into the program
    74   #: accepted: This project has been accepted into the program
    70   #: mid_term_passed: This project has passed the midterm evaluation
    75   #: mid_term_passed: This project has passed the midterm evaluation
    71   #: mid_term_failed: This project has failed the midterm evaluation
    76   #: mid_term_failed: This project has failed the midterm evaluation
    72   #: final_failed: This project has failed the final evaluation
    77   #: final_failed: This project has failed the final evaluation
    73   #: passed: This project has completed the program successfully
    78   #: passed: This project has completed the program successfully
    74   status = db.StringProperty(required=True, default='accepted',
    79   status = db.StringProperty(required=True, default='accepted',
    75       choices=['accepted', 'mid_term_passed', 'mid_term_failed', 
    80       choices=['accepted', 'mid_term_passed', 'mid_term_failed', 
    76               'final_failed', 'passed'])
    81               'final_failed', 'passed'])
    77 
    82 
    78   #: student which this project is from
    83   #: Student which this project is from
    79   student = db.ReferenceProperty(
    84   student = db.ReferenceProperty(
    80       reference_class=soc.models.student.Student,
    85       reference_class=soc.models.student.Student,
    81       required=True, collection_name='student_projects')
    86       required=True, collection_name='student_projects')
    82 
    87 
    83   #: program in which this project has been created
    88   #: Program in which this project has been created
    84   program = db.ReferenceProperty(reference_class=soc.models.program.Program,
    89   program = db.ReferenceProperty(reference_class=soc.models.program.Program,
    85                                  required=True, 
    90                                  required=True, 
    86                                  collection_name='student_projects')
    91                                  collection_name='student_projects')