parent
87690d0547
commit
672a08b4dd
@ -3,8 +3,9 @@
|
||||
* added option to generate models based on multiple databases(#144)
|
||||
* fixed generation of ManyToMany relations on junction tables with custom names(#151)
|
||||
* fixed problems with mysql 8
|
||||
* fixed shadowed variables tslint errors( #141)
|
||||
* fixed generated columns order
|
||||
* fixed shadowed variables tslint errors(#141)
|
||||
* fixed order of generated columns
|
||||
* mariadb default value comatibility changes(#153)
|
||||
|
||||
## 0.3.1
|
||||
* Fixed npx ussage(#146)
|
||||
|
@ -428,9 +428,12 @@ export class MysqlDriver extends AbstractDriver {
|
||||
return ret;
|
||||
}
|
||||
private ReturnDefaultValueFunction(defVal: string | null): string | null {
|
||||
if (!defVal) {
|
||||
if (!defVal || defVal === "NULL") {
|
||||
return null;
|
||||
}
|
||||
if (defVal.toLowerCase() === "current_timestamp()") {
|
||||
defVal = "CURRENT_TIMESTAMP";
|
||||
}
|
||||
if (defVal === "CURRENT_TIMESTAMP" || defVal.startsWith(`'`)) {
|
||||
return `() => "${defVal}"`;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user