Post by straightlight » Sun Jun 19, 2016 12:24 pm

This contribution allows merchants to set points to customers account whenever they:

- Register an account
- Post a review

The merchant can either activate, deactivate the module, set the debug function in case of failed emails to track its position.
Email notifications can be configured through the module so that merchants gets a store notice that 'x' customer is out of points.
Customer's account notification added through the site near the breadcrumb so that customers can be notified that new points have been reset on their account.

Additionally, multiple rows can be added through the module by configuring:

- The customer groups
- Points based on Total or Subtotal
- Configure the worth price
- Configure the Minimum order amount when points can be used

Points are being calculated through order totals when customers adds products to their cart based on the total amount, not per-item.

Simply follow the documentation below to add new SQL fields. No core files alteration involved, simply new files and a VQMod file.

Detailed documentation provided in the package.

Contribution: http://www.opencart.com/index.php?route ... n_id=27013

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by i2Paq » Tue Jun 21, 2016 3:43 pm

Just bought your Extension!

Will report back with a review ;)

Norman in 't Veldt
Moderator OpenCart Forums

_________________ READ and Search BEFORE POSTING _________________

Our FREE search: Find your answer FAST!.

[How to] BTW + Verzend + betaal setup.


User avatar
Global Moderator

Posts

Joined
Mon Nov 09, 2009 7:00 pm
Location - Winkel - The Netherlands

Post by straightlight » Tue Jun 21, 2016 6:36 pm

Thanks i2paq. That is greatly appreciated.

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by straightlight » Tue Jun 21, 2016 8:46 pm

Additional notes: The points has only been programmed by integer; no decimals according to your other topic demonstrating the functionality of your last version's contribution though (points worth value field).
Last edited by straightlight on Tue Jun 21, 2016 8:48 pm, edited 1 time in total.

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by i2Paq » Tue Jun 21, 2016 9:57 pm

I' seem to be missing this in the config module part:

Code: Select all

$_['entry_customer_registration'] = 'Customer Registration';

Norman in 't Veldt
Moderator OpenCart Forums

_________________ READ and Search BEFORE POSTING _________________

Our FREE search: Find your answer FAST!.

[How to] BTW + Verzend + betaal setup.


User avatar
Global Moderator

Posts

Joined
Mon Nov 09, 2009 7:00 pm
Location - Winkel - The Netherlands

Post by straightlight » Tue Jun 21, 2016 10:01 pm

i2Paq wrote:I'm also missing this in the config module part:

Code: Select all

$_['entry_customer_registration'] = 'Customer Registration';
Correct. Although, it is not missing. I simply forgot to remove the entries but will not cause any impact on the extension. Thanks for reporting this, though. I will remove the entries accordingly and refresh the package momentarily.

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by i2Paq » Tue Jun 21, 2016 10:18 pm

How does it work?

Points Worth Cost: 1 point cost $25

Min. Order Amount = $45

Points Per Review = $1

Points Worth Value 1 point = ? (can I set it at $25cent)?
Because setting 1 point = $1 is not what I need.

It should be more like 1 point = $0.25 or 4 points = $1

Norman in 't Veldt
Moderator OpenCart Forums

_________________ READ and Search BEFORE POSTING _________________

Our FREE search: Find your answer FAST!.

[How to] BTW + Verzend + betaal setup.


User avatar
Global Moderator

Posts

Joined
Mon Nov 09, 2009 7:00 pm
Location - Winkel - The Netherlands

Post by straightlight » Tue Jun 21, 2016 10:22 pm

It should be more like 1 point = $0.25 or 4 points = $1
That is correct.

Points Worth Value: 1 (or 4 points)
Points Worth Cost: 0.25 (or 1 x 4 points from the points worth value = 1)
Min. Order Amount: 45.00
Status: Yes / No
Points Per Review: 1

According to your example, the Points worth value is numeric, points worth cost is float, min order amount is float and points per review, as per your screenshot is numeric.

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by straightlight » Tue Jun 21, 2016 10:28 pm

i2Paq wrote:Great!

Next!

I ordered for an amount of $600, no points get added.
The points are reflected to the customer's account once a purchase has been set to processing before completion, not on the order; same methodology as the original Opencart order history is defined from checkout. From the API, when you edit an order for instance, the order total will still re-affect the customer's account when setting the points and also when posting new reviews in this case. :)

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by straightlight » Wed Jun 22, 2016 8:52 pm

Package updated on the extensions page. Several bug fixes have been applied, information module language file added. Documentation added on the extensions page. Everything should be working as expected, now.

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by i2Paq » Wed Jun 22, 2016 10:28 pm

