Add opened section (#7265)
When object is not part of the workspace favorite list, we want to show it in the "opened section" while its record page is accessed. This PR: - adds a new component `NavigationDrawerOpenedSection` - makes workflow versions and runs not system object + creates a prefilled view index for these - do not create workspace favorites for these so these do not appear in the workspace section <img width="1129" alt="Capture d’écran 2024-09-26 à 11 45 25" src="https://github.com/user-attachments/assets/c84d773c-0bef-4dce-b66a-55d7d00b0fb6">
This commit is contained in:
@ -2,6 +2,7 @@ import { DataSource, EntityManager } from 'typeorm';
|
||||
|
||||
import { seedWorkspaceFavorites } from 'src/database/typeorm-seeds/workspace/favorites';
|
||||
import { ObjectMetadataEntity } from 'src/engine/metadata-modules/object-metadata/object-metadata.entity';
|
||||
import { shouldSeedWorkspaceFavorite } from 'src/engine/utils/should-seed-workspace-favorite';
|
||||
import { companyPrefillDemoData } from 'src/engine/workspace-manager/demo-objects-prefill-data/company';
|
||||
import { opportunityPrefillDemoData } from 'src/engine/workspace-manager/demo-objects-prefill-data/opportunity';
|
||||
import { personPrefillDemoData } from 'src/engine/workspace-manager/demo-objects-prefill-data/person';
|
||||
@ -42,7 +43,7 @@ export const demoObjectsPrefillData = async (
|
||||
|
||||
await seedWorkspaceFavorites(
|
||||
viewDefinitionsWithId
|
||||
.filter((view) => view.key === 'INDEX')
|
||||
.filter((view) => view.key === 'INDEX' && shouldSeedWorkspaceFavorite(view.objectMetadataId, objectMetadataMap))
|
||||
.map((view) => view.id),
|
||||
entityManager,
|
||||
schemaName,
|
||||
|
||||
Reference in New Issue
Block a user