Uniphix
Active member
When updating an addon already installed, lets say I have some listeners that are called such as initDependencies... One of the issues I'm having is when I need to rebuild data and the 'table' has not yet been created, or something of this sort or a table column is missing etc.
SO in this case I have to manually add a table to the database directly which in my opinion is a pain if I have to tell all my customers to update their database with the new changes. What I would like to know is there a way to check the addon's version and see if the version is installed before proceeding the typical rebuilding of data which requires a table that has not yet been made due to needing ot update the addon first before that data could be rebuilt correctly...
For example:
Installed Addon already there and a new table that requires data to be used across the site so I store this in the data registry. Now the problem the table that has not yet been made is on a new update
So install version is version 1 update version is version 2...
Current Version is 1 therefore is there a way to check against the addon such as
if( $currentVersion > 1 ) then perform the typical duties of rebuilding the data otherwise ignore if I need to do an update on the addon first...
Thanks
SO in this case I have to manually add a table to the database directly which in my opinion is a pain if I have to tell all my customers to update their database with the new changes. What I would like to know is there a way to check the addon's version and see if the version is installed before proceeding the typical rebuilding of data which requires a table that has not yet been made due to needing ot update the addon first before that data could be rebuilt correctly...
For example:
Installed Addon already there and a new table that requires data to be used across the site so I store this in the data registry. Now the problem the table that has not yet been made is on a new update
So install version is version 1 update version is version 2...
Current Version is 1 therefore is there a way to check against the addon such as
if( $currentVersion > 1 ) then perform the typical duties of rebuilding the data otherwise ignore if I need to do an update on the addon first...
Thanks