Index: main/waeup.kwarapoly/trunk/src/waeup/kwarapoly/students/browser.py
===================================================================
--- main/waeup.kwarapoly/trunk/src/waeup/kwarapoly/students/browser.py	(revision 10682)
+++ main/waeup.kwarapoly/trunk/src/waeup/kwarapoly/students/browser.py	(revision 10691)
@@ -18,9 +18,18 @@
 import grok
 from zope.i18n import translate
+from zope.component import getUtility
 from hurry.workflow.interfaces import IWorkflowInfo
 from waeup.kofa.interfaces import ADMITTED
-from waeup.kofa.interfaces import MessageFactory as _
+from waeup.kofa.browser.layout import UtilityView
+from waeup.kofa.students.interfaces import IStudentsUtils
 from waeup.kofa.widgets.datewidget import FriendlyDatetimeDisplayWidget
-from waeup.kofa.students.browser import StartClearancePage, BedTicketAddPage
+from waeup.kofa.students.browser import (
+    StartClearancePage, BedTicketAddPage, ExportPDFAdmissionSlipPage)
+from waeup.kwarapoly.students.interfaces import (
+    ICustomStudent, ICustomStudentBase)
+from waeup.kwarapoly.interfaces import MessageFactory as _
+from waeup.kofa.students.workflow import (
+    ADMITTED, PAID, REQUESTED, RETURNING, CLEARED, REGISTERED,
+    VALIDATED, GRADUATED, TRANSCRIPT, CREATED, CLEARANCE)
 from kofacustom.nigeria.students.browser import (
     NigeriaOnlinePaymentDisplayFormPage,
@@ -75,2 +84,47 @@
     notice = ''
     with_ac = False
+
+class CustomExportPDFAdmissionSlipPage(ExportPDFAdmissionSlipPage):
+    """Deliver a PDF Admission slip.
+    """
+    grok.context(ICustomStudent)
+
+    omit_fields = ('date_of_birth',)
+
+    form_fields = grok.AutoFields(ICustomStudent).select('student_id', 'reg_number')
+
+    def render(self):
+        if self.context.state in (CREATED, ADMITTED,
+                                  CLEARANCE, REQUESTED, CLEARED):
+            self.flash('Not allowed.')
+            self.redirect(self.url(self.context))
+            return
+        students_utils = getUtility(IStudentsUtils)
+        return students_utils.renderPDFAdmissionLetter(self,
+            self.context.student, omit_fields=self.omit_fields)
+
+class ExportPDFAdmissionNotificationPage(UtilityView, grok.View):
+    """Deliver a PDF Admission nostification slip.
+    """
+    grok.context(ICustomStudent)
+    grok.name('admission_notification.pdf')
+    grok.require('waeup.viewStudent')
+    prefix = 'form'
+    label = 'Notification of Provisional Admission'
+
+    omit_fields = ('date_of_birth',)
+
+    form_fields = grok.AutoFields(ICustomStudent).select(
+        'student_id', 'reg_number', 'sex', 'lga')
+
+    def render(self):
+        if self.context.state not in (ADMITTED, CLEARANCE, REQUESTED, CLEARED):
+            self.flash('Not allowed.')
+            self.redirect(self.url(self.context))
+            return
+        students_utils = getUtility(IStudentsUtils)
+        pre_text = ''
+        post_text = '<strong>Instructions for Freshers</strong>'
+        return students_utils.renderPDFAdmissionLetter(self,
+            self.context.student, omit_fields=self.omit_fields,
+            pre_text=pre_text, post_text=post_text)
Index: main/waeup.kwarapoly/trunk/src/waeup/kwarapoly/students/tests/test_browser.py
===================================================================
--- main/waeup.kwarapoly/trunk/src/waeup/kwarapoly/students/tests/test_browser.py	(revision 10682)
+++ main/waeup.kwarapoly/trunk/src/waeup/kwarapoly/students/tests/test_browser.py	(revision 10691)
@@ -19,4 +19,5 @@
 import shutil
 import tempfile
+from mechanize import LinkNotFoundError
 from StringIO import StringIO
 from hurry.workflow.interfaces import IWorkflowState, IWorkflowInfo
@@ -345,2 +346,33 @@
                            self.browser.contents)
         return
