Index: WAeUP_SRP/trunk/profiles/default/layouts/student_clearance.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/student_clearance.xml	(revision 843)
+++ WAeUP_SRP/trunk/profiles/default/layouts/student_clearance.xml	(revision 844)
@@ -4,5 +4,5 @@
  <property name="layout_edit_method"></property>
  <property name="layout_view_method"></property>
- <property name="style_prefix">layout_waeup_</property>
+ <property name="style_prefix">layout_clearance_</property>
  <property name="flexible_widgets"/>
  <property name="validate_values_expr"></property>
@@ -248,5 +248,4 @@
   <property name="label_edit">Entry Date</property>
   <property name="readonly_layout_modes">
-   <element value="edit"/>
   </property>
   <property name="hidden_layout_modes">
@@ -263,5 +262,4 @@
   <property name="label_edit">Entry Session</property>
   <property name="readonly_layout_modes">
-   <element value="edit"/>
   </property>
   <property name="hidden_layout_modes">
@@ -557,5 +555,4 @@
   <property name="label_edit">Matriculation Number</property>
   <property name="readonly_layout_modes">
-   <element value="edit"/>
   </property>
   <property name="hidden_layout_modes">
Index: WAeUP_SRP/trunk/profiles/default/types/StudentAccommodation.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/types/StudentAccommodation.xml	(revision 843)
+++ WAeUP_SRP/trunk/profiles/default/types/StudentAccommodation.xml	(revision 844)
@@ -34,5 +34,5 @@
  </action>
  <action title="action_edit" action_id="edit" category="object"
-    condition_expr="" url_expr="string:${object_url}/cpsdocument_edit"
+    condition_expr="" url_expr="string:${object_url}/cpsdocument_edit_form"
     visible="True">
   <permission value="Modify portal content"/>
Index: WAeUP_SRP/trunk/profiles/default/types/StudentApplication.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/types/StudentApplication.xml	(revision 843)
+++ WAeUP_SRP/trunk/profiles/default/types/StudentApplication.xml	(revision 844)
@@ -34,5 +34,5 @@
  </action>
  <action title="action_edit" action_id="edit" category="object"
-    condition_expr="" url_expr="string:${object_url}/cpsdocument_edit"
+    condition_expr="" url_expr="string:${object_url}/cpsdocument_edit_form"
     visible="True">
   <permission value="Modify portal content"/>
Index: WAeUP_SRP/trunk/profiles/default/types/StudentClearance.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/types/StudentClearance.xml	(revision 843)
+++ WAeUP_SRP/trunk/profiles/default/types/StudentClearance.xml	(revision 844)
@@ -38,5 +38,5 @@
  <action title="action_edit" action_id="edit" category="object"
     condition_expr=""
-    url_expr="string:${object_url}/cpsdocument_edit_form"
+    url_expr="string:${object_url}/clearance_edit_form_manager"
     visible="True">
   <permission value="Modify portal content"/>
Index: WAeUP_SRP/trunk/profiles/default/types/StudentPume.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/types/StudentPume.xml	(revision 843)
+++ WAeUP_SRP/trunk/profiles/default/types/StudentPume.xml	(revision 844)
@@ -34,5 +34,5 @@
  </action>
  <action title="action_edit" action_id="edit" category="object"
-    condition_expr="" url_expr="string:${object_url}/cpsdocument_edit"
+    condition_expr="" url_expr="string:${object_url}/cpsdocument_edit_form"
     visible="True">
   <permission value="Modify portal content"/>
Index: WAeUP_SRP/trunk/skins/waeup_academics/getAcademicsInfo.py
===================================================================
--- WAeUP_SRP/trunk/skins/waeup_academics/getAcademicsInfo.py	(revision 843)
+++ WAeUP_SRP/trunk/skins/waeup_academics/getAcademicsInfo.py	(revision 844)
@@ -1,3 +1,3 @@
-## Script (Python) "cpsdocument_edit"
+## Script (Python) "getAcademicsInfo"
 ##bind container=container
 ##bind context=context
Index: WAeUP_SRP/trunk/skins/waeup_custom/cpsdocument_edit_form.pt
===================================================================
--- WAeUP_SRP/trunk/skins/waeup_custom/cpsdocument_edit_form.pt	(revision 843)
+++ WAeUP_SRP/trunk/skins/waeup_custom/cpsdocument_edit_form.pt	(revision 844)
@@ -1,3 +1,4 @@
 <tal:block define="
