Skip to content
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

5343 Updated wishlist resolver and schema to support pagination #32

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

denisprotassoff
Copy link

@denisprotassoff denisprotassoff commented Dec 28, 2022

BE modifications for 5343.

protected function getWishlistCollection(
Wishlist $wishlist,
array $args
): \Magento\Wishlist\Model\ResourceModel\Item\Collection {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Import collection in head of file

Comment on lines +324 to +326
$itemsNode = array_filter(iterator_to_array($info->fieldNodes), function ($node) {
return $node->name->value === 'items_v2';
})[0];

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why like that? Do we really need to get the field out here?
Maybe move it into getFieldsFromProductInfo where semantically it can fit?

Comment on lines +17 to +18
<preference for="Magento\WishlistGraphQl\Model\Resolver\WishlistItems"
type="ScandiPWA\WishlistGraphQl\Model\Resolver\WishlistItemsResolver"/>

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How looks the original file? Do we really need to override it fully without extending it?
At all, what for this preference?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants