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

Saving Price Rules #426

Closed
AnatolZaitsev opened this issue Apr 16, 2018 · 2 comments
Closed

Saving Price Rules #426

AnatolZaitsev opened this issue Apr 16, 2018 · 2 comments

Comments

@AnatolZaitsev
Copy link

I have something like this, when try to change Price Rule:

price_rules = ShopifyAPI::PriceRule.all
=> array of #<ShopifyAPI::PriceRule>

samples = price_rules.find { |rule| rule.title == 'SAMPLES' }
=> one #<ShopifyAPI::PriceRule> with 'SAMPLES' title

samples.entitled_variant_ids << 1188572168211
=> [45260587539, 47350981459, ... 1188572168211]

samples.save
=> false

Tried update and update_attribute but it wasn't solve the problem.

@AnatolZaitsev
Copy link
Author

Can it be connected with limit of 100 items for one Price Rule?

@jamiemtdwyer
Copy link
Contributor

jamiemtdwyer commented Apr 17, 2018

samples.error.full_messages will return all of the errors on the resource.

Can it be connected with limit of 100 items for one Price Rule?

I'm not sure – I think only you would be able to answer this.

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

No branches or pull requests

2 participants