PrestaShop Smarty fatal error - smarty

I am really new to PrestaShop and am facing trouble debugging an error in PrestaShop 1.6.1.3
It was working just fine, until I have changed some localization and delivery settings in admin panel.
Now, whenever I make an order, and try to proceed with bank wire payment, I receive the following error:
Fatal error: Call to undefined method Tools::getInvoiceProductName() in /home/makede/domains/manokede.lt/public_html/tools/smarty/sysplugins/smarty_internal_templatebase.php(157) : eval()'d code on line 36
Any help or guidance for how to solve it or at least debug deeper is much appreciated.

by default class Tools have no method called getInvoiceProductName in Presta, if you added this line (where method called), just comment/delete it

Can you please try clearing your cache and then check again?

Related

Can't clear cache Symfony in production

Despite of all my attempts to understand the problem, I still can't figure out what is happening.
I developped a website with Symfony 2.7 which perfectly works in dev mode. When I tested it in production mode, an error 500 is returned.
The exception is :
Uncaught PHP Exception Symfony\Component\Debug\Exception\FatalErrorException:
"Error: Call to a member function getCacheFactory() on a non-object" at
/home/admdev-php/public_html/sfSUAPS/vendor/doctrine/orm/lib/Doctrine/ORM/UnitOfWork.php line 3039
{"exception":"[object] (Symfony\\Component\\Debug\\Exception\\FatalErrorException(code: 0):
Error: Call to a member function getCacheFactory() on a non-object at
/home/admdev-php/public_html/sfSUAPS/vendor/doctrine/orm/lib/Doctrine/ORM/UnitOfWork.php:3039)"} []
So I've tried to clear the cache and I had the same message :
[Symfony\Component\Debug\Exception\FatalErrorException]
Compile Error: require(): Failed opening required
'/home/stagiaire/workspace/suaps/app/cache/prod/doctrine/orm/Proxies/__CG__AppBundleEntityPlace.php'
(include_path='.:/usr/share/php:/usr/share/pear')`
I've tried to clear doctrine's cache but this doesn't solve the problem.
There are severals roles : One for students, one for teachers and one for admins. I only get this error when my role is student. So I looked closer to methods which are concerned and I commented everything related to studies and it worked. So I think the error is linked with my Entity Repository since "findBy" and "findAll" are failing.
I've took a look into Symfony's code but the error seems to be on my side. I really don't know what is going on, thank you if you can help me.
Problem solved
Turns out someone used an entity directly from cache...
Turns out someone used an entity directly from cache...
use Proxies\__CG__\AppBundle\Entity\Place;

Magento getReadConnection() Error in /app/code/core/Mage/Core/Model/Resource/Db/Collection/Abstract.php on line 134

There is an error suddenly started popping up. The error occurs on various part of website like cart area, product detail page etc..
I am running my site on local server.
the error is as follows:
Fatal error: Call to a member function getReadConnection() on boolean in app/code/core/Mage/Core/Model/Resource/Db/Collection/Abstract.php on line 134
I have googled the issue but that didn't helped either.
You have to define the class and the resource model. Please check this link. I hope solve your problem.

Magento Cash on Delivery success page throwing error after upgarding to 1.9.2

After upgrading to magento 1.9.2 and also updating the theme, when I was checking the payment option after i selected the cashondelivery payment option and clicked on place an order got a message that "Your order has been received.
Thank you for your purchase!" but below that page I got this error -
Fatal error: Call to a member function loadByIncrementId() on a non-object in /public_html/app/design/frontend/theme/default/template/checkout/success.phtml on line 87
Could someone please help me to resolve this issue?
I debugged success.phtml and found that the google conversion tracking code was causing the error. I removed it and the error is not coming up anymore.
I debugged checkout/success.phtml and found that the some useless code for send order mail which not found helper class so I found fatal error. I removed it and the error is not coming up anymore.

Error loading in Magento admin

When I load my Magento admin I get the error.
Fatal error: Call to a member function isLoggedIn() on a non-object
in /home/xxx/public_html/app/code/community/TM/Core/Model/Observer.php
on line 12
I think it happened when I replaced some files somewhere in app/code/...
I’m really stuck on this and need desperate help.
Error is in your extension file TM/Core/Model/Observer.php
Disable extension and check after refresh cache
This was fixed by the Full Page Cache Extension people.
I don't know what they did but it was their extension which broke my magento however they fixed it for me right away

Getting an error while adding a role in Magento

I am setting up a Magento(v. 1.6.1.0) site.
To access the API, I needed to create a rule (Admin > System > Web Services > Rules > Add new rule).
When I click the button, I got the following error.
Fatal error: Call to a member function toHtml() on a non-object in /home/dinamal7/public_html/app/code/core/Mage/Adminhtml/Block/Api/Editroles.php on line 52
I ran some research about the issue but couldn't find any solution. Can anybody help me?
Thanks.
Sam
#Sam, looks like there is some problem with the object calling that particular function. As you can see, it is indicating the core file, which is not supposed to have any errors. You can try and replace the "core" folder of your current installation with the one extracted fresh. This should do the trick.

Resources