diff --git a/ChangeLog b/ChangeLog index 2a72296477c..43fecf4d2e7 100644 --- a/ChangeLog +++ b/ChangeLog @@ -2,8 +2,20 @@ English Dolibarr ChangeLog -------------------------------------------------------------- + +***** ChangeLog for 8.0.0 compared to 7.0.0 ***** + +WARNING: + +Following changes may create regressions for some external modules, but were necessary to make Dolibarr better: +* Hook 'maildao' was renamed into 'mail' into the method sendfile that send emails, and method was renamed from + 'doaction' into 'sendMail'. + + ***** ChangeLog for 7.0.0 compared to 6.0.5 ***** For users: +NEW: When payment is registered, PDF of invoices are also regenerated so payments + appears with no need to click on regenerate. NEW: #5711 Add shipment line deleting and editing for draft shipments. NEW: Accept substitution key __[ABC]__ replaced with value of const ABC NEW: Accountancy Add variant on sell account for intracommunity sales & export sales @@ -276,6 +288,12 @@ Following changes may create regressions for some external modules, but were nec and add 'td.' to the beginning of the dragHandle match string. * IE8 and earlier and Firefox 12 and earlier (< 2012) are no more supported. +* If you use the external module "multicompany", you must also upgrade the module. Multicompany module for + Dolibarr v7 is required because with Dolibarr v7, payment modes and payment conditions are management as data + that are dedicated to each company. If you keep your old version of multicompany module, mode and + condition of payments will appears empty in all companies that are not the first one. By upgrading the + multicompany module to a version that support Dolibarr v7, everything should work as expected. + ***** ChangeLog for 6.0.5 compared to 6.0.4 ***** FIX: security vulnerability reported by ADLab of Venustech diff --git a/htdocs/accountancy/bookkeeping/list.php b/htdocs/accountancy/bookkeeping/list.php index 8ecf04fdbc8..42328fbc1ed 100644 --- a/htdocs/accountancy/bookkeeping/list.php +++ b/htdocs/accountancy/bookkeeping/list.php @@ -87,7 +87,7 @@ $offset = $limit * $page; $pageprev = $page - 1; $pagenext = $page + 1; if ($sortorder == "") $sortorder = "ASC"; -if ($sortfield == "") $sortfield = "t.rowid"; +if ($sortfield == "") $sortfield = "t.piece_num,t.rowid"; $object = new BookKeeping($db); @@ -98,25 +98,30 @@ $form = new Form($db); if (! in_array($action, array('export_file', 'delmouv', 'delmouvconfirm')) && ! isset($_POST['begin']) && ! isset($_GET['begin']) && ! isset($_POST['formfilteraction']) && GETPOST('page','int') == '' && ! GETPOST('noreset','int')) { - $query = "SELECT date_start, date_end from ".MAIN_DB_PREFIX."accounting_fiscalyear "; - $query.= " where date_start < '".$this->idate(dol_now())."' and date_end > '".$this->idate(dol_now())."' limit 1"; - $res = $db->query($query); - if ($res->num_rows > 0) { - $fiscalYear = $db->fetch_object($res); - $search_date_start = strtotime($fiscalYear->date_start); - $search_date_end = strtotime($fiscalYear->date_end); - } else { - $month_start= ($conf->global->SOCIETE_FISCAL_MONTH_START?($conf->global->SOCIETE_FISCAL_MONTH_START):1); - $year_start = dol_print_date(dol_now(), '%Y'); - $year_end = $year_start + 1; - $month_end = $month_start - 1; - if ($month_end < 1) - { - $month_end = 12; - $year_end--; + if (empty($search_date_start) && empty($search_date_end)) + { + $query = "SELECT date_start, date_end from ".MAIN_DB_PREFIX."accounting_fiscalyear "; + $query.= " where date_start < '".$db->idate(dol_now())."' and date_end > '".$db->idate(dol_now())."' limit 1"; + $res = $db->query($query); + + if ($res->num_rows > 0) { + $fiscalYear = $db->fetch_object($res); + $search_date_start = strtotime($fiscalYear->date_start); + $search_date_end = strtotime($fiscalYear->date_end); + } else { + $month_start= ($conf->global->SOCIETE_FISCAL_MONTH_START?($conf->global->SOCIETE_FISCAL_MONTH_START):1); + $year_start = dol_print_date(dol_now(), '%Y'); + if (dol_print_date(dol_now(), '%m') < $month_start) $year_start--; // If current month is lower that starting fiscal month, we start last year + $year_end = $year_start + 1; + $month_end = $month_start - 1; + if ($month_end < 1) + { + $month_end = 12; + $year_end--; + } + $search_date_start = dol_mktime(0, 0, 0, $month_start, 1, $year_start); + $search_date_end = dol_get_last_day($year_end, $month_end); } - $search_date_start = dol_mktime(0, 0, 0, $month_start, 1, $year_start); - $search_date_end = dol_get_last_day($year_end, $month_end); } } @@ -124,7 +129,7 @@ if (! in_array($action, array('export_file', 'delmouv', 'delmouvconfirm')) && ! $arrayfields=array( 't.piece_num'=>array('label'=>$langs->trans("TransactionNumShort"), 'checked'=>1), 't.doc_date'=>array('label'=>$langs->trans("Docdate"), 'checked'=>1), - 't.doc_ref'=>array('label'=>$langs->trans("Docref"), 'checked'=>1), + 't.doc_ref'=>array('label'=>$langs->trans("Piece"), 'checked'=>1), 't.numero_compte'=>array('label'=>$langs->trans("AccountAccountingShort"), 'checked'=>1), 't.subledger_account'=>array('label'=>$langs->trans("SubledgerAccount"), 'checked'=>1), 't.label_operation'=>array('label'=>$langs->trans("Label"), 'checked'=>1), @@ -430,7 +435,7 @@ else $button.= $langs->trans("ExportList"); $button.= ''; -$groupby = ' ' . $langs->trans("GroupByAccountAccounting") . ''; +$groupby = ' ' . $langs->trans("GroupByAccountAccounting") . ''; $addbutton = '' . $langs->trans("NewAccountingMvt") . ''; print_barre_liste($title_page, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $button, $result, $nbtotalofrecords, 'title_accountancy', 0, $groupby.$addbutton, '', $limit); @@ -576,17 +581,17 @@ print ''; print "\n"; print '
| '.$langs->trans("ExportModel").' | '."\n"; +print ''; +print ' | '."\n"; + + +// Example with a yes / no select +$var=!$var; +print ' |
| '.$langs->trans("set_EXPORTS_SHARE_MODELS").' | '; +print ''; +print ' | '; +print ''; +print ' |
| ';
print ' ';
print ''.$langs->trans("InputReceiptNumber").': ';
print ''; // The only default value is value we just entered
print ' ';
- if ($options) {
+ if (is_array($options) && count($options))
+ {
print $langs->trans("EventualyAddCategory").': ';
print Form::selectarray('cat', $options, GETPOST('cat'), 1);
}
@@ -629,7 +625,6 @@ if ($resql)
';
}
print ''; -// print ' |
| '.$langs->trans("Label").' | '.$object->label.' |
| '.$langs->trans("Label").' | '.$object->label.' |