wremacle Posted May 4, 2020 Share Posted May 4, 2020 (edited) Hello, I'm investigating for a while not but I'm stuck and need some help. I'm running prestashop 1.7.3 with PHP7.3 Sometimes product updates in back office are not working while a success message is given. - When I look at the tools to inspect, I can see with a positive test that an answer is provided from the Ajax calls. - When I do the same test with another product that I know upfront is causing trouble, I got an empty answer and it looks interpreted as a success then. Which is wrong. I already tried : - Cache cleaning - Multiple browsers - Compare ajax query string, nothing particular - Check server logs, nothing raised - Compare both success and failing product in database tables. Didn't see any particular difference. - Debug mode does not show anything. So from that I would like to see how to investigate further. Would you have some indication? From that empty answer, ideally I would like to see an error somewhere Thanks a lot ! Edited May 11, 2020 by wremacle (see edit history) Link to comment Share on other sites More sharing options...
JBW Posted May 5, 2020 Share Posted May 5, 2020 Prestashop is not compatible to PHP 7.3. - downgrade to 7.2 to avoid issues Link to comment Share on other sites More sharing options...
wremacle Posted May 9, 2020 Author Share Posted May 9, 2020 Thanks. I did downgraded but the problem is not solved 😞 How can I investigate this? Any particular source or function? Thank you. Link to comment Share on other sites More sharing options...
JBW Posted May 11, 2020 Share Posted May 11, 2020 Do you have any special characters in the product name? If there is nothing in the log or ajax response while debugging is active this is tricky... Try to compare the prodcuts on database to see whats differnt and could cause the issue Link to comment Share on other sites More sharing options...
wremacle Posted May 11, 2020 Author Share Posted May 11, 2020 I tried to replace all information displayed in admin to modify the product description, all fields by regular information but it didn't work neither. Also nothing in the logs of apache or prestashop... I also compared the database and http query to ajax calls... could not see any difference. I finally found the right source to investigate in AdminProductsController.php where I could start debugging by adding echo to some variables to see where the problem is. In my version, around line 1840, in function processUpdate, for some reasons, there are errors after checkProduct() call and those errors are not raised. There is just a return false. So the ajax call is empty. Consequently I just displayed the table print_r($this->errors); right before the return and I could see as answer of the ajax call that there was an error related to the keywords of my product. I don't know what exactly. I removed them in backoffice but it did not solved the problem. So I removed them directly in the database and finally my product could be updated as usual. Finally my problem is solved! Note: I suspect the origin come from a module generating keywords for the product. I disabled it as well. Thanks for your help! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now