mirror of
https://github.com/strapi/strapi.git
synced 2025-11-02 02:44:55 +00:00
Merge pull request #969 from juampynr/fix-mysql-5.7
Fix invalid timestamp default values for MySQL 5.7
This commit is contained in:
commit
21ed0156a0
@ -34,8 +34,8 @@ module.exports = async cb => {
|
||||
size text,
|
||||
url text,
|
||||
provider text,
|
||||
updated_at ${Model.client === 'pg' ? 'timestamp with time zone' : 'timestamp'},
|
||||
created_at ${Model.client === 'pg' ? 'timestamp with time zone' : 'timestamp'}
|
||||
updated_at ${Model.client === 'pg' ? 'timestamp with time zone' : 'timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP'},
|
||||
created_at ${Model.client === 'pg' ? 'timestamp with time zone' : 'timestamp DEFAULT CURRENT_TIMESTAMP'}
|
||||
);
|
||||
|
||||
CREATE TABLE ${quote}upload_file_morph${quote} (
|
||||
|
||||
@ -460,8 +460,8 @@ CREATE TABLE ${quote}${details[currentModel].tableName}${quote} (
|
||||
role ${details[currentModel].client === 'pg' ? 'integer' : 'int'},
|
||||
${quote}resetPasswordToken${quote} text,
|
||||
password text,
|
||||
updated_at ${details[currentModel].client === 'pg' ? 'timestamp with time zone' : 'timestamp'},
|
||||
created_at ${details[currentModel].client === 'pg' ? 'timestamp with time zone' : 'timestamp'}
|
||||
updated_at ${details[currentModel].client === 'pg' ? 'timestamp with time zone' : 'timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP'},
|
||||
created_at ${details[currentModel].client === 'pg' ? 'timestamp with time zone' : 'timestamp DEFAULT CURRENT_TIMESTAMP'}
|
||||
);`);
|
||||
break;
|
||||
case 'role':
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user