Zen Cart Logo

Gift Certificate not Crediting

Views: 5,897

Results 1 to 20 of 29
25 Feb 2010, 8:13 PM
#1
hspraggins avatar

hspraggins

New Zenner

Join Date:
Feb 2010
Posts:
3
Plugin Contributions:
0

Gift Certificate not Crediting

Hello,
I didn’t see a fix in the previous posts for this problem:
New customer creates a new account and a $5 gift certificate code is emailed to him; he enters the redemption code during checkout, but the $5 is not credited toward his purchase. How to fix? Please advise. Thank you.
Current Specs:
• PHP Version 5.2.9
• MySQL 5.0.89
• Zen Cart 1.3.0.2, Patch: 1, Database Patch Level: 1.3.0.2 (Given I just took this site over and it's my first ZenCart site, we're hiring someone this weekend to upgrade the site to the current ZenCart version; however, in the meantime, I need a fix to this gift certificate issue.)

26 Feb 2010, 2:02 AM
#2
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Gift Certificate not Crediting

Entering the code places the amount into their account ...

They have to add it by applying the amount to their order ...

26 Feb 2010, 3:34 PM
#3
hspraggins avatar

hspraggins

New Zenner

Join Date:
Feb 2010
Posts:
3
Plugin Contributions:
0

Re: Gift Certificate not Crediting

Thank you, I should have included in my original post that I did a test purchase and in that applied the amount and it still didn't credit the total.

26 Feb 2010, 4:36 PM
#4
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Gift Certificate not Crediting

Try it again ...

What happens on a new account that does not follow the email link, is that you enter the code on the checkout_payment page ... if a payment module is selected then it will apply the Gift Certificate to the customer's GV account, but it has NOT applied any of that amount to the Order ...

Unless the customer enters an amount in the
Apply Amount:

input box, nothing is applied to the Order itself, it is just added to the Customer's Gift Certificate balance ...

What is happening is, the
Apply Amount:

input box is not showing as there isn't a balance in the Customer's Account when they get to the checkout_payment ...

Unfortunately, they add the GV code and, having selected a Payment choice, go on to the checkout_confirmation ... and do not have the amount applied to the order ...

One method to help the customer out is to ALWAYS show the
Apply Amount:

input box, regardless of whether or not they have a GV balance ...

In the Gift Certificate order total module
/includes/modules/order_total/ot_gv.php

you could customize this by changing the line:

    $this->checkbox = $this->user_prompt . '<input type="text" size="6" onkeyup="submitFunction()" name="cot_gv" value="' . number_format($_SESSION['cot_gv'], 2) . '" onfocus="if (this.value == \'' . number_format($_SESSION['cot_gv'], 2) . '\') this.value = \'\';" />' . ($this->user_has_gv_account($_SESSION['customer_id']) > 0 ? '<br />' . MODULE_ORDER_TOTAL_GV_USER_BALANCE . $currencies->format($this->user_has_gv_account($_SESSION['customer_id'])) : '');

Currently, that tests is there a GV Balance for the customer, and if there is, the input box is shown ... if there is not a GV Balance then the input box is not shown ...

Change that line so that it always shows ...

Now the customer can enter the GV code and amount to apply to the order ...

27 Feb 2010, 7:19 PM
#5
hspraggins avatar

hspraggins

New Zenner

Join Date:
Feb 2010
Posts:
3
Plugin Contributions:
0

Re: Gift Certificate not Crediting

Thank you!

9 Apr 2010, 10:36 PM
#6
notageek avatar

notageek

Zen Follower

Join Date:
Mar 2009
Posts:
418
Plugin Contributions:
0

Re: Gift Certificate not Crediting

Hi. I cannot find the "Apply Amount" box. I entered a gift certificate amount in the discount box and was told it was redeemed, but I do not see the funds anywhere.

I will, of course, log out and log back in, to see what happens, but placing myself in the shoes of the customer, I don't want to lose a customer by having this happen.

Basic question: At the moment, there are existing funds in my gift certificate redemption account (notwithstanding that the ones I tried to apply to a purchase as a discount certificate disappeared into redemption-space). Despite funds being there, I cannot locate an "Apply Amount" box.

Second question: I do not know how to change the code Ajeh has identified so that the "Apply Amount" box is always showing.

