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

Did nmaier95/shopify-product-fetcher 2.2.0 also have a collection field? #101

Closed
AmandaLutzTO opened this issue Apr 1, 2024 · 2 comments
Assignees
Labels
bug Something isn't working Plugins → Shopify For Linear sync Plugins For Linear sync

Comments

@AmandaLutzTO
Copy link

Description

I inherited this Craft site and first task is updating to Craft 4.
Migrating from nmaier95/shopify-product-fetcher 2.2.0 to craftcms/shopify 4.0.0.
Working through the migration steps (https://github.com/craftcms/shopify/tree/v4?tab=readme-ov-file#migrating-from-v2x) but I have 2 missing field types:

  • shopify\fieldtypes\ProductFieldType
  • shopify\fieldtypes\CollectionFieldType

image

Steps to reproduce

  1. Upgrade to Craft 4
  2. Configure Shopify plugin settings
  3. Sync products (success)
  4. Start doc migration steps
  5. Can create new Shopify Products field but missing Collection field type

Additional info

  • Craft version: 4.8.3
  • PHP version: 8.1.8
  • Database driver & version: MySQL 8.0.32
  • Plugins & versions: Shopify 4.0.0
@AmandaLutzTO AmandaLutzTO added bug Something isn't working Plugins For Linear sync Plugins → Shopify For Linear sync labels Apr 1, 2024
Copy link

linear bot commented Apr 1, 2024

@lukeholder
Copy link
Member

The docs explain how to migrate the products field using the resave command.

As for the collections field, until we add collections syncing, you will need to do the same steps as the products and make a text field to store the old collection handle, and then retrieve the collection with the API directly with twig:

{% set req = craft.shopify.api.get('custom_collections') %}
{% set collections = req.response.custom_collections %}

Hope that helps in the interim.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Plugins → Shopify For Linear sync Plugins For Linear sync
Projects
None yet
Development

No branches or pull requests

2 participants