[offers][misc] update seed script

pull/522/head
Yangshun Tay 2 years ago
parent 5afb0506d2
commit 373480b9e1

@ -0,0 +1,2 @@
-- AlterTable
ALTER TABLE "Company" ADD COLUMN "website" TEXT;

@ -98,6 +98,7 @@ model Company {
slug String @unique
description String? @db.Text
logoUrl String?
website String?
createdAt DateTime @default(now())
updatedAt DateTime @updatedAt

@ -96,13 +96,13 @@ const getLevel = (type: string) => {
processedType.includes('FRESH GRAD') ||
processedType.includes('JUNIOR')
) {
return 'L1';
return 'Junior';
} else if (processedType.includes('MID')) {
return 'L2';
return 'Mid';
} else if (processedType.includes('SENIOR')) {
return 'L4';
return 'Senior';
} else {
return 'L0';
return 'N/A';
}
};

@ -16,6 +16,7 @@ async function main() {
name: company.name,
slug: company.slug,
description: company.description,
website: company.website,
logoUrl: company.logoUrl,
})),
skipDuplicates: true,

Loading…
Cancel
Save