Skip to content

Commit

Permalink
release 4.12.8 (#28)
Browse files Browse the repository at this point in the history
* Get correct country code setting

* Bump OpenCart version

* Update version

* Remove temporary order id in test mode
  • Loading branch information
KFoobar authored Jan 7, 2025
1 parent 4ea2b3d commit 8e9e592
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

## OpenCart - Svea Checkout and Svea payment modules

* Supports OpenCart 3.0.0.0 - 3.0.3.8 (older versions can be found in the branches)
* Supports OpenCart 3.0.0.0 - 3.0.3.9 (older versions can be found in the branches)
* Requires PHP 7.3 or higher

Features:
Expand Down
2 changes: 1 addition & 1 deletion docs/info.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"module_version": "4.12.7"
"module_version": "4.12.8"
}
4 changes: 0 additions & 4 deletions src/catalog/controller/extension/svea/payment.php
Original file line number Diff line number Diff line change
Expand Up @@ -89,10 +89,6 @@ public function index()

$order_id = $this->addOrder($order_id, $email);

if ($this->config->get($this->moduleString . 'sco_test_mode')) {
$order_id = hash('crc32', HTTPS_SERVER) . $order_id;
}

if ($this->config->get($this->moduleString . 'sco_currency')) {
$currency = strtoupper($this->session->data[$this->moduleString . 'sco_currency']);
} else {
Expand Down
10 changes: 7 additions & 3 deletions src/catalog/controller/extension/svea/shipping.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,13 @@ public function index()

$address = array(
'postcode' => $postcode,
'country_id' => isset($this->session->data[$this->moduleString . 'sco_country_id']) ? strtoupper($this->session->data[$this->moduleString . 'sco_country_id']) : $this->config->get('config_country_id'),
'country_id' => isset($this->session->data['svea_checkout']['country_id'])
? strtoupper($this->session->data['svea_checkout']['country_id'])
: $this->config->get('config_country_id'),
'zone_id' => $this->config->get('config_zone_id'),
'iso_code_2' => isset($this->session->data[$this->moduleString . 'sco_country']) ? $this->session->data[$this->moduleString . 'sco_country'] : strtoupper($this->language->get('code')),
'iso_code_2' => isset($this->session->data['svea_checkout']['country_code'])
? $this->session->data['svea_checkout']['country_code']
: strtoupper($this->language->get('code')),
);

$json = array();
Expand All @@ -44,7 +48,7 @@ public function index()
}

foreach ($results as $result) {
if ($this->config->get($this->shippingString .$result['code'] . '_status')) {
if ($this->config->get($this->shippingString . $result['code'] . '_status')) {
$this->load->model('extension/shipping/' . $result['code']);
$quote = $this->{'model_extension_shipping_' . $result['code']}->getQuote($address);

Expand Down
2 changes: 1 addition & 1 deletion src/svea/version.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"version": "4.12.7"
"version": "4.12.8"
}

0 comments on commit 8e9e592

Please sign in to comment.