Commit Graph

6 Commits

Author SHA1 Message Date
Justin Shreve 0268a67c4b Address a few of the feedback items from the PR:
* Switch all coupon fields to _data
* Move coupon custom fields to _meta_data
* Shorten the 'yes' -> true checks
* Add a test for getting custom fields
2016-03-17 09:19:28 -07:00
Justin Shreve 50e1bc7117 Add tests for the getter/setter methods 2016-03-17 09:19:28 -07:00
Justin Shreve 7a0c8d146b Add the ability to create coupons via code (so things like Points & Rewards will still work). 2016-03-17 09:19:27 -07:00
Justin Shreve 3eacb992bc Address issues from Mike's Feedback:
* Rename individual use, free shipping, and exclude sale items to match their meta names closer.
* Sanitize emails when using set_email_restrictions
* Remove some unnecessary explict true checks
* Move ID into _data with the rest of the fields
* Fixed some spacing issues
2016-03-17 09:19:27 -07:00
Justin Shreve 447462b274 Allow access to coupon properties directly to allow for back-compat usage, but throw a deprecated notice. Also adds a test to make sure these properties work as they should. 2016-03-17 09:19:27 -07:00
Justin Shreve d738dec05d Coupon CRUD (WIP). 2016-03-17 09:19:27 -07:00