Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

### POINTS AND REWARDS MODULE V1.00 ###


Recommended Posts

I have actually gotten PayPal Standard to work now using PuffDandEd's update but I have the same problem as him.

 

(Points are rewarded/deducted automatically when the customer goes to the 'Confirmation page' and not when the customer clicks on 'Confirm Order'.)

 

If anyone gets a fix for this, I would really appreciate it if you would let me know.

 

Thanks.

 

Hey everyone,

 

Im currently trying to get the contribution to work with PayPal Website Payments Standard.

 

I saw the .patch update that was posted on the contribution website but I dont know what to do with it.

 

Does anyone how I am supposed to use the .patch file?

 

...Or did anyone here manage to get everything to work good with PayPal Website Payments Standard some how?

 

Thanks.

Link to comment
Share on other sites

Hey everyone,

 

For all of you who have gotten PayPal IPN to work with this contribution...

 

I would be willing to pay you a payment of $10 through PayPal if you can help me to get it to fully work.

 

Please PM me if you are interested.

 

Thanks a lot.

Link to comment
Share on other sites

  • 3 weeks later...
Hi all,

 

And now I have a new problem, everytime, when the order amount is equal or over $1,000, when the customers choose

to redeem the bonus points, after subtracting the points, the order total amount will be $1.00

It is terrible, hahaha.... no matter what original amount it should be, everytime it reaches 4 digit, then the total amount

will be equal to 1.

 

So please someone can help me solve this problem.

 

(one of my customers DID pay $1 for order originally equal to $1,395, <_< )

I also had the same problem, I believe this will fix it

 

includes/modules/order_total/ot_redemption.php

Find

$order->info['total'] = number_format($order->info['total'] - tep_calc_shopping_pvalue($customer_shopping_points_spending), 4);

Replace With

$order->info['total'] -= tep_calc_shopping_pvalue($customer_shopping_points_spending);

 

Can someone confirm?

Edited by sashaben
Link to comment
Share on other sites

I also had the same problem, I believe this will fix it

 

includes/modules/order_total/ot_redemption.php

Find

$order->info['total'] = number_format($order->info['total'] - tep_calc_shopping_pvalue($customer_shopping_points_spending), 4);

Replace With

$order->info['total'] -= tep_calc_shopping_pvalue($customer_shopping_points_spending);

 

Can someone confirm?

 

I can definitely confirm that your code does in fact fix the total addup issue when an order is in the 4 digits. Thank you so much!

Link to comment
Share on other sites

Hi,

 

When paying the full order amount with points, it still offers the payment types like Paypal and IDEAL.

When a customer also chooses IDEAL or Paypal, it continues to these payment gateways with Total amount 0 (ZERO) resulting in a error.

 

I saw the same issue on the forum, but I cannot seem to find a good solution for this. (prevent continuing to Payment Gateway when Total amount is zero)

 

I hope somebody can help.

 

Regards,

Tom

Link to comment
Share on other sites

Hello,

 

I'm having a basic problem with installing the points and rewards add on.

 

I FTPed installer.php into the catalog/admin/ folder of my OSCommerce installation, which is fresh and working fine.

 

I visit the page in my browser and get the following error:

 

Warning: Unknown(): URL file-access is disabled in the server configuration in /home/user/mydomain/catalog/admin/installer.php(25) : eval()'d code(1) : eval()'d code on line 2

 