straightlight wrote:Package updated on the extensions page. Several bug fixes have been applied, information module language file added. Documentation added on the extensions page. Everything should be working as expected, now.
Cleaned up this topic ;)

I will try later today or tomorrow.

Busy in my kitchen as it will be completely renewed next week and the plasterer will come tomorrow ^-^

Norman in 't Veldt
Moderator OpenCart Forums

_________________ READ and Search BEFORE POSTING _________________

Our FREE search: Find your answer FAST!.

[How to] BTW + Verzend + betaal setup.


User avatar
Global Moderator

Posts

Joined
Mon Nov 09, 2009 7:00 pm
Location - Winkel - The Netherlands

Post by straightlight » Wed Jun 22, 2016 10:48 pm

Sure, no problem. Let me know once tested.

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by i2Paq » Wed Jul 13, 2016 2:21 pm

I installed the latest version you send me but I still get no reward points, anywhere.

What else do I need to configure?

Norman in 't Veldt
Moderator OpenCart Forums

_________________ READ and Search BEFORE POSTING _________________

Our FREE search: Find your answer FAST!.

[How to] BTW + Verzend + betaal setup.


User avatar
Global Moderator

Posts

Joined
Mon Nov 09, 2009 7:00 pm
Location - Winkel - The Netherlands

Post by straightlight » Wed Jul 13, 2016 6:36 pm

i2Paq wrote:I installed the latest version you send me but I still get no reward points, anywhere.

What else do I need to configure?
Quite of a very vague review there. Could you provide the step-by-step that you did? Also, which OC version are you using?

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by i2Paq » Wed Jul 13, 2016 9:13 pm

straightlight wrote:
i2Paq wrote:I installed the latest version you send me but I still get no reward points, anywhere.

What else do I need to configure?
Quite of a very vague review there. Could you provide the step-by-step that you did? Also, which OC version are you using?
I'm using 2.2.0.0

I have uploaded all the files and cleared my vQmod cache.

I then installed the module + created how many points, points worth etc. (see attached image).

Then I registered a new account an placed an order.

Attachments

Screenshot - 13-7-2016 , 15_11_59.png

Screenshot - 13-7-2016 , 15_11_59.png (16.87 KiB) Viewed 3399 times


Norman in 't Veldt
Moderator OpenCart Forums

_________________ READ and Search BEFORE POSTING _________________

Our FREE search: Find your answer FAST!.

[How to] BTW + Verzend + betaal setup.


User avatar
Global Moderator

Posts

Joined
Mon Nov 09, 2009 7:00 pm
Location - Winkel - The Netherlands

Post by straightlight » Wed Jul 13, 2016 9:22 pm

According to your screenshot, the cost and the amount is still considered as integer rather than forcing float values.

In admin/controller/module/global_reward_point.php file,

find all instances of:

Code: Select all

FILTER_VALIDATE_FLOAT
replace each with:

Code: Select all

FILTER_SANITIZE_NUMBER_FLOAT, FILTER_FLAG_ALLOW_FRACTION
Then, edit the module form and see if the same behavior occurs when saving those specific values as integers.

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by i2Paq » Wed Jul 13, 2016 11:25 pm

I've done that but still no points when registering.

Norman in 't Veldt
Moderator OpenCart Forums

_________________ READ and Search BEFORE POSTING _________________

Our FREE search: Find your answer FAST!.

[How to] BTW + Verzend + betaal setup.


User avatar
Global Moderator

Posts

Joined
Mon Nov 09, 2009 7:00 pm
Location - Winkel - The Netherlands

Post by straightlight » Wed Jul 13, 2016 11:31 pm

i2Paq wrote:I've done that but still no points when registering.
Are the changed decimals forced to decimal outputs on the text box in the module or they are still being outputted as integers? Could you confirm these results?

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by i2Paq » Wed Jul 13, 2016 11:32 pm

straightlight wrote:
i2Paq wrote:I've done that but still no points when registering.
Are the changed decimals forced to decimal outputs on the text box in the module or they are still being outputted as integers? Could you confirm these results?
I'm not sure what you mean.

Maybe have a look yourself in my Admin?

Norman in 't Veldt
Moderator OpenCart Forums

_________________ READ and Search BEFORE POSTING _________________

Our FREE search: Find your answer FAST!.

[How to] BTW + Verzend + betaal setup.


User avatar
Global Moderator

Posts

Joined
Mon Nov 09, 2009 7:00 pm
Location - Winkel - The Netherlands

Post by straightlight » Wed Jul 13, 2016 11:37 pm

Sure, send me the info over PM.

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON
Who is online

Users browsing this forum: No registered users and 1 guest