I've tried looking around but haven't seen anything specific to my problem. On install the rules have errors. I can't find any docs or anything in the queue so I'll post them here. for Coupon Redeem:
Error: Data selector coupon:commerce-coupon-fixed-amount for parameter data is invalid.
and for Coupon Validate:
Error: The component commerce_coupon_basic_validate_uses_of_coupon_component fails the integrity check. Error: Data selector commerce_coupon:commerce-coupon-number-of-uses for parameter data is invalid.
Running updated Rules, cleared cache, disabled/uninstalled Commerce Coupon, and tried reinstalling but same issue both times. It's late so I might be missing something. I've also been told on occasion that I'm stupid so that might be it too.
Thanks.
Comments
Comment #1
pcambraHave you tried the -dev version?
I can't reproduce this, some additional details would help.
Comment #2
RKS CreditAttribution: RKS commentedWhat kind of details would you like? All I did was install and the Rules come out invalid. I haven't tried dev but i will and let you know if that fixes it.
Comment #3
Darren Shelley CreditAttribution: Darren Shelley commentedYou will receive this error because the entity metainfo for "commerce_coupon_number_of_uses" is not provided unless you have created a 'coupon type'. See commerce_coupon_entity_property_info_alter(&$info)
I feel this issue should be addressed, enabling via drush will throw the rules integrity error. This caused me, I feel to have to unnecessarily debug the module. Had i not seen the error i would have just got on and added a coupon type and everything would have been okay.
pcambra, what do you think the best solution going forward is, I recommend either:
- include a default coupon type OR
- rule is off by default, and is enabled if any coupon types present
Comment #4
pcambraSetting back to active, we need to address this issue, however, what is the point of having the coupon module installed without any coupon type.
Thanks for the details Darren.
Comment #5
firfin CreditAttribution: firfin commentedI agree that there is little point to having coupon module without having a coupon type ( let alone coupons.) But it does raise questions. So maybe a (note / faq / known problems/issues section)* in the readme would be sufficient?
And maybe a notice for drush installs (not sure if that is even possible) ?
* = choose your favorite
Comment #6
RKS CreditAttribution: RKS commentedYeah, that's what happened to me, too. I saw the error first and never got to the point of creating a coupon type. Had I not, I would have just created a coupon and never noticed anything. For the time being while you decide what you want to do, would you like me to add this to your documentation? Just to ignore the error at first and create a coupon type?
Comment #7
firfin CreditAttribution: firfin commentedSeems to me as a good (at least temporarily) idea RKS.
Go for it :-)
Comment #8
Kebz CreditAttribution: Kebz commentedIt's throwing too many errors for the "coupon validation". Should I negate??
Coupon Validation: Check the number of redemptions
Machine name: commerce_coupon_validate_uses_of_coupon, Weight: 0
Error: *The utilized component commerce_coupon_validate_uses_of_coupon_component fails the integrity check.*
ERRORS come up for:
Conditions
Elements Operations
Entity has field
Parameter: Entity: [commerce_coupon], Field: commerce_coupon_number_of_uses
editdelete
AND
Error: *Data selector commerce_coupon:commerce-coupon-number-of-uses for parameter data is invalid.*
editdeleteAdd conditionAdd orAdd and
OR
Error: *Data selector commerce_coupon:commerce-coupon-number-of-uses for parameter data is invalid.*
editdeleteAdd conditionAdd orAdd and
Data comparison
Parameter: Data to compare: [commerce_coupon:commerce..., Operator: is lower than, Data value: [number-of-redemptions]
Error: *Data selector commerce_coupon:commerce-coupon-number-of-uses for parameter data is invalid.*
editdelete
Data comparison
Parameter: Data to compare: [commerce_coupon:commerce..., Data value: [number-of-redemptions]
Error: *Data selector commerce_coupon:commerce-coupon-number-of-uses for parameter data is invalid*