@powerhousedao/network-admin 1.0.0-dev.3 → 1.0.0-staging.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/document-models/builders/actions.d.ts +14 -0
- package/dist/document-models/builders/actions.d.ts.map +1 -0
- package/dist/document-models/builders/actions.js +4 -0
- package/dist/document-models/builders/gen/actions.d.ts +4 -0
- package/dist/document-models/builders/gen/actions.d.ts.map +1 -0
- package/dist/document-models/builders/gen/actions.js +1 -0
- package/dist/document-models/builders/gen/builders/actions.d.ts +12 -0
- package/dist/document-models/builders/gen/builders/actions.d.ts.map +1 -0
- package/dist/document-models/builders/gen/builders/actions.js +1 -0
- package/dist/document-models/builders/gen/builders/creators.d.ts +5 -0
- package/dist/document-models/builders/gen/builders/creators.d.ts.map +1 -0
- package/dist/document-models/builders/gen/builders/creators.js +4 -0
- package/dist/document-models/builders/gen/builders/error.d.ts +2 -0
- package/dist/document-models/builders/gen/builders/error.d.ts.map +1 -0
- package/dist/document-models/builders/gen/builders/error.js +1 -0
- package/dist/document-models/builders/gen/builders/operations.d.ts +8 -0
- package/dist/document-models/builders/gen/builders/operations.d.ts.map +1 -0
- package/dist/document-models/builders/gen/builders/operations.js +1 -0
- package/dist/document-models/builders/gen/creators.d.ts +3 -0
- package/dist/document-models/builders/gen/creators.d.ts.map +1 -0
- package/dist/document-models/builders/gen/creators.js +2 -0
- package/dist/document-models/builders/gen/document-model.d.ts +3 -0
- package/dist/document-models/builders/gen/document-model.d.ts.map +1 -0
- package/dist/document-models/builders/gen/document-model.js +59 -0
- package/dist/document-models/builders/gen/document-schema.d.ts +44 -0
- package/dist/document-models/builders/gen/document-schema.d.ts.map +1 -0
- package/dist/document-models/builders/gen/document-schema.js +33 -0
- package/dist/document-models/builders/gen/document-type.d.ts +2 -0
- package/dist/document-models/builders/gen/document-type.d.ts.map +1 -0
- package/dist/document-models/builders/gen/document-type.js +1 -0
- package/dist/document-models/builders/gen/index.d.ts +12 -0
- package/dist/document-models/builders/gen/index.d.ts.map +1 -0
- package/dist/document-models/builders/gen/index.js +11 -0
- package/dist/document-models/builders/gen/ph-factories.d.ts +23 -0
- package/dist/document-models/builders/gen/ph-factories.d.ts.map +1 -0
- package/dist/document-models/builders/gen/ph-factories.js +47 -0
- package/dist/document-models/builders/gen/reducer.d.ts +3 -0
- package/dist/document-models/builders/gen/reducer.d.ts.map +1 -0
- package/dist/document-models/builders/gen/reducer.js +23 -0
- package/dist/document-models/builders/gen/schema/index.d.ts +3 -0
- package/dist/document-models/builders/gen/schema/index.d.ts.map +1 -0
- package/dist/document-models/builders/gen/schema/index.js +2 -0
- package/dist/document-models/builders/gen/schema/types.d.ts +158 -0
- package/dist/document-models/builders/gen/schema/types.d.ts.map +1 -0
- package/dist/document-models/builders/gen/schema/types.js +1 -0
- package/dist/document-models/builders/gen/schema/zod.d.ts +13 -0
- package/dist/document-models/builders/gen/schema/zod.d.ts.map +1 -0
- package/dist/document-models/builders/gen/schema/zod.js +21 -0
- package/dist/document-models/builders/gen/types.d.ts +12 -0
- package/dist/document-models/builders/gen/types.d.ts.map +1 -0
- package/dist/document-models/builders/gen/types.js +1 -0
- package/dist/document-models/builders/gen/utils.d.ts +15 -0
- package/dist/document-models/builders/gen/utils.d.ts.map +1 -0
- package/dist/document-models/builders/gen/utils.js +51 -0
- package/dist/document-models/builders/hooks.d.ts +14 -0
- package/dist/document-models/builders/hooks.d.ts.map +1 -0
- package/dist/document-models/builders/hooks.js +25 -0
- package/dist/document-models/builders/index.d.ts +6 -0
- package/dist/document-models/builders/index.d.ts.map +1 -0
- package/dist/document-models/builders/index.js +5 -0
- package/dist/document-models/builders/module.d.ts +5 -0
- package/dist/document-models/builders/module.d.ts.map +1 -0
- package/dist/document-models/builders/module.js +11 -0
- package/dist/document-models/builders/src/index.d.ts +2 -0
- package/dist/document-models/builders/src/index.d.ts.map +1 -0
- package/dist/document-models/builders/src/index.js +1 -0
- package/dist/document-models/builders/src/reducers/builders.d.ts +3 -0
- package/dist/document-models/builders/src/reducers/builders.d.ts.map +1 -0
- package/dist/document-models/builders/src/reducers/builders.js +8 -0
- package/dist/document-models/builders/src/tests/builders.test.d.ts +6 -0
- package/dist/document-models/builders/src/tests/builders.test.d.ts.map +1 -0
- package/dist/document-models/builders/src/tests/builders.test.js +29 -0
- package/dist/document-models/builders/src/tests/document-model.test.d.ts +10 -0
- package/dist/document-models/builders/src/tests/document-model.test.d.ts.map +1 -0
- package/dist/document-models/builders/src/tests/document-model.test.js +104 -0
- package/dist/document-models/builders/src/utils.d.ts +2 -0
- package/dist/document-models/builders/src/utils.d.ts.map +1 -0
- package/dist/document-models/builders/src/utils.js +1 -0
- package/dist/document-models/builders/tests/builders.test.d.ts +2 -0
- package/dist/document-models/builders/tests/builders.test.d.ts.map +1 -0
- package/dist/document-models/builders/tests/builders.test.js +25 -0
- package/dist/document-models/builders/tests/document-model.test.d.ts +10 -0
- package/dist/document-models/builders/tests/document-model.test.d.ts.map +1 -0
- package/dist/document-models/builders/tests/document-model.test.js +104 -0
- package/dist/document-models/builders/utils.d.ts +14 -0
- package/dist/document-models/builders/utils.d.ts.map +1 -0
- package/dist/document-models/builders/utils.js +7 -0
- package/dist/document-models/document-models.d.ts.map +1 -1
- package/dist/document-models/document-models.js +2 -0
- package/dist/document-models/index.d.ts +1 -0
- package/dist/document-models/index.d.ts.map +1 -1
- package/dist/document-models/index.js +1 -0
- package/dist/document-models/network-profile/gen/document-model.d.ts.map +1 -1
- package/dist/document-models/network-profile/gen/document-model.js +84 -84
- package/dist/document-models/network-profile/gen/document-schema.d.ts +80 -0
- package/dist/document-models/network-profile/gen/document-schema.d.ts.map +1 -0
- package/dist/document-models/network-profile/gen/ph-factories.d.ts.map +1 -1
- package/dist/document-models/network-profile/gen/ph-factories.js +2 -0
- package/dist/document-models/network-profile/gen/reducer.d.ts +1 -0
- package/dist/document-models/network-profile/gen/reducer.d.ts.map +1 -1
- package/dist/document-models/network-profile/gen/schema/types.d.ts +6 -2
- package/dist/document-models/network-profile/gen/schema/types.d.ts.map +1 -1
- package/dist/document-models/network-profile/gen/schema/zod.d.ts +8 -2
- package/dist/document-models/network-profile/gen/schema/zod.d.ts.map +1 -1
- package/dist/document-models/network-profile/gen/schema/zod.js +6 -2
- package/dist/document-models/network-profile/gen/utils.d.ts.map +1 -1
- package/dist/document-models/network-profile/gen/utils.js +3 -1
- package/dist/document-models/network-profile/hooks.d.ts +2 -2
- package/dist/document-models/network-profile/hooks.d.ts.map +1 -1
- package/dist/document-models/network-profile/src/reducers/network-profile-management.d.ts +0 -1
- package/dist/document-models/network-profile/src/reducers/network-profile-management.d.ts.map +1 -1
- package/dist/document-models/network-profile/src/reducers/network-profile-management.js +27 -18
- package/dist/document-models/network-profile/src/tests/document-model.test.d.ts +4 -0
- package/dist/document-models/network-profile/src/tests/document-model.test.d.ts.map +1 -1
- package/dist/document-models/network-profile/src/tests/document-model.test.js +92 -6
- package/dist/document-models/network-profile/src/tests/network-profile-management.test.js +69 -115
- package/dist/document-models/payment-terms/actions.d.ts +1 -2
- package/dist/document-models/payment-terms/actions.d.ts.map +1 -1
- package/dist/document-models/payment-terms/gen/clauses/error.d.ts +1 -40
- package/dist/document-models/payment-terms/gen/clauses/error.d.ts.map +1 -1
- package/dist/document-models/payment-terms/gen/clauses/error.js +1 -32
- package/dist/document-models/payment-terms/gen/document-model.d.ts.map +1 -1
- package/dist/document-models/payment-terms/gen/document-model.js +89 -180
- package/dist/document-models/payment-terms/gen/document-schema.d.ts +95 -0
- package/dist/document-models/payment-terms/gen/document-schema.d.ts.map +1 -0
- package/dist/document-models/payment-terms/gen/milestones/error.d.ts +1 -26
- package/dist/document-models/payment-terms/gen/milestones/error.d.ts.map +1 -1
- package/dist/document-models/payment-terms/gen/milestones/error.js +1 -18
- package/dist/document-models/payment-terms/gen/ph-factories.d.ts.map +1 -1
- package/dist/document-models/payment-terms/gen/ph-factories.js +1 -2
- package/dist/document-models/payment-terms/gen/reducer.d.ts +1 -0
- package/dist/document-models/payment-terms/gen/reducer.d.ts.map +1 -1
- package/dist/document-models/payment-terms/gen/reducer.js +4 -9
- package/dist/document-models/payment-terms/gen/schema/types.d.ts +14 -29
- package/dist/document-models/payment-terms/gen/schema/types.d.ts.map +1 -1
- package/dist/document-models/payment-terms/gen/schema/zod.d.ts +36 -12
- package/dist/document-models/payment-terms/gen/schema/zod.d.ts.map +1 -1
- package/dist/document-models/payment-terms/gen/schema/zod.js +29 -55
- package/dist/document-models/payment-terms/gen/terms/actions.d.ts +5 -9
- package/dist/document-models/payment-terms/gen/terms/actions.d.ts.map +1 -1
- package/dist/document-models/payment-terms/gen/terms/creators.d.ts +3 -4
- package/dist/document-models/payment-terms/gen/terms/creators.d.ts.map +1 -1
- package/dist/document-models/payment-terms/gen/terms/creators.js +2 -3
- package/dist/document-models/payment-terms/gen/terms/operations.d.ts +2 -3
- package/dist/document-models/payment-terms/gen/terms/operations.d.ts.map +1 -1
- package/dist/document-models/payment-terms/gen/utils.d.ts.map +1 -1
- package/dist/document-models/payment-terms/gen/utils.js +2 -3
- package/dist/document-models/payment-terms/hooks.d.ts +2 -2
- package/dist/document-models/payment-terms/hooks.d.ts.map +1 -1
- package/dist/document-models/payment-terms/src/reducers/clauses.d.ts +0 -1
- package/dist/document-models/payment-terms/src/reducers/clauses.d.ts.map +1 -1
- package/dist/document-models/payment-terms/src/reducers/clauses.js +13 -15
- package/dist/document-models/payment-terms/src/reducers/milestones.d.ts +0 -1
- package/dist/document-models/payment-terms/src/reducers/milestones.d.ts.map +1 -1
- package/dist/document-models/payment-terms/src/reducers/milestones.js +10 -12
- package/dist/document-models/payment-terms/src/reducers/terms.d.ts +0 -1
- package/dist/document-models/payment-terms/src/reducers/terms.d.ts.map +1 -1
- package/dist/document-models/payment-terms/src/reducers/terms.js +14 -24
- package/dist/document-models/payment-terms/src/tests/clauses.test.js +26 -21
- package/dist/document-models/payment-terms/src/tests/document-model.test.d.ts +4 -0
- package/dist/document-models/payment-terms/src/tests/document-model.test.d.ts.map +1 -1
- package/dist/document-models/payment-terms/src/tests/document-model.test.js +92 -6
- package/dist/document-models/payment-terms/src/tests/milestones.test.js +22 -19
- package/dist/document-models/payment-terms/src/tests/terms.test.js +24 -29
- package/dist/document-models/payment-terms/tests/terms.test.js +5 -15
- package/dist/document-models/request-for-proposals/gen/document-model.js +4 -4
- package/dist/document-models/request-for-proposals/gen/document-schema.d.ts +83 -0
- package/dist/document-models/request-for-proposals/gen/document-schema.d.ts.map +1 -0
- package/dist/document-models/request-for-proposals/gen/ph-factories.d.ts.map +1 -1
- package/dist/document-models/request-for-proposals/gen/ph-factories.js +6 -4
- package/dist/document-models/request-for-proposals/gen/reducer.d.ts +1 -0
- package/dist/document-models/request-for-proposals/gen/reducer.d.ts.map +1 -1
- package/dist/document-models/request-for-proposals/gen/schema/zod.d.ts +64 -9
- package/dist/document-models/request-for-proposals/gen/schema/zod.d.ts.map +1 -1
- package/dist/document-models/request-for-proposals/gen/utils.d.ts.map +1 -1
- package/dist/document-models/request-for-proposals/gen/utils.js +7 -5
- package/dist/document-models/request-for-proposals/hooks.d.ts +2 -2
- package/dist/document-models/request-for-proposals/hooks.d.ts.map +1 -1
- package/dist/document-models/request-for-proposals/src/reducers/contex-document.d.ts +0 -1
- package/dist/document-models/request-for-proposals/src/reducers/contex-document.d.ts.map +1 -1
- package/dist/document-models/request-for-proposals/src/reducers/contex-document.js +3 -4
- package/dist/document-models/request-for-proposals/src/reducers/proposals.d.ts +0 -1
- package/dist/document-models/request-for-proposals/src/reducers/proposals.d.ts.map +1 -1
- package/dist/document-models/request-for-proposals/src/reducers/proposals.js +4 -5
- package/dist/document-models/request-for-proposals/src/reducers/rfp-state.d.ts +0 -1
- package/dist/document-models/request-for-proposals/src/reducers/rfp-state.d.ts.map +1 -1
- package/dist/document-models/request-for-proposals/src/reducers/rfp-state.js +2 -3
- package/dist/document-models/request-for-proposals/src/tests/contex-document.test.d.ts +2 -1
- package/dist/document-models/request-for-proposals/src/tests/contex-document.test.d.ts.map +1 -1
- package/dist/document-models/request-for-proposals/src/tests/contex-document.test.js +24 -181
- package/dist/document-models/request-for-proposals/src/tests/document-model.test.d.ts +4 -0
- package/dist/document-models/request-for-proposals/src/tests/document-model.test.d.ts.map +1 -1
- package/dist/document-models/request-for-proposals/src/tests/document-model.test.js +92 -6
- package/dist/document-models/request-for-proposals/src/tests/proposals.test.d.ts +2 -1
- package/dist/document-models/request-for-proposals/src/tests/proposals.test.d.ts.map +1 -1
- package/dist/document-models/request-for-proposals/src/tests/proposals.test.js +33 -327
- package/dist/document-models/request-for-proposals/src/tests/rfp-state.test.d.ts +2 -1
- package/dist/document-models/request-for-proposals/src/tests/rfp-state.test.d.ts.map +1 -1
- package/dist/document-models/request-for-proposals/src/tests/rfp-state.test.js +15 -240
- package/dist/document-models/workstream/gen/document-model.d.ts.map +1 -1
- package/dist/document-models/workstream/gen/document-model.js +16 -16
- package/dist/document-models/workstream/gen/document-schema.d.ts +71 -0
- package/dist/document-models/workstream/gen/document-schema.d.ts.map +1 -0
- package/dist/document-models/workstream/gen/reducer.d.ts +1 -0
- package/dist/document-models/workstream/gen/reducer.d.ts.map +1 -1
- package/dist/document-models/workstream/gen/schema/types.d.ts +1 -1
- package/dist/document-models/workstream/gen/schema/types.d.ts.map +1 -1
- package/dist/document-models/workstream/gen/schema/zod.d.ts +35 -5
- package/dist/document-models/workstream/gen/schema/zod.d.ts.map +1 -1
- package/dist/document-models/workstream/gen/utils.js +1 -1
- package/dist/document-models/workstream/hooks.d.ts +2 -2
- package/dist/document-models/workstream/hooks.d.ts.map +1 -1
- package/dist/document-models/workstream/src/reducers/proposals.d.ts +0 -1
- package/dist/document-models/workstream/src/reducers/proposals.d.ts.map +1 -1
- package/dist/document-models/workstream/src/reducers/proposals.js +83 -6
- package/dist/document-models/workstream/src/reducers/workstream.d.ts +0 -1
- package/dist/document-models/workstream/src/reducers/workstream.d.ts.map +1 -1
- package/dist/document-models/workstream/src/reducers/workstream.js +6 -7
- package/dist/document-models/workstream/src/tests/document-model.test.d.ts +4 -0
- package/dist/document-models/workstream/src/tests/document-model.test.d.ts.map +1 -1
- package/dist/document-models/workstream/src/tests/document-model.test.js +89 -3
- package/dist/document-models/workstream/src/tests/proposals.test.js +26 -25
- package/dist/document-models/workstream/src/tests/workstream.test.js +34 -29
- package/dist/editors/builders/editor.d.ts +3 -0
- package/dist/editors/builders/editor.d.ts.map +1 -0
- package/dist/editors/builders/editor.js +285 -0
- package/dist/editors/builders/hooks/useRemoteBuilderProfiles.d.ts +20 -0
- package/dist/editors/builders/hooks/useRemoteBuilderProfiles.d.ts.map +1 -0
- package/dist/editors/builders/hooks/useRemoteBuilderProfiles.js +57 -0
- package/dist/editors/builders/module.d.ts +4 -0
- package/dist/editors/builders/module.d.ts.map +1 -0
- package/dist/editors/builders/module.js +10 -0
- package/dist/editors/builders/utils/graphql-client.d.ts +41 -0
- package/dist/editors/builders/utils/graphql-client.d.ts.map +1 -0
- package/dist/editors/builders/utils/graphql-client.js +189 -0
- package/dist/editors/editors.d.ts +3 -0
- package/dist/editors/editors.d.ts.map +1 -0
- package/dist/editors/editors.js +14 -0
- package/dist/editors/index.d.ts +6 -6
- package/dist/editors/index.d.ts.map +1 -1
- package/dist/editors/index.js +6 -6
- package/dist/editors/network-admin/components/CreateDocument.d.ts.map +1 -1
- package/dist/editors/network-admin/components/CreateDocument.js +8 -12
- package/dist/editors/network-admin/components/DriveContents.d.ts +3 -0
- package/dist/editors/network-admin/components/DriveContents.d.ts.map +1 -0
- package/dist/editors/network-admin/components/DriveContents.js +10 -0
- package/dist/editors/network-admin/components/DriveExplorer.d.ts +1 -1
- package/dist/editors/network-admin/components/DriveExplorer.d.ts.map +1 -1
- package/dist/editors/network-admin/components/DriveExplorer.js +53 -230
- package/dist/editors/network-admin/components/EmptyState.d.ts +3 -0
- package/dist/editors/network-admin/components/EmptyState.d.ts.map +1 -0
- package/dist/editors/network-admin/components/EmptyState.js +10 -0
- package/dist/editors/network-admin/components/Files.d.ts +3 -0
- package/dist/editors/network-admin/components/Files.d.ts.map +1 -0
- package/dist/editors/network-admin/components/Files.js +12 -0
- package/dist/editors/network-admin/components/FolderTree.d.ts +9 -1
- package/dist/editors/network-admin/components/FolderTree.d.ts.map +1 -1
- package/dist/editors/network-admin/components/FolderTree.js +216 -55
- package/dist/editors/network-admin/components/Folders.d.ts +3 -0
- package/dist/editors/network-admin/components/Folders.d.ts.map +1 -0
- package/dist/editors/network-admin/components/Folders.js +12 -0
- package/dist/editors/network-admin/components/NavigationBreadcrumbs.d.ts +3 -0
- package/dist/editors/network-admin/components/NavigationBreadcrumbs.d.ts.map +1 -0
- package/dist/editors/network-admin/components/NavigationBreadcrumbs.js +6 -0
- package/dist/editors/network-admin/components/icons/PaymentIcon.d.ts.map +1 -1
- package/dist/editors/network-admin/components/icons/RfpIcon.d.ts.map +1 -1
- package/dist/editors/network-admin/components/icons/SowIcon.d.ts.map +1 -1
- package/dist/editors/network-admin/components/icons/WorkstreamIcon.d.ts.map +1 -1
- package/dist/editors/network-admin/config.d.ts +1 -0
- package/dist/editors/network-admin/config.d.ts.map +1 -1
- package/dist/editors/network-admin/config.js +1 -1
- package/dist/editors/network-admin/editor.d.ts +2 -1
- package/dist/editors/network-admin/editor.d.ts.map +1 -1
- package/dist/editors/network-admin/editor.js +4 -1
- package/dist/editors/network-admin/module.d.ts +4 -0
- package/dist/editors/network-admin/module.d.ts.map +1 -0
- package/dist/editors/network-admin/module.js +10 -0
- package/dist/editors/network-profile/components/EditName.d.ts +3 -0
- package/dist/editors/network-profile/components/EditName.d.ts.map +1 -0
- package/dist/editors/network-profile/components/EditName.js +31 -0
- package/dist/editors/network-profile/editor.d.ts +1 -1
- package/dist/editors/network-profile/editor.d.ts.map +1 -1
- package/dist/editors/network-profile/editor.js +45 -13
- package/dist/editors/network-profile/module.d.ts +4 -0
- package/dist/editors/network-profile/module.d.ts.map +1 -0
- package/dist/editors/network-profile/module.js +10 -0
- package/dist/editors/payment-terms/components/clauses-section.d.ts +12 -0
- package/dist/editors/payment-terms/components/clauses-section.d.ts.map +1 -0
- package/dist/editors/payment-terms/components/clauses-section.js +269 -0
- package/dist/editors/payment-terms/components/escrow-section.d.ts +13 -0
- package/dist/editors/payment-terms/components/escrow-section.d.ts.map +1 -0
- package/dist/editors/payment-terms/components/escrow-section.js +72 -0
- package/dist/editors/payment-terms/components/evaluation-section.d.ts +13 -0
- package/dist/editors/payment-terms/components/evaluation-section.d.ts.map +1 -0
- package/dist/editors/payment-terms/components/evaluation-section.js +94 -0
- package/dist/editors/payment-terms/components/header-section.d.ts +16 -0
- package/dist/editors/payment-terms/components/header-section.d.ts.map +1 -0
- package/dist/editors/payment-terms/components/header-section.js +67 -0
- package/dist/editors/payment-terms/components/milestones-section.d.ts +11 -0
- package/dist/editors/payment-terms/components/milestones-section.d.ts.map +1 -0
- package/dist/editors/payment-terms/components/milestones-section.js +236 -0
- package/dist/editors/payment-terms/components/parties-section.d.ts +11 -0
- package/dist/editors/payment-terms/components/parties-section.d.ts.map +1 -0
- package/dist/editors/payment-terms/components/parties-section.js +36 -0
- package/dist/editors/payment-terms/components/payment-config-section.d.ts +11 -0
- package/dist/editors/payment-terms/components/payment-config-section.d.ts.map +1 -0
- package/dist/editors/payment-terms/components/payment-config-section.js +68 -0
- package/dist/editors/payment-terms/components/time-materials-section.d.ts +11 -0
- package/dist/editors/payment-terms/components/time-materials-section.d.ts.map +1 -0
- package/dist/editors/payment-terms/components/time-materials-section.js +68 -0
- package/dist/editors/payment-terms/editor.d.ts +0 -2
- package/dist/editors/payment-terms/editor.d.ts.map +1 -1
- package/dist/editors/payment-terms/editor.js +39 -55
- package/dist/editors/payment-terms/module.d.ts +4 -0
- package/dist/editors/payment-terms/module.d.ts.map +1 -0
- package/dist/editors/payment-terms/module.js +10 -0
- package/dist/editors/request-for-proposals/components/EditName.d.ts +3 -0
- package/dist/editors/request-for-proposals/components/EditName.d.ts.map +1 -0
- package/dist/editors/request-for-proposals/components/EditName.js +31 -0
- package/dist/editors/request-for-proposals/editor.d.ts.map +1 -1
- package/dist/editors/request-for-proposals/editor.js +4 -4
- package/dist/editors/request-for-proposals/markdown-editor.d.ts.map +1 -1
- package/dist/editors/request-for-proposals/markdown-editor.js +3 -3
- package/dist/editors/request-for-proposals/module.d.ts +4 -0
- package/dist/editors/request-for-proposals/module.d.ts.map +1 -0
- package/dist/editors/request-for-proposals/module.js +10 -0
- package/dist/editors/workstream/editor.d.ts.map +1 -1
- package/dist/editors/workstream/editor.js +290 -165
- package/dist/editors/workstream/module.d.ts +4 -0
- package/dist/editors/workstream/module.d.ts.map +1 -0
- package/dist/editors/workstream/module.js +10 -0
- package/dist/index.d.ts +2 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -4
- package/dist/powerhouse.manifest.json +27 -6
- package/dist/processors/factory.d.ts +1 -1
- package/dist/processors/factory.d.ts.map +1 -1
- package/dist/processors/factory.js +1 -1
- package/dist/processors/index.d.ts +1 -1
- package/dist/processors/index.d.ts.map +1 -1
- package/dist/processors/index.js +1 -1
- package/dist/processors/workstreams/factory.d.ts.map +1 -1
- package/dist/processors/workstreams/factory.js +4 -1
- package/dist/processors/workstreams/index.d.ts +4 -2
- package/dist/processors/workstreams/index.d.ts.map +1 -1
- package/dist/processors/workstreams/index.js +102 -43
- package/dist/processors/workstreams/migrations.d.ts.map +1 -1
- package/dist/processors/workstreams/migrations.js +12 -15
- package/dist/scripts/sow-mirror/mirror_sow_state.js +119 -114
- package/dist/style.css +6046 -6846
- package/dist/subgraphs/{payment-terms → builders-addon}/index.d.ts +1 -1
- package/dist/subgraphs/builders-addon/index.d.ts.map +1 -0
- package/dist/subgraphs/{workstream → builders-addon}/index.js +2 -2
- package/dist/subgraphs/builders-addon/resolvers.d.ts.map +1 -0
- package/dist/subgraphs/builders-addon/resolvers.js +442 -0
- package/dist/subgraphs/builders-addon/schema.d.ts.map +1 -0
- package/dist/subgraphs/builders-addon/schema.js +294 -0
- package/dist/subgraphs/index.d.ts +1 -5
- package/dist/subgraphs/index.d.ts.map +1 -1
- package/dist/subgraphs/index.js +1 -5
- package/dist/subgraphs/networks/resolvers.d.ts +2 -2
- package/dist/subgraphs/networks/resolvers.d.ts.map +1 -1
- package/dist/subgraphs/networks/resolvers.js +138 -8
- package/dist/subgraphs/networks/schema.d.ts.map +1 -1
- package/dist/subgraphs/networks/schema.js +66 -1
- package/dist/subgraphs/workstreams/index.d.ts +4 -1
- package/dist/subgraphs/workstreams/index.d.ts.map +1 -1
- package/dist/subgraphs/workstreams/index.js +6 -0
- package/dist/subgraphs/workstreams/resolvers.d.ts.map +1 -1
- package/dist/subgraphs/workstreams/resolvers.js +495 -30
- package/dist/subgraphs/workstreams/schema.d.ts.map +1 -1
- package/dist/subgraphs/workstreams/schema.js +228 -35
- package/dist/vite.config.d.ts.map +1 -1
- package/dist/vite.config.js +6 -1
- package/package.json +58 -87
- package/dist/document-models/workstream/src/tests/proposals-reducers.test.d.ts +0 -5
- package/dist/document-models/workstream/src/tests/proposals-reducers.test.d.ts.map +0 -1
- package/dist/document-models/workstream/src/tests/proposals-reducers.test.js +0 -318
- package/dist/document-models/workstream/src/tests/workstream-reducers.test.d.ts +0 -5
- package/dist/document-models/workstream/src/tests/workstream-reducers.test.d.ts.map +0 -1
- package/dist/document-models/workstream/src/tests/workstream-reducers.test.js +0 -210
- package/dist/editors/hooks/useNetworkProfileDocument.d.ts +0 -4
- package/dist/editors/hooks/useNetworkProfileDocument.d.ts.map +0 -1
- package/dist/editors/hooks/useNetworkProfileDocument.js +0 -8
- package/dist/editors/hooks/usePaymentTermsDocument.d.ts +0 -4
- package/dist/editors/hooks/usePaymentTermsDocument.d.ts.map +0 -1
- package/dist/editors/hooks/usePaymentTermsDocument.js +0 -8
- package/dist/editors/hooks/useRequestForProposalsDocument.d.ts +0 -4
- package/dist/editors/hooks/useRequestForProposalsDocument.d.ts.map +0 -1
- package/dist/editors/hooks/useRequestForProposalsDocument.js +0 -8
- package/dist/editors/hooks/useWorkstreamDocument.d.ts +0 -4
- package/dist/editors/hooks/useWorkstreamDocument.d.ts.map +0 -1
- package/dist/editors/hooks/useWorkstreamDocument.js +0 -8
- package/dist/editors/network-admin/index.d.ts +0 -3
- package/dist/editors/network-admin/index.d.ts.map +0 -1
- package/dist/editors/network-admin/index.js +0 -10
- package/dist/editors/network-profile/index.d.ts +0 -4
- package/dist/editors/network-profile/index.d.ts.map +0 -1
- package/dist/editors/network-profile/index.js +0 -10
- package/dist/editors/payment-terms/basic-terms-tab.d.ts +0 -10
- package/dist/editors/payment-terms/basic-terms-tab.d.ts.map +0 -1
- package/dist/editors/payment-terms/basic-terms-tab.js +0 -89
- package/dist/editors/payment-terms/clauses-tab.d.ts +0 -12
- package/dist/editors/payment-terms/clauses-tab.d.ts.map +0 -1
- package/dist/editors/payment-terms/clauses-tab.js +0 -213
- package/dist/editors/payment-terms/cost-materials-tab.d.ts +0 -10
- package/dist/editors/payment-terms/cost-materials-tab.d.ts.map +0 -1
- package/dist/editors/payment-terms/cost-materials-tab.js +0 -63
- package/dist/editors/payment-terms/escrow-tab.d.ts +0 -10
- package/dist/editors/payment-terms/escrow-tab.d.ts.map +0 -1
- package/dist/editors/payment-terms/escrow-tab.js +0 -57
- package/dist/editors/payment-terms/evaluation-tab.d.ts +0 -10
- package/dist/editors/payment-terms/evaluation-tab.d.ts.map +0 -1
- package/dist/editors/payment-terms/evaluation-tab.js +0 -63
- package/dist/editors/payment-terms/index.d.ts +0 -4
- package/dist/editors/payment-terms/index.d.ts.map +0 -1
- package/dist/editors/payment-terms/index.js +0 -10
- package/dist/editors/payment-terms/milestones-tab.d.ts +0 -10
- package/dist/editors/payment-terms/milestones-tab.d.ts.map +0 -1
- package/dist/editors/payment-terms/milestones-tab.js +0 -205
- package/dist/editors/payment-terms/retainer-tab.d.ts +0 -10
- package/dist/editors/payment-terms/retainer-tab.d.ts.map +0 -1
- package/dist/editors/payment-terms/retainer-tab.js +0 -91
- package/dist/editors/request-for-proposals/index.d.ts +0 -4
- package/dist/editors/request-for-proposals/index.d.ts.map +0 -1
- package/dist/editors/request-for-proposals/index.js +0 -10
- package/dist/editors/workstream/index.d.ts +0 -4
- package/dist/editors/workstream/index.d.ts.map +0 -1
- package/dist/editors/workstream/index.js +0 -10
- package/dist/editors/workstream/project-management-import.d.ts +0 -3
- package/dist/editors/workstream/project-management-import.d.ts.map +0 -1
- package/dist/editors/workstream/project-management-import.js +0 -5
- package/dist/subgraphs/network-profile/index.d.ts +0 -11
- package/dist/subgraphs/network-profile/index.d.ts.map +0 -1
- package/dist/subgraphs/network-profile/index.js +0 -11
- package/dist/subgraphs/network-profile/resolvers.d.ts.map +0 -1
- package/dist/subgraphs/network-profile/resolvers.js +0 -205
- package/dist/subgraphs/network-profile/schema.d.ts.map +0 -1
- package/dist/subgraphs/network-profile/schema.js +0 -139
- package/dist/subgraphs/payment-terms/index.d.ts.map +0 -1
- package/dist/subgraphs/payment-terms/index.js +0 -11
- package/dist/subgraphs/payment-terms/resolvers.d.ts +0 -3
- package/dist/subgraphs/payment-terms/resolvers.d.ts.map +0 -1
- package/dist/subgraphs/payment-terms/resolvers.js +0 -277
- package/dist/subgraphs/payment-terms/schema.d.ts +0 -3
- package/dist/subgraphs/payment-terms/schema.d.ts.map +0 -1
- package/dist/subgraphs/payment-terms/schema.js +0 -324
- package/dist/subgraphs/request-for-proposals/index.d.ts +0 -11
- package/dist/subgraphs/request-for-proposals/index.d.ts.map +0 -1
- package/dist/subgraphs/request-for-proposals/index.js +0 -11
- package/dist/subgraphs/request-for-proposals/resolvers.d.ts +0 -3
- package/dist/subgraphs/request-for-proposals/resolvers.d.ts.map +0 -1
- package/dist/subgraphs/request-for-proposals/resolvers.js +0 -145
- package/dist/subgraphs/request-for-proposals/schema.d.ts +0 -3
- package/dist/subgraphs/request-for-proposals/schema.d.ts.map +0 -1
- package/dist/subgraphs/request-for-proposals/schema.js +0 -232
- package/dist/subgraphs/workstream/index.d.ts +0 -11
- package/dist/subgraphs/workstream/index.d.ts.map +0 -1
- package/dist/subgraphs/workstream/resolvers.d.ts +0 -3
- package/dist/subgraphs/workstream/resolvers.d.ts.map +0 -1
- package/dist/subgraphs/workstream/resolvers.js +0 -181
- package/dist/subgraphs/workstream/schema.d.ts +0 -3
- package/dist/subgraphs/workstream/schema.d.ts.map +0 -1
- package/dist/subgraphs/workstream/schema.js +0 -206
- package/dist/vitest.config.d.ts +0 -3
- package/dist/vitest.config.d.ts.map +0 -1
- package/dist/vitest.config.js +0 -8
- /package/dist/subgraphs/{network-profile → builders-addon}/resolvers.d.ts +0 -0
- /package/dist/subgraphs/{network-profile → builders-addon}/schema.d.ts +0 -0
|
@@ -2,15 +2,41 @@ import {} from "@powerhousedao/reactor-api";
|
|
|
2
2
|
import { WorkstreamsProcessor } from "../../processors/workstreams/index.js";
|
|
3
3
|
import {} from "../../document-models/request-for-proposals/index.js";
|
|
4
4
|
import {} from "../../document-models/workstream/index.js";
|
|
5
|
+
import { sql } from "kysely";
|
|
5
6
|
export const getResolvers = (subgraph) => {
|
|
6
7
|
const reactor = subgraph.reactor;
|
|
7
8
|
const db = subgraph.relationalDb;
|
|
9
|
+
// Shared state for builder profile resolution (used by field resolvers)
|
|
10
|
+
let getBuilderProfileByPhid = null;
|
|
8
11
|
const deriveSlug = (name) => name.toLowerCase().trim().split(/\s+/).join("-");
|
|
12
|
+
const extractPhid = (value) => {
|
|
13
|
+
if (typeof value === "string") {
|
|
14
|
+
// Return null for empty strings, otherwise return the string
|
|
15
|
+
return value.trim() || null;
|
|
16
|
+
}
|
|
17
|
+
if (value &&
|
|
18
|
+
typeof value === "object" &&
|
|
19
|
+
"id" in value &&
|
|
20
|
+
typeof value.id === "string") {
|
|
21
|
+
const id = value.id;
|
|
22
|
+
// Return null for empty strings
|
|
23
|
+
return id.trim() || null;
|
|
24
|
+
}
|
|
25
|
+
return null;
|
|
26
|
+
};
|
|
27
|
+
// Normalize drive IDs to match the format used by the processor factory
|
|
28
|
+
// reactor.getDrives() returns base64-like IDs (with + and =)
|
|
29
|
+
// but driveHeader.id in the factory uses - instead of +
|
|
30
|
+
// TODO: Report this inconsistency to @powerhousedao packages
|
|
31
|
+
const normalizeDriveId = (driveId) => {
|
|
32
|
+
return driveId.replace(/\+/g, "-").replace(/=+$/, "");
|
|
33
|
+
};
|
|
9
34
|
const getCandidateDrives = async () => {
|
|
10
35
|
try {
|
|
11
36
|
const drives = await reactor.getDrives?.();
|
|
12
|
-
if (Array.isArray(drives) && drives.length > 0)
|
|
13
|
-
return drives;
|
|
37
|
+
if (Array.isArray(drives) && drives.length > 0) {
|
|
38
|
+
return drives.map(normalizeDriveId);
|
|
39
|
+
}
|
|
14
40
|
}
|
|
15
41
|
catch { }
|
|
16
42
|
return [];
|
|
@@ -65,6 +91,102 @@ export const getResolvers = (subgraph) => {
|
|
|
65
91
|
};
|
|
66
92
|
}
|
|
67
93
|
};
|
|
94
|
+
const loadNetworkProfile = async (networkId) => {
|
|
95
|
+
if (!networkId) {
|
|
96
|
+
return null;
|
|
97
|
+
}
|
|
98
|
+
try {
|
|
99
|
+
const networkDoc = await reactor.getDocument(networkId);
|
|
100
|
+
const state = networkDoc.state.global;
|
|
101
|
+
return {
|
|
102
|
+
name: state.name ?? null,
|
|
103
|
+
slug: state.name
|
|
104
|
+
? state.name.toLowerCase().trim().split(/\s+/).join("-")
|
|
105
|
+
: null,
|
|
106
|
+
icon: state.icon ?? null,
|
|
107
|
+
darkThemeIcon: state.darkThemeIcon ?? null,
|
|
108
|
+
logo: state.logo ?? null,
|
|
109
|
+
darkThemeLogo: state.darkThemeLogo ?? null,
|
|
110
|
+
logoBig: state.logoBig ?? null,
|
|
111
|
+
website: state.website ?? null,
|
|
112
|
+
description: state.description ?? null,
|
|
113
|
+
category: Array.isArray(state.category) ? state.category : null,
|
|
114
|
+
x: state.x ?? null,
|
|
115
|
+
github: state.github ?? null,
|
|
116
|
+
discord: state.discord ?? null,
|
|
117
|
+
youtube: state.youtube ?? null,
|
|
118
|
+
};
|
|
119
|
+
}
|
|
120
|
+
catch {
|
|
121
|
+
return null;
|
|
122
|
+
}
|
|
123
|
+
};
|
|
124
|
+
// Helper function to collect SOWs from hydrated workstreams
|
|
125
|
+
const collectSowsFromWorkstreams = (workstreams) => {
|
|
126
|
+
const sowDocs = [];
|
|
127
|
+
for (const workstream of workstreams) {
|
|
128
|
+
if (workstream.sow) {
|
|
129
|
+
sowDocs.push(workstream.sow);
|
|
130
|
+
}
|
|
131
|
+
if (workstream.initialProposal?.sow) {
|
|
132
|
+
sowDocs.push(workstream.initialProposal.sow);
|
|
133
|
+
}
|
|
134
|
+
for (const altProposal of workstream.alternativeProposals || []) {
|
|
135
|
+
if (altProposal.sow) {
|
|
136
|
+
sowDocs.push(altProposal.sow);
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
return sowDocs;
|
|
141
|
+
};
|
|
142
|
+
// Helper function to fetch builder profiles for contributors
|
|
143
|
+
const fetchBuilderProfilesForContributors = async (contributorPhids) => {
|
|
144
|
+
const builderProfileMap = new Map();
|
|
145
|
+
if (contributorPhids.size > 0) {
|
|
146
|
+
const builderProfileDocs = await Promise.all(Array.from(contributorPhids).map(async (phid) => {
|
|
147
|
+
try {
|
|
148
|
+
return await reactor.getDocument(phid);
|
|
149
|
+
}
|
|
150
|
+
catch (error) {
|
|
151
|
+
console.warn(`Failed to fetch builder profile ${phid}:`, error);
|
|
152
|
+
return null;
|
|
153
|
+
}
|
|
154
|
+
}));
|
|
155
|
+
builderProfileDocs.forEach((doc) => {
|
|
156
|
+
if (doc && doc.header.documentType === "powerhouse/builder-profile") {
|
|
157
|
+
builderProfileMap.set(doc.header.id, doc);
|
|
158
|
+
// Also collect contributor PHIDs from these builder profiles
|
|
159
|
+
const state = doc.state.global;
|
|
160
|
+
if (state?.contributors && Array.isArray(state.contributors)) {
|
|
161
|
+
state.contributors.forEach((phid) => {
|
|
162
|
+
if (phid && !builderProfileMap.has(phid)) {
|
|
163
|
+
contributorPhids.add(phid);
|
|
164
|
+
}
|
|
165
|
+
});
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
});
|
|
169
|
+
// Fetch nested contributors if any were found
|
|
170
|
+
const nestedContributorPhids = Array.from(contributorPhids).filter((phid) => !builderProfileMap.has(phid));
|
|
171
|
+
if (nestedContributorPhids.length > 0) {
|
|
172
|
+
const nestedContributorDocs = await Promise.all(nestedContributorPhids.map(async (phid) => {
|
|
173
|
+
try {
|
|
174
|
+
return await reactor.getDocument(phid);
|
|
175
|
+
}
|
|
176
|
+
catch (error) {
|
|
177
|
+
console.warn(`Failed to fetch contributor builder profile ${phid}:`, error);
|
|
178
|
+
return null;
|
|
179
|
+
}
|
|
180
|
+
}));
|
|
181
|
+
nestedContributorDocs.forEach((doc) => {
|
|
182
|
+
if (doc && doc.header.documentType === "powerhouse/builder-profile") {
|
|
183
|
+
builderProfileMap.set(doc.header.id, doc);
|
|
184
|
+
}
|
|
185
|
+
});
|
|
186
|
+
}
|
|
187
|
+
}
|
|
188
|
+
return builderProfileMap;
|
|
189
|
+
};
|
|
68
190
|
const hydrateWorkstreamRow = async (row) => {
|
|
69
191
|
try {
|
|
70
192
|
const doc = await reactor.getDocument(row.workstream_phid);
|
|
@@ -81,14 +203,16 @@ export const getResolvers = (subgraph) => {
|
|
|
81
203
|
status: p.status,
|
|
82
204
|
author: p.author,
|
|
83
205
|
}));
|
|
84
|
-
const [topSowDoc, topPaymentTermsDoc, initialSowDoc, initialPaymentTermsDoc, altSowDocs, altPaymentDocs, rfpDetails,] = await Promise.all([
|
|
85
|
-
|
|
206
|
+
const [topSowDoc, topPaymentTermsDoc, initialSowDoc, initialPaymentTermsDoc, altSowDocs, altPaymentDocs, rfpDetails, networkInfo,] = await Promise.all([
|
|
207
|
+
// Use document state as source of truth - don't fallback to DB
|
|
208
|
+
loadLinkedDocument(state.sow || null),
|
|
86
209
|
loadLinkedDocument(state.paymentTerms || null),
|
|
87
|
-
loadLinkedDocument(state.initialProposal?.sow ||
|
|
210
|
+
loadLinkedDocument(state.initialProposal?.sow || null),
|
|
88
211
|
loadLinkedDocument(state.initialProposal?.paymentTerms || null),
|
|
89
212
|
Promise.all((state.alternativeProposals || []).map((p) => loadLinkedDocument(p.sow || null))),
|
|
90
213
|
Promise.all((state.alternativeProposals || []).map((p) => loadLinkedDocument(p.paymentTerms || null))),
|
|
91
214
|
loadRfpDetails(state.rfp || null),
|
|
215
|
+
loadNetworkProfile(state.client?.id || row.network_phid || null),
|
|
92
216
|
]);
|
|
93
217
|
const client = state.client ??
|
|
94
218
|
(row.network_phid
|
|
@@ -97,8 +221,12 @@ export const getResolvers = (subgraph) => {
|
|
|
97
221
|
return {
|
|
98
222
|
code: state.code || null,
|
|
99
223
|
title: state.title || row.workstream_title || null,
|
|
224
|
+
slug: state.title
|
|
225
|
+
? state.title.toLowerCase().trim().split(/\s+/).join("-")
|
|
226
|
+
: null,
|
|
100
227
|
status: state.status || row.workstream_status || null,
|
|
101
228
|
client,
|
|
229
|
+
network: networkInfo,
|
|
102
230
|
rfp: rfpDetails,
|
|
103
231
|
initialProposal: initialProposalBase
|
|
104
232
|
? {
|
|
@@ -118,13 +246,16 @@ export const getResolvers = (subgraph) => {
|
|
|
118
246
|
};
|
|
119
247
|
}
|
|
120
248
|
catch {
|
|
249
|
+
const networkInfo = await loadNetworkProfile(row.network_phid || null);
|
|
121
250
|
return {
|
|
122
251
|
code: row.workstream_title || null,
|
|
123
252
|
title: row.workstream_title || null,
|
|
253
|
+
slug: row.workstream_slug || null,
|
|
124
254
|
status: row.workstream_status || null,
|
|
125
255
|
client: row.network_phid
|
|
126
256
|
? { id: row.network_phid, name: row.network_slug, icon: null }
|
|
127
257
|
: null,
|
|
258
|
+
network: networkInfo,
|
|
128
259
|
rfp: null,
|
|
129
260
|
initialProposal: null,
|
|
130
261
|
alternativeProposals: [],
|
|
@@ -135,12 +266,22 @@ export const getResolvers = (subgraph) => {
|
|
|
135
266
|
}
|
|
136
267
|
};
|
|
137
268
|
const applyWorkstreamFilters = (qb, filters, wantedSlug) => {
|
|
138
|
-
|
|
269
|
+
// Handle workstreamId and workstreamSlug (from WorkstreamFilter)
|
|
270
|
+
if ("workstreamId" in filters && filters.workstreamId) {
|
|
139
271
|
qb = qb.where("workstream_phid", "=", filters.workstreamId);
|
|
140
272
|
}
|
|
141
|
-
else if (filters.workstreamSlug) {
|
|
273
|
+
else if ("workstreamSlug" in filters && filters.workstreamSlug) {
|
|
142
274
|
qb = qb.where("workstream_slug", "=", filters.workstreamSlug);
|
|
143
275
|
}
|
|
276
|
+
// Handle workstreamTitle filter (from WorkstreamsFilter)
|
|
277
|
+
if ("workstreamTitle" in filters && filters.workstreamTitle) {
|
|
278
|
+
// Use case-insensitive partial match for workstream title
|
|
279
|
+
// Filter out NULL values and do case-insensitive search
|
|
280
|
+
const searchPattern = `%${filters.workstreamTitle.toLowerCase()}%`;
|
|
281
|
+
qb = qb
|
|
282
|
+
.where("workstream_title", "is not", null)
|
|
283
|
+
.where((eb) => eb(sql `LOWER(workstream_title)`, "like", searchPattern));
|
|
284
|
+
}
|
|
144
285
|
if (filters.networkId) {
|
|
145
286
|
qb = qb.where("network_phid", "=", filters.networkId);
|
|
146
287
|
}
|
|
@@ -150,6 +291,15 @@ export const getResolvers = (subgraph) => {
|
|
|
150
291
|
else if (filters.networkName && wantedSlug) {
|
|
151
292
|
qb = qb.where("network_slug", "=", wantedSlug);
|
|
152
293
|
}
|
|
294
|
+
else if ("networkNames" in filters && filters.networkNames) {
|
|
295
|
+
// Handle networkNames filter (from WorkstreamsFilter)
|
|
296
|
+
const networkSlugs = filters.networkNames
|
|
297
|
+
.filter((name) => Boolean(name))
|
|
298
|
+
.map((name) => deriveSlug(name));
|
|
299
|
+
if (networkSlugs.length > 0) {
|
|
300
|
+
qb = qb.where("network_slug", "in", networkSlugs);
|
|
301
|
+
}
|
|
302
|
+
}
|
|
153
303
|
const statuses = (filters.workstreamStatuses || []).filter((status) => Boolean(status));
|
|
154
304
|
if (statuses.length > 0) {
|
|
155
305
|
qb = qb.where("workstream_status", "in", statuses);
|
|
@@ -182,13 +332,21 @@ export const getResolvers = (subgraph) => {
|
|
|
182
332
|
};
|
|
183
333
|
return {
|
|
184
334
|
Query: {
|
|
185
|
-
processorWorkstreams: async (
|
|
335
|
+
processorWorkstreams: async () => {
|
|
186
336
|
const drives = await getCandidateDrives();
|
|
187
337
|
const allProcessorWorkstreams = await Promise.all(drives.map(async (driveId) => {
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
.
|
|
338
|
+
const namespace = WorkstreamsProcessor.getNamespace(driveId);
|
|
339
|
+
console.log(`[WorkstreamsProcessor] Resolver querying drive: ${driveId}, namespace: ${namespace}`);
|
|
340
|
+
try {
|
|
341
|
+
return await WorkstreamsProcessor.query(driveId, db)
|
|
342
|
+
.selectFrom("workstreams")
|
|
343
|
+
.selectAll()
|
|
344
|
+
.execute();
|
|
345
|
+
}
|
|
346
|
+
catch (error) {
|
|
347
|
+
console.warn(`[WorkstreamsProcessor] Failed to query namespace ${namespace}:`, error);
|
|
348
|
+
return []; // Return empty array if table doesn't exist for this drive
|
|
349
|
+
}
|
|
192
350
|
}));
|
|
193
351
|
// Flatten the array of arrays into a single array
|
|
194
352
|
const flattenedWorkstreams = allProcessorWorkstreams.flat();
|
|
@@ -211,18 +369,100 @@ export const getResolvers = (subgraph) => {
|
|
|
211
369
|
const candidateDrives = await getCandidateDrives();
|
|
212
370
|
const wantedSlug = filters.networkSlug ||
|
|
213
371
|
(filters.networkName ? deriveSlug(filters.networkName) : undefined);
|
|
214
|
-
|
|
372
|
+
const resolved = [];
|
|
373
|
+
const contributorPhids = new Set();
|
|
215
374
|
for (const driveId of candidateDrives) {
|
|
216
375
|
let qb = WorkstreamsProcessor.query(driveId, db)
|
|
217
376
|
.selectFrom("workstreams")
|
|
218
377
|
.selectAll();
|
|
219
378
|
qb = applyWorkstreamFilters(qb, filters, wantedSlug);
|
|
220
|
-
const
|
|
221
|
-
if (
|
|
379
|
+
const rows = await qb.execute();
|
|
380
|
+
if (rows.length === 0) {
|
|
222
381
|
continue;
|
|
223
|
-
|
|
382
|
+
}
|
|
383
|
+
for (const row of rows) {
|
|
384
|
+
const hydrated = await hydrateWorkstreamRow(row);
|
|
385
|
+
resolved.push(hydrated);
|
|
386
|
+
}
|
|
224
387
|
break;
|
|
225
388
|
}
|
|
389
|
+
// Collect SOWs and their contributors
|
|
390
|
+
const sowDocs = collectSowsFromWorkstreams(resolved);
|
|
391
|
+
for (const sow of sowDocs) {
|
|
392
|
+
if (!sow || typeof sow !== "object")
|
|
393
|
+
continue;
|
|
394
|
+
if (Array.isArray(sow.contributors)) {
|
|
395
|
+
sow.contributors.forEach((contributor) => {
|
|
396
|
+
const phid = extractPhid(contributor);
|
|
397
|
+
if (phid)
|
|
398
|
+
contributorPhids.add(phid);
|
|
399
|
+
});
|
|
400
|
+
}
|
|
401
|
+
// Collect deliverable owners too so `SOW_Deliverable.owner` can resolve
|
|
402
|
+
if (Array.isArray(sow.deliverables)) {
|
|
403
|
+
sow.deliverables.forEach((deliverable) => {
|
|
404
|
+
if (!deliverable || typeof deliverable !== "object")
|
|
405
|
+
return;
|
|
406
|
+
const phid = extractPhid(deliverable.owner);
|
|
407
|
+
if (phid)
|
|
408
|
+
contributorPhids.add(phid);
|
|
409
|
+
});
|
|
410
|
+
}
|
|
411
|
+
// Collect project owners too so `SOW_Project.projectOwner` can resolve
|
|
412
|
+
if (Array.isArray(sow.projects)) {
|
|
413
|
+
sow.projects.forEach((project) => {
|
|
414
|
+
if (!project || typeof project !== "object")
|
|
415
|
+
return;
|
|
416
|
+
const phid = extractPhid(project.projectOwner);
|
|
417
|
+
if (phid)
|
|
418
|
+
contributorPhids.add(phid);
|
|
419
|
+
});
|
|
420
|
+
}
|
|
421
|
+
}
|
|
422
|
+
// Fetch all builder profile documents for contributors
|
|
423
|
+
const builderProfileMap = await fetchBuilderProfilesForContributors(contributorPhids);
|
|
424
|
+
// Create helper function to get builder profile data by PHID
|
|
425
|
+
getBuilderProfileByPhid = (phid) => {
|
|
426
|
+
const doc = builderProfileMap.get(phid);
|
|
427
|
+
if (!doc)
|
|
428
|
+
return null;
|
|
429
|
+
const state = doc.state.global;
|
|
430
|
+
// Store contributor PHIDs separately - they'll be resolved by the field resolver
|
|
431
|
+
const contributorPhids = state?.contributors ?? [];
|
|
432
|
+
// Ensure all non-nullable Builder fields are properly handled
|
|
433
|
+
// name: String! - non-nullable
|
|
434
|
+
const name = String(state?.name ?? doc.header?.name ?? "");
|
|
435
|
+
// icon: String! - non-nullable
|
|
436
|
+
const icon = String(state?.icon ?? "");
|
|
437
|
+
// description: String! - non-nullable
|
|
438
|
+
const description = String(state?.description ?? state?.slug ?? "");
|
|
439
|
+
// isOperator: Boolean! - non-nullable, default to false
|
|
440
|
+
const isOperator = state?.isOperator ?? false;
|
|
441
|
+
// operationalHubMember: OpHubMember! - non-nullable
|
|
442
|
+
const operationalHubMember = state?.operationalHubMember ?? { name: null, phid: null };
|
|
443
|
+
// skills: [BuilderSkill!]! - non-nullable array (document model uses 'skils' typo)
|
|
444
|
+
const skills = Array.isArray(state?.skils) ? state.skils : Array.isArray(state?.skills) ? state.skills : [];
|
|
445
|
+
// scopes: [BuilderScope!]! - non-nullable array
|
|
446
|
+
const scopes = Array.isArray(state?.scopes) ? state.scopes : [];
|
|
447
|
+
// links: [BuilderLink!]! - non-nullable array
|
|
448
|
+
const links = Array.isArray(state?.links) ? state.links : [];
|
|
449
|
+
return {
|
|
450
|
+
id: doc.header.id,
|
|
451
|
+
code: state?.code ?? null,
|
|
452
|
+
slug: state?.slug ?? null,
|
|
453
|
+
name,
|
|
454
|
+
icon,
|
|
455
|
+
description,
|
|
456
|
+
lastModified: state?.lastModified ?? null,
|
|
457
|
+
isOperator,
|
|
458
|
+
operationalHubMember,
|
|
459
|
+
_contributorPhids: contributorPhids, // Internal field for resolver
|
|
460
|
+
status: state?.status ?? null,
|
|
461
|
+
skills,
|
|
462
|
+
scopes,
|
|
463
|
+
links,
|
|
464
|
+
};
|
|
465
|
+
};
|
|
226
466
|
return resolved;
|
|
227
467
|
},
|
|
228
468
|
workstreams: async (parent, args) => {
|
|
@@ -232,26 +472,21 @@ export const getResolvers = (subgraph) => {
|
|
|
232
472
|
const hasFilters = filters.networkId ||
|
|
233
473
|
filters.networkSlug ||
|
|
234
474
|
filters.networkName ||
|
|
475
|
+
(filters.networkNames && filters.networkNames.length > 0) ||
|
|
476
|
+
filters.workstreamTitle ||
|
|
235
477
|
filters.workstreamStatus ||
|
|
236
|
-
(filters.workstreamStatuses &&
|
|
237
|
-
filters.workstreamStatuses.length > 0);
|
|
478
|
+
(filters.workstreamStatuses && filters.workstreamStatuses.length > 0);
|
|
238
479
|
const wantedSlug = filters.networkSlug ||
|
|
239
480
|
(filters.networkName ? deriveSlug(filters.networkName) : undefined);
|
|
240
481
|
const results = [];
|
|
482
|
+
const contributorPhids = new Set();
|
|
241
483
|
for (const driveId of candidateDrives) {
|
|
242
484
|
let qb = WorkstreamsProcessor.query(driveId, db)
|
|
243
485
|
.selectFrom("workstreams")
|
|
244
486
|
.selectAll();
|
|
245
487
|
// Only apply filters if any are provided
|
|
246
488
|
if (hasFilters) {
|
|
247
|
-
|
|
248
|
-
networkId: filters.networkId,
|
|
249
|
-
networkSlug: filters.networkSlug,
|
|
250
|
-
networkName: filters.networkName,
|
|
251
|
-
workstreamStatus: filters.workstreamStatus,
|
|
252
|
-
workstreamStatuses: filters.workstreamStatuses,
|
|
253
|
-
};
|
|
254
|
-
qb = applyWorkstreamFilters(qb, filterArgs, wantedSlug);
|
|
489
|
+
qb = applyWorkstreamFilters(qb, filters, wantedSlug);
|
|
255
490
|
}
|
|
256
491
|
const rows = await qb.execute();
|
|
257
492
|
if (rows.length === 0) {
|
|
@@ -262,6 +497,83 @@ export const getResolvers = (subgraph) => {
|
|
|
262
497
|
results.push(hydrated);
|
|
263
498
|
}
|
|
264
499
|
}
|
|
500
|
+
// Collect SOWs and their contributors
|
|
501
|
+
const sowDocs = collectSowsFromWorkstreams(results);
|
|
502
|
+
for (const sow of sowDocs) {
|
|
503
|
+
if (!sow || typeof sow !== "object")
|
|
504
|
+
continue;
|
|
505
|
+
if (Array.isArray(sow.contributors)) {
|
|
506
|
+
sow.contributors.forEach((contributor) => {
|
|
507
|
+
const phid = extractPhid(contributor);
|
|
508
|
+
if (phid)
|
|
509
|
+
contributorPhids.add(phid);
|
|
510
|
+
});
|
|
511
|
+
}
|
|
512
|
+
// Collect deliverable owners too so `SOW_Deliverable.owner` can resolve
|
|
513
|
+
if (Array.isArray(sow.deliverables)) {
|
|
514
|
+
sow.deliverables.forEach((deliverable) => {
|
|
515
|
+
if (!deliverable || typeof deliverable !== "object")
|
|
516
|
+
return;
|
|
517
|
+
const phid = extractPhid(deliverable.owner);
|
|
518
|
+
if (phid)
|
|
519
|
+
contributorPhids.add(phid);
|
|
520
|
+
});
|
|
521
|
+
}
|
|
522
|
+
// Collect project owners too so `SOW_Project.projectOwner` can resolve
|
|
523
|
+
if (Array.isArray(sow.projects)) {
|
|
524
|
+
sow.projects.forEach((project) => {
|
|
525
|
+
if (!project || typeof project !== "object")
|
|
526
|
+
return;
|
|
527
|
+
const phid = extractPhid(project.projectOwner);
|
|
528
|
+
if (phid)
|
|
529
|
+
contributorPhids.add(phid);
|
|
530
|
+
});
|
|
531
|
+
}
|
|
532
|
+
}
|
|
533
|
+
// Fetch all builder profile documents for contributors
|
|
534
|
+
const builderProfileMap = await fetchBuilderProfilesForContributors(contributorPhids);
|
|
535
|
+
// Create helper function to get builder profile data by PHID
|
|
536
|
+
getBuilderProfileByPhid = (phid) => {
|
|
537
|
+
const doc = builderProfileMap.get(phid);
|
|
538
|
+
if (!doc)
|
|
539
|
+
return null;
|
|
540
|
+
const state = doc.state.global;
|
|
541
|
+
// Store contributor PHIDs separately - they'll be resolved by the field resolver
|
|
542
|
+
const contributorPhids = state?.contributors ?? [];
|
|
543
|
+
// Ensure all non-nullable Builder fields are properly handled
|
|
544
|
+
// name: String! - non-nullable
|
|
545
|
+
const name = String(state?.name ?? doc.header?.name ?? "");
|
|
546
|
+
// icon: String! - non-nullable
|
|
547
|
+
const icon = String(state?.icon ?? "");
|
|
548
|
+
// description: String! - non-nullable
|
|
549
|
+
const description = String(state?.description ?? state?.slug ?? "");
|
|
550
|
+
// isOperator: Boolean! - non-nullable, default to false
|
|
551
|
+
const isOperator = state?.isOperator ?? false;
|
|
552
|
+
// operationalHubMember: OpHubMember! - non-nullable
|
|
553
|
+
const operationalHubMember = state?.operationalHubMember ?? { name: null, phid: null };
|
|
554
|
+
// skills: [BuilderSkill!]! - non-nullable array (document model uses 'skils' typo)
|
|
555
|
+
const skills = Array.isArray(state?.skils) ? state.skils : Array.isArray(state?.skills) ? state.skills : [];
|
|
556
|
+
// scopes: [BuilderScope!]! - non-nullable array
|
|
557
|
+
const scopes = Array.isArray(state?.scopes) ? state.scopes : [];
|
|
558
|
+
// links: [BuilderLink!]! - non-nullable array
|
|
559
|
+
const links = Array.isArray(state?.links) ? state.links : [];
|
|
560
|
+
return {
|
|
561
|
+
id: doc.header.id,
|
|
562
|
+
code: state?.code ?? null,
|
|
563
|
+
slug: state?.slug ?? null,
|
|
564
|
+
name,
|
|
565
|
+
icon,
|
|
566
|
+
description,
|
|
567
|
+
lastModified: state?.lastModified ?? null,
|
|
568
|
+
isOperator,
|
|
569
|
+
operationalHubMember,
|
|
570
|
+
_contributorPhids: contributorPhids, // Internal field for resolver
|
|
571
|
+
status: state?.status ?? null,
|
|
572
|
+
skills,
|
|
573
|
+
scopes,
|
|
574
|
+
links,
|
|
575
|
+
};
|
|
576
|
+
};
|
|
265
577
|
return results;
|
|
266
578
|
},
|
|
267
579
|
rfpByWorkstream: async (parent, args) => {
|
|
@@ -300,6 +612,7 @@ export const getResolvers = (subgraph) => {
|
|
|
300
612
|
const wantedSlug = filters.networkSlug ||
|
|
301
613
|
(filters.networkName ? deriveSlug(filters.networkName) : undefined);
|
|
302
614
|
const results = [];
|
|
615
|
+
const contributorPhids = new Set();
|
|
303
616
|
for (const driveId of candidateDrives) {
|
|
304
617
|
let qb = WorkstreamsProcessor.query(driveId, db)
|
|
305
618
|
.selectFrom("workstreams")
|
|
@@ -342,10 +655,43 @@ export const getResolvers = (subgraph) => {
|
|
|
342
655
|
else if (filters.proposalRole === "AWARDED") {
|
|
343
656
|
// For AWARDED, we check if the workstream status is AWARDED
|
|
344
657
|
// and return the initial proposal's SOW (as it's typically the awarded one)
|
|
345
|
-
if (hydrated.status === "AWARDED" &&
|
|
658
|
+
if (hydrated.status === "AWARDED" &&
|
|
659
|
+
hydrated.initialProposal?.sow) {
|
|
346
660
|
sowDocs.push(hydrated.initialProposal.sow);
|
|
347
661
|
}
|
|
348
662
|
}
|
|
663
|
+
// Collect contributor PHIDs from all SOWs
|
|
664
|
+
for (const sow of sowDocs) {
|
|
665
|
+
if (!sow || typeof sow !== "object")
|
|
666
|
+
continue;
|
|
667
|
+
if (Array.isArray(sow.contributors)) {
|
|
668
|
+
sow.contributors.forEach((contributor) => {
|
|
669
|
+
const phid = extractPhid(contributor);
|
|
670
|
+
if (phid)
|
|
671
|
+
contributorPhids.add(phid);
|
|
672
|
+
});
|
|
673
|
+
}
|
|
674
|
+
// Collect deliverable owners too so `SOW_Deliverable.owner` can resolve
|
|
675
|
+
if (Array.isArray(sow.deliverables)) {
|
|
676
|
+
sow.deliverables.forEach((deliverable) => {
|
|
677
|
+
if (!deliverable || typeof deliverable !== "object")
|
|
678
|
+
return;
|
|
679
|
+
const phid = extractPhid(deliverable.owner);
|
|
680
|
+
if (phid)
|
|
681
|
+
contributorPhids.add(phid);
|
|
682
|
+
});
|
|
683
|
+
}
|
|
684
|
+
// Collect project owners too so `SOW_Project.projectOwner` can resolve
|
|
685
|
+
if (Array.isArray(sow.projects)) {
|
|
686
|
+
sow.projects.forEach((project) => {
|
|
687
|
+
if (!project || typeof project !== "object")
|
|
688
|
+
return;
|
|
689
|
+
const phid = extractPhid(project.projectOwner);
|
|
690
|
+
if (phid)
|
|
691
|
+
contributorPhids.add(phid);
|
|
692
|
+
});
|
|
693
|
+
}
|
|
694
|
+
}
|
|
349
695
|
// Filter out null/undefined SOWs and add to results
|
|
350
696
|
for (const sow of sowDocs) {
|
|
351
697
|
if (sow) {
|
|
@@ -357,13 +703,58 @@ export const getResolvers = (subgraph) => {
|
|
|
357
703
|
break;
|
|
358
704
|
}
|
|
359
705
|
}
|
|
706
|
+
// Fetch all builder profile documents for contributors
|
|
707
|
+
const builderProfileMap = await fetchBuilderProfilesForContributors(contributorPhids);
|
|
708
|
+
// Create helper function to get builder profile data by PHID
|
|
709
|
+
getBuilderProfileByPhid = (phid) => {
|
|
710
|
+
const doc = builderProfileMap.get(phid);
|
|
711
|
+
if (!doc)
|
|
712
|
+
return null;
|
|
713
|
+
const state = doc.state.global;
|
|
714
|
+
// Store contributor PHIDs separately - they'll be resolved by the field resolver
|
|
715
|
+
const contributorPhids = state?.contributors ?? [];
|
|
716
|
+
// Ensure all non-nullable Builder fields are properly handled
|
|
717
|
+
// name: String! - non-nullable
|
|
718
|
+
const name = String(state?.name ?? doc.header?.name ?? "");
|
|
719
|
+
// icon: String! - non-nullable
|
|
720
|
+
const icon = String(state?.icon ?? "");
|
|
721
|
+
// description: String! - non-nullable
|
|
722
|
+
const description = String(state?.description ?? state?.slug ?? "");
|
|
723
|
+
// isOperator: Boolean! - non-nullable, default to false
|
|
724
|
+
const isOperator = state?.isOperator ?? false;
|
|
725
|
+
// operationalHubMember: OpHubMember! - non-nullable
|
|
726
|
+
const operationalHubMember = state?.operationalHubMember ?? { name: null, phid: null };
|
|
727
|
+
// skills: [BuilderSkill!]! - non-nullable array (document model uses 'skils' typo)
|
|
728
|
+
const skills = Array.isArray(state?.skils) ? state.skils : Array.isArray(state?.skills) ? state.skills : [];
|
|
729
|
+
// scopes: [BuilderScope!]! - non-nullable array
|
|
730
|
+
const scopes = Array.isArray(state?.scopes) ? state.scopes : [];
|
|
731
|
+
// links: [BuilderLink!]! - non-nullable array
|
|
732
|
+
const links = Array.isArray(state?.links) ? state.links : [];
|
|
733
|
+
return {
|
|
734
|
+
id: doc.header.id,
|
|
735
|
+
code: state?.code ?? null,
|
|
736
|
+
slug: state?.slug ?? null,
|
|
737
|
+
name,
|
|
738
|
+
icon,
|
|
739
|
+
description,
|
|
740
|
+
lastModified: state?.lastModified ?? null,
|
|
741
|
+
isOperator,
|
|
742
|
+
operationalHubMember,
|
|
743
|
+
_contributorPhids: contributorPhids, // Internal field for resolver
|
|
744
|
+
status: state?.status ?? null,
|
|
745
|
+
skills,
|
|
746
|
+
scopes,
|
|
747
|
+
links,
|
|
748
|
+
};
|
|
749
|
+
};
|
|
360
750
|
return results;
|
|
361
751
|
},
|
|
362
752
|
},
|
|
363
753
|
SOW_Progress: {
|
|
364
754
|
__resolveType(obj) {
|
|
365
755
|
if (obj && typeof obj === "object") {
|
|
366
|
-
if (Object.prototype.hasOwnProperty.call(obj, "total") &&
|
|
756
|
+
if (Object.prototype.hasOwnProperty.call(obj, "total") &&
|
|
757
|
+
Object.prototype.hasOwnProperty.call(obj, "completed")) {
|
|
367
758
|
return "SOW_StoryPoint";
|
|
368
759
|
}
|
|
369
760
|
if (Object.prototype.hasOwnProperty.call(obj, "value")) {
|
|
@@ -374,7 +765,81 @@ export const getResolvers = (subgraph) => {
|
|
|
374
765
|
}
|
|
375
766
|
}
|
|
376
767
|
return null;
|
|
377
|
-
}
|
|
378
|
-
}
|
|
768
|
+
},
|
|
769
|
+
},
|
|
770
|
+
SOW_ScopeOfWorkState: {
|
|
771
|
+
contributors: (parent) => {
|
|
772
|
+
// Resolve contributor PHIDs to Builder objects
|
|
773
|
+
if (!parent.contributors || parent.contributors.length === 0) {
|
|
774
|
+
return [];
|
|
775
|
+
}
|
|
776
|
+
if (!getBuilderProfileByPhid) {
|
|
777
|
+
return [];
|
|
778
|
+
}
|
|
779
|
+
return parent.contributors
|
|
780
|
+
.map((contributor) => {
|
|
781
|
+
// Handle both string PHIDs and objects with id property
|
|
782
|
+
const phid = typeof contributor === "string" ? contributor : contributor?.id;
|
|
783
|
+
if (!phid || typeof phid !== "string") {
|
|
784
|
+
return null;
|
|
785
|
+
}
|
|
786
|
+
return getBuilderProfileByPhid(phid);
|
|
787
|
+
})
|
|
788
|
+
.filter((builder) => builder !== null);
|
|
789
|
+
},
|
|
790
|
+
},
|
|
791
|
+
SOW_Deliverable: {
|
|
792
|
+
owner: (parent) => {
|
|
793
|
+
// Handle null, undefined, or empty string cases
|
|
794
|
+
if (parent?.owner === null || parent?.owner === undefined) {
|
|
795
|
+
return null;
|
|
796
|
+
}
|
|
797
|
+
// Check if it's an empty string
|
|
798
|
+
if (typeof parent.owner === "string" && parent.owner.trim() === "") {
|
|
799
|
+
return null;
|
|
800
|
+
}
|
|
801
|
+
if (!getBuilderProfileByPhid)
|
|
802
|
+
return null;
|
|
803
|
+
const phid = extractPhid(parent.owner);
|
|
804
|
+
if (!phid)
|
|
805
|
+
return null;
|
|
806
|
+
return getBuilderProfileByPhid(phid);
|
|
807
|
+
},
|
|
808
|
+
},
|
|
809
|
+
SOW_Project: {
|
|
810
|
+
projectOwner: (parent) => {
|
|
811
|
+
// Handle null, undefined, or empty string cases
|
|
812
|
+
if (parent?.projectOwner === null ||
|
|
813
|
+
parent?.projectOwner === undefined) {
|
|
814
|
+
return null;
|
|
815
|
+
}
|
|
816
|
+
// Check if it's an empty string
|
|
817
|
+
if (typeof parent.projectOwner === "string" &&
|
|
818
|
+
parent.projectOwner.trim() === "") {
|
|
819
|
+
return null;
|
|
820
|
+
}
|
|
821
|
+
if (!getBuilderProfileByPhid)
|
|
822
|
+
return null;
|
|
823
|
+
const phid = extractPhid(parent.projectOwner);
|
|
824
|
+
if (!phid)
|
|
825
|
+
return null;
|
|
826
|
+
return getBuilderProfileByPhid(phid);
|
|
827
|
+
},
|
|
828
|
+
},
|
|
829
|
+
Builder: {
|
|
830
|
+
contributors: (parent) => {
|
|
831
|
+
// Resolve contributor PHIDs to Builder objects
|
|
832
|
+
if (!parent._contributorPhids ||
|
|
833
|
+
parent._contributorPhids.length === 0) {
|
|
834
|
+
return [];
|
|
835
|
+
}
|
|
836
|
+
if (!getBuilderProfileByPhid) {
|
|
837
|
+
return [];
|
|
838
|
+
}
|
|
839
|
+
return parent._contributorPhids
|
|
840
|
+
.map((phid) => getBuilderProfileByPhid(phid))
|
|
841
|
+
.filter((builder) => builder !== null);
|
|
842
|
+
},
|
|
843
|
+
},
|
|
379
844
|
};
|
|
380
845
|
};
|