X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Third Party Add-Ons for X-Cart 5 (https://forum.x-cart.com/forumdisplay.php?f=64)
-   -   Module Creation (https://forum.x-cart.com/showthread.php?t=74844)

Sooraj 01-05-2017 01:39 AM

Module Creation
 
Hi,
I'm a xcart5 newbie. Trying to create a module related to order. I want to execute sql query when my module is installed. In xcart4 there is an option in admin backend to execute sql query.
My requirement is - i need to add new column to order table. In xcart4, I can execute sql query. What about xcart5? Can I add it in install.yaml and execute that query?

qualiteam 01-06-2017 12:29 AM

Re: Module Creation
 
YAML files are for data only.

To alter the structure you should "decorate" existing PHP classes.
Please check these articles:
- http://devs.x-cart.com/en/basics/understanding_models.html
- http://devs.x-cart.com/en/basics/adding_new_property_to_a_product/ (search for "IDecorator")


All times are GMT -8. The time now is 08:14 AM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.