Third question: I thought I once saw a box for "gift certificate" right above or below the "discount certificate" box. That would be a really clear invitation to apply a gift certificate. However, I do not see such a box now. Is the existence of such a box a figment of my imagination?

Thanks for any responses.

9 Apr 2010, 11:29 PM
#7
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Gift Certificate not Crediting

Discount Coupons are redeemed in the Redeem Discount Coupon and Gift Certificates are redeemed in the Redeem Gift Certificiate Code ...

Did you have a Discount Coupon to redeem or a Gift Certificate?

How did you receive the Discount Coupon?

How did you receive the Gift Certificate? Did you "buy the gift certificate" or did it get sent from the Admin?

10 Apr 2010, 12:01 AM
#8
notageek avatar

notageek

Zen Follower

Join Date:
Mar 2009
Posts:
418
Plugin Contributions:
0

Re: Gift Certificate not Crediting

Ajeh, thanks for responding.

I have it set up to send both a discount coupon and a $2 gift certificate upon a new login.

I successfully used the discount coupon code in the discount coupon box.

I redeemed the gift certificate sent to my test self as a new customer.

I then sent it to myself, which I am recommending my customers do to become familiar with the gift process.

Remaining logged in, I sent part of the funds to myself again, so that left only $.50 in my gift account.

I then tried a purchase using the code from the gift certificate, but could not see how to use it. I then put that code in the discount coupon box. The first time, nothing happened, but the second time I did this it gave me the green message that it had been redeemed.

However, the funds did not appear in my gift certificate account and have not reappeared after I logged out and in again.

I am not sure why I cannot see an option to apply funds.

10 Apr 2010, 12:13 AM
#9
notageek avatar

notageek

Zen Follower

Join Date:
Mar 2009
Posts:
418
Plugin Contributions:
0

Re: Gift Certificate not Crediting

I have been reading the thread here and found post 180 that seems on the subject, but the code is different from the code section referenced above:

http://www.zen-cart.com/forum/showthread.php?t=35726

10 Apr 2010, 12:16 AM
#10
notageek avatar

notageek

Zen Follower

Join Date:
Mar 2009
Posts:
418
Plugin Contributions:
0

Re: Gift Certificate not Crediting

Well, that link didn't work but here is the Post #180 on page 19 of the thread I was trying to link to:

Re: Gift Certificate Help Please
The Apply Amount: box does not show unless there is a GV balance in the customer's account ...

You could change this by customizing the Gift Certificate module and change:
Code:
function selection_test() {
if ($this->user_has_gv_account($_SESSION['customer_id'])) {
return true;
} else {
return false;
}
}
to read:
Code:
function selection_test() {
if ($this->user_has_gv_account($_SESSION['customer_id'])) {
return true;
} else {
return true;
}
}
This would display the Apply Amount: with or without a current balance so that the customer can enter the GV Redeem Code, the Apply Amount, Select PayPal and click CONTINUE and when you get to the checkout_confirmation you will see the Success Message on the Redeem of the Gift Certificate and the amount entered in the Apply on the Order so that when the customer goes to PayPal the amount has been deducted ...


Linda McGrath
If you have to think ... you haven't been zenned ...

10 Apr 2010, 12:17 AM
#11
notageek avatar

notageek

Zen Follower

Join Date:
Mar 2009
Posts:
418
Plugin Contributions:
0

Re: Gift Certificate not Crediting

Well, that link didn't work but here is the Post #180 on page 19 of the thread I was trying to link to:

Re: Gift Certificate Help Please
The Apply Amount: box does not show unless there is a GV balance in the customer's account ...

You could change this by customizing the Gift Certificate module and change:
Code:
function selection_test() {
if ($this->user_has_gv_account($_SESSION['customer_id'])) {
return true;
} else {
return false;
}
}
to read:
Code:
function selection_test() {
if ($this->user_has_gv_account($_SESSION['customer_id'])) {
return true;
} else {
return true;
}
}
This would display the Apply Amount: with or without a current balance so that the customer can enter the GV Redeem Code, the Apply Amount, Select PayPal and click CONTINUE and when you get to the checkout_confirmation you will see the Success Message on the Redeem of the Gift Certificate and the amount entered in the Apply on the Order so that when the customer goes to PayPal the amount has been deducted ...


