app/soc/views/models/student.py
changeset 2186 eeb26c67cffa
parent 2158 2cbadb6efe9f
child 2239 9a47a64dcc08
equal deleted inserted replaced
2185:09ca8e661728 2186:eeb26c67cffa
    32 from soc.logic.models import user as user_logic
    32 from soc.logic.models import user as user_logic
    33 from soc.views import out_of_band
    33 from soc.views import out_of_band
    34 from soc.views.helper import access
    34 from soc.views.helper import access
    35 from soc.views.helper import decorators
    35 from soc.views.helper import decorators
    36 from soc.views.helper import dynaform
    36 from soc.views.helper import dynaform
       
    37 from soc.views.helper import responses
    37 from soc.views.helper import redirects
    38 from soc.views.helper import redirects
    38 from soc.views.helper import widgets
    39 from soc.views.helper import widgets
    39 from soc.views.models import program as program_view
    40 from soc.views.models import program as program_view
    40 from soc.views.models import role
    41 from soc.views.models import role
    41 
    42 
   172         'scope_path': kwargs['scope_path']}
   173         'scope_path': kwargs['scope_path']}
   173 
   174 
   174     try:
   175     try:
   175       student_entity = student_logic.logic.getFromKeyFieldsOr404(fields)
   176       student_entity = student_logic.logic.getFromKeyFieldsOr404(fields)
   176     except out_of_band.Error, error:
   177     except out_of_band.Error, error:
   177       return helper.responses.errorResponse(
   178       return responses.errorResponse(
   178           error, request, template=params['error_public'])
   179           error, request, template=params['error_public'])
   179 
   180 
   180     # set the fields we need for the Student Project list
   181     # set the fields we need for the Student Project list
   181     fields = {'student': student_entity}
   182     fields = {'student': student_entity}
   182 
   183