+
+    def test_pdf_slips(self):
+        IWorkflowState(self.student).setState('school fee paid')
+        # Login
+        self.browser.open(self.login_path)
+        self.browser.getControl(name="form.login").value = self.student_id
+        self.browser.getControl(name="form.password").value = 'spwd'
+        self.browser.getControl("Login").click()
+        self.browser.open(self.student_path)
+        self.browser.getLink("Download admission letter").click()
+        self.assertEqual(self.browser.headers['Status'], '200 Ok')
+        self.assertEqual(self.browser.headers['Content-Type'],
+                         'application/pdf')
+        self.browser.open(self.student_path)
+        self.assertRaises(
+            LinkNotFoundError, self.browser.getLink, 'Download admission notification')
+        self.browser.open(self.student_path, 'admission_notification.pdf')
+        self.assertFalse('Not allowed' in self.browser.contents)
+
+        IWorkflowState(self.student).setState('cleared')
+        self.browser.open(self.student_path)
+        self.browser.getLink("Download admission notification").click()
+        self.assertEqual(self.browser.headers['Status'], '200 Ok')
+        self.assertEqual(self.browser.headers['Content-Type'],
+                         'application/pdf')
+        self.browser.open(self.student_path)
+        self.assertRaises(
+            LinkNotFoundError, self.browser.getLink, 'Download admission letter')
+        self.browser.open(self.student_path, 'admission_slip.pdf')
+        self.assertFalse('Not allowed' in self.browser.contents)
+        return
Index: main/waeup.kwarapoly/trunk/src/waeup/kwarapoly/students/viewlets.py
===================================================================
--- main/waeup.kwarapoly/trunk/src/waeup/kwarapoly/students/viewlets.py	(revision 10682)
+++ main/waeup.kwarapoly/trunk/src/waeup/kwarapoly/students/viewlets.py	(revision 10691)
@@ -17,6 +17,14 @@
 ##
 
+import grok
 from waeup.kofa.students.viewlets import (
-    AddPreviousPaymentActionButton, AddBalancePaymentActionButton)
+    AddPreviousPaymentActionButton, AddBalancePaymentActionButton,
+    ManageActionButton)
+from waeup.kofa.students.interfaces import IStudent
+from waeup.kofa.students.browser import StudentBaseDisplayFormPage
+from waeup.kofa.students.workflow import (
+    ADMITTED, PAID, REQUESTED, RETURNING, CLEARED, REGISTERED,
+    VALIDATED, GRADUATED, TRANSCRIPT, CREATED, CLEARANCE)
+from waeup.kwarapoly.interfaces import MessageFactory as _
 
 class AddPreviousPaymentActionButton(AddPreviousPaymentActionButton):
@@ -31,2 +39,33 @@
     def target_url(self):
         return ''
+
+class AdmissionNotificationActionButton(ManageActionButton):
+    grok.order(4)
+    grok.context(IStudent)
+    grok.view(StudentBaseDisplayFormPage)
+    grok.require('waeup.viewStudent')
+    icon = 'actionicon_pdf.png'
+    text = _('Download admission notification')
+    target = 'admission_notification.pdf'
+
+    @property
+    def target_url(self):
+        if self.context.state not in (ADMITTED, CLEARANCE, REQUESTED, CLEARED):
+            return ''
+        return self.view.url(self.view.context, self.target)
+
+class AdmissionSlipActionButton(ManageActionButton):
+    grok.order(4)
+    grok.context(IStudent)
+    grok.view(StudentBaseDisplayFormPage)
+    grok.require('waeup.viewStudent')
+    icon = 'actionicon_pdf.png'
+    text = _('Download admission letter')
+    target = 'admission_slip.pdf'
+
+    @property
+    def target_url(self):
+        if self.context.state in (CREATED, ADMITTED,
+                                  CLEARANCE, REQUESTED, CLEARED):
+            return ''
+        return self.view.url(self.view.context, self.target)
