Screenshot: Example with limited Coupon:
Coupon validation messages
Note: The coupon code exists and is correct.

The problem

The used messages are not the best.

1. Second message in limited coupon context

 

  • The message are wrong if entered coupon code exist and correct.
  • In the displayed special case, limited coupon, the second message are not needed.

 

Give the user a hint! A better message in this context, for example:

Please remove the code, or use a different code.

2. Second message in correct coupon context without limitation

 

The message

Your coupon code is not valid.

is too little information.

Give the user a hint! A better message, for example: See example above.

3. Second message in wrong coupon context without limitation

 

Use the exist second message and extend the message with a hint. For the hint see first example above.

CommentFileSizeAuthor
coupon_validation_messages.jpg14.63 KBquiptime
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

pcambra’s picture

Priority: Major » Normal

Patches are welcome.

quiptime’s picture

Sorry, patches for this module currently not possible by me.
Right now, my work is focused on the Commerce Payment Network module.

pcambra’s picture

I must say that this is how feature request normally work :)

bkonetzny’s picture

Just thinking: maybe it would be better to clear the coupon form and add the used/failed coupon code to the message? What do you think about that? In this case, the failed code doesn't have to be removed by the user, and we still supply the given code in the error-message.

quiptime’s picture

to clear the coupon form

good idea

 

add the used/failed coupon code to the message

good idea

Juisi’s picture

Issue summary: View changes

Hello!

i'd start by adding
-date invalidation specific message, something like "Coupon is valid from date - date"
-maximum usage invalidation.

The date validation is built into the "calculate the sell price of the product" discount rule having a date checker condition in it.
Being no rules expert, hacking this code seems not like the best idea.

The coupon module acts as a controller for the coupon validation and to me it seems a plausible idea to write a piece of rules independent code that checks the dates, puts out the message and modifies the $error variable that is passed as a reference to the commerce_coupon_evaluate_conditions -function.

-Jussi