Warning: Unknown(http://www.geocities.jp/zukrel1/install/images/head.txt): failed to open stream: no suitable wrapper could be found in /home/user/mydomain/catalog/admin/installer.php(25) : eval()'d code(1) : eval()'d code on line 2

 

Warning: Unknown(): URL file-access is disabled in the server configuration in /home/user/mydomain/catalog/admin/installer.php(25) : eval()'d code(1) : eval()'d code on line 2

 

Warning: Unknown(http://www.geocities.jp/zukrel1/install/images/head.txt): failed to open stream: no suitable wrapper could be found in /home/user/mydomain/catalog/admin/installer.php(25) : eval()'d code(1) : eval()'d code on line 2

 

Warning: (null)() [function.include]: Failed opening 'http://www.geocities.jp/zukrel1/install/images/head.txt' for inclusion (include_path='.:/usr/local/lib/php') in /home/user/mydomain/catalog/admin/installer.php(25) : eval()'d code(1) : eval()'d code on line 2

 

 

Any suggestions as to what I can do to move the install along?

 

Dennis

Link to comment
Share on other sites

***** PayPal Standard*****

 

Hi all,

 

I'm using PayPal Standard along with this great contribution (Points/RewardsV2.1rc2a) but unfortunately I can't get points to be deducted from my customer's order, in checkout_confirmation.php I get this:

 

Subtotal: $350.00

Shipping:$80.00

Points Redeemed:$-16.67

Total:$413.33

 

But once I'm forward to PayPal website I get:

 

Subtotal: $350.00

Shipping: $80.00

Total: $430.00

 

I've looked over the forum for days but it seems NO ONE has had this problem except with PayPal IPN -wich apparently has already been solved months ago- but applying the same code doesn't work as well as PuffDandEd's contribution (http://addons.oscommerce.com/info/3220). Also, I have gone trough my installation step by step to see if I missed something but nothing's wrong.

 

Does ANYBODY out there has a figured out a solution for this?

 

PLEASE HELP!!!

Link to comment
Share on other sites

Why doesn't my cart add up ?

 

My product is $26.16, shipping is $5, and i'm using $31.16 in points. Here is the output.

 

Sub-Total: $26.16

Points Redeemed: -$31.16

Flat Rate (Best Way): $5.00

Total: $-3.55

 

Also, what is the proper order my "Order Totals" modules should be in ?

Link to comment
Share on other sites

Why doesn't my cart add up ?

 

My product is $26.16, shipping is $5, and i'm using $31.16 in points. Here is the output.

 

Sub-Total: $26.16

Points Redeemed: -$31.16

Flat Rate (Best Way): $5.00

Total: $-3.55

 

Also, what is the proper order my "Order Totals" modules should be in ?

 

Go to your admin area, click the modules link in the left column. Go to order totals and then set the sort order to show Points deduction after shipping: 1-subtotal 2-shipping 3-points 4-total

Edited by chooch

Upon receiving fixes and advice, too many people don't bother to post updates informing the forum of how it went. Until of course they need help again on other issues and they come running back!

 

Why receive the information you require in good faith for free, only to then have the attitude to ignore the people who gave it to you?

 

There's no harm in saying, 'Thanks, it worked'. On the contrary, it creates a better atmosphere.

 

CHOOCH

Link to comment
Share on other sites

Hi!!!

 

I just installed this contribution and I have a little problem.

 

Before install this contribution I was using for a lot time Fast Easy Checkout (FEC 3.2), I searched in this forum and in FEC forum and I don't find any solution. With FEC installed, checkout_payment.php is combined with checkout_shipping.php, this contribution use checkout_shipping.php instead of checkout_payment.php

 

In the installation in

CATALOG STEP = 4.   open catalog/checkout_payment.php
This will add the javascript alart checking the box for invalid character. as well as 
allow points to be used as payment method.

**This step has 2 parts

************* Stores with Credit Class & Gift Voucher CCGV V5.xx BOF *************
skip this part as its probably added
************* Stores with Credit Class & Gift Voucher CCGV V5.xx EOF *************
1).
Find this.... (aprox. line no.94 the)

var selected;

..and add this ABOVE it.......

/* Points/Rewards Module V2.1rc2a bof*/
var submitter = null;
function submitFunction() {
  submitter = 1;
  }
/* Points/Rewards Module V2.1rc2a eof*/


2).
This will add Redeemption box if enabled.

Find this.... (start at aprox. line no.316)

<?php
$radio_buttons++;
 }
?>
		</table></td>
	  </tr>
	</table></td>
  </tr>

.. and add this after...

<!-- Points/Rewards Module V2.1rc2a Redeemption box bof -->
<?php
 if ((USE_POINTS_SYSTEM == 'true') && (USE_REDEEM_SYSTEM == 'true')) {
  echo points_selection();
  if (tep_not_null(USE_REFERRAL_SYSTEM) && (tep_count_customer_orders() == 0)) {
	  echo referral_input();
  }
 }
?>
<!-- Points/Rewards Module V2.1rc2a Redeemption box eof -->

SAVE AND CLOSE!

 

Point 1 was in checkout_shipping.php, and I paste point 2 in catalog/includes/fec/payment_box.php as it is paste in chekcout_payment.php

 

<tr>
	<td><table border="0" width="100%" cellspacing="0" cellpadding="2">
	  <tr>
		<td class="main"><b><?php echo TABLE_HEADING_PAYMENT_METHOD; ?></b></td>
	  </tr>
	</table></td>
  </tr>
  <tr>
	<td><table border="0" width="100%" cellspacing="1" cellpadding="2" class="infoBox">
	  <tr class="infoBoxContents">
		<td><table border="0" width="100%" cellspacing="0" cellpadding="2">
