Fixed prisma.schema, package.json and prisma seed.ts
This commit is contained in:
@ -141,7 +141,7 @@ const equipmentData = [
|
||||
"undervognsbehandlet"
|
||||
];
|
||||
|
||||
const brandData = [
|
||||
/* const brandData = [
|
||||
"Abarth", "AC", "Adler", "Aiways", "Alfa Romeo", "Alpina", "Aston Martin",
|
||||
"Auburn", "Audi", "Austin", "Austin Healey", "Auto Union", "Bentley",
|
||||
"BMW", "Buick", "BYD", "Cadillac", "CF Moto", "Chevrolet", "Chrysler",
|
||||
@ -157,7 +157,7 @@ const brandData = [
|
||||
"Seat", "Seres", "Singer", "Skoda", "Smart", "SsangYong", "Studebaker",
|
||||
"Subaru", "Suzuki", "Saab", "Tesla", "Toyota", "Triumph", "Vauxhall",
|
||||
"Volvo", "Voyah", "VW", "Wolseley", "Xpeng", "Yugo"
|
||||
];
|
||||
]; */
|
||||
|
||||
async function main() {
|
||||
for (const equipment of equipmentData) {
|
||||
@ -166,18 +166,8 @@ async function main() {
|
||||
});
|
||||
}
|
||||
console.log('Equipment data seeded');
|
||||
|
||||
|
||||
// Seed Brands
|
||||
for (const brand of brandData) {
|
||||
await prisma.brand.create({
|
||||
data: { name: brand },
|
||||
});
|
||||
}
|
||||
console.log('Brand data seeded');
|
||||
}
|
||||
|
||||
|
||||
main()
|
||||
.catch((e) => {
|
||||
console.error(e);
|
||||
|
||||
Reference in New Issue
Block a user