2
0
forked from Wavyzz/dolibarr

Fix creation of fields tms into sql scripts

This commit is contained in:
Laurent Destailleur
2022-01-11 00:55:54 +01:00
parent 564bae453e
commit 00108589fd
23 changed files with 44 additions and 38 deletions

View File

@@ -305,6 +305,8 @@ function rebuildObjectSql($destdir, $module, $objectname, $newmask, $readdir = '
$texttoinsert .= "\t".$key." ".$type;
if ($key == 'rowid') {
$texttoinsert .= ' AUTO_INCREMENT PRIMARY KEY';
} elseif ($type == 'timestamp') {
$texttoinsert .= ' DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP';
}
if ($key == 'entity') {
$texttoinsert .= ' DEFAULT 1';