Skip to content

Commit

Permalink
Fixed #3510
Browse files Browse the repository at this point in the history
  • Loading branch information
lukeholder committed May 22, 2024
1 parent fe54415 commit 8eedaa3
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
- Fixed an SQL error that occurred when using the `hasStock` Purchasable query param. ([#3505](https://github.com/craftcms/commerce/issues/3505))
- Fixed an error that could occur when querying products via GraphQL.
- Fixed an error that could occur when querying variants via GraphQL.
- Fixed a bug where untracked stock items did not show correctly on the example templates. ([#3510](https://github.com/craftcms/commerce/issues/3510))
- Added `craft\commerce\gql\types\input\IntFalse`.

## 5.0.6 - 2024-05-15
Expand Down
2 changes: 1 addition & 1 deletion example-templates/dist/shop/products/_includes/grid.twig
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
checked: loop.first,
class: not variant.getIsAvailable() ? 'opacity-10' : '',
disabled: not variant.availableForPurchase,
}) }}<span class="pl-1">{{ variant.sku }} ({{ variant.stock ? variant.stock ~ ' available' : 'out of stock'}})</span><span class="ml-auto">{% if variant.onPromotion %} <del class="text-gray-400 text-xs">{{ variant.price|currency(cart.currency) }}</del>{% endif %} {{ variant.salePrice|currency(cart.currency) }}</span>
}) }}<span class="pl-1">{{ variant.sku }} {% if variant.inventoryTracked %}({{ variant.stock ? variant.stock ~ ' available' : 'out of stock'}}){% endif %}</span><span class="ml-auto">{% if variant.onPromotion %} <del class="text-gray-400 text-xs">{{ variant.price|currency(cart.currency) }}</del>{% endif %} {{ variant.salePrice|currency(cart.currency) }}</span>
</label>
{% endfor %}
</div>
Expand Down
2 changes: 1 addition & 1 deletion example-templates/src/shop/products/_includes/grid.twig
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
checked: loop.first,
class: not variant.getIsAvailable() ? 'opacity-10' : '',
disabled: not variant.availableForPurchase,
}) }}<span class="pl-1">{{ variant.sku }} ({{ variant.stock ? variant.stock ~ ' available' : 'out of stock'}})</span><span class="ml-auto">{% if variant.onPromotion %} <del class="text-gray-400 text-xs">{{ variant.price|currency(cart.currency) }}</del>{% endif %} {{ variant.salePrice|currency(cart.currency) }}</span>
}) }}<span class="pl-1">{{ variant.sku }} {% if variant.inventoryTracked %}({{ variant.stock ? variant.stock ~ ' available' : 'out of stock'}}){% endif %}</span><span class="ml-auto">{% if variant.onPromotion %} <del class="text-gray-400 text-xs">{{ variant.price|currency(cart.currency) }}</del>{% endif %} {{ variant.salePrice|currency(cart.currency) }}</span>
</label>
{% endfor %}
</div>
Expand Down

0 comments on commit 8eedaa3

Please sign in to comment.