Linda McGrath
If you have to think ... you haven't been zenned ...

10 Apr 2010, 12:33 AM
#12
notageek avatar

notageek

Zen Follower

Join Date:
Mar 2009
Posts:
418
Plugin Contributions:
0

Re: Gift Certificate not Crediting

Sorry about the double post. It didn't seem to take at first.

I did try the above code, but I do not see an "Apply Amount" option. The funds in the gift certificate account only say they can be sent to someone if I click on the link.

My site is in test mode at http://www.riverfrontsouth.com

Thanks for any help.

10 Apr 2010, 1:54 AM
#13
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Gift Certificate not Crediting

All I have done is change both to true and both show ...

Make sure when testing that you are logging in and out to test your changes ...

10 Apr 2010, 1:57 AM
#14
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Gift Certificate not Crediting

NOTE: you may want to view the ot_gv.php on the server and ensure the change is in there for this change:

  function selection_test() {
    if ($this->user_has_gv_account($_SESSION['customer_id'])) {
      return true;
    } else {
      return true;
    }
  }
10 Apr 2010, 2:26 AM
#15
notageek avatar

notageek

Zen Follower

Join Date:
Mar 2009
Posts:
418
Plugin Contributions:
0

Re: Gift Certificate not Crediting

Where should I expect the "Apply Amount" message to appear? Would it be in the gift certificate box to the side, or the center box? Maybe I am not looking in the right place. I would expect it to be on the same page page where I input my credit card information.

I have re-uploaded the includes/modules/order_total/ot_gv.php after verifying it does have the false changed to true.

10 Apr 2010, 3:47 AM
#16
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Gift Certificate not Crediting

It should be to the right of the Gift Certificate Redeem box ...

10 Apr 2010, 4:14 AM
#17
notageek avatar

notageek

Zen Follower

Join Date:
Mar 2009
Posts:
418
Plugin Contributions:
0

Re: Gift Certificate not Crediting

Ajeh,

I previously had gift certificates working and the one I sent from admin plus the ones automatically sent to new test customers are working, and can be redeemed from the email.

I have gift certificates configured to go to the queue, but those do not go into the queue and are automatically released.

I previously could also purchase gift certificates.

However, I may not have tried to purchase one since installing the Numinix Store Credit and Rewards module. That module uses the sort order 840, which is the gift certificate sort order. Numinix states somewhere that this was done purposefully, so I assumed it would not interfere with gift certificates. I guess I haven't tried to purchase a gift certificate as a customer since installing that module, and now am wondering if, in fact, the Store Credit and Rewards module, by using the gift certificate sort order, actually prevents using gift certificates.

Is there another sort order the Gift Certificate could use, if this is truly a conflict?

I just purchased a gift certificate and although it shows as a purchase, there is nothing in the gift certificate queue to release.

Also, I, as the purchaser, did not receive an email notifying me that the funds are available to be redeemed or used via a code, and I received no code. This is different behavior than the gift certificates successfully sent from Admin by hand and automatically to new test customers.

I have double-checked each gift certificate product. I am not using the attributes style of certificate, because I liked to see the actual product at some point which I do not recall specifically at the moment, as that was clearer to me. I have the certificates set up as you have suggested, with the exception that I have named them GIFT005, or GIFT025. I noted somewhere in a thread that a person found his certificate only worked with 5 "x"s (not 4). Should I be entitling them GIFT-00025? Would that make a difference?

10 Apr 2010, 4:15 AM
#18
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Gift Certificate not Crediting

You cannot have duplicate sort orders on the order total modules or they will delete one or the other duplicates as they are stored to an array ...

Change one to 845 ...

10 Apr 2010, 4:19 AM
#19
notageek avatar

notageek

Zen Follower

Join Date:
Mar 2009
Posts:
418
Plugin Contributions:
0

Re: Gift Certificate not Crediting

Ajeh,

In the event you feel it would be useful to see this from the Admin perspective, I will be pleased to email you the access information.

I appreciate your input so far very much.

Notageek

10 Apr 2010, 4:20 AM
#20
notageek avatar

notageek

Zen Follower

Join Date:
Mar 2009
Posts:
418
Plugin Contributions:
0

Re: Gift Certificate not Crediting

Thank you for the quick response. I will let you know what happens.