Index: /main/waeup.aaue/trunk/src/waeup/aaue/interswitch/browser.py
===================================================================
--- /main/waeup.aaue/trunk/src/waeup/aaue/interswitch/browser.py	(revision 13378)
+++ /main/waeup.aaue/trunk/src/waeup/aaue/interswitch/browser.py	(revision 13379)
@@ -31,5 +31,6 @@
 from waeup.aaue.interfaces import MessageFactory as _
 
-PRODUCT_ID = '5040'
+PRODUCT_ID_PT = '5040'
+PRODUCT_ID_REGULAR = '5845'
 SITE_NAME = 'aaue.waeup.org'
 PROVIDER_ACCT = '1010764827'
@@ -47,7 +48,15 @@
 httplib.HTTPSConnection.debuglevel = 0
 
+
+def school(student):
+    if student.current_mode == 'found' or student.current_mode.endswith('_pt'):
+        return 'pt'
+    return 'regular'
+
 class CustomInterswitchPageApplicant(InterswitchPageApplicant):
     """ View which sends a POST request to the Interswitch
     CollegePAY payment gateway.
+
+    So far only PT application has been configured.
     """
     grok.context(ICustomApplicantOnlinePayment)
@@ -56,5 +65,5 @@
     currency = CURRENCY
     pay_item_id = '101'
-    product_id = PRODUCT_ID
+    product_id = PRODUCT_ID_PT
     mac = '74424F1DFECD6058F153148255CDD55E16724B4F380ADB2C63C5D1D7A5675759010C8153DCB930AAF2D38903CBF7CE32B8A6BA2C16BBC46721DF2E3F3E4548E3'
 
