Created
May 17, 2024 23:34
-
-
Save DiegoPinho/7206da08e64fe31a145a23e04790b48a to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
/** @type {import('sequelize-cli').Migration} */ | |
module.exports = { | |
async up(queryInterface, Sequelize) { | |
await queryInterface.bulkInsert( | |
"localidade", | |
[ | |
{ | |
nome_localidade: "Localidade 10", | |
created_at: new Date(), | |
updated_at: new Date(), | |
}, | |
{ | |
nome_localidade: "Localidade 5", | |
created_at: new Date(), | |
updated_at: new Date(), | |
}, | |
{ | |
nome_localidade: "Localidade 6", | |
created_at: new Date(), | |
updated_at: new Date(), | |
}, | |
], | |
{} | |
); | |
}, | |
async down(queryInterface, Sequelize) { | |
await queryInterface.bulkDelete("localidade", null, {}); | |
} | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment