Post by cartgirl » Tue Sep 25, 2012 1:42 am

Is there a way to set the minimum # of Rewards Points required before a customer is eligible to redeem them toward a product?

ie. The customer has 580 points.
The product they are buying will reward them with 160 points for buying it.
If they wanted to get the product for FREE, they'd need 1600 points.

But, the customer is still permitted to use their 580 points toward this product, which means they get $5.80 off of the item.
I don't want that. I want them to have a minimum of 1000 points earned before they can redeem.

Possible??

Active Member

Posts

Joined
Fri Aug 03, 2012 10:12 pm

Post by dirtboy » Tue Sep 25, 2012 1:47 am

check out this module, it enforces the product minimum for reward points so they can use all or none

http://www.opencart.com/index.php?route ... d%20points

“Anyone who stops learning is old, whether at twenty or eighty. Anyone who keeps learning stays young. The greatest thing in life is to keep your mind young.”
- Henry Ford


User avatar
Active Member

Posts

Joined
Wed Mar 07, 2012 3:04 pm

Post by cartgirl » Tue Sep 25, 2012 2:00 am

Thanks so much!
I'm going to try that out!

Active Member

Posts

Joined
Fri Aug 03, 2012 10:12 pm

Post by mash0028 » Tue Mar 08, 2016 2:37 pm

For you to set the minimum or Maximum used of Reward points

For version 2.0X and above, I am using 2.0.2.0

Just add or Change
in file :
catalog/language/english/checkout/reward.php

Code: Select all

$_['error_maximum'] = 'Warning: The maximum number of points that can be applied is less than %s!';
$_['error_min']     = 'Warning: The minimum number of points that can be applied is greater than %s!';

In

catalog/controller/checkout/reward.php


Change the Two SAME codes in

public function index() {
and
public function reward() {

in same file

change your Points_total to (MAXIMUM POINTS CAN BE USED) or DONT CHANGE IT IF YOU WANT TO MAKE IT BASED ON TOTAL PRODUCT POINTS IN YOUR CUSTOMER CART.


for POINT_MIN (MINIMUM POINTS CAN BE USED)


Code: Select all

		$points_total = 210;

		$points_min = 100;

		foreach ($this->cart->getProducts() as $product) {
			if ($product['points']) {
				$points_total <= $product['points'];
			} else {
				$points_min >= $product['points'];
			}
		}


and

Before

Code: Select all

		if ($this->request->post['reward'] > $points_total) {
			$json['error'] = sprintf($this->language->get('error_maximum'), $points_total);
		}

Add this

Code: Select all

		if ($this->request->post['reward'] < $points_min) {
			$json['error'] = sprintf($this->language->get('error_min'), $points_min);
		}
Hoping I can help!

New member

Posts

Joined
Fri Jul 24, 2015 3:36 pm
Who is online

Users browsing this forum: No registered users and 45 guests