Skip to content

Commit

Permalink
#415 [SQL] add: rename table for backward compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolas-eoxia committed Jul 19, 2023
1 parent bb9d2ba commit f965a20
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
4 changes: 2 additions & 2 deletions class/actions_dolisirh.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -1349,13 +1349,13 @@ public function printFieldListWhere(array $parameters): int
*/
public function printFieldPreListTitle(array $parameters): int
{
global $conf, $db, $user;
global $db, $user;

if (in_array($parameters['currentcontext'] , ['invoicelist', 'invoicereclist'])) {
// Filter on categories.
if (isModEnabled('categorie') && $user->rights->categorie->lire) {
require_once DOL_DOCUMENT_ROOT . '/core/class/html.formcategory.class.php';
$formCategory = new FormCategory($db);
$formCategory = new FormCategory($db);
switch ($parameters['currentcontext']) {
case 'invoicelist' :
$type = 'facture';
Expand Down
6 changes: 6 additions & 0 deletions sql/update.sql
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,9 @@
ALTER TABLE `llx_dolisirh_timesheet` DROP `last_main_doc`, DROP `model_pdf`, DROP `model_odt`;
ALTER TABLE `llx_element_workinghours` CHANGE `tms` `tms` TIMESTAMP on update CURRENT_TIMESTAMP NULL DEFAULT CURRENT_TIMESTAMP;
ALTER TABLE `llx_element_workinghours` ADD `fk_user_modif` INT NULL AFTER `fk_user_creat`;

RENAME TABLE `llx_categorie_invoice` TO `llx_categorie_facture`;
ALTER TABLE `llx_categorie_facture` CHANGE `fk_invoice` `fk_facture` INT NOT NULL;

RENAME TABLE `llx_categorie_invoicerec` TO `llx_categorie_facturerec`;
ALTER TABLE `llx_categorie_facturerec` CHANGE `fk_invoicerec` `fk_facturerec` INT NOT NULL;

0 comments on commit f965a20

Please sign in to comment.