Index: /WAeUP_SRP/base/skins/cps_custom/logged_in.py
===================================================================
--- /WAeUP_SRP/base/skins/cps_custom/logged_in.py	(revision 2406)
+++ /WAeUP_SRP/base/skins/cps_custom/logged_in.py	(revision 2407)
@@ -45,4 +45,10 @@
         student_app = getattr(student,'application',None)
         student_per = getattr(student,'personal',None)
+        
+        #########################################################
+        
+        # perform makeStudentData for returning students who login for the first time
+        # the returning key comes from set_access_data
+              
         if request.has_key('returning') and  student_app is None:
             email=request.get("email")
@@ -60,4 +66,9 @@
             context.waeup_tool.makeStudentData(str(member))
         student_app = getattr(student,'application',None)
+        
+        #########################################################
+        
+        # add missing payments folders
+        
         if 'payments' not in student.objectIds():
             student.invokeFactory('PaymentsFolder','payments')
@@ -67,5 +78,8 @@
             d['Title'] = 'Online Payments'
             payments.getContent().edit(mapping=d)
-        student_pume = getattr(student,'pume',None)
+            
+        #########################################################            
+            
+        #student_pume = getattr(student,'pume',None)
         s_review_state = context.getStudentReviewState(student.id)
         a_review_state = wftool.getInfoFor(student_app,'review_state',None)
@@ -74,4 +88,8 @@
         logger.info('%s logged in, review_state %s' % (member,s_review_state))
         app_doc = student_app.getContent()
+
+        #########################################################
+        
+        # save email and phone of returning students after all objects have been created
 
         if request.has_key('returning'):
@@ -88,6 +106,9 @@
             per_doc.edit(mapping = {'email' : email, 'phone' : phone})
             wftool.doActionFor(student_app,'close')
-
-        #from Products.zdb import set_trace;set_trace()
+            
+        #########################################################     
+        
+        # look for passport pictures of returning students
+
         if s_review_state == 'returning' and 'passport' not in app_doc.objectIds():
             folder = 'pictures_returning'
@@ -96,4 +117,10 @@
             msg = context.waeup_tool.loadStudentFoto(student,filename,folder)
             logger.info('%s (%s), %s' % (member,s_review_state,msg))
+
+
+        #########################################################
+        
+        # look for passport pictures of new students
+
         if s_review_state in ('admitted', 'clearance_pin_entered', 'clearance_requested')  and 'passport' not in app_doc.objectIds():
             folder = 'pictures_admitted_latest'
@@ -101,11 +128,21 @@
             msg = context.waeup_tool.loadStudentFoto(student,filename,folder)
             logger.info('%s (%s), %s' % (member,s_review_state,msg))
+
+
+        #########################################################
+        
+        # perform necessary updates for new students
+
+        # 1. add pin and application date to app_doc
+        
         if s_review_state in ("student_created","admitted") and\
                              a_review_state == 'created' :
             wftool.doActionFor(student_app,'open')
-            if student_pume is not None:
-              wftool.doActionFor(student_pume,'close')
+            #if student_pume is not None:
+            #  wftool.doActionFor(student_pume,'close')
             da = {}
             pin = request.get('pin')
+            
+            # if the student comes directly, add missing pin (fix)
             if not pin:
                 jamb_reg_no = app_doc.jamb_reg_no
@@ -123,4 +160,7 @@
             da['app_ac_date'] = current
             app_doc.edit(mapping = da)
+            
+        # 2. same as 1 but without opening app_doc    
+            
         elif s_review_state in ("admitted") and a_review_state == 'opened' and\
                                             not app_doc.app_ac_pin:
@@ -139,10 +179,21 @@
                 da['app_ac_pin'] = pin
                 app_doc.edit(mapping = da)
+                
+        # 2. open personal object. This should be done in clearance_edit.       
+                
         elif s_review_state in ("cleared_and_validated",) and\
                              p_review_state == 'created' :
             wftool.doActionFor(student_per,'open')
+            
+        #########################################################
+            
         res = context.students_catalog(id = str(member))
         matric_no = res[0].matric_no
         verdict = res[0].verdict
+
+        #########################################################
+        
+        # fetch current verdict via getVerdict
+
         if s_review_state in ('returning','school_fee_paid') and not verdict:
             results = context.results_import(matric_no = matric_no)
@@ -157,5 +208,13 @@
                 study_course_doc.edit(mapping = dsc)
                 wftool.doActionFor(study_course,'close_for_edit')
+                
+        #########################################################
+                
         has_results = context.results_import(matric_no = matric_no)
+
+        #########################################################
+        
+        # determine appropriate redirect url
+
         if s_review_state == "application_pin_entered":
             redirect_url = "%s/application_edit_form" % student.absolute_url()
@@ -172,4 +231,6 @@
         else:
             redirect_url = "%s/student_index" % student.absolute_url()
