diff --git a/Charge.php b/Charge.php index 48e9212..79025ae 100644 --- a/Charge.php +++ b/Charge.php @@ -1,11 +1,11 @@ mixed) */ - protected function pCharge() {$s = $this->s(); return [];} + protected function pCharge() {$s = $this->s(); return [ + // 2018-09-26 «transaction amount in fractional units, mandatory (up to 12 digits)» + 'amount' => $this->amountF() + // 2018-09-26 «client’s IP address, mandatory (15 characters)» + ,'client_ip_addr' => df_visitor_ip() + ,'command' => 'v' // 2018-09-26 «identifies a request for transaction registration» + ,'currency' => 981 // 2018-09-26 «transaction currency code (ISO 4217), mandatory, (3 digits)» + ,'description' => 'UFCTEST' // 2018-09-26 «transaction details, optional (up to 125 characters)» + ,'msg_type' => 'SMS' // 2018-09-26 «STUB» + ];} /** * 2017-04-18 diff --git a/T/CaseT/Init.php b/T/CaseT/Init.php index 313d1be..4d59469 100644 --- a/T/CaseT/Init.php +++ b/T/CaseT/Init.php @@ -8,7 +8,7 @@ final class Init extends \Dfe\TBCBank\T\CaseT { /** @test 2018-09-26 */ function t00() {} - /** @test 2018-09-26 */ + /** 2018-09-26 */ function t01() {echo $this->transId();} /** 2018-09-26 */ @@ -27,6 +27,9 @@ function t02() { echo $z->request()->getBody(); } + /** @test 2018-09-26 */ + function t03() {echo df_currency_num('GEL') . ' ' . gettype(df_currency_num('GEL'));} + /** * 2018-09-26 * @used-by t01() diff --git a/composer.json b/composer.json index 042895d..283baf7 100644 --- a/composer.json +++ b/composer.json @@ -1,6 +1,6 @@ { "name": "mage2pro/tbc-bank" - ,"version": "0.0.2" + ,"version": "0.0.3" ,"description": "TBC Bank (Georgia) integration with Magento 2" ,"type": "magento2-module" ,"homepage": "https://mage2.pro/c/extensions/tbc-bank" @@ -11,7 +11,7 @@ "homepage": "https://mage2.pro/users/dmitry_fedyuk", "role": "Developer" }] - ,"require": {"mage2pro/core": ">=3.8.9"} + ,"require": {"mage2pro/core": ">=3.9.9"} ,"autoload": {"files": ["registration.php"], "psr-4": {"Dfe\\TBCBank\\": ""}} ,"keywords": [ "API"