AlphaUserPoints plugin has wrong behavior

  • Posts: 40
  • Thank you received: 2
11 years 1 week ago #133269

I am experiencing wrong behavior with the AlphaUserPoints plugin. (Sorry posted in wrong category)

The plugin is deducting currency (from points) that would be given after a payment would be received, already in checkout (before paying). This seems wrong.
I think there might be a problem with the configuration of the plugin regarding that setting (earn points after payment) or something similar.

-- HikaShop version -- : 2.2.2
-- Joomla version -- : 3.2.0
-- PHP version -- : 5.4.21
-- Browser(s) name and version -- : anyone

Thanks,
Frank

Last edit: 11 years 1 week ago by thesilentman.

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
11 years 6 days ago #133274

Hi,

I don't understand your message and your problem.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 40
  • Thank you received: 2
11 years 6 days ago #133371

I wrote it in a hurry as I had to leave... here's the longer version...

I have the UserPoints plugin set up to work with AlphaUserPoints. I have set up for the user to earn some points when a payment is made for a purchase.

First problem: there is no translation for some settings of the plugin (See the capitalized language file strings)...
I read:

Specific configuration:
==================
"POINTS_MODE:" - This one is clear. either use AUP or Hikashop points
"POINTS_NOT_GIVE_WHEN_USE" - I believe that means "do not give points until paid" Right? Wrong? I have set this to "Yes"
"GIVE_VIRTUAL_POINTS" - This seems clear... Have set this to "Yes"
Rates: I set this to 0.1 (EUR = 1 Points)
"Products " - is empty. I believe this stands for "All"
LIMIT_POINTS_BY_TYPE - Not sure about this setting. Yes seems to work.
"Shipping gives points" - This is set to "Yes" I believe that this means that shipping costs do also give points.

Points earning on categories:
=======================
"LIMIT_POINTS_BY_CATEGORY" - This seems clear. I have no specific setting for this.

Points earning on groups:
=====================
No specific setup here...

Access level:
===========
I have set this to "all"


The second problem is, that there is no manual on this plugin. How to use it correctly?

The third is the actual issue:
Let's say I am a new user and have never purchased something before.
I put something in my cart, let's say worth of 10 Euro and let's say for simplicity it has no shipping .

When I click checkout, it will show me the 10 Euro of the product and will deduct automatically 1 Euro worth of points, which I have not earned yet, as I have not yet paid for the purchase. So, Hikashop is somehow giving points, before I have paid anything.

BTW, the one Euro comes from the setting "Rate" in the plugin, which I set to 0.1 EUR = 1 Points

I hope you understand my message and problem now... ;)

Thanks

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
11 years 6 days ago #133479

Hi,

POINTS_MODE="Points mode"
POINTS_NOT_GIVE_WHEN_USE="Don't give points when using some"
GIVE_VIRTUAL_POINTS="Give virtual points"
LIMIT_POINTS_BY_TYPE="Limit by type"
LIMIT_POINTS_BY_CATEGORY="Limit by category"
HIKASHOP_USER_POINTS="HikaShop user points"
The option of the plugin "User Points" come from the "old" plugin for AlphaUserPoints.
www.hikashop.com/support/integrated-docu...userpoints-form.html

POINTS_NOT_GIVE_WHEN_USE : Do not give points if the user is using some.
If the user is using some points during the order, we won't give him points for this order.

Use virtual points : If you turn on that option, the points which would be earned by the user when finishing the order can directly be used (along with the points already on the user's account) to pay/get a discount on the current cart.

Limit by type: If you activate this option, the defined points above will be given only once for each kind of product. Else, each product will give the defined number of points (for example, 4 T-shirt will give here 40 points).


Hope it will help you to understand the plugin.
We do a migration of the AlphaUserPoints plugin in order to separate the payment and the gain of points. We also introduce the possibility to use points from an HikaShop custom field (that you have to name "user_points") in order to have some kind of point system for Joomla 3.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 40
  • Thank you received: 2
11 years 6 days ago #133495

Hi Jerome,
thanks for your reply.

I understand now.

Basically that means that if I want to use virtual points for payment, I don't have the choice not to use the points that "WOULD BE" earned for this purchase. Is there something you can do about that? As it does not make sense commercially... ;)
Explanation: When a user earns points we want to give them to him after he/she has paid, so that the user has some incentive to come back again for another purchase.
I think I remember the old plugin correctly having a setting for that. Why does the new one not have this setting?

Thanks

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
11 years 6 days ago #133499

Hi,

As it does not make sense commercially... ;)

You can search on the forum, it was a user request for commercial purposes.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 40
  • Thank you received: 2
11 years 6 days ago #133512

Hi,
sorry, couldn't find anything that would resemble the issue I am having.

I searched for AUP, alpha and points

