News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

[Fixed]Order name empty virtuemart 3.6.11

Started by amlil71, April 25, 2020, 17:15:44 PM

Previous topic - Next topic

amlil71

Hello,

i have update virtuemart to 3.6.11 since i have some bugs with 3.6.10.

It's ok now but the name of customers is empty in the orders list page.

Do you have an idea to solve this ?

Thank you.

Regards.

Jörgen

#1
Is it also emptied in the order view?
If it is visible there check with the inspector F12 to see if the name is hidden with CSS.

Jörgen @ Kreativ Fotografi
Joomla 3.9.18
Virtuemart 3.4.x
Olympiantheme Hera (customized)
This reflects current status when viewing old post.

amlil71

#2
Hello,

thank you for your answer.

I have found the roof of this issue.

I have change the code of the orders.php file  located in administrator\components\com_virtuemart\views\orders\tmpl

The code wich doesn't work in 3.6.11 release

$userlink = JRoute::_ ('index.php?option=com_virtuemart&view=user&task=edit&virtuemart_user_id[]=' . $order->virtuemart_user_id, FALSE);
echo JHtml::_ ('link', $userlink, FALSE, $orderName, array('title' => vmText::_ ('COM_VIRTUEMART_ORDER_EDIT_USER') . ' ' .  $orderName));


I have replaced this code with the one from 3.6.10 release which works

$userlink = JROUTE::_ ('index.php?option=com_virtuemart&view=user&task=edit&virtuemart_user_id[]=' . $order->virtuemart_user_id, FALSE);
echo JHtml::_ ('link', JRoute::_ ($userlink, FALSE), $order->order_name, array('title' => vmText::_ ('COM_VIRTUEMART_ORDER_EDIT_USER') . ' ' .  $order->order_name));


It's ok now.

Thank you.
Regards.


AH

#3
HI, thanks for posting back

Post data removed to prevent people using my incorrect code that was bugged


Regards
A

Joomla 3.10.11
php 8.0

amlil71

Hello,

thank you for your reply.

I have put your code and sory it does'nt work.

Regards.

GJC Web Design

Quotei have update virtuemart to 3.6.11 since i have some bugs with 3.6.10.

also u don't say WHICH VM3.6.11 ....  the numbering/versioning is important as the are all work in progress
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

AH

Oops

Yes that code does not work in core - there appears to be a bug in core

This is what I use in my override:-


if ($order->virtuemart_user_id) {
$userlink = JROUTE::_ ('index.php?option=com_virtuemart&view=user&task=edit&virtuemart_user_id[]=' . $order->virtuemart_user_id, FALSE);
echo html_entity_decode(JHtml::_ ('link', JRoute::_ ($userlink, FALSE), $order->order_name, array('title' => vmText::_ ('COM_VIRTUEMART_ORDER_EDIT_USER') . ' ' .  $order->order_name)));
} else {
echo "<strong>" .  html_entity_decode( $order->order_name) . "</strong>";
}

Regards
A

Joomla 3.10.11
php 8.0

Milbo

Quote from: amlil71 on April 26, 2020, 06:09:00 AM
Hello,

thank you for your answer.

I have found the roof of this issue.

I have change the code of the orders.php file  located in administrator\components\com_virtuemart\views\orders\tmpl

The code wich doesn't work in 3.6.11 release

$userlink = JRoute::_ ('index.php?option=com_virtuemart&view=user&task=edit&virtuemart_user_id[]=' . $order->virtuemart_user_id, FALSE);
echo JHtml::_ ('link', $userlink, FALSE, $orderName, array('title' => vmText::_ ('COM_VIRTUEMART_ORDER_EDIT_USER') . ' ' .  $orderName));


I have replaced this code with the one from 3.6.10 release which works

$userlink = JROUTE::_ ('index.php?option=com_virtuemart&view=user&task=edit&virtuemart_user_id[]=' . $order->virtuemart_user_id, FALSE);
echo JHtml::_ ('link', JRoute::_ ($userlink, FALSE), $order->order_name, array('title' => vmText::_ ('COM_VIRTUEMART_ORDER_EDIT_USER') . ' ' .  $order->order_name));


It's ok now.

Thank you.
Regards.



Thank you for reporting and finding the right file. The error is the "False" as 3rd parameter, which was just left from the JRoute::_ ($userlink, FALSE) and so the right code is

echo JHtml::_ ('link', $userlink, $orderName, array('title' => vmText::_ ('COM_VIRTUEMART_ORDER_EDIT_USER') . ' ' .  $orderName) );


Fixed
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

AH

Regards
A

Joomla 3.10.11
php 8.0

amlil71

Hello all,

thank you. It's working now  :)

Regards.