+
+
     else:
         logger.info('%s logged in' % (member))
Index: eUP_SRP/base/skins/waeup_layout/layout_pume_view.pt
===================================================================
--- /WAeUP_SRP/base/skins/waeup_layout/layout_pume_view.pt	(revision 2406)
+++ 	(revision )
@@ -1,1 +1,0 @@
-<metal:block use-macro="here/layout_waeup_lib/macros/table_view" />
Index: eUP_SRP/base/skins/waeup_layout/layout_pume_view_slip.pt
===================================================================
--- /WAeUP_SRP/base/skins/waeup_layout/layout_pume_view_slip.pt	(revision 2406)
+++ 	(revision )
@@ -1,29 +1,0 @@
-<!-- a layout_lib macro -->
-<!-- $Id: layout_pume_view_slip.pt 985 2006-12-04 22:24:44Z henrik $ -->
-<metal:block define-macro="default_view"
-       tal:define="layout options/layout;
-              dm options/datastructure/getDataModel;
-              widgets python:context.getRenderedWidgets(layout);
-              fields python:('pume_tot_score',)"
-              >
-  <table width="" cellpadding="2" cellspacing="0" summary="Form layout">
-    <tr tal:repeat="field fields">
-      <tal:block tal:define="cell python: widgets[field]">
-        <tal:block define="widget cell/widget">
-          <div tal:attributes="class cell/widget_css_class|string:label;
-            id python:widget.getHtmlWidgetId()+'_widget';">
-            <td width="180px">
-             <span class="dlabel"
-                    tal:condition="widget/label"
-                    tal:content="widget/label">label</span>:
-            </td>
-            <td> 
-               <span tal:condition="cell" tal:content="structure cell/widget_rendered"></span>
-               <span tal:condition="not:cell/widget_rendered"> none </span>
-            </td>
-          </div>
-        </tal:block>
-      </tal:block>
-    </tr>
-  </table>
-</metal:block>
Index: /WAeUP_SRP/base/skins/waeup_layout/portlet_student_workflow_display.pt
===================================================================
--- /WAeUP_SRP/base/skins/waeup_layout/portlet_student_workflow_display.pt	(revision 2406)
+++ /WAeUP_SRP/base/skins/waeup_layout/portlet_student_workflow_display.pt	(revision 2407)
@@ -11,37 +11,4 @@
 
 <table class="registration" tal:condition="not:info/cr">
-  <span tal:condition="python:path('info/review_state')=='application_pin_entered'">
-  <tr><td class="active">
-    <a href="" tal:attributes="href string:${info/url}/application_edit_form">
-    Admission started
-    </a>
-  </td></tr>
-  </span>
-  <span tal:condition="python:path('info/review_state')!='application_pin_entered'">
-  <tr><td>
-    Admission started
-  </td></tr>
-  </span>
-  <span tal:condition="python:path('info/review_state')=='admission_applied'">
-  <tr><td class="active">
-    <a href="" tal:attributes="href string:${info/url}/application_view">
-    Admission requested
-    </a>
-  </td></tr>
-  </span>
-  <span tal:condition="python:path('info/review_state')!='admission_applied'">
-  <tr><td>
-    Admission requested
-  </td></tr>
-  </span>
-  <span tal:condition="python:path('info/review_state')=='pume_passed'">
-  <tr><td class="active">PUME passed</td></tr>
-  </span>
-  <span tal:condition="python:path('info/review_state')=='pume_failed'">
-  <tr><td class="stopped">PUME failed</td></tr>
-  </span>
-  <span tal:condition="python:not path('info/review_state') in ('pume_passed', 'pume_failed',)">
-  <tr><td>PUME passed</td></tr>
-  </span>  
   <span tal:condition="python:path('info/review_state')=='admitted'">
   <tr>
Index: /WAeUP_SRP/base/skins/waeup_student/check_admission.py
===================================================================
--- /WAeUP_SRP/base/skins/waeup_student/check_admission.py	(revision 2406)
+++ /WAeUP_SRP/base/skins/waeup_student/check_admission.py	(revision 2407)
@@ -69,7 +69,7 @@
     student = getattr(context.campus.students, s_id)
     review_state = wf.getInfoFor(student,'review_state',None)
-    if review_state == "admission_rejected":
-        url = "%s/campus/students/%s/pume/admission_rejected_view" % (context.portal_url(),s_id)
-        return redirect(url)
+    #if review_state == "admission_rejected":
+    #    url = "%s/campus/students/%s/pume/admission_rejected_view" % (context.portal_url(),s_id)
+    #    return redirect(url)
     pw = str(ds.get('app_ac_pin_n'))
     args = {}
