Re: Reward Points Module- Live Release now available.
Quote:
Originally Posted by
snowy2007
Good thinking about that pitfall Andrew! I think I will leave it so that they change when the order status changes to processing.
Another thing : I have over 7000 newsletter subscribers, 2500ish of which are registered customers. I realise that I can try to convert the 5500 subscribers who aren't yet customers by giving x number of free points to new accounts but.... Is there any way I can reward my existing customers by giving them all, say, 500 points to spend?
It's on the wishlist.
Re: Reward Points Module- Live Release now available.
Quote:
Originally Posted by
hem
It's on the wishlist.
I take it the only easy way at the moment would be via an SQL query?
Re: Reward Points Module- Live Release now available.
I have just had a look at the tables - scrap my previous post :)
A small bit of php code should do the trick. Am I correct in thinking it would have to do the following :
For each record in the
customer table :
1. Extract the customers_id
2. Insert a new record into the reward_customer_points table with the extracted customers_id copied into the corresponding field and a points value inserted into the reward_points field
Re: Reward Points Module- Live Release now available.
Would this bit of code do the trick to add 200 points to each customer? :
PHP Code:
<?PHP
$user_name = "username";
$password = "password";
$database = "databasename";
$server = "localhost";
$db_handle = mysql_connect($server, $user_name, $password);
$db_found = mysql_select_db($database, $db_handle);
if ($db_found) {
$SQL = "SELECT * FROM customers";
$result = mysql_query($SQL);
while ($db_field = mysql_fetch_assoc($result)) {
$custid=$db_field['customers_id'];
$SQLINSERT = "INSERT INTO reward_customer_points (customers_id, reward_points)"
. " VALUES ('$custid', 200)";
$rows = mysql_query($SQLINSERT);
if(!$rows) {
$message = "Insert error: " . mysql_error();
}
}
mysql_close($db_handle);
}
else {
print "Database NOT Found ";
mysql_close($db_handle);
}
?>
Re: Reward Points Module- Live Release now available.
Quick question - I searched the thread but haven't found anything on it.
If I have Dual Pricing installed, it is possible to NOT allow my wholesale customers to accumulate points or would this be a custom bit of code?
Thanks!
Re: Reward Points Module- Live Release now available.
Quote:
Originally Posted by
snowy2007
Would this bit of code do the trick to add 200 points to each customer? :
PHP Code:
<?PHP
$user_name = "username";
$password = "password";
$database = "databasename";
$server = "localhost";
$db_handle = mysql_connect($server, $user_name, $password);
$db_found = mysql_select_db($database, $db_handle);
if ($db_found) {
$SQL = "SELECT * FROM customers";
$result = mysql_query($SQL);
while ($db_field = mysql_fetch_assoc($result)) {
$custid=$db_field['customers_id'];
$SQLINSERT = "INSERT INTO reward_customer_points (customers_id, reward_points)"
. " VALUES ('$custid', 200)";
$rows = mysql_query($SQLINSERT);
if(!$rows) {
$message = "Insert error: " . mysql_error();
}
}
mysql_close($db_handle);
}
else {
print "Database NOT Found ";
mysql_close($db_handle);
}
?>
That should do it. If you "include 'application_top.php'" you could use the function UpdateCustomerRewardPoints($customer_id,$reward_points,$pending_points) which will append the points to any customer that already has points.
Re: Reward Points Module- Live Release now available.
Quote:
Originally Posted by
janellez
Quick question - I searched the thread but haven't found anything on it.
If I have Dual Pricing installed, it is possible to NOT allow my wholesale customers to accumulate points or would this be a custom bit of code?
Thanks!
If they are all Grouped together you can set the redeem ratio for the group to 0.
Re: Reward Points Module- Live Release now available.
Quote:
Originally Posted by
hem
That should do it. If you "include 'application_top.php'" you could use the function UpdateCustomerRewardPoints($customer_id,$reward_points,$pending_points) which will append the points to any customer that already has points.
Excellent!
Here's something to think about: Can you think of a way of doing this :
1. Give all customers the 200 points on Friday
2. If they haven't spent them (or some of them) by Sunday evening then take the 200 points away from them (time limited points offer basically).
Also, is there any easy way of turning the module off on a temporary basis - It is on the site now but I don't really want customers to be earning points until I send a newsletter out announcing it later this week.
Re: Reward Points Module- Live Release now available.
Quote:
Originally Posted by
snowy2007
Excellent!
Here's something to think about: Can you think of a way of doing this :
1. Give all customers the 200 points on Friday
2. If they haven't spent them (or some of them) by Sunday evening then take the 200 points away from them (time limited points offer basically).
Also, is there any easy way of turning the module off on a temporary basis - It is on the site now but I don't really want customers to be earning points until I send a newsletter out announcing it later this week.
I have ideas for a Campaign addon which would do things like that, as well as say double points for certain items ordered within a particular period and Reward Points being worth more (again it would be time based).
As for switching off the mod- Just uninstall the Order Total modules and switch off any of the Reward Point sideboxes under Layout Manager.
Re: Reward Points Module- Live Release now available.
Quote:
Originally Posted by
hem
I have ideas for a Campaign addon which would do things like that, as well as say double points for certain items ordered within a particular period and Reward Points being worth more (again it would be time based).
That would be a fantastic addition to an already great mod - i'm guessing there is no time scale for it yet though :blush: