realmagic Posted April 6, 2016 Share Posted April 6, 2016 (edited) Hello everyone That is the best practice to create and manage orders and other objects in modules? Webservice or Direct DB editing by php functions, prestashop controllers and classes methods? Have a nice day Eugene Edited April 6, 2016 by realmagic (see edit history) Link to comment Share on other sites More sharing options...
realmagic Posted April 11, 2016 Author Share Posted April 11, 2016 Any developers here? Link to comment Share on other sites More sharing options...
diegonella Posted May 8, 2016 Share Posted May 8, 2016 (edited) I have a same problem, i don't howto develop a module, for create groups, customer, etc I know vía webservices but if correcto use? Edited May 8, 2016 by diegonella (see edit history) Link to comment Share on other sites More sharing options...
imagetag Posted May 10, 2016 Share Posted May 10, 2016 Hello everyone That is the best practice to create and manage orders and other objects in modules? Webservice or Direct DB editing by php functions, prestashop controllers and classes methods? Have a nice day Eugene Hello, if you're going to write a module, try to stick to the existing functions. That doesn't meand, that you wouldn't have to write your own queries, but even than, use the DB class to fetch and write. If you need to display and edit objects of any kind, look at the helper classes. These will help you, to develop grids and such much faster. Webservices are nice, if you want to let 2 servers to communicate with each other. But even the webservices rely on the core classes . If you once got the basic object & controller model, you will be able to quickly check, which functions could be reuses and which need to be written by you. Last but not least, whenever possible, use hooks instead of overwrites, nevertheless this doesn't work in every case, or sometimes you would have to spend 5x more time to shio around. Regards Peter 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