X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;ds=sidebyside;f=sql%2Falter2.4.php;h=e2cbf7c9f6cb80402f23525f2bfb6807e7b93c35;hb=26c3aa914a802dab194638f7750e5b486beedb0f;hp=0dfdbface1845fa5906fc6a73153289d2285e318;hpb=96088f054d37cc1f9f5e7aa5efbc6d2e0c9c5905;p=fa-stable.git diff --git a/sql/alter2.4.php b/sql/alter2.4.php index 0dfdbfac..e2cbf7c9 100644 --- a/sql/alter2.4.php +++ b/sql/alter2.4.php @@ -16,6 +16,7 @@ class fa2_4 extends fa_patch { var $description; var $sql = 'alter2.4.sql'; var $preconf = true; + var $max_upgrade_time = 900; // table recoding is really long process function fa2_4() { parent::fa_patch(); @@ -101,6 +102,13 @@ class fa2_4 extends fa_patch { $pref = $this->companies[$company]['tbpref']; db_query("DROP TABLE IF EXISTS " . $pref . 'wo_costing'); db_query("DROP TABLE IF EXISTS " . $pref . 'stock_fa_class'); + db_query("DELETE FROM ".$pref."sys_prefs + WHERE `name` in ( + 'gl_closing_date', 'deferred_income_act', 'no_zero_lines_amount', 'accounts_alpha', + 'tax_algorithm', 'grn_clearing_act', 'default_receival_required', + 'default_quote_valid_days', 'no_zero_lines_amount', 'show_po_item_codes', 'accounts_alpha', + 'loc_notification', 'print_invoice_no', 'allow_negative_prices', 'print_item_images_on_quote', + 'bcc_email', 'alternative_tax_include_on_docs', 'suppress_tax_rates')"); } function update_workorders() @@ -108,7 +116,7 @@ class fa2_4 extends fa_patch { global $db; $sql = "SELECT DISTINCT type, type_no, tran_date, person_id FROM ".TB_PREF."gl_trans WHERE `type`=".ST_WORKORDER - ." AND person_type_id=1"; + ." AND person_type_id=1"; $res = db_query($sql); if (!$res) return $this->log_error(sprintf(_("Cannot update work orders costs:\n%s"), db_error_msg($db)));