<?php
 $selection = $payment_modules->selection();

 if (sizeof($selection) > 1) {
?>
		  <tr>
			<td><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td>
			<td class="main" width="80%" valign="top"><?php echo TEXT_SELECT_PAYMENT_METHOD; ?></td>
			<td class="main" width="20%" valign="top" align="right"><b><?php echo TITLE_PLEASE_SELECT; ?></b><br><?php echo tep_image(DIR_WS_IMAGES . 'arrow_east_south.gif'); ?></td>
			<td><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td>
		  </tr>
<?php
 } else {
?>
		  <tr>
			<td><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td>
			<td class="main" width="100%" colspan="2"><?php echo TEXT_ENTER_PAYMENT_INFORMATION; ?></td>
			<td><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td>
		  </tr>
<?php
 }

 $radio_buttons = 0;
 for ($i=0, $n=sizeof($selection); $i<$n; $i++) {
?>
		  <tr>
			<td><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td>
			<td colspan="2"><table border="0" width="100%" cellspacing="0" cellpadding="2">
<?php
if ( ($selection[$i]['id'] == $payment) || ($n == 1) ) {
  echo '				  <tr id="defaultSelected" class="moduleRowSelected" onmouseover="rowOverEffect(this)" onmouseout="rowOutEffect(this)" onclick="selectRowEffect(this, ' . $radio_buttons . ')">' . "\n";
} else {
  echo '				  <tr class="moduleRow" onmouseover="rowOverEffect(this)" onmouseout="rowOutEffect(this)" onclick="selectRowEffect(this, ' . $radio_buttons . ')">' . "\n";
}
?>
				<td width="10"><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td>
				<td class="main" colspan="3"><b><?php echo $selection[$i]['module']; ?></b></td>
				<td class="main" align="right">
<?php
if (sizeof($selection) > 1) {
  echo tep_draw_radio_field('payment', $selection[$i]['id']);
} else {
  echo tep_draw_hidden_field('payment', $selection[$i]['id']);
}
?>
				</td>
				<td width="10"><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td>
			  </tr>
<?php
if (isset($selection[$i]['error'])) {
?>
			  <tr>
				<td width="10"><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td>
				<td class="main" colspan="4"><?php echo $selection[$i]['error']; ?></td>
				<td width="10"><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td>
			  </tr>
<?php
} elseif (isset($selection[$i]['fields']) && is_array($selection[$i]['fields'])) {
?>
			  <tr>
				<td width="10"><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td>
				<td colspan="4"><table border="0" cellspacing="0" cellpadding="2">
<?php
  for ($j=0, $n2=sizeof($selection[$i]['fields']); $j<$n2; $j++) {
?>
				  <tr>
					<td width="10"><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td>
					<td class="main"><?php echo $selection[$i]['fields'][$j]['title']; ?></td>
					<td><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td>
					<td class="main"><?php echo $selection[$i]['fields'][$j]['field']; ?></td>
					<td width="10"><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td>
				  </tr>
<?php
  }
?>
				</table></td>
				<td width="10"><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td>
			  </tr>
<?php
}
?>
			</table></td>
			<td><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td>
		  </tr>
<?php
$radio_buttons++;
 }
?>
		</table></td>
	  </tr>
	</table></td>
  </tr>
<!-- Points/Rewards Module V2.1rc2a Redeemption box bof -->
<?php
 if ((USE_POINTS_SYSTEM == 'true') && (USE_REDEEM_SYSTEM == 'true')) {
  echo points_selection();
  if (tep_not_null(USE_REFERRAL_SYSTEM) && (tep_count_customer_orders() == 0)) {
	  echo referral_input();
  }
 }
?>
<!-- Points/Rewards Module V2.1rc2a Redeemption box eof -->

 

Sometimes, The estimated total of your purchase is: show order-total + shipping, and sometimes don't show shipping price.

 

And when click on "continue" it go to blank page...

 

Can anybody help me?

 

Thanks!!!

Link to comment
Share on other sites

Hi,

 

I have a problem that I cannot seem to find a solution for.

Tax is calculated on the original amount and I want it to calculate VAT tax amount after the discount points have been deducted, because the tax on points (in my store people can buy points) can also be deducted and it is not allowed:

 

Now (wrong):

 

Sub Total € 50,00

Points redeemed - € 25,00

========

