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

Add documentation that summarizes Solidus's built-in promotion calculators #2524

Merged
merged 2 commits into from
Apr 17, 2018

Conversation

benjaminwil
Copy link
Contributor

@benjaminwil benjaminwil commented Jan 23, 2018

This pull request extends my previous pull request for calculators documentation (#2511).

This is part a larger project to improve Solidus's documentation. See this gist with the high-level table of contents. Where and how this documentation will exist is still up for discussion.

Copy link
Member

@gmacdougall gmacdougall left a comment

Choose a reason for hiding this comment

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

Looks pretty good overall. Just a couple of small changes.

### Flexi rate

The [`Spree::Calculator::FlexiRate` calculator][flexi-rate] provides a flexible
rate depending on the items on an order. (Or, a subset of specific line items on
Copy link
Member

Choose a reason for hiding this comment

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

The flexible rate needs more explanation here.


- `base_percent`: The base discount for any order where the promotion applies.
- `tiers`: A hash where the key is the minimum order total for the tier and the
value is the tier discount: `{ tier=>discount_percentage }`.
Copy link
Member

Choose a reason for hiding this comment

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

It's difficult to infer what this needs to be based upon the table above.

Copy link
Member

@kennyadsl kennyadsl left a comment

Choose a reason for hiding this comment

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

Mostly agree with Gregor on his notes and left some other ones, great job!

# Promotion calculators

Promotion calculators are similar to [shipping
calculators][shipping-calculators]: the calculate against your preferred
Copy link
Member

Choose a reason for hiding this comment

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

the calculate -> they calculate?

### Percent on line item

The [`Spree::Calculator::PercentOnLineItem` calculator][percent-on-line-item]
provide a percentage-based discount for each applicable line item in an order.
Copy link
Member

Choose a reason for hiding this comment

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

provide -> provides


The [`Spree::Calculator::PercentOnLineItem` calculator][percent-on-line-item]
provide a percentage-based discount for each applicable line item in an order.
In the `solidus_backend` interface, this calculator is labeled "Percent Per
Copy link
Member

Choose a reason for hiding this comment

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

Do you think we should change the label in the admin UI?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think that "Percent Per Item" makes sense in the admin UI. I think I just wanted to note this in case someone was looking for "Percent on Line Item" in the admin and weren't finding it.

@benjaminwil benjaminwil force-pushed the promotion_calculators branch from c857231 to 43f1af4 Compare March 14, 2018 22:07
@benjaminwil benjaminwil force-pushed the promotion_calculators branch from 43f1af4 to b19be58 Compare March 15, 2018 00:04
Thanks to gmacdougall and kennyadsl for their reviews.
@gmacdougall gmacdougall merged commit eea07a8 into solidusio:master Apr 17, 2018
@benjaminwil benjaminwil deleted the promotion_calculators branch April 30, 2018 18:28
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

Successfully merging this pull request may close these issues.

3 participants