ed0522 Posted August 8, 2015 Share Posted August 8, 2015 How does the object model work in Prestashop? I see the $definition class such as in customer.php just define the structure and requirement of the customer table. If we input a value of first name in the front page, it will be save in to $customer->firstname. How is it saved to the customer table? Link to comment Share on other sites More sharing options...
NemoPS Posted August 8, 2015 Share Posted August 8, 2015 The object model has a Save method that either updates or adds the entry (calling its update or add). Inside those you'll find the queries you need.It will basically save everything it finds in the definitions array 1 Link to comment Share on other sites More sharing options...
Nishith Nesdiya Posted August 8, 2015 Share Posted August 8, 2015 (edited) How does the object model work in Prestashop? I see the $definition class such as in customer.php just define the structure and requirement of the customer table. If we input a value of first name in the front page, it will be save in to $customer->firstname. How is it saved to the customer table? hi... please show this link http://doc.prestashop.com/display/PS15/Diving+into+PrestaShop+Core+development https://www.prestashop.com/forums/topic/325110-creating-an-objectmodel-for-a-module/ thanks.. Edited August 8, 2015 by Nishith (see edit history) 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