dc
Showing
Bayanlogs.txt
deleted
100644 → 0
[1] Merchant ID : 201901291000002 | |||
[2] Merchant Key : +Hu4bL6iVk943JmFAvGtWEYMODFry4fad2I+iM0X2m0= | |||
[3] Collaborator ID : BAYANPAY | |||
[4] Bayan URL : https://staging.bayanpay.sa/direcpay/secure/PaymentTxnServlet | |||
[5] Block Existence Indicator : 1110000 | |||
[6] DataBlock1 : TransactionDataBlock1 : 11111111|1552564762|100.00|http://localhost/timeOut/Api/paymentGateway|http://localhost/timeOut/Api/paymentGateway|INTERNET|CC|01|SAR | |||
[7] DataBlock2 : billingDataBlock : 1111111111000|Soloman|Vandy|123,ParkStreet|Park Street|Riyadh|Riyadh|400081|IN|[email protected]|9820998209 | |||
[8] DataBlock3 : shippingDataBlock : 111111110001|Soloman|Vandy|123ParkStreet|parkstreet|Riyadh|Riyadh|400081|IN|9820998209 | |||
[9] DataBlock4 : paymentDataBlock : NULL | |||
[10] DataBlock5 : merchantDataBlock : NULL | |||
[11] DataBlock6 : otherDataBlock : NULL | |||
[12] DataBlock7 : DCCDataBlock : NULL | |||
[13] beforeEncryptionString : 1110000||11111111|1552564762|100.00|http://localhost/timeOut/Api/paymentGateway|http://localhost/timeOut/Api/paymentGateway|INTERNET|CC|01|SAR||1111111111000|Soloman|Vandy|123,ParkStreet|Park Street|Riyadh|Riyadh|400081|IN|[email protected]|9820998209||111111110001|Soloman|Vandy|123ParkStreet|parkstreet|Riyadh|Riyadh|400081|IN|9820998209 | |||
[14] EncryptedString : RKeCiPHQnrq4Ih8pVYOhUNd0KfqxD2Qby/wkUPbEvj23Xft2HvphIethb29a7Myq8E5b0uHFoKs9UpMiz9/j9ntt08QUmxUUx6796JKGexbz3qX7HwMuZaG31+FgM6BL1NqoybToj95/b2VpJ+PiznhjDPKtRHw1ghUTYRUdmM6z8dhuPGjfgKHvD93wH7p3SnktHyQVwa77nPyBT+3xVSARLWSHMzJn128/EaKVn37Hw9ml6NBR//D2fZhopsnvcdOWVLS9EOGffPbaSX3oijDjxaiW1BzrfC9opGdzXY9Vih9sohxhgqHIWvNakCk5Ctqav7hC23iZ5Aj4PCaILTpDUfQsHpF4RaP4HtC+P94DYFWPuScMYy+yeEjWCuDWNj1pcJBUwFqmN4ZHlafClfMm6vLfJOCspMq+8MShA0T/NvYd9fNYPg8C5Kl3HSTEF7cbGU7qNFT/vrlNlHkYNw== | |||
[15] BayanPostData : 201901291000002||BAYANPAY||RKeCiPHQnrq4Ih8pVYOhUNd0KfqxD2Qby/wkUPbEvj23Xft2HvphIethb29a7Myq8E5b0uHFoKs9UpMiz9/j9ntt08QUmxUUx6796JKGexbz3qX7HwMuZaG31+FgM6BL1NqoybToj95/b2VpJ+PiznhjDPKtRHw1ghUTYRUdmM6z8dhuPGjfgKHvD93wH7p3SnktHyQVwa77nPyBT+3xVSARLWSHMzJn128/EaKVn37Hw9ml6NBR//D2fZhopsnvcdOWVLS9EOGffPbaSX3oijDjxaiW1BzrfC9opGdzXY9Vih9sohxhgqHIWvNakCk5Ctqav7hC23iZ5Aj4PCaILTpDUfQsHpF4RaP4HtC+P94DYFWPuScMYy+yeEjWCuDWNj1pcJBUwFqmN4ZHlafClfMm6vLfJOCspMq+8MShA0T/NvYd9fNYPg8C5Kl3HSTEF7cbGU7qNFT/vrlNlHkYNw== | |||
\ No newline at end of file |
... | @@ -265,7 +265,7 @@ class Api extends CI_Controller { | ... | @@ -265,7 +265,7 @@ class Api extends CI_Controller { |
public function event() { | public function event() { | ||
$data = (array) json_decode(file_get_contents('php://input')); | $data = (array) json_decode(file_get_contents('php://input')); | ||
//$data['auth_token'] = $this->auth_token; | $data['auth_token'] = (isset($this->auth_token))?$this->auth_token:''; | ||
$res = $this->Api_model->event($data); | $res = $this->Api_model->event($data); | ||
if($res['status']!=0){ | if($res['status']!=0){ | ||
$this->response($res['data']); | $this->response($res['data']); | ||
... | @@ -328,7 +328,7 @@ class Api extends CI_Controller { | ... | @@ -328,7 +328,7 @@ class Api extends CI_Controller { |
$res = $this->Api_model->payNow($payData); | $res = $this->Api_model->payNow($payData); | ||
if($res['status']==1){ | if($res['status']==1){ | ||
$this->paymentGateway($amount,$res['transaction_id'],$event_id,$booking_id); | $this->paymentGateway($amount,$res['transaction_id'],$event_id,$booking_id,$res['custData']); | ||
} | } | ||
else{ | else{ | ||
redirect('https://projects.nuvento.com/failure?event_id='.$eventid); | redirect('https://projects.nuvento.com/failure?event_id='.$eventid); | ||
... | @@ -380,9 +380,9 @@ class Api extends CI_Controller { | ... | @@ -380,9 +380,9 @@ class Api extends CI_Controller { |
} | } | ||
} | } | ||
public function paymentGateway($amount='0',$lastid='0',$event_id='0',$booking_id='0'){ | public function paymentGateway($amount='0',$lastid='0',$event_id='0',$booking_id='0',$custData=array()){ | ||
BayanPayPayment(); | BayanPayPayment(); | ||
$BayanPayArray = $this->bayanPayArray($amount,$lastid,$event_id,$booking_id); | $BayanPayArray = $this->bayanPayArray($amount,$lastid,$event_id,$booking_id,$custData); | ||
$BayanPayOnlineObject = new BayanPayBitmapPaymentIntegration($BayanPayArray); | $BayanPayOnlineObject = new BayanPayBitmapPaymentIntegration($BayanPayArray); | ||
$requestParameter = $BayanPayOnlineObject->BayanPostData; | $requestParameter = $BayanPayOnlineObject->BayanPostData; | ||
... | @@ -405,8 +405,9 @@ class Api extends CI_Controller { | ... | @@ -405,8 +405,9 @@ class Api extends CI_Controller { |
return $protocol . "://" . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; | return $protocol . "://" . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; | ||
} | } | ||
function bayanPayArray($amount = '0',$lastid='',$event_id='',$booking_id=''){ | function bayanPayArray($amount='0',$lastid='',$event_id='',$booking_id='',$custData=array()){ | ||
$settings = getSettings(); | $settings = getSettings(); | ||
$BayanPayArray = | $BayanPayArray = | ||
array( | array( | ||
'BayanPay_Online_setting' => array( | 'BayanPay_Online_setting' => array( | ||
... | @@ -414,7 +415,7 @@ class Api extends CI_Controller { | ... | @@ -414,7 +415,7 @@ class Api extends CI_Controller { |
'merchantId' => $settings['merchant_id'], | 'merchantId' => $settings['merchant_id'], | ||
'collaboratorId' => 'BAYANPAY', | 'collaboratorId' => 'BAYANPAY', | ||
'iv' => '0123456789abcdef', | 'iv' => '0123456789abcdef', | ||
'url' => false// Set to false if you are using testing environment , set to true if you are using live environment | 'url' => false | ||
), | ), | ||
'Block_Existence_Indicator'=> array( | 'Block_Existence_Indicator'=> array( | ||
'transactionDataBlock' => true, | 'transactionDataBlock' => true, | ||
... | @@ -436,46 +437,46 @@ class Api extends CI_Controller { | ... | @@ -436,46 +437,46 @@ class Api extends CI_Controller { |
'currency' => 'SAR' | 'currency' => 'SAR' | ||
), | ), | ||
'Field_Existence_Indicator_Billing' => array( | 'Field_Existence_Indicator_Billing' => array( | ||
'billToFirstName' => 'Soloman', | 'billToFirstName' => $custData->name, | ||
'billToLastName' => 'Vandy', | 'billToLastName' => '', | ||
'billToStreet1' => '123,ParkStreet', | 'billToStreet1' => '', | ||
'billToStreet2' => 'Park Street', | 'billToStreet2' => '', | ||
'billToCity' => 'Riyadh', | 'billToCity' => '', | ||
'billToState' => 'Riyadh', | 'billToState' => '', | ||
'billtoPostalCode' => '400081', | 'billtoPostalCode' => '', | ||
'billToCountry' => 'IN', | 'billToCountry' => '', | ||
'billToEmail' => '[email protected]', | 'billToEmail' => $custData->email, | ||
'billToMobileNumber' => '9820998209', | 'billToMobileNumber' => $custData->phone, | ||
'billToPhoneNumber1' => '', | 'billToPhoneNumber1' => '', | ||
'billToPhoneNumber2' => '', | 'billToPhoneNumber2' => '', | ||
'billToPhoneNumber3' => '' | 'billToPhoneNumber3' => '' | ||
), | ), | ||
'Field_Existence_Indicator_Shipping' => array( | 'Field_Existence_Indicator_Shipping' => array( | ||
'shipToFirstName' => 'Soloman', | 'shipToFirstName' => $custData->name, | ||
'shipToLastName' => 'Vandy', | 'shipToLastName' => '', | ||
'shipToStreet1' => '123ParkStreet', | 'shipToStreet1' => '', | ||
'shipToStreet2' => 'parkstreet', | 'shipToStreet2' => '', | ||
'shipToCity' => 'Riyadh', | 'shipToCity' => '', | ||
'shipToState' => 'Riyadh', | 'shipToState' => '', | ||
'shipToPostalCode' => '400081', | 'shipToPostalCode' => '', | ||
'shipToCountry' => 'IN', | 'shipToCountry' => '', | ||
'shipToPhoneNumber1' => '', | 'shipToPhoneNumber1' => '', | ||
'shipToPhoneNumber2' => '', | 'shipToPhoneNumber2' => '', | ||
'shipToPhoneNumber3' => '', | 'shipToPhoneNumber3' => '', | ||
'shipToMobileNumber' => '9820998209' | 'shipToMobileNumber' => $custData->phone | ||
), | ), | ||
'Field_Existence_Indicator_Payment' => array( | 'Field_Existence_Indicator_Payment' => array( | ||
'cardNumber' => '4111111111111111', // 1. Card Number | 'cardNumber' => '4111111111111111', | ||
'expMonth' => '08', // 2. Expiry Month | 'expMonth' => '08', | ||
'expYear' => '2020', // 3. Expiry Year | 'expYear' => '2020', | ||
'CVV' => '123', // 4. CVV | 'CVV' => '123', | ||
'cardHolderName' => 'Soloman', // 5. Card Holder Name | 'cardHolderName' => 'Soloman', | ||
'cardType' => 'Visa', // 6. Card Type | 'cardType' => 'Visa', | ||
'custMobileNumber' => '9820998209', // 7. Customer Mobile Number | 'custMobileNumber' => '9820998209', | ||
'paymentID' => '123456', // 8. Payment ID | 'paymentID' => '123456', | ||
'OTP' => '123456', // 9. OTP field | 'OTP' => '123456', | ||
'gatewayID' => '1026', // 10.Gateway ID | 'gatewayID' => '1026', | ||
'cardToken' => '1202' // 11.Card Token | 'cardToken' => '1202' | ||
), | ), | ||
'Field_Existence_Indicator_Merchant' => array( | 'Field_Existence_Indicator_Merchant' => array( | ||
'UDF1' => $lastid, | 'UDF1' => $lastid, | ||
... | @@ -483,18 +484,18 @@ class Api extends CI_Controller { | ... | @@ -483,18 +484,18 @@ class Api extends CI_Controller { |
'UDF3' => $booking_id | 'UDF3' => $booking_id | ||
), | ), | ||
'Field_Existence_Indicator_OtherData' => array( | 'Field_Existence_Indicator_OtherData' => array( | ||
'custID' => '12345', | 'custID' => $custData->userId, | ||
'transactionSource' => 'IVR', | 'transactionSource' => 'IVR', | ||
'productInfo' => 'Book', | 'productInfo' => '', | ||
'isUserLoggedIn' => 'Y', | 'isUserLoggedIn' => '', | ||
'itemTotal' => '500.00, 1000.00', | 'itemTotal' => '', | ||
'itemCategory' => 'CD, Book', | 'itemCategory' => '', | ||
'ignoreValidationResult'=> 'FALSE' | 'ignoreValidationResult'=> 'FALSE' | ||
), | ), | ||
'Field_Existence_Indicator_DCC' => array( | 'Field_Existence_Indicator_DCC' => array( | ||
'DCCReferenceNumber' => '09898787', // DCC Reference Number | 'DCCReferenceNumber' => $lastid.$event_id.$booking_id, | ||
'foreignAmount' => '240.00', // Foreign Amount | 'foreignAmount' => $amount, | ||
'ForeignCurrency' => 'USD' // Foreign Currency | 'ForeignCurrency' => 'SAR' | ||
) | ) | ||
); | ); | ||
return $BayanPayArray; | return $BayanPayArray; | ||
... | ... |
application/controllers/Staff.php
0 → 100644
application/models/Staff_model.php
0 → 100644
application/views/Staff/staffForm.php
0 → 100644
application/views/Staff/viewStaff.php
0 → 100644
Please
register
or
sign in
to comment