-
Notifications
You must be signed in to change notification settings - Fork 9.4k
M2C-22090 Translate Wishlist and Compare label in template #25583
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
ptylek
wants to merge
29
commits into
magento:2.4-develop
Choose a base branch
from
ptylek:fix-wishlist_and_compare_label-M2C-22090
base: 2.4-develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 10 commits
Commits
Show all changes
29 commits
Select commit
Hold shift + click to select a range
f56b4ca
M2C-22090 Translate wishlist and counter label in template
ptylek 7578451
M2C-22090 Fix tests
ptylek dfd123d
M2C-22090 Fix tests
ptylek 0313531
M2C-22090 Refactor $this->helper into $block functions
ptylek b2cc15f
M2C-22090 Add short description to Sidebar Class
ptylek 6aa7ae7
M2C-22090 Add Sidebar ViewModel
ptylek 5f398d0
M2C-22090 Add compare viewModel
ptylek a6f3979
M2C-22090 Fix namespace
ptylek 94e66d9
M2C-22090 Fix namespace
ptylek 75f1487
M2C-22090 Use private modifier
ptylek 463e0b1
Merge branch '2.4-develop' of https://github.com/magento/magento2 int…
Nazar65 c4ec968
Merge branch '2.4-develop' into fix-wishlist_and_compare_label-M2C-22090
ptylek de361d3
Merge branch '2.4-develop' into fix-wishlist_and_compare_label-M2C-22090
ptylek 9e684f9
Update Wishlist.php
ptylek 5bb3c23
Fix integration test for WishList as counter now only returns a number
ptylek baf5d26
Change counter to number in integration tests
ptylek 9d93bae
Merge branch '2.4-develop' of http://github.com/magento/magento2 into…
engcom-Echo 5e9f5aa
Fix static test
engcom-Echo 72d52e0
Merge branch '2.4-develop' of http://github.com/magento/magento2 into…
engcom-Echo ccd1d9f
Merge branch '2.4-develop' into fix-wishlist_and_compare_label-M2C-22090
ptylek 0ab84fd
Merge branch '2.4-develop' of github.com:ptylek/magento2 into fix-wis…
ptylek f925a4d
M2C-22090 Move logic to js
ptylek 4ba36df
Fix static tests
ptylek 1d98cae
Update app/code/Magento/Wishlist/CustomerData/Wishlist.php
ptylek dd546cd
Merge branch '2.4-develop' into fix-wishlist_and_compare_label-M2C-22090
ed824ce
M2C-22090 Fix Unit test
ptylek 9c261c2
Merge branch '2.4-develop' into fix-wishlist_and_compare_label-M2C-22090
4df77f8
Merge branch '2.4-develop' into fix-wishlist_and_compare_label-M2C-22090
ptylek 85549f9
Remove wishlist ViewModel becasue it already exists
ptylek File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
39 changes: 39 additions & 0 deletions
39
app/code/Magento/Catalog/ViewModel/Product/Compare/Sidebar.php
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
<?php | ||
/** | ||
* Copyright © Magento, Inc. All rights reserved. | ||
* See COPYING.txt for license details. | ||
*/ | ||
|
||
namespace Magento\Catalog\ViewModel\Product\Compare; | ||
|
||
use Magento\Catalog\Helper\Product\Compare as CompareHelper; | ||
use Magento\Framework\View\Element\Block\ArgumentInterface; | ||
|
||
/** | ||
* ViewModel for Compare Product List | ||
*/ | ||
class Sidebar implements ArgumentInterface | ||
{ | ||
/** | ||
* @var CompareHelper | ||
*/ | ||
private $compareHelper; | ||
|
||
/** | ||
* @param CompareHelper $compareHelper | ||
*/ | ||
public function __construct(CompareHelper $compareHelper) | ||
{ | ||
$this->compareHelper = $compareHelper; | ||
} | ||
|
||
/** | ||
* Get parameters to clear compare list | ||
* | ||
* @return string | ||
*/ | ||
public function getClearCompareListParameters() | ||
{ | ||
return $this->compareHelper->getPostDataClearList(); | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
<?php | ||
/** | ||
* Copyright © Magento, Inc. All rights reserved. | ||
* See COPYING.txt for license details. | ||
*/ | ||
|
||
namespace Magento\Wishlist\ViewModel; | ||
|
||
use Magento\Wishlist\Helper\Data as WishlistHelper; | ||
use Magento\Framework\View\Element\Block\ArgumentInterface; | ||
|
||
/** | ||
* ViewModel for Wishlist Url | ||
*/ | ||
class Sidebar implements ArgumentInterface | ||
{ | ||
/** | ||
* @var WishlistHelper | ||
*/ | ||
private $wishlistHelper; | ||
|
||
/** | ||
* @param WishlistHelper $wishlistHelper | ||
*/ | ||
public function __construct(WishlistHelper $wishlistHelper) | ||
{ | ||
$this->wishlistHelper = $wishlistHelper; | ||
} | ||
|
||
/** | ||
* Get Wishlist URL | ||
* | ||
* @return string | ||
*/ | ||
public function getWishlistUrl() | ||
{ | ||
return $this->wishlistHelper->getListUrl(); | ||
} | ||
|
||
/** | ||
* Check whether the Wishlist is allowed | ||
* | ||
* @return bool | ||
*/ | ||
public function isWishlistAllowed() | ||
{ | ||
return $this->wishlistHelper->isAllow(); | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.