Reputation: 503
In our company we want to use PrestaShop as online shop system. But we also have an ERP-System which needs customers, addresses and orders, too.
Therefore i have to synchronize the data. First i thought that i just request all data via webservice calls. But this would mean i have to implement polling which is a 'dirty' solution in my opinion.
Is there any module or another possible solution that exports the data everytime when new data is inserted or existing data is changed / deleted?
I'm very new to PrestaShop. Maybe somebody could help me :)
Thanks in advance
Best wishes
Andi
Upvotes: 0
Views: 310
Reputation: 1022
Each time that an object is added, modified or deleted a function is called:
Function add
from Object
class:
Hook::exec('actionObject'.get_class($this).'AddAfter', array('object' => $this));
Function update
from Object
class:
Hook::exec('actionObject'.get_class($this).'UpdateAfter', array('object' => $this));
Function delete
from Object
class:
Hook::exec('actionObject'.get_class($this).'DeleteAfter', array('object' => $this));
Then you can create a module and use these hooks to integrate it with your ERP.
Upvotes: 1