There were some that came close, but they were using the old plugin, which actually still has the:
Give points on statuses option...
and as the documentation here states ==>
"Give points on statuses: With that option, you can override the statuses for which the points are given to users."

This is what I need to do, but the option is just not there anymore...
What to do?

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
11 years 5 days ago #133520

Hi,

Because it is a global option, it is now in the plugin configuration itself.
demo.hikashop.com/administrator/index.ph...t&extension_id=10162

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.
The following user(s) said Thank You: thesilentman

Please Log in or Create an account to join the conversation.

  • Posts: 40
  • Thank you received: 2
11 years 5 days ago #133602

Thanks! I'll try it out a bit later.

Please Log in or Create an account to join the conversation.

  • Posts: 40
  • Thank you received: 2
11 years 5 days ago #133647

Hi,
I set the statuses to: "confirmed, shipped" but it is still allowing to use the points that are not yet earned. See picture



(It's the german translation, but you see that the user has 0 points and the system offers to convert the (not yet earned points to a coupon))

Here are the settings of the Userpoint plugin [1/2]:



Here are the settings of the Userpoint plugin (Payment) [2/2]:



What to do?

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
11 years 5 days ago #133682

Hi,

I do not understand you and your screenshots.
If the user don't have points, it is sure that he won't be able to use it to pay.
We are not interesting by your userpoints payment configuration, but by your userpoints hikashop plugin configuration ; the one in the plugin section.
demo.hikashop.com/administrator/index.ph...=plugin&subtask=edit

Do you have AlphaUserPoints ? What is the point status of your user ?
Are you sure that the order will give points to the user ?
Does the order been create after your userpoints configuration ?
Is your "status" configuration right (the previous post) ?

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.
Last edit: 11 years 5 days ago by Jerome.

Please Log in or Create an account to join the conversation.

  • Posts: 40
  • Thank you received: 2
11 years 5 days ago #133686

Hi,

I really don't understand why you can't understand me and my screenshots.
It's all clearly laid out!
And I am proving below, the one screenshot in my previous post is the plugin configuration that you're asking for.
I attached the other screenshot just in case it would help you in some way.

If the user don't have points, it is sure that he won't be able to use it to pay.

The first screenshot in the previous post is from the checkout process and it is only there to prove to you, that even if the user has ZERO points, he gets the option to turn the points he would earn from this purchase, to a coupon.
The text is from your German translations.
You can see clearly that it says that the user has 0 points which corresponds to 0,00 €.
And then it says that the user can turn his points (WHICH HE HAS ACTUALLY NOT YET EARNED!!!) into a discount of 1,98€ !
Don't need to know German for that, in that context.
BTW the total in the cart was 19,80EUR and the user would earn 198 points. Those 198 points should not be there yet, in order to produce a discount coupon. They should be earned after confirmation or shipment.

We are not interesting by your userpoints payment configuration, but by your userpoints hikashop plugin configuration ; the one in the plugin section.


2. The second screenshot IS from the userpoints hikashop plugin plugin configuration!! It's the right bar, and there you see all the configuration!!

Do you have AlphaUserPoints ? What is the point status of your user ?

Of course I have AlphaUserPoints... And I have done several tests. The last one having reset the user to ZERO points. Directly after that I went to make a test order. And result of this is the first screenshot showing that in the payment options page having ZERO point I can already use the points that I HAVE NOT YET EARNED!

Are you sure that the order will give points to the user ?

Yes, It will give points --> It's already giving the points before actually reaching status "confirmed" or "shipped" . That's the issue here!

Does the order been create after your userpoints configuration ?

Yes.

The content of the status field is exactly this(copied and pasted): confirmed, shipped

Last edit: 11 years 5 days ago by thesilentman.

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
11 years 2 hours ago #134241

Hi,

Please edit the plugin "plugins/hikashoppayment/userpoints/userpoints.php" and replace

	function getVirtualPoints($order, $mode = 'all') {
		$plugin = hikashop_import('hikashop', 'userpoints');
		$points = 0;
		if($mode == 'all')
			$points = array();
		$plugin->onGetUserPointsEarned($order, $points, $mode);
		return $points;
	}
By:
	function getVirtualPoints($order, $mode = 'all') {
		$plugin = hikashop_import('hikashop', 'userpoints');
		$points = 0;
		if($mode == 'all')
			$points = array();
		$plugin->onGetUserPointsEarned($order, $points, $mode, true);
		return $points;
	}
It will fix your problem about virtual points.
This fix will be include in the next HikaShop release.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.
The following user(s) said Thank You: thesilentman

Please Log in or Create an account to join the conversation.

  • Posts: 40
  • Thank you received: 2
10 years 11 months ago #134384

Hi Jerome,

Yes :) this was the solution. Works as expected now.

Thank you

Please Log in or Create an account to join the conversation.

Time to create page: 0.093 seconds
Powered by Kunena Forum