Index: main/waeup.aaue/trunk/src/waeup/aaue/interswitch/browser.py
===================================================================
--- main/waeup.aaue/trunk/src/waeup/aaue/interswitch/browser.py	(revision 14920)
+++ main/waeup.aaue/trunk/src/waeup/aaue/interswitch/browser.py	(revision 14945)
@@ -106,16 +106,4 @@
         xmldict['institution_name'] = INSTITUTION_NAME
 
-        if self.applicant.applicant_id.startswith('ijmbe'):
-            xmldict['institution_acct'] = '1010827641'
-            xmldict['institution_bank_id'] = '117'
-
-        if self.applicant.applicant_id.startswith('trans'):
-            xmldict['institution_acct'] = '1010827641'
-            xmldict['institution_bank_id'] = '117'
-
-        if self.applicant.applicant_id.startswith('cert'):
-            xmldict['institution_acct'] = '1010827641'
-            xmldict['institution_bank_id'] = '117'
-
         if self.applicant.applicant_id.startswith('pg'):
             handbook_amount = 2000.0
@@ -127,5 +115,5 @@
 <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" />
 <item_detail item_id="2" item_name="%(provider_item_name)s" item_amt="%(provider_amt)d" bank_id="%(provider_bank_id)s" acct_num="%(provider_acct)s" />
-<item_detail item_id="3" item_name="PG Handbook" item_amt="%(handbook_amount)d" bank_id="117" acct_num="1014270207" />
+<item_detail item_id="3" item_name="PG Handbook" item_amt="%(handbook_amount)d" bank_id="117" acct_num="1010827641" />
 </item_details>
 </payment_item_detail>""" % xmldict
@@ -179,8 +167,4 @@
     def update(self):
         error = self.init_update()
-
-        ######################################
-        #error = 'Sorry, Interswitch payments are temporarily disabled.'
-        ######################################
 
         if error:
@@ -228,5 +212,6 @@
         xmldict = self.xmldict
         xmltext = ""
-        # Provider data
+        xmldict['institution_acct'] = '1010827641'
+        xmldict['institution_bank_id'] = '117'
         xmldict['detail_ref'] = self.context.p_id
         xmldict['provider_acct'] = PROVIDER_ACCT
@@ -248,8 +233,6 @@
                 student_welfare_assurance_amt = gateway_net_amt(
                     academic_session.welfare_fee)
-                xmldict['institution_bank_id'] = '117'
-                xmldict['institution_acct'] = '1010827641'
-                xmldict['student_union_bank_id'] = '31'
-                xmldict['student_union_acct'] = '0051005007'
+                xmldict['student_union_bank_id'] = '117'
+                xmldict['student_union_acct'] = '1010827641'
                 xmldict['aaue_share_bank_id'] = '117'
                 xmldict['aaue_share_acct'] = '1010827641'
@@ -269,8 +252,6 @@
                 student_welfare_assurance_amt = gateway_net_amt(
                     academic_session.welfare_fee)
-                xmldict['institution_bank_id'] = '117'
-                xmldict['institution_acct'] = '1010827641'
-                xmldict['student_union_bank_id'] = '7'
-                xmldict['student_union_acct'] = '1019763348'
+                xmldict['student_union_bank_id'] = '117'
+                xmldict['student_union_acct'] = '1010827641'
                 xmldict['aaue_share_bank_id'] = '117'
                 xmldict['aaue_share_acct'] = '1010827641'
@@ -279,13 +260,9 @@
                 self.pay_item_id = '107'
                 if student.is_postgrad:
-                    xmldict['institution_bank_id'] = '117'
-                    xmldict['institution_acct'] = '1010827641'
                     self.pay_item_id = '111'
                 if student.current_mode == 'ijmbe':
-                    xmldict['institution_bank_id'] = '117'
-                    xmldict['institution_acct'] = '1010827641'
                     self.pay_item_id = '119'
                     xmldict['joint_venture_bank_id'] = '117'
-                    xmldict['joint_venture_acct'] = '1014066969'
+                    xmldict['joint_venture_acct'] = '1010827641'
 
             xmldict['provider_amt'] = 100 * provider_amt
@@ -295,9 +272,4 @@
                 xmldict['institution_amt'] = 100 * (
                     gateway_net_amt(self.context.amount_auth))
-                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" />
-</item_details>
-</payment_item_detail>""" % xmldict
             elif self.context.p_category in ('schoolfee_incl', 'schoolfee_1'):
                 # Schoolfee including additional fees
@@ -318,5 +290,5 @@
 <item_detail item_id="4" item_name="AAUE Share" item_amt="%(aaue_share_amt)d" bank_id="%(aaue_share_bank_id)s" acct_num="%(aaue_share_acct)s" />
 <item_detail item_id="5" item_name="Student Union" item_amt="%(student_union_due_amt)d" bank_id="%(student_union_bank_id)s" acct_num="%(student_union_acct)s" />
