Changeset 10176 for main/waeup.kwarapoly/trunk/src
- Timestamp:
- 13 May 2013, 05:06:23 (12 years ago)
- Location:
- main/waeup.kwarapoly/trunk/src/waeup/kwarapoly/interswitch
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kwarapoly/trunk/src/waeup/kwarapoly/interswitch/browser.py
r10142 r10176 221 221 self.context.creation_date, tz).strftime("%Y-%m-%d %H:%M:%S %Z") 222 222 self.site_redirect_url = self.url(self.context, 'request_webservice') 223 provider_amt = 500.0 223 provider_amt = 300.0 224 dalash_amt = 200.0 224 225 if self.applicant.applicant_id.startswith('hnd'): 225 226 xmldict['institution_acct'] = '7000016463' … … 231 232 xmldict['institution_acct'] = '00000000000' 232 233 xmldict['institution_bank_id'] = '00' 234 xmldict['dalash_amt'] = 100 * dalash_amt 233 235 xmldict['detail_ref'] = self.context.p_id 234 236 xmldict['provider_amt'] = 100 * provider_amt … … 237 239 xmldict['provider_item_name'] = PROVIDER_ITEM_NAME 238 240 xmldict['institution_amt'] = 100 * ( 239 self.context.amount_auth - provider_amt - GATEWAY_AMT )241 self.context.amount_auth - provider_amt - GATEWAY_AMT - dalash_amt) 240 242 xmldict['institution_item_name'] = self.context.p_category 241 243 xmldict['institution_name'] = INSTITUTION_NAME … … 254 256 <item_details detail_ref="%(detail_ref)s" college="%(institution_name)s"> 255 257 <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" /> 256 <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" /> 258 <item_detail item_id="2" item_name="Dalash" item_amt="%(dalash_amt)d" bank_id="117" acct_num="1013196791" /> 259 <item_detail item_id="3" item_name="%(provider_item_name)s" item_amt="%(provider_amt)d" bank_id="%(provider_bank_id)s" acct_num="%(provider_acct)s" /> 257 260 </item_details> 258 261 </payment_item_detail>""" % xmldict … … 260 263 self.context.provider_amt = provider_amt 261 264 self.context.gateway_amt = GATEWAY_AMT 265 self.context.thirdparty_amt = dalash_amt 262 266 return 263 267 -
main/waeup.kwarapoly/trunk/src/waeup/kwarapoly/interswitch/tests.py
r10143 r10176 357 357 'item_amt="253300" bank_id="9" acct_num="7000016463" />' 358 358 in self.browser.contents) 359 self.assertTrue( 360 '<item_detail item_id="2" item_name="BT Education" ' 361 'item_amt="50000" bank_id="117" acct_num="1010764827" />' 362 in self.browser.contents) 359 # Commission or bribe? 360 self.assertTrue( 361 '<item_detail item_id="2" item_name="Dalash" item_amt="20000" ' 362 'bank_id="117" acct_num="1013196791" />' 363 in self.browser.contents) 364 self.assertTrue( 365 '<item_detail item_id="3" item_name="BT Education" ' 366 'item_amt="30000" bank_id="117" acct_num="1010764827" />' 367 in self.browser.contents)
Note: See TracChangeset for help on using the changeset viewer.