Skip to content

Commit

Permalink
Merge pull request #225 from magmodules/release/1.18.3
Browse files Browse the repository at this point in the history
Release/1.18.3
  • Loading branch information
Marvin-Magmodules authored Jun 7, 2024
2 parents a703a08 + bd789a2 commit 49e84cb
Show file tree
Hide file tree
Showing 7 changed files with 12 additions and 5 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/setup-upgrade.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ jobs:
MAGENTO_VERSION: 2.4.4
- PHP_VERSION: php82-fpm
MAGENTO_VERSION: 2.4.6
- PHP_VERSION: php83-fpm
MAGENTO_VERSION: 2.4.7
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
Expand Down
2 changes: 1 addition & 1 deletion Controller/Adminhtml/Log/Stream.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ class Stream extends Action
*
* @see _isAllowed()
*/
public const ADMIN_RESOURCE = 'Magmodules_Channable::config';
public const ADMIN_RESOURCE = 'Magmodules_Channable::configuration';

/**
* @var JsonFactory
Expand Down
2 changes: 1 addition & 1 deletion Service/Order/Items/Add.php
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ public function execute(Quote $quote, array $data, StoreInterface $store, bool $
$product = $this->getProductById((int)$item['id'], (int)$store->getStoreId());
$price = $this->getProductPrice($item, $product, $store, $quote, $isBusinessOrder);
$product = $this->setProductData($product, $price, $store, $lvbOrder);
if ($isBusinessOrder) {
if ($isBusinessOrder && (isset($item['price_tax']) && $item['price_tax'] == 0)) {
$product->setTaxClassId(0);
}

Expand Down
5 changes: 5 additions & 0 deletions Service/Order/Process/CreateInvoice.php
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,11 @@ public function execute(OrderInterface $order)
$invoice = $this->invoiceService->prepareInvoice($order);
$invoice->setRequestedCaptureCase(Invoice::CAPTURE_OFFLINE);
$invoice->setTransactionFee($order->getTransactionFee());
$invoice->setDiscountAmount($order->getDiscountAmount());
$invoice->setBaseDiscountAmount($order->getDiscountAmount());
$invoice->setDiscountDescription($order->getDiscountDescription());
$invoice->setGrandTotal($order->getGrandTotal());
$invoice->setBaseGrandTotal($order->getBaseGrandTotal());
$invoice->register();

$this->transaction->addObject($invoice);
Expand Down
2 changes: 1 addition & 1 deletion Service/Product/InventoryData.php
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ private function getReservations(array $skus, int $stockId): void

$reservations = $connection->fetchAll($select);
foreach ($reservations as $reservation) {
$this->reservation[$stockId][$reservation['sku']] = $reservation['quantity'];
$this->reservation[$stockId][$reservation['sku']] = max(0, $reservation['quantity'] * -1);
}
}

Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "magmodules/magento2-channable",
"description": "Channable integration for Magento 2",
"type": "magento2-module",
"version": "1.18.2",
"version": "1.18.3",
"license": "BSD-2-Clause",
"homepage": "https://github.com/magmodules/magento2-channable",
"require": {
Expand Down
2 changes: 1 addition & 1 deletion etc/config.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<general>
<enable>0</enable>
<limit>250</limit>
<version>v1.18.2</version>
<version>v1.18.3</version>
</general>
<data>
<name_attribute>name</name_attribute>
Expand Down

0 comments on commit 49e84cb

Please sign in to comment.