dashboard workspace standard seeds (#16962)
# Introduction In this pull request we're introducing new standard page layout, tabs and widget ( 1 page layout, 1 tab and 8 widgets ) and also a new opportunity field Also now prefilling new records, 6 opportunities and a dashboard. ## Standard declaration ### New workspace creation Relies on existing standard declaration builder ### Backfill command We've been hacking through the standard builder in order to extract only the standard page layout entities, updated their entity dependencies to match the workspace ids so the validation passes ## Remark - Refactored the `PageLayoutWidget` configuration type to be dynamically typed through a generic discriminated union --------- Co-authored-by: prastoin <paul@twenty.com>
This commit is contained in:
+3
@@ -12,6 +12,7 @@ type OpportunityDataSeed = {
|
||||
position: number;
|
||||
pointOfContactId: string;
|
||||
companyId: string;
|
||||
ownerId: string;
|
||||
createdBySource: string;
|
||||
createdByWorkspaceMemberId: string;
|
||||
createdByName: string;
|
||||
@@ -30,6 +31,7 @@ export const OPPORTUNITY_DATA_SEED_COLUMNS: (keyof OpportunityDataSeed)[] = [
|
||||
'position',
|
||||
'pointOfContactId',
|
||||
'companyId',
|
||||
'ownerId',
|
||||
'createdBySource',
|
||||
'createdByWorkspaceMemberId',
|
||||
'createdByName',
|
||||
@@ -191,6 +193,7 @@ const GENERATE_OPPORTUNITY_SEEDS = (): OpportunityDataSeed[] => {
|
||||
COMPANY_DATA_SEED_IDS[
|
||||
`ID_${Math.ceil(INDEX / 2)}` as keyof typeof COMPANY_DATA_SEED_IDS
|
||||
] || COMPANY_DATA_SEED_IDS.ID_1,
|
||||
ownerId: WORKSPACE_MEMBER_DATA_SEED_IDS.TIM,
|
||||
createdBySource: 'MANUAL',
|
||||
createdByWorkspaceMemberId: WORKSPACE_MEMBER_DATA_SEED_IDS.TIM,
|
||||
createdByName: 'Tim Cook',
|
||||
|
||||
Reference in New Issue
Block a user