There is no clear direction on hooks at this time. We are still in discussion and experimentation phase.alanms wrote:Hi guys, great discussion, just wondering what the latest thinking is here? I saw http://forum.opencart.com/viewtopic.php?f=24&t=17143 - so it seems hook events are still in the pipeline as of July 2010. Just wondering if there's any tips on the shape these might be taking, for those of us needing to roll our own in the meantime.
I'm another newcomer to OC loving the crisp use of MVC, and working on a module that requires a function to occur with every successful call to model_checkout_order->confirm. So far, my module has kept core completely untouched, using $_GET and session data to make module functions roughly coincide with the appropriate core functions. That's not going to work for a model function.
I'd love to leave my clients with the simplest possible housekeeping instructions for when they wish to update OC. So, I'm just wondering: is there a better or more future-proof method to extend a vital Core function like this than tacking something like "if x module enabled, do y function from module" into function confirm(...) in model/checkout/order.php? Some method that is most in line with current thinking about how the future hook system might work?
If there's a clear direction emerging for how this will work, I could also be up for contributing what I can to help make it happen from my modest experience of hooks in Drupal.
OpenCart commercial mods and development http://spotonsolutions.net
Layered Navigation
Shipment Tracking
Vehicle Year/Make/Model Filter
Who is online
Users browsing this forum: No registered users and 7 guests