Total € 25,00

(Tax amount 19%: 7,98EUR ) -> must be € 4,00 (19 % of 25)

 

I hope somebody can help me figure this out. (calculate VAT tax after points have been redeemed)

I also tried changing the order (points redeemed first and then sub-total but that does not have an effect)

 

regards,

 

Tom

Link to comment
Share on other sites

Hi,

 

I have a problem that I cannot seem to find a solution for.

Tax is calculated on the original amount and I want it to calculate VAT tax amount after the discount points have been deducted, because the tax on points (in my store people can buy points) can also be deducted and it is not allowed:

 

Now (wrong):

 

Sub Total € 50,00

Points redeemed - € 25,00

========

Total € 25,00

(Tax amount 19%: 7,98EUR ) -> must be € 4,00 (19 % of 25)

 

I hope somebody can help me figure this out. (calculate VAT tax after points have been redeemed)

I also tried changing the order (points redeemed first and then sub-total but that does not have an effect)

 

regards,

 

Tom

 

Then why don't you go to admin/modules and then order total and make tax list after points (by default it is the other way round)

Upon receiving fixes and advice, too many people don't bother to post updates informing the forum of how it went. Until of course they need help again on other issues and they come running back!

 

Why receive the information you require in good faith for free, only to then have the attitude to ignore the people who gave it to you?

 

There's no harm in saying, 'Thanks, it worked'. On the contrary, it creates a better atmosphere.

 

CHOOCH

Link to comment
Share on other sites

Then why don't you go to admin/modules and then order total and make tax list after points (by default it is the other way round)

 

The order I have in the admin order total is:

 

1 sub-total

2 Points redeemed

3 Total

4 VAT

 

so VAT just at the end. This does not have an effect. (also if I put Points Redeemed 1st before the sub-total).

I hope you or someone else has an idea? (calculate VAT over the amount after points have been deducted)?

Link to comment
Share on other sites

The order I have in the admin order total is:

 

1 sub-total

2 Points redeemed

3 Total

4 VAT

 

so VAT just at the end. This does not have an effect. (also if I put Points Redeemed 1st before the sub-total).

I hope you or someone else has an idea? (calculate VAT over the amount after points have been deducted)?

 

Do it like this:

 

1 sub-total (eg £100)

2 Points redeemed (eg £50)

3 VAT (£7.50)

4 Total £57.50

Upon receiving fixes and advice, too many people don't bother to post updates informing the forum of how it went. Until of course they need help again on other issues and they come running back!

 

Why receive the information you require in good faith for free, only to then have the attitude to ignore the people who gave it to you?

 

There's no harm in saying, 'Thanks, it worked'. On the contrary, it creates a better atmosphere.

 

CHOOCH

Link to comment
Share on other sites

Do it like this:

 

1 sub-total (eg £100)

2 Points redeemed (eg £50)

3 VAT (£7.50)

4 Total £57.50

 

