X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=admin%2Finst_upgrade.php;h=4a5106b96a2c59a6f439102eaf6b2032130ccc48;hb=c4eae7a18f0eb824e6eda7be2ba6fa820e9e58c9;hp=9141808debec6d073754a488a8164527e1f844ef;hpb=d2bd6087025dfd8497777f6ce2305ff98879473a;p=fa-stable.git diff --git a/admin/inst_upgrade.php b/admin/inst_upgrade.php index 9141808d..4a5106b9 100644 --- a/admin/inst_upgrade.php +++ b/admin/inst_upgrade.php @@ -1,13 +1,13 @@ . + See the License here . ***********************************************************************/ $page_security = 20; $path_to_root=".."; @@ -98,7 +98,7 @@ function upgrade_step($index, $conn) { if (!$inst->installed($pref) || $force) { - // if(!$inst->pre_check($pref)) return false; + if (!$inst->pre_check($pref)) return false; if ($sql != '') $ret &= db_import($path_to_root.'/sql/'.$sql, $conn, $force); @@ -156,7 +156,13 @@ if (get_post('Upgrade')) if (!$ret) break; } if($ret) + { // re-read the prefs + global $path_to_root; + include_once($path_to_root . "/admin/db/users_db.inc"); + $user = get_user($_SESSION["wa_current_user"]->username); + $_SESSION["wa_current_user"]->prefs = new user_prefs($user); display_notification(_('All companies data has been successfully updated')); + } $Ajax->activate('_page_body'); }