+    info context/getStudentInfo;
     rendered_main python:context.getContent().render(layout_mode='edit', 
            cluster=None,
@@ -9,4 +10,5 @@
     edition python:True;
     metadata metadata|nothing;
+    is_manager info/is_manager|nothing;
     ">
 <metal:block define-macro="edit_form">
@@ -67,4 +69,8 @@
   
   <metal:block fill-slot="header">
+    <span tal:condition="not: is_manager">
+        <metal:block use-macro="here/error_not_found/macros/not_found" />
+    </span>
+    <span tal:condition="is_manager">
     <h3 tal:condition="creation" i18n:translate="">
       Create a document of type
@@ -91,9 +97,9 @@
     <br />        
     </span>
+    </span>
   </metal:block>
   
-  
-  
-  <metal:block fill-slot="main">
+ 
+  <metal:block fill-slot="main" tal:condition="is_manager">
     <form action="ACTION" method="post" id="editForm"
           enctype="multipart/form-data" class="workflow"
Index: WAeUP_SRP/trunk/skins/waeup_default/isManager.py
===================================================================
--- WAeUP_SRP/trunk/skins/waeup_default/isManager.py	(revision 843)
+++ WAeUP_SRP/trunk/skins/waeup_default/isManager.py	(revision 844)
@@ -1,3 +1,3 @@
-## Script (Python) "cpsdocument_edit"
+## Script (Python) "isManager"
 ##bind container=container
 ##bind context=context
Index: WAeUP_SRP/trunk/skins/waeup_student/clearance_edit.py
===================================================================
--- WAeUP_SRP/trunk/skins/waeup_student/clearance_edit.py	(revision 843)
+++ WAeUP_SRP/trunk/skins/waeup_student/clearance_edit.py	(revision 844)
@@ -56,5 +56,8 @@
         args = getFormUidUrlArg(REQUEST)
         psm = "Please correct Your errors."
-args['portal_status_message'] = psm
-url = clear.absolute_url() + action + '?' + urlencode(args)
-REQUEST.RESPONSE.redirect(url)
+	args['portal_status_message'] = psm
+if args:
+  url = clear.absolute_url() + action + '?' + urlencode(args)
+else:
+  url = clear.absolute_url() + action
+REQUEST.RESPONSE.redirect(url) 
Index: WAeUP_SRP/trunk/skins/waeup_student/clearance_edit_form.pt
===================================================================
--- WAeUP_SRP/trunk/skins/waeup_student/clearance_edit_form.pt	(revision 843)
+++ WAeUP_SRP/trunk/skins/waeup_student/clearance_edit_form.pt	(revision 844)
@@ -14,29 +14,4 @@
 <metal:block define-macro="edit_form">
 <metal:block use-macro="here/waeup_content_master/macros/master">
-  <metal:block fill-slot="style_slot">
-    <link rel="Stylesheet" type="text/css" href=""
-      tal:attributes="href string:${base_url}document.css" />
-
-    <metal:block define-macro="widgets_javascript">
-    <!-- XXX this has to move to CPSSchemas -->
-    <style type="text/css"
-      tal:content="string:@import url(${base_url}calendar-win2k-1.css);"></style>
-    <script type="text/javascript" src="calendar.js"
-      tal:attributes="src string:${base_url}calendar.js"></script>
-    <script type="text/javascript" src="lang/calendar-en.js"
-      tal:define="local cpsmcat/getSelectedLanguage"
-      tal:attributes="src string:${base_url}lang/calendar-${local}.js"></script>
-    <script type="text/javascript" src="calendar-setup.js"
-      tal:attributes="src string:${base_url}calendar-setup.js"></script>
-    <script type="text/javascript" src="prototype.js"
-      tal:attributes="src string:${base_url}prototype.js"></script>
-    <script type="text/javascript" src="effects.js"
-      tal:attributes="src string:${base_url}effects.js"></script>
-    <script type="text/javascript" src="controls.js"
-      tal:attributes="src string:${base_url}controls.js"></script>
-    <script type="text/javascript" src="cpsdocument.js"
-      tal:attributes="src string:${base_url}cpsdocument.js"></script>
-   </metal:block>
-  </metal:block>
 
   <metal:block fill-slot="header">
Index: WAeUP_SRP/trunk/skins/waeup_student/clearance_edit_form_manager.pt
===================================================================
--- WAeUP_SRP/trunk/skins/waeup_student/clearance_edit_form_manager.pt	(revision 844)
+++ WAeUP_SRP/trunk/skins/waeup_student/clearance_edit_form_manager.pt	(revision 844)
@@ -0,0 +1,69 @@
+<tal:block define="
+           info context/getStudentInfo;
+           rendered_main python:info['clear_doc'].render(request=request,
+                                               layout_mode = 'edit',
+                                               schema_id='student_clearance',
+                                               layout_id='student_clearance',
+                                               layout_mode='edit',
+                                               use_session=True);
+           form_action string:clearance_edit;
+           edition python:True;
+           creation python:False;
+           metadata nothing;
+           is_manager info/is_manager|nothing;
+    ">
+<metal:block define-macro="edit_form">
+<metal:block use-macro="here/waeup_content_master/macros/master">
+
+  <metal:block fill-slot="header">
+    <span tal:condition="not: is_manager">
+        <metal:block use-macro="here/error_not_found/macros/not_found" />
+    </span>
+    <span tal:condition="is_manager">
+    <a href=""
+       tal:attributes="href string:${here/academicsParent}">
+      <img tal:attributes="src string:${here/portal_url}/arrow_up.gif"/>
+      Up one level
+    </a>
+       <h3> 
+         <span tal:condition="info">
+           <span tal:content="info/student/Title" />:
+         </span>
+         <span tal:content="here/title_or_id" />
+      </h3>
+    <br />    
+    </span>
+  </metal:block>
+
+  <metal:block fill-slot="main" tal:condition="is_manager">
+    <form action="ACTION" method="post" id="editForm"
+          enctype="multipart/form-data" class="workflow"
+          tal:attributes="action form_action">
+      <div class="group">
+        <div class="documentFields">
+          <tal:block define="getFormUidHtml nocall:modules/Products.CPSDocument.utils/getFormUidHtml"
+                     replace="structure python:getFormUidHtml(request)"/>
+          <input type="hidden" id="button_placeholder" name="button_placeholder" value="" />
+          <div id="rendered_main" tal:content="structure rendered_main">
+            CONTENT
+          </div>
+        </div>
+      </div>
+    <input type="submit" class="standalone" name="cpsdocument_edit_button"
+         value="Save & Return later" 
+         id="cpsdocument_edit_button"
+         tal:condition="not:creation" />
+    <input type="submit" class="standalone"
+          tal:condition="request/final_submit|nothing"
+          name="final_submit"
+          tal:attributes="value request/final_submit"
+          />
+    </form>
+    <div id="ajax_psm" style="display:none">
+      ajax feedback
+    </div>
+  </metal:block>
+  
+</metal:block>
+</metal:block>
+</tal:block>
Index: WAeUP_SRP/trunk/skins/waeup_student/clearance_edit_manager.py
===================================================================
--- WAeUP_SRP/trunk/skins/waeup_student/clearance_edit_manager.py	(revision 844)
+++ WAeUP_SRP/trunk/skins/waeup_student/clearance_edit_manager.py	(revision 844)
@@ -0,0 +1,64 @@
+## Script (Python) "cpsdocument_edit"
+##bind container=container
+##bind context=context
+##bind namespace=
+##bind script=script
+##bind subpath=traverse_subpath
+##parameters=REQUEST,proceed=None, cpsdocument_edit_button=None, final_submit=None, action=None
+##title=
+# $Id: clearance_edit.py 832 2006-11-10 16:52:23Z joachim $
+"""
+"""
+wftool = context.portal_workflow
+from urllib import urlencode
+from Products.CPSDocument.utils import getFormUidUrlArg
+import DateTime
+current = DateTime.DateTime()
+
+# Until ajax posts directly to its own script...
+##if 'ajax_edit' in REQUEST.form:
+##    return context.cpsdocument_edit_ajax(REQUEST, cluster=cluster)
+
+# Check flexible controls
+#context.editLayouts(REQUEST=REQUEST)
+
+# Validate the document and write it if it's valid
+# (We don't call getEditableContent here, validate does it when needed.)
+wftool = context.portal_workflow
+info = context.getStudentInfo()
+
+student = info['student']
+app = info['app']
+app_doc = info['app_doc']
+clear = info['clear']
+clear_doc = info['clear_doc']
+state = context.getStudentInfo()['review_state']
+if final_submit:
+    wftool.doActionFor(info['clear'],'close')
+    wftool.doActionFor(info['student'],'request_clearance')
+    return REQUEST.RESPONSE.redirect("%s/student_index" % info['url'])
+
+is_valid, ds = clear_doc.validate(request=REQUEST,
+                                schema_id = 'student_clearance',
+                                layout_id = 'student_clearance',
+                                proxy=clear,
+                                use_session=True)
+
+psm = ""
+args = {}
+action = "/clearance_edit_form_manager"
+if cpsdocument_edit_button:
+    if is_valid:
+        psm = 'Content changed.'
+        if ds.get('acknow'):
+            args['final_submit'] = "Finally Submit"
+    else:
+        args = getFormUidUrlArg(REQUEST)
+        psm = "Please correct Your errors."
+	args['portal_status_message'] = psm
+if args:
+  url = clear.absolute_url() + action + '?' + urlencode(args)
+else:
+  url = clear.absolute_url() + action
+REQUEST.RESPONSE.redirect(url)  
+
Index: WAeUP_SRP/trunk/skins/waeup_student/clearance_slip.pt
===================================================================
--- WAeUP_SRP/trunk/skins/waeup_student/clearance_slip.pt	(revision 843)
+++ WAeUP_SRP/trunk/skins/waeup_student/clearance_slip.pt	(revision 844)
@@ -7,5 +7,5 @@
       <span tal:condition="info">
             
-        <h3>My Clearance/Eligibility Record</h3>
+        <h3>Clearance/Eligibility Record</h3>
         <br />
         <span tal:omit-tag=""
Index: WAeUP_SRP/trunk/skins/waeup_student/layout_clearance_view.pt
===================================================================
--- WAeUP_SRP/trunk/skins/waeup_student/layout_clearance_view.pt	(revision 843)
+++ WAeUP_SRP/trunk/skins/waeup_student/layout_clearance_view.pt	(revision 844)
@@ -19,5 +19,5 @@
             <tr>                         
             <tal:block condition="widget/label">
-            <td valign="top" nowrap>
+            <td width="180px" valign="top" nowrap>
               <span i18n:translate="" tal:condition="widget/is_i18n">
                   <span tal:content="widget/label" />:</span>