-<item_detail item_id="6" item_name="Student Welfare Assurance" item_amt="%(student_welfare_assurance_amt)d" bank_id="123" acct_num="1006407792" />
+<item_detail item_id="6" item_name="Student Welfare Assurance" item_amt="%(student_welfare_assurance_amt)d" bank_id="117" acct_num="1010827641" />
 </item_details>
 </payment_item_detail>""" % xmldict
@@ -346,18 +318,10 @@
                 else:
                     self.pay_item_id = '104'
-                xmldict['institution_acct'] = '1010827641'
-                xmldict['institution_bank_id'] = '117'
             else:
                 # Second agreement
                 self.pay_item_id = '102'
-                xmldict['institution_acct'] = '1010827641'
-                xmldict['institution_bank_id'] = '117'
                 if student.is_postgrad:
-                    xmldict['institution_bank_id'] = '117'
-                    xmldict['institution_acct'] = '1010827641'
                     self.pay_item_id = '110'
                 if student.current_mode == 'ijmbe':
-                    xmldict['institution_bank_id'] = '117'
-                    xmldict['institution_acct'] = '1010827641'
                     self.pay_item_id = '120'
 
@@ -376,5 +340,5 @@
 <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" />
 <item_detail item_id="2" item_name="Matriculation Gown Fee" item_amt="%(gown_fee_amt)d" bank_id="117" acct_num="1010827641" />
-<item_detail item_id="3" item_name="AAU File-Lapel Fee" item_amt="%(aaue_lf_fee_amt)d" bank_id="51" acct_num="4010660109" />
+<item_detail item_id="3" item_name="AAU File-Lapel Fee" item_amt="%(aaue_lf_fee_amt)d" bank_id="117" acct_num="1010827641" />
 </item_details>
 </payment_item_detail>""" % xmldict
@@ -384,93 +348,40 @@
                 xmldict['institution_amt'] = 100 * (
                     gateway_net_amt(self.context.amount_auth))
-                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" />
-</item_details>
-</payment_item_detail>""" % xmldict
 
         # Union Dues
         elif self.context.p_category == 'union':
             self.pay_item_id = '103'
-            if contr_agreement_student(student) == 'first':
-                # First agreement
-                xmldict['institution_acct'] = '0051005007'
-                xmldict['institution_bank_id'] = '31'
-            else:
-                # Second agreement
-                xmldict['institution_bank_id'] = '7'
-                xmldict['institution_acct'] = '1019763348'
-            xmldict['institution_amt'] = 100 * (
-                gateway_net_amt(self.context.amount_auth))
-            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" />
-</item_details>
-</payment_item_detail>""" % xmldict
+            xmldict['institution_amt'] = 100 * (
+                gateway_net_amt(self.context.amount_auth))
 
         # Lapel/File
         elif self.context.p_category == 'lapel':
             self.pay_item_id = '104'
-            xmldict['institution_acct'] = '4010660109'
-            xmldict['institution_bank_id'] = '51'
-            xmldict['institution_amt'] = 100 * (
-                gateway_net_amt(self.context.amount_auth))
-            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" />
-</item_details>
-</payment_item_detail>""" % xmldict
+            xmldict['institution_amt'] = 100 * (
+                gateway_net_amt(self.context.amount_auth))
 
         # Welfare Assurance
         elif self.context.p_category == 'welfare':
             self.pay_item_id = '105'
-            xmldict['institution_acct'] = '1006407792'
-            xmldict['institution_bank_id'] = '123'
-            xmldict['institution_amt'] = 100 * (
-                gateway_net_amt(self.context.amount_auth))
-            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" />
-</item_details>
-</payment_item_detail>""" % xmldict
+            xmldict['institution_amt'] = 100 * (
+                gateway_net_amt(self.context.amount_auth))
 
         # ID Card
         elif self.context.p_category == 'id_card':
             self.pay_item_id = '000'
-            xmldict['institution_acct'] = '1010827641'
-            xmldict['institution_bank_id'] = '117'
-            xmldict['institution_amt'] = 100 * (
-                gateway_net_amt(self.context.amount_auth))
-            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" />
-</item_details>
-</payment_item_detail>""" % xmldict
+            xmldict['institution_amt'] = 100 * (
+                gateway_net_amt(self.context.amount_auth))
 
         # Matric Gown
         elif self.context.p_category == 'matric_gown':
             self.pay_item_id = '106'
-            xmldict['institution_acct'] = '1010827641'
-            xmldict['institution_bank_id'] = '117'
-            xmldict['institution_amt'] = 100 * (
-                gateway_net_amt(self.context.amount_auth))
-            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" />
-</item_details>
-</payment_item_detail>""" % xmldict
+            xmldict['institution_amt'] = 100 * (
+                gateway_net_amt(self.context.amount_auth))
 
         # Concessional
         elif self.context.p_category == 'concessional':
             self.pay_item_id = '107'
