User Points earned in each order in the order list

  • Posts: 45
  • Thank you received: 0
  • Hikashop Business
3 years 9 months ago #329028

-- HikaShop version -- : 4.4
-- Joomla version -- : 3.9.24
-- PHP version -- : 7.3
-- Error-message(debug-mod must be tuned on) -- : User Points earned in each order in the order list or order detail in backend

Hello,
I want, if possible, that order list in backend management display the User Points earned in each order or if not possible in the order detail. I use the user points of Hikashop. It's possible? What customisation i need to do in the layouts?
Thanks a lot by your help.

Best regards,
Bruno Simões

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

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
3 years 9 months ago #329100

Hi,

For the orders listing, you can edit the file order / listing.php via the menu Display>Views.
There, you can add such code to display the points of the current order supposing that you're not using AltaUserPoints nor EasySocial:

<?php echo @$row->order_payment_params->userpoints->earn_points['hk'] ?>
For example, you could add such code after the line:
<?php echo $this->currencyHelper->format($row->order_full_price,$row->order_currency_id);?>
to have it displayed next to the order total amount.

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

  • Posts: 45
  • Thank you received: 0
  • Hikashop Business
3 years 9 months ago #329101

Super!!!! Thanks a lot Nicolas.

Best regards,
Bruno

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

  • Posts: 45
  • Thank you received: 0
  • Hikashop Business
3 years 9 months ago #329110

Hi Nicolas,
I tryed your solution in the backend editing the file order / listing.php (version 4.4.0) and the points are not show.
I missing something?

Best regards,
Bruno

Last edit: 3 years 9 months ago by bsimoes.

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

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
3 years 9 months ago #329112

Hi,

Well, I don't know.
I've written this code from the top of my head.
I didn't do a debug to check that the variable is correct and that no additional processing is required. It would require I setup an environemnt locally to get an order with points so that I could then do some debugging to check the variables I'm trying to use in this code.
Please understand that we're here to provide answers to your questions and fix bugs. Note do custom development for free.

If you want us to work on that for you, we can do it as a custom job. You can contact us via our contact form to discuss about the details:
www.hikashop.com/support/contact-us.html
We could also add on our todo list to add an extra option to the points plugin system to add a column to the orders listing to display the points but then, I can't say when that would be available in the future as we have already many things on our todo list.

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

  • Posts: 45
  • Thank you received: 0
  • Hikashop Business
3 years 9 months ago #329154

Hello,

I don't ask a custom development. I ask some help or idea to control the points given to orders. And I give you some feedback about that your suggestion doesn’t works.
Why? Because in some moment of second quarter of 2020 the point system of Hikashop starts doubling points to users without a reason. And this causes loses in online store. And it's difficult explain to the client that his points are incorrect when the points earned or spend aren't visible in their order information. So, if you fix bugs, fix your bugs to don't causes loses to the users that paid a hikashop license!
At this moment I don't trust in hikashop point systems and I looking for a simple solution that allows me to control the points given in each order.

Stay well and healthy!

Best regards,
Bruno

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

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
3 years 9 months ago #329529

Hello,

I'm sorry but in your very first message in that thread, you were talking about a new feature in order to display the user points in the order details.
Thus, Nicolas tried to give you a fast solution for a specific case.
There was no mention of any bug or issue regarding the points.

If you have bugs, please open a forum thread in that direction (as you did in the other thread).
If you have a feature request, fell free to submit them and the team will take it under consideration for future improvements.
If you have important need of a feature, the custom development is still a possibility.

In the year 2020, the only modification in the plugin which could have an effect on the number of points is related to that thread:
www.hikashop.com/forum/4-how-to/896295-h...r-points.html#325882
So, if your issue is not related to the order modification in the backend (CF: www.hikashop.com/forum/orders-management...ts-issue.html#329174 ) ; you might want to check your configuration for the limit on product type which didn't work properly before the patch, but which can have an unwanted side effect for you.

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: 45
  • Thank you received: 0
  • Hikashop Business
3 years 9 months ago #329552

Hello Jerome,

As I said in my first message, I’m looking for a simple solution to see the user points changes (earns and used) in the backend order. Why? Because I detect that in some moment of the second quarter of 2020 some users earned much more points than they should in their orders. I detect this now as I told in my second message. As I said in another post ( www.hikashop.com/forum/orders-management...ts-issue.html#329245 ) there are other issues with Hikashop user points. So, I’m looking for something simples and visual that shows the earn and uses of points without the need to dive into the database.
I appreciate the quick answer from Nicolas, I tried and how it didn’t work I tell here.
If you want a suggestion, you may consider in future updates add the points earned/used in order details.
At this moment a have a simple solution as you can see in the image attached (Pontos atribuídos: earned points | utilizados: used points).





Best regards,
Bruno

Attachments:
Last edit: 3 years 9 months ago by bsimoes.

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

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
3 years 9 months ago #329718

Hi,

Thank you for your feedback.
I agree that it's a nice feature to have in the future.
I've added it on our end so that we can add that option rapidly to the user points system.
I think we should be able to add that for the next version of HikaShop in 2 months.

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

Time to create page: 0.078 seconds
Powered by Kunena Forum