## Script (Python) "getApplicantsStatistics"
##bind container=container
##bind context=context
##bind namespace=
##bind script=script
##bind subpath=traverse_subpath
##parameters=
##title=
##
# $Id: getApplicantsStatistics.py 1277 2007-01-11 21:11:37Z joachim $
"""
return Student Statistics
"""

import logging
logger = logging.getLogger('Skins.getApplicantsStatistics')

logger.info('%s invoked statistics' % context.portal_membership.getAuthenticatedMember())
if not context.isStaff():
    return 'Not allowed'


info = {}

res_submitted_pce = context.applicants_catalog(status = 'submitted', screening_type = 'pce')
res_admitted_prence = context.applicants_catalog(status = 'submitted', screening_type = 'prence')

info['submitted_pce'] = len(res_submitted_pce)
info['admitted_prence'] = len(res_admitted_prence)

return info