-            xmldict['institution_acct'] = '1010827641'
-            xmldict['institution_bank_id'] = '117'
-            xmldict['institution_amt'] = 100 * (
-                gateway_net_amt(self.context.amount_auth))
-            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" />
-</item_details>
-</payment_item_detail>""" % xmldict
+            xmldict['institution_amt'] = 100 * (
+                gateway_net_amt(self.context.amount_auth))
 
         # Hostel Maintenance
@@ -479,6 +390,4 @@
             self.pay_item_id = '109'
             xmldict['provider_amt'] = 100 * provider_amt
-            xmldict['institution_acct'] = '1010827641'
-            xmldict['institution_bank_id'] = '117'
             xmldict['institution_amt'] = 100 * (
                 gateway_net_amt(self.context.amount_auth) - provider_amt)
@@ -496,13 +405,6 @@
             else:
                 self.pay_item_id = '116'
-            xmldict['institution_acct'] = '1010893123'
-            xmldict['institution_bank_id'] = '117'
-            xmldict['institution_amt'] = 100 * (
-                gateway_net_amt(self.context.amount_auth))
-            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" />
-</item_details>
-</payment_item_detail>""" % xmldict
+            xmldict['institution_amt'] = 100 * (
+                gateway_net_amt(self.context.amount_auth))
 
         # ENT Fees
@@ -512,39 +414,18 @@
             else:
                 self.pay_item_id = '118'
-            xmldict['institution_acct'] = '6220029828'
-            xmldict['institution_bank_id'] = '51'
-            xmldict['institution_amt'] = 100 * (
-                gateway_net_amt(self.context.amount_auth))
-            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" />
-</item_details>
-</payment_item_detail>""" % xmldict
+            xmldict['institution_amt'] = 100 * (
+                gateway_net_amt(self.context.amount_auth))
 
         # Faculty and Departmental Dues
         elif self.context.p_category == 'fac_dep':
             self.pay_item_id = '117'
-            xmldict['institution_acct'] = '1010827641'
-            xmldict['institution_bank_id'] = '117'
-            xmldict['institution_amt'] = 100 * (
-                gateway_net_amt(self.context.amount_auth))
-            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" />
-</item_details>
-</payment_item_detail>""" % xmldict
+            xmldict['institution_amt'] = 100 * (
+                gateway_net_amt(self.context.amount_auth))
 
         # Restitution Fee
         elif self.context.p_category == 'restitution':
             self.pay_item_id = '117'
-            xmldict['institution_acct'] = '0772002144'
-            xmldict['institution_bank_id'] = '47'
-            xmldict['institution_amt'] = 100 * (
-                gateway_net_amt(self.context.amount_auth))
-            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" />
-</item_details>
-</payment_item_detail>""" % xmldict
+            xmldict['institution_amt'] = 100 * (
+                gateway_net_amt(self.context.amount_auth))
 
         # Late Registration Fee
@@ -554,8 +435,8 @@
             else:
                 self.pay_item_id = '123'
-            xmldict['institution_acct'] = '1010827641'
-            xmldict['institution_bank_id'] = '117'
-            xmldict['institution_amt'] = 100 * (
-                gateway_net_amt(self.context.amount_auth))
+            xmldict['institution_amt'] = 100 * (
+                gateway_net_amt(self.context.amount_auth))
+
+        if not xmltext:
             xmltext = """<payment_item_detail>
 <item_details detail_ref="%(detail_ref)s" college="%(institution_name)s" department="%(department)s" faculty="%(faculty)s">
@@ -563,5 +444,4 @@
 </item_details>
 </payment_item_detail>""" % xmldict
-
         self.xml_data = """<input type="hidden" name="xml_data" value='%s'  />""" % xmltext
         self.context.provider_amt = provider_amt
Index: main/waeup.aaue/trunk/src/waeup/aaue/interswitch/tests.py
===================================================================
--- main/waeup.aaue/trunk/src/waeup/aaue/interswitch/tests.py	(revision 14920)
+++ main/waeup.aaue/trunk/src/waeup/aaue/interswitch/tests.py	(revision 14945)
@@ -115,5 +115,5 @@
             in self.browser.contents)
         self.assertTrue(
-            'item_name="PG Handbook" item_amt="200000" bank_id="117" acct_num="1014270207"'
+            'item_name="PG Handbook" item_amt="200000" bank_id="117" acct_num="1010827641"'
             in self.browser.contents)
         self.assertTrue(
@@ -147,7 +147,4 @@
         self.assertTrue(
             'item_name="Application Fee" item_amt="575000" bank_id="117" acct_num="1010827641"'
-            in self.browser.contents)
-        self.assertFalse(
-            'item_name="Screening Guide" item_amt="200000" bank_id="117" acct_num="1013879579"'
             in self.browser.contents)
         self.assertTrue(
