News:

Looking for documentation? Take a look on our wiki

Main Menu

[SOLVED] Error 0 Call to a member function priceDisplay() on null

Started by mauriziomomix, January 24, 2019, 20:56:49 PM

Previous topic - Next topic

mauriziomomix

Hello,
in two websites using VirtueMart 3.4.2 I am noticing the same error when clicking on the link present in the email notification of the order ("{SITEURL}/index.php?option=com_virtuemart&view=orders&layout=details&order_number={ORDERNUMBER}")

The error is: Error 0 Call to a member function priceDisplay() on null.

The PHP version is 7.1 but I also changed it in lower or upper without better results.
One of the two websites is in J3.9.1 and the second is in 3.9.2.

Anyone has experienced the same?

Thanks in advance
Maurizio

GJC Web Design

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

mauriziomomix

Hello,
thanks for replying me.
Full debugging is getting this output:

Undefined property: VirtuemartViewOrders::$print in /var/www/vhosts/ruggedstore.it/httpdocs/templates/vp_smart/layouts/default/html/com_virtuemart/orders/details.php on line 16
Informazioni sull'ordine

Notice: Undefined property: VirtuemartViewOrders::$orderdetails in /var/www/vhosts/ruggedstore.it/httpdocs/templates/vp_smart/layouts/default/html/com_virtuemart/orders/details.php on line 38

Notice: Trying to get property of non-object in /var/www/vhosts/ruggedstore.it/httpdocs/templates/vp_smart/layouts/default/html/com_virtuemart/orders/details.php on line 38

Warning: Creating default object from empty value in /var/www/vhosts/ruggedstore.it/httpdocs/templates/vp_smart/layouts/default/html/com_virtuemart/orders/details.php on line 38

Jörgen

Looks like a problem with Your template, try switching to protostar or VMBeez3.

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

mauriziomomix

Hello Jörgen,
thank you very much.
Actually I did this (with the same result) adding all menu voices to Protostar but now I've done it again setting it as predefined also.
Well, the link works correctly. So is definitely a Virtueplanet Smart template Issue.
I already informed the template producer.

Thanks to all.

Maurizio

escozul

Hello,

I'm getting the same error too after a successfull order.

How exactly were you able to resolve it?

Jörgen

Try with Protostar as template setting. If error disappers then You have a template issue.

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

StefanSTS

Who has marked this as SOLVED?
Solved posts generally include an answer to the question, otherwise it is not solved and useless as a forum post.


EDIT: Actually there was an answer from the first poster, the unsolved question was from someone else.
How rude am I? ;-)

Stefan
--
Stefan Schumacher
www.jooglies.com - VirtueMart Invoice Layouts

Please use only stable versions with even numbers for your live shop! Use Alpha versions only if you know what risk you are taking.

Jörgen

I guess mauriziomomix since he saw this as a template issue

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

webcomil

I had it also
and it took me some time to understand and solve.

The reason for that error is that the user is not authorized to view the compoeted order, meaning, in the sysem seting it sets to allow only registretd user  to view ordrs.

Therefore when user is not authorized, the data in that function is null,
therefore you get this error.  it is aslo on VM views (template files) as for 3.4.2 versioin

So the solution for it on configuration → check out field "Order tracking mode" needs to be set to allow guest shoppers.