basic seed files and restructuring

This commit is contained in:
Arjun Patel
2019-03-13 21:22:01 -07:00
parent 66173a978b
commit 0c88460b54
26 changed files with 104 additions and 202 deletions
+73
View File
@@ -0,0 +1,73 @@
'use strict';
module.exports = {
up: (queryInterface, Sequelize) => {
return queryInterface.bulkInsert('organizations', [
{
name: 'Gopala Goshala',
email: '[email protected]',
password: hashedPass, //hashed password
short_description:
'We are focused on bringing lawful animal treatment in North India. Check out our many projects such as city water fountains for animals',
primary_cause: 'Animal',
primary_region,
ein,
primary_contact_first_name,
primary_contact_last_name,
phone,
country,
address,
city,
zip,
estimate_assets,
estimate_year_operating_cost
},
{
name,
email,
password: hashedPass, //hashed password
short_description,
primary_cause,
primary_region,
ein,
primary_contact_first_name,
primary_contact_last_name,
phone,
country,
address,
city,
zip,
estimate_assets,
estimate_year_operating_cost
},
{
name,
email,
password: hashedPass, //hashed password
short_description,
primary_cause,
primary_region,
ein,
primary_contact_first_name,
primary_contact_last_name,
phone,
country,
address,
city,
zip,
estimate_assets,
estimate_year_operating_cost
}
]);
},
down: (queryInterface, Sequelize) => {
return queryInterface.bulkDelete('organizations', {
[Sequelize.Op.or]: [
{ name: 'Gopala Goshala' },
{ name: 'Water Organization India' },
{ name: "Pete's Animals" }
]
});
}
};