@@ -91,5 +100,5 @@
         hashargs = (
             self.context.p_id +
-            PRODUCT_ID +
+            PRODUCT_ID_PT +
             self.pay_item_id +
             str(int(self.amount_auth)) +
@@ -108,5 +117,4 @@
     site_name = SITE_NAME
     currency = CURRENCY
-    product_id = PRODUCT_ID
     pay_item_id = '101'
     mac = '74424F1DFECD6058F153148255CDD55E16724B4F380ADB2C63C5D1D7A5675759010C8153DCB930AAF2D38903CBF7CE32B8A6BA2C16BBC46721DF2E3F3E4548E3'
@@ -156,30 +164,34 @@
         xmldict['institution_name'] = INSTITUTION_NAME
 
-        if self.context.p_category == 'schoolfee':
-            xmldict['institution_bank_id'] = '7'
-            xmldict['institution_acct'] = '1014847058'
-            if student.current_mode == 'found':
-                self.pay_item_id = '103'
-            else:
-                self.pay_item_id = '105'
-            provider_amt = 1900.0
-            joint_venture_amt = 1100.0
-            aaue_share_amt = 1000.0
-            student_union_due_amt = 1000.0
-            student_welfare_assurance_amt = 500.0
-            xmldict['provider_amt'] = 100 * provider_amt
-            xmldict['joint_venture_amt'] = 100 * joint_venture_amt
-            xmldict['aaue_share_amt'] = 100 * aaue_share_amt
-            xmldict['student_union_due_amt'] = 100 * student_union_due_amt
-            xmldict['student_welfare_assurance_amt'] = 100 * student_welfare_assurance_amt
-            xmldict['institution_amt'] = 100 * (
-                self.context.amount_auth
-                - provider_amt
-                - joint_venture_amt
-                - aaue_share_amt
-                - student_union_due_amt
-                - student_welfare_assurance_amt
-                - GATEWAY_AMT)
-            xmltext = """<payment_item_detail>
+        # PT
+
+        if school(student) == 'pt':
+            product_id = PRODUCT_ID_PT
+            if self.context.p_category == 'schoolfee':
+                xmldict['institution_bank_id'] = '7'
+                xmldict['institution_acct'] = '1014847058'
+                if student.current_mode == 'found':
+                    self.pay_item_id = '103'
+                else:
+                    self.pay_item_id = '105'
+                provider_amt = 1900.0
+                joint_venture_amt = 1100.0
+                aaue_share_amt = 1000.0
+                student_union_due_amt = 1000.0
+                student_welfare_assurance_amt = 500.0
+                xmldict['provider_amt'] = 100 * provider_amt
+                xmldict['joint_venture_amt'] = 100 * joint_venture_amt
+                xmldict['aaue_share_amt'] = 100 * aaue_share_amt
+                xmldict['student_union_due_amt'] = 100 * student_union_due_amt
+                xmldict['student_welfare_assurance_amt'] = 100 * student_welfare_assurance_amt
+                xmldict['institution_amt'] = 100 * (
+                    self.context.amount_auth
+                    - provider_amt
+                    - joint_venture_amt
+                    - aaue_share_amt
+                    - student_union_due_amt
+                    - student_welfare_assurance_amt
+                    - GATEWAY_AMT)
+                xmltext = """<payment_item_detail>
 <item_details detail_ref="%(detail_ref)s" college="%(institution_name)s" department="%(department)s" faculty="%(faculty)s">
 <item_detail item_id="1" item_name="%(institution_item_name)s" item_amt="%(institution_amt)d" bank_id="%(institution_bank_id)s" acct_num="%(institution_acct)s" />
@@ -191,22 +203,22 @@
 </item_details>
 </payment_item_detail>""" % xmldict
-        elif self.context.p_category == 'clearance':
-            if student.current_mode == 'found':
-                self.pay_item_id = '102'
-            else:
-                self.pay_item_id = '104'
-            xmldict['institution_acct'] = '1014066976'
-            xmldict['institution_bank_id'] = '117'
-            provider_amt = 0.0
-            gown_fee_amt = 2000.0
-            aaue_fl_fee_amt = 800.0
-            xmldict['gown_fee_amt'] = 100 * gown_fee_amt
-            xmldict['aaue_fl_fee_amt'] = 100 * aaue_fl_fee_amt
-            xmldict['institution_amt'] = 100 * (
-                self.context.amount_auth
-                - gown_fee_amt
-                - aaue_fl_fee_amt
-                - GATEWAY_AMT)
-            xmltext = """<payment_item_detail>
+            elif self.context.p_category == 'clearance':
+                if student.current_mode == 'found':
+                    self.pay_item_id = '102'
+                else:
+                    self.pay_item_id = '104'
+                xmldict['institution_acct'] = '1014066976'
+                xmldict['institution_bank_id'] = '117'
+                provider_amt = 0.0
+                gown_fee_amt = 2000.0
+                aaue_fl_fee_amt = 800.0
+                xmldict['gown_fee_amt'] = 100 * gown_fee_amt
+                xmldict['aaue_fl_fee_amt'] = 100 * aaue_fl_fee_amt
+                xmldict['institution_amt'] = 100 * (
+                    self.context.amount_auth
+                    - gown_fee_amt
+                    - aaue_fl_fee_amt
+                    - GATEWAY_AMT)
+                xmltext = """<payment_item_detail>
 <item_details detail_ref="%(detail_ref)s" college="%(institution_name)s" department="%(department)s" faculty="%(faculty)s">
 <item_detail item_id="1" item_name="%(institution_item_name)s" item_amt="%(institution_amt)d" bank_id="%(institution_bank_id)s" acct_num="%(institution_acct)s" />
@@ -216,4 +228,9 @@
 </payment_item_detail>""" % xmldict
 
+        # REGULAR
+
+        else:
+            pass
+
 
         self.xml_data = """<input type="hidden" name="xml_data" value='%s'  />""" % xmltext
@@ -222,5 +239,5 @@
         hashargs = (
             self.context.p_id +
-            PRODUCT_ID +
+            product_id +
             self.pay_item_id +
             str(int(self.amount_auth)) +
@@ -234,7 +251,9 @@
     InterswitchPaymentRequestWebservicePageApplicant):
     """ Request webservice view for the CollegePAY gateway
+
+    So far only PT application has been configured.
     """
     grok.context(ICustomApplicantOnlinePayment)
-    product_id = PRODUCT_ID
+    product_id = PRODUCT_ID_PT
     gateway_host = HOST
     gateway_url = URL
@@ -246,6 +265,11 @@
     """
     grok.context(ICustomStudentOnlinePayment)
-    product_id = PRODUCT_ID
     gateway_host = HOST
     gateway_url = URL
     https = HTTPS
+
+    @property
+    def product_id(self):
+        if school(self.context.student) == 'pt':
+            return PRODUCT_ID_PT
+        return PRODUCT_ID_REGULAR
Index: /main/waeup.aaue/trunk/src/waeup/aaue/interswitch/tests.py
===================================================================
--- /main/waeup.aaue/trunk/src/waeup/aaue/interswitch/tests.py	(revision 13378)
+++ /main/waeup.aaue/trunk/src/waeup/aaue/interswitch/tests.py	(revision 13379)
@@ -188,4 +188,5 @@
 
     def test_interswitch_form_ticket_expired(self):
+        self.certificate.study_mode = 'ug_pt'
         self.browser.addHeader('Authorization', 'Basic mgr:mgrpw')
         acc_payment = createObject('waeup.StudentOnlinePayment')
@@ -202,5 +203,5 @@
         self.assertMatches('...Total Amount Authorized:...',
                            self.browser.contents)
-        self.assertEqual(self.student.current_mode, 'ug_ft')
+        self.assertEqual(self.student.current_mode, 'ug_pt')
         self.assertMatches(
             '...<input type="hidden" name="amount" value="87600" />...',