Index: /WAeUP_SRP/base/skins/waeup_student/getStudentFolderInfo.py
===================================================================
--- /WAeUP_SRP/base/skins/waeup_student/getStudentFolderInfo.py	(revision 2406)
+++ /WAeUP_SRP/base/skins/waeup_student/getStudentFolderInfo.py	(revision 2407)
@@ -80,5 +80,4 @@
               'StudentStudyCourse': 'study_course_view',
               'PaymentsFolder': 'payments_view',
-              'StudentPume': 'pume_view',
               }
 sos = context.portal_catalog(container_path=student_path_root)
Index: /WAeUP_SRP/base/skins/waeup_student/getStudentInfo.py
===================================================================
--- /WAeUP_SRP/base/skins/waeup_student/getStudentInfo.py	(revision 2406)
+++ /WAeUP_SRP/base/skins/waeup_student/getStudentInfo.py	(revision 2407)
@@ -57,9 +57,4 @@
 if student is None or student.portal_type != "Student":
     return None
-##res = context.portal_catalog(id = student_id,portal_type='Student')
-##if not res:# or len(res) > 1:
-##    return None
-##brain = res[-1]
-##student = brain.getObject()
 
 info['review_state'] = context.getStudentReviewState()
@@ -70,13 +65,5 @@
 info['app'] = student.application
 info['app_doc'] = student.application.getContent()
-#info['per'] = getattr(student,'personal',None)
-#info['sex'] = 'male'
-#if info['per'] is not None:
-#    info['per_doc'] = student.personal.getContent()
-#    if info['per_doc'].sex:
-#        info['sex'] = 'female'
-#else:
-#    if info['app_doc'].jamb_sex == "F":
-#        info['sex'] = 'female'
+
 course = getattr(student,'study_course',None)
 if course:
@@ -95,19 +82,4 @@
     else:
         info['course'] = None
-#
-
-#clear = getattr(student,'clearance',None)
-#info['clear'] = clear
-#if clear is not None:
-#    info['clear_doc'] = clear.getContent()
-#    info['clear_review_state'] = wf.getInfoFor(clear,'review_state',None)
-#
-#pume = getattr(student,'pume',None)
-#info['pume'] = pume
-#if pume is not None:
-#    info['pume_doc'] = pume.getContent()
-#    info['pume_review_state'] = wf.getInfoFor(pume,'review_state',None)
-#else:
-#    info['pume'] = None
 
 if not with_items:
Index: eUP_SRP/base/skins/waeup_student/pume_slip.pt
===================================================================
--- /WAeUP_SRP/base/skins/waeup_student/pume_slip.pt	(revision 2406)
+++ 	(revision )
@@ -1,21 +1,0 @@
-<metal:html tal:define="info context/getStudentInfo"> 
-  <metal:body use-macro="here/slip_template/macros/master">
-    <metal:main fill-slot="main">
-      <span tal:condition="not: info">
-        <metal:block use-macro="here/error_not_found/macros/not_found" />
-      </span>
-      <h3>PUME Result Slip</h3>
-      <br />
-      <span tal:omit-tag=""
-            tal:content="structure python: info['app_doc'].render(proxy=info['app_doc'],
-            layout_mode='view_info', 
-            layout_id='student_application_fe')" 
-            />
-      <span tal:omit-tag=""
-            tal:content="structure python: info['pume_doc'].render(proxy=info['pume_doc'],
-            layout_mode='view_slip', 
-            layout_id='student_pume_fe')" 
-            />
-    </metal:main>
-  </metal:body>
-</metal:html>
Index: eUP_SRP/base/skins/waeup_student/pume_view.pt
===================================================================
--- /WAeUP_SRP/base/skins/waeup_student/pume_view.pt	(revision 2406)
+++ 	(revision )
@@ -1,30 +1,0 @@
-<metal:html tal:define="info context/getStudentInfo">
-  <metal:body use-macro="here/main_template/macros/master">
-    <metal:main fill-slot="main">
-      <span tal:condition="not: info">
-        <span tal:content="here/illegal_view" />
-      </span>
-      <span tal:condition="info"
-            tal:define="review_state info/review_state">
-            
-        <div style="text-align: right"
-            >
-        <a href="" target="slip" tal:attributes="href string:pume_slip"
-            onclick="javascript:window.open('','slip','width=600, height=700, directories=no, toolbar=no, location=no, menubar=yes, scrollbars=yes, status=no, resizable=no, dependent=no')">
-            <img tal:attributes="src string:${here/portal_url}/actionicon_print.png" />
-            PUME Result Slip
-        </a>
-        
-        </div>
-
-        <h3>My PUME Results</h3>
-        <br />
-        <span tal:omit-tag=""
-              tal:content="structure python: info['pume_doc'].render(proxy=info['pume_doc'],
-              layout_mode='view', 
-              layout_id='student_pume_fe')" 
-              />
-      </span>
-    </metal:main>
-  </metal:body>
-</metal:html>
