View Issue Details

IDProjectCategoryView StatusLast Update
0001957OXID eShop (all versions)3.1. Design, GUI, UXpublic2013-01-15 10:04
Reportermarco_steinhaeuser Assigned To 
PriorityurgentSeveritycrashReproducibilitysometimes
Status resolvedResolutionfixed 
Product Version4.4.0 revision 28699 
Fixed in Version4.4.1 revision 28950 
Summary0001957: order history throws an error
DescriptionFatal error: Call to a member function getOrderArticles() on a non-object in /var/www/CE_4.4.0/eshop/tmp/cc91668a07ab6133d5dc6342e7675fbb^%%75^752^75201DD9%%account_order.tpl.php on line 132

is displayed in http://192.168.152.128/CE_4.4.0/eshop/en/order-history/

System: Debian-Etch VMware
Couldn't reproduce in Demoshop

See Screenshot attached
Steps To ReproduceFatal error occurs when customer has no orders yet, and opened the Order History page (from My Account) (in the place where info about orders should be displayed). If user already has some orders made, the fatal error will not occur in this page.

Additional Informationfound here:
http://www.oxid-esales.com/forum/showthread.php?t=5910

As this is probably a bug in template and can only be fixed in 4.5.0, pls provide a solution here. Thanks!
TagsNo tags attached.
Attached Files
Clipboard01.jpg (125,875 bytes)   
Clipboard01.jpg (125,875 bytes)   
Theme
BrowserAll
PHP Versionany
Database Versionany

Relationships

has duplicate 0001967 resolveddainius.bigelis Fatal error occurs in Order History page when there are no orders yet 

Activities

knackig

2010-07-13 12:31

reporter   ~0003257

I am, who had this issue... Yesterday I could solve it by my own.

This is my solution:
I found the problem in the file ..\out\basic\tpl\account_order.tpl.

In the 11th line there is the following code:
[{if count($oView->getOrderList()) > 0 }]
But the result of count($oView->getOrderList()) do not fit to the expression in the if-statement. But in the file inc\account_header.tpl, there is a correct command to show the number of the orders. So I took this command to replace the fail command mentioned above.

So I replaced the line above with the following code:
[{if $oView->getOrderCnt() >= 1 }]
And now it works great ;)

You can take it for the future versions. I hope, I could help you ;)
If you have any questions concerning this solution, just send me an email...

vilma_liorensaityte

2010-07-21 09:00

reporter   ~0003285

Solved it in Account_Order::getOrderList(). If order is not set, it returns empty array.