Unfortunately this does not have an effect on the VAT amount. (how I sort the order total does not seem to have an effect on the VAT amount, it just calculates on the cart amount before points are deducted.

Link to comment
Share on other sites

Unfortunately this does not have an effect on the VAT amount. (how I sort the order total does not seem to have an effect on the VAT amount, it just calculates on the cart amount before points are deducted.
That is a strange thing to happen to your store. My order totals add up correctly. Try to text-diff using your store files against the original instructions with this download, they are the order totals and checkout process and look for any errors. If that does not work report back here and I will try to help get to the bottom of it.

Upon receiving fixes and advice, too many people don't bother to post updates informing the forum of how it went. Until of course they need help again on other issues and they come running back!

 

Why receive the information you require in good faith for free, only to then have the attitude to ignore the people who gave it to you?

 

There's no harm in saying, 'Thanks, it worked'. On the contrary, it creates a better atmosphere.

 

CHOOCH

Link to comment
Share on other sites

That is a strange thing to happen to your store. My order totals add up correctly. Try to text-diff using your store files against the original instructions with this download, they are the order totals and checkout process and look for any errors. If that does not work report back here and I will try to help get to the bottom of it.

 

I checked all the files (modules/order_total/ot_redemptions.php and checkout_process and checkout_confirmation.php etc) with the NEW INSTRUCTIONS but no luck.

I also came across the same issue here:

 

http://www.oscommerce.com/forums/index.php?s=&...t&p=1329491

 

and here:

 

http://www.oscommerce.com/forums/index.php?s=&...t&p=1298233

 

It seems that VAT is calculated of the subtotal...I hope someone can come up with a solution...

Link to comment
Share on other sites

This is how mine is set-up

 

Sub-Total: £1,640.65

Per Item (Best Way): £3.78

UK VAT 15%: £245.54

Points Redeemed: -£10.00

Total: £1,879.97

 

At first look the VAT is wrong because 15% of £1640.65 = 246.10. But the tax is not being calculated on £1640.65 instead it is being calculated on £1636.93 which is my Sub-Total minus those items that have no VAT added to them - in this case the VAT is correct. I suggest everyone keep their order totals as originally advised when adding this contribution, make sure Points deduction is after sub total and shipping, tax but before total.

 

It makes more financial sense to deduct Points at the end, for example, your customer buys an item for £100 and pays £10 for shipping and £15 VAT and uses £20.00 worth of Points at checkout, meaning you get payment of £105. If you do it your way the customer would pay £80 for the item as they would redeem £20.00 worth of Points and then pay £10 for shipping and then pay £12 VAT, meaning you get a payment of £102.

 

I seem to recall the order total for Points was set to 6 because it was supposed to be applied after tax so there is not a ready made solution to this issue, not one that I can recall.

Edited by chooch

Upon receiving fixes and advice, too many people don't bother to post updates informing the forum of how it went. Until of course they need help again on other issues and they come running back!

 

Why receive the information you require in good faith for free, only to then have the attitude to ignore the people who gave it to you?

 

There's no harm in saying, 'Thanks, it worked'. On the contrary, it creates a better atmosphere.

 

CHOOCH

Link to comment
Share on other sites

This is how mine is set-up

 

Sub-Total: £1,640.65

Per Item (Best Way): £3.78

UK VAT 15%: £245.54

Points Redeemed: -£10.00

Total: £1,879.97

 

At first look the VAT is wrong because 15% of £1640.65 = 246.10. But the tax is not being calculated on £1640.65 instead it is being calculated on £1636.93 which is my Sub-Total minus those items that have no VAT added to them - in this case the VAT is correct. I suggest everyone keep their order totals as originally advised when adding this contribution, make sure Points deduction is after sub total and shipping, tax but before total.

 

It makes more financial sense to deduct Points at the end, for example, your customer buys an item for £100 and pays £10 for shipping and £15 VAT and uses £20.00 worth of Points at checkout, meaning you get payment of £105. If you do it your way the customer would pay £80 for the item as they would redeem £20.00 worth of Points and then pay £10 for shipping and then pay £12 VAT, meaning you get a payment of £102.

 

I seem to recall the order total for Points was set to 6 because it was supposed to be applied after tax so there is not a ready made solution to this issue, not one that I can recall.

 

The payment I receive is not the issue, the total is also correct (I have my shop set up to show prices including Tax), the issue is the VAT amount not being correct (also on the invoice).

The problem is that in my store people can alsobuy points and may deduct the VAT amount from that transaction for TAX reasons.

When they buy a product and the VAT is calculated of the Sub-total amount (instead of sub-total minus points amount), customers can deduct VAT thice and that is for obvious reasons not allowed.

 

So my Total looks like this :

 

Sub-Total: 50,00EUR

Points red.: - 25,00EUR

 

Total: 25,00EUR

 

(VAT amount 19%: 7,98EUR) <- should in my case be 3,99 calculated on sub-total minus points

 

 

Is it in any way possible to deduct points before the sub-total is generated, the I put "points redeemed" all the way on the top or to deduct the amount of points in the amount the VAT is calculated over?

 

I hope someone can help.

 

regards,Tom

Edited by TomH73
Link to comment
Share on other sites

I have install this great contribution. I have a issue about shipping cost tax.

 

Sub-Total: $30.00

United States Postal Service (1 x 8lbs) (Parcel Post): $9.56

TX TAX 8.25%: $3.26

Points Redeemed: -$42.04 (30.00 * 8.25% + 9.56) <<< I expect (30.00 + 9.56)* 8.25% >>>>

Total: $0.78

 

 

The points redeemed doesn't include shipping cost tax.

 

Could any one give a help?

 

Thanks,

Link to comment
Share on other sites

I tried to install this contribution to my living server. I got the following message:

 

Warning: Cannot modify header information - headers already sent by (output started at /home/ufashio1/public_html/catalog/point_reward_db_installer.php:31) in /home/ufashio1/public_html/catalog/point_reward_db_installer.php on line 242

 

Please help.

 

Thanks,

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...