Upgrade Packages

{jstabs tab=0} {jstab title="Available Upgrades"} {form id="package_select" legend="Packages that will be upgraded" id="package_select"} {if $packageUpgrades}

Packages and their upgrades

You are about to run an upgrade which might make changes to your database. We strongly recommend that you back up your database (preferably carry out the entire backup procedure).

{foreach from=$packageUpgrades item=upgrade key=package} {* users don't have the option to select what packages to upgrade since the code of the package is dependent on this upgrade

*}

{$package}

{$gBitSystem->getVersion($package)}
Currently installed version
{foreach from=$upgrade item=data key=version}
{$data.version}
{$data.description}
{if $errors.$package.$version}

SQL errors that occurred during the {$version} upgrade:
{if $errors.$package.$version.failedcommands} {foreach from=$errors.$package.$version.failedcommands item=command} {$command}
{/foreach} {/if}

{/if} {/foreach}
{/foreach} {if $errors}

The upgrade process was halted due to the SQL problems listed above. Please contact the bitweaver team to fix this issue.

{/if} {elseif !$success}

Seems all installed packages are up to date!

{/if} {if $success}

Post Install Notes

Some packages were successfully updated which might have important post upgrade notes.

{foreach from=$success item=upgrade key=package} {foreach from=$upgrade item=data key=version} {if $data.post_upgrade}
{$package}
Upgrade → {$version}
Post install notes
{$data.post_upgrade}
{/if} {/foreach} {/foreach}
{/if} {if $requirementsMap}

Requirements Graph

Below you will find an illustration of how packages will depend on each other after the upgrade has been completed.

A graphical representation of package requirements {$requirementsMap}
{/if} {if $requirements}

Requirements Table

Below you will find a detailed table with package requirements after the upgrade has completed successfully. If not all package requirements are met, consider trying to meet all package requirements. If you don't meet them, you may continue at your own peril.

{foreach from=$requirements item=dep} {if $pkg != $dep.package} {assign var=pkg value=$dep.package} {/if} {if $dep.result == 'ok'} {assign var=class value=success} {elseif $dep.result == 'missing'} {assign var=class value=error} {elseif $dep.result == 'min_dep'} {assign var=class value=error} {else} {assign var=class value=warning} {/if} {/foreach}
Package Requirements
Requirement Min Version Max Version Available Result
{$dep.package|ucfirst} requirements
{$dep.requires|ucfirst} {$dep.required_version.min} {$dep.required_version.max} {$dep.version.available} {if $dep.result == 'ok'} OK {elseif $dep.result == 'missing'} Package missing {assign var=missing value=true} {elseif $dep.result == 'min_dep'} Minimum version not met {assign var=min_dep value=true} {elseif $dep.result == 'max_dep'} Maximum version exceeded {assign var=max_dep value=true} {elseif $dep.result == 'inactive'} Package disabled {assign var=inactive value=true} {else} Unknown state {assign var=confused value=true} {/if}
{if $missing}

At least one required package is missing. Please install that package before proceeding with the upgrade.

{/if} {if $min_dep}

At least one package did not meet the minimum version requirement in our calculations. If possible, please get a newer version of those packages and upgrade them as well.

{/if} {if $max_dep}

At least one package recommend a version lower to the one you have installed or are about to upgrade to. The package you wish to upgrade might work with this combination, but no guarantees can be given.

{/if} {if $inactive}

At least one required package is disabled. Please activate that package once your install is complete.

{/if} {if $confused}

At least one required package is in an unknown state. The upgrade may not work because of this. It is probably worth reinstalling the latest version of that package or contacting its developer.

{/if} {if !$min_dep && !$max_dep && !$missing}

All package requirements have been met. You can proceed with the installation process.

{/if} {/if}
{forminput} {formhelp note="Display SQL statements."} {/forminput}
{/form} {/jstab} {jstab title="Installed Packages"} {legend legend="Already Installed Packages"} {foreach from=$schema key=package item=item} {if $item.installed}
{forminput} {$package|capitalize} {formhelp note=`$item.info`} {formhelp note="Location: `$item.url`"} {formhelp package=$package} {/forminput}
{/if} {/foreach} {/legend} {/jstab} {/jstabs}