@powerhousedao/network-admin 0.0.64 → 1.0.0-dev.2
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/document-models.d.ts.map +1 -1
- package/dist/document-models/document-models.js +0 -2
- package/dist/document-models/index.d.ts +0 -1
- package/dist/document-models/index.d.ts.map +1 -1
- package/dist/document-models/index.js +0 -1
- 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/ph-factories.d.ts.map +1 -1
- package/dist/document-models/network-profile/gen/ph-factories.js +0 -2
- package/dist/document-models/network-profile/gen/reducer.d.ts +0 -1
- package/dist/document-models/network-profile/gen/reducer.d.ts.map +1 -1
- package/dist/document-models/network-profile/gen/schema/types.d.ts +2 -6
- 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 +2 -8
- package/dist/document-models/network-profile/gen/schema/zod.d.ts.map +1 -1
- package/dist/document-models/network-profile/gen/schema/zod.js +2 -6
- package/dist/document-models/network-profile/gen/utils.d.ts.map +1 -1
- package/dist/document-models/network-profile/gen/utils.js +1 -3
- 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/module.d.ts +1 -1
- package/dist/document-models/network-profile/module.d.ts.map +1 -1
- package/dist/document-models/network-profile/module.js +1 -1
- package/dist/document-models/network-profile/src/reducers/network-profile-management.d.ts +1 -0
- 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 +18 -27
- package/dist/document-models/network-profile/src/tests/document-model.test.d.ts +0 -4
- 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 +6 -92
- package/dist/document-models/network-profile/src/tests/network-profile-management.test.js +115 -69
- package/dist/document-models/payment-terms/actions.d.ts +2 -1
- package/dist/document-models/payment-terms/actions.d.ts.map +1 -1
- package/dist/document-models/payment-terms/gen/clauses/error.d.ts +40 -1
- package/dist/document-models/payment-terms/gen/clauses/error.d.ts.map +1 -1
- package/dist/document-models/payment-terms/gen/clauses/error.js +32 -1
- package/dist/document-models/payment-terms/gen/document-model.d.ts.map +1 -1
- package/dist/document-models/payment-terms/gen/document-model.js +180 -89
- package/dist/document-models/payment-terms/gen/milestones/error.d.ts +26 -1
- package/dist/document-models/payment-terms/gen/milestones/error.d.ts.map +1 -1
- package/dist/document-models/payment-terms/gen/milestones/error.js +18 -1
- package/dist/document-models/payment-terms/gen/ph-factories.d.ts.map +1 -1
- package/dist/document-models/payment-terms/gen/ph-factories.js +2 -1
- package/dist/document-models/payment-terms/gen/reducer.d.ts +0 -1
- package/dist/document-models/payment-terms/gen/reducer.d.ts.map +1 -1
- package/dist/document-models/payment-terms/gen/reducer.js +9 -4
- package/dist/document-models/payment-terms/gen/schema/types.d.ts +29 -14
- 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 +12 -36
- package/dist/document-models/payment-terms/gen/schema/zod.d.ts.map +1 -1
- package/dist/document-models/payment-terms/gen/schema/zod.js +55 -29
- package/dist/document-models/payment-terms/gen/terms/actions.d.ts +9 -5
- 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 +4 -3
- package/dist/document-models/payment-terms/gen/terms/creators.d.ts.map +1 -1
- package/dist/document-models/payment-terms/gen/terms/creators.js +3 -2
- package/dist/document-models/payment-terms/gen/terms/operations.d.ts +3 -2
- 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 +3 -2
- 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/module.d.ts +1 -1
- package/dist/document-models/payment-terms/module.d.ts.map +1 -1
- package/dist/document-models/payment-terms/module.js +1 -1
- package/dist/document-models/payment-terms/src/reducers/clauses.d.ts +1 -0
- package/dist/document-models/payment-terms/src/reducers/clauses.d.ts.map +1 -1
- package/dist/document-models/payment-terms/src/reducers/clauses.js +15 -13
- package/dist/document-models/payment-terms/src/reducers/milestones.d.ts +1 -0
- package/dist/document-models/payment-terms/src/reducers/milestones.d.ts.map +1 -1
- package/dist/document-models/payment-terms/src/reducers/milestones.js +12 -10
- package/dist/document-models/payment-terms/src/reducers/terms.d.ts +1 -0
- package/dist/document-models/payment-terms/src/reducers/terms.d.ts.map +1 -1
- package/dist/document-models/payment-terms/src/reducers/terms.js +24 -14
- package/dist/document-models/payment-terms/src/tests/clauses.test.js +21 -26
- package/dist/document-models/payment-terms/src/tests/document-model.test.d.ts +0 -4
- 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 +6 -92
- package/dist/document-models/payment-terms/src/tests/milestones.test.js +19 -22
- package/dist/document-models/payment-terms/src/tests/terms.test.js +29 -24
- package/dist/document-models/payment-terms/tests/terms.test.js +15 -5
- package/dist/document-models/request-for-proposals/gen/document-model.js +4 -4
- 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 +4 -6
- package/dist/document-models/request-for-proposals/gen/reducer.d.ts +0 -1
- 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 +9 -64
- 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 +5 -7
- 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/module.d.ts +1 -1
- package/dist/document-models/request-for-proposals/module.d.ts.map +1 -1
- package/dist/document-models/request-for-proposals/module.js +1 -1
- package/dist/document-models/request-for-proposals/src/reducers/contex-document.d.ts +1 -0
- 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 +4 -3
- package/dist/document-models/request-for-proposals/src/reducers/proposals.d.ts +1 -0
- 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 +5 -4
- package/dist/document-models/request-for-proposals/src/reducers/rfp-state.d.ts +1 -0
- 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 +3 -2
- package/dist/document-models/request-for-proposals/src/tests/contex-document.test.d.ts +1 -2
- 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 +181 -24
- package/dist/document-models/request-for-proposals/src/tests/document-model.test.d.ts +0 -4
- 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 +6 -92
- package/dist/document-models/request-for-proposals/src/tests/proposals.test.d.ts +1 -2
- 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 +327 -33
- package/dist/document-models/request-for-proposals/src/tests/rfp-state.test.d.ts +1 -2
- 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 +240 -15
- 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/reducer.d.ts +0 -1
- 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 +5 -35
- 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/module.d.ts +1 -1
- package/dist/document-models/workstream/module.d.ts.map +1 -1
- package/dist/document-models/workstream/module.js +1 -1
- package/dist/document-models/workstream/src/reducers/proposals.d.ts +1 -0
- package/dist/document-models/workstream/src/reducers/proposals.d.ts.map +1 -1
- package/dist/document-models/workstream/src/reducers/proposals.js +6 -83
- package/dist/document-models/workstream/src/reducers/workstream.d.ts +1 -0
- package/dist/document-models/workstream/src/reducers/workstream.d.ts.map +1 -1
- package/dist/document-models/workstream/src/reducers/workstream.js +7 -6
- package/dist/document-models/workstream/src/tests/document-model.test.d.ts +0 -4
- 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 +3 -89
- package/dist/document-models/workstream/src/tests/proposals-reducers.test.d.ts +5 -0
- package/dist/document-models/workstream/src/tests/proposals-reducers.test.d.ts.map +1 -0
- package/dist/document-models/workstream/src/tests/proposals-reducers.test.js +318 -0
- package/dist/document-models/workstream/src/tests/proposals.test.js +25 -26
- package/dist/document-models/workstream/src/tests/workstream-reducers.test.d.ts +5 -0
- package/dist/document-models/workstream/src/tests/workstream-reducers.test.d.ts.map +1 -0
- package/dist/document-models/workstream/src/tests/workstream-reducers.test.js +210 -0
- package/dist/document-models/workstream/src/tests/workstream.test.js +29 -34
- package/dist/editors/hooks/useNetworkProfileDocument.d.ts +4 -0
- package/dist/editors/hooks/useNetworkProfileDocument.d.ts.map +1 -0
- package/dist/editors/hooks/useNetworkProfileDocument.js +8 -0
- package/dist/editors/hooks/usePaymentTermsDocument.d.ts +4 -0
- package/dist/editors/hooks/usePaymentTermsDocument.d.ts.map +1 -0
- package/dist/editors/hooks/usePaymentTermsDocument.js +8 -0
- package/dist/editors/hooks/useRequestForProposalsDocument.d.ts +4 -0
- package/dist/editors/hooks/useRequestForProposalsDocument.d.ts.map +1 -0
- package/dist/editors/hooks/useRequestForProposalsDocument.js +8 -0
- package/dist/editors/hooks/useWorkstreamDocument.d.ts +4 -0
- package/dist/editors/hooks/useWorkstreamDocument.d.ts.map +1 -0
- package/dist/editors/hooks/useWorkstreamDocument.js +8 -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 +12 -8
- 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 +230 -53
- package/dist/editors/network-admin/components/FolderTree.d.ts +1 -9
- package/dist/editors/network-admin/components/FolderTree.d.ts.map +1 -1
- package/dist/editors/network-admin/components/FolderTree.js +55 -216
- 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 +0 -1
- 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 +1 -2
- package/dist/editors/network-admin/editor.d.ts.map +1 -1
- package/dist/editors/network-admin/editor.js +1 -4
- package/dist/editors/network-admin/index.d.ts +3 -0
- package/dist/editors/network-admin/index.d.ts.map +1 -0
- package/dist/editors/network-admin/index.js +10 -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 +13 -45
- package/dist/editors/network-profile/index.d.ts +4 -0
- package/dist/editors/network-profile/index.d.ts.map +1 -0
- package/dist/editors/network-profile/index.js +10 -0
- package/dist/editors/payment-terms/basic-terms-tab.d.ts +10 -0
- package/dist/editors/payment-terms/basic-terms-tab.d.ts.map +1 -0
- package/dist/editors/payment-terms/basic-terms-tab.js +89 -0
- package/dist/editors/payment-terms/clauses-tab.d.ts +12 -0
- package/dist/editors/payment-terms/clauses-tab.d.ts.map +1 -0
- package/dist/editors/payment-terms/clauses-tab.js +213 -0
- package/dist/editors/payment-terms/cost-materials-tab.d.ts +10 -0
- package/dist/editors/payment-terms/cost-materials-tab.d.ts.map +1 -0
- package/dist/editors/payment-terms/cost-materials-tab.js +63 -0
- package/dist/editors/payment-terms/editor.d.ts +2 -0
- package/dist/editors/payment-terms/editor.d.ts.map +1 -1
- package/dist/editors/payment-terms/editor.js +55 -39
- package/dist/editors/payment-terms/escrow-tab.d.ts +10 -0
- package/dist/editors/payment-terms/escrow-tab.d.ts.map +1 -0
- package/dist/editors/payment-terms/escrow-tab.js +57 -0
- package/dist/editors/payment-terms/evaluation-tab.d.ts +10 -0
- package/dist/editors/payment-terms/evaluation-tab.d.ts.map +1 -0
- package/dist/editors/payment-terms/evaluation-tab.js +63 -0
- package/dist/editors/payment-terms/index.d.ts +4 -0
- package/dist/editors/payment-terms/index.d.ts.map +1 -0
- package/dist/editors/payment-terms/index.js +10 -0
- package/dist/editors/payment-terms/milestones-tab.d.ts +10 -0
- package/dist/editors/payment-terms/milestones-tab.d.ts.map +1 -0
- package/dist/editors/payment-terms/milestones-tab.js +205 -0
- package/dist/editors/payment-terms/retainer-tab.d.ts +10 -0
- package/dist/editors/payment-terms/retainer-tab.d.ts.map +1 -0
- package/dist/editors/payment-terms/retainer-tab.js +91 -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/index.d.ts +4 -0
- package/dist/editors/request-for-proposals/index.d.ts.map +1 -0
- package/dist/editors/request-for-proposals/index.js +10 -0
- 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/workstream/editor.d.ts.map +1 -1
- package/dist/editors/workstream/editor.js +165 -290
- package/dist/editors/workstream/index.d.ts +4 -0
- package/dist/editors/workstream/index.d.ts.map +1 -0
- package/dist/editors/workstream/index.js +10 -0
- package/dist/editors/workstream/project-management-import.d.ts +3 -0
- package/dist/editors/workstream/project-management-import.d.ts.map +1 -0
- package/dist/editors/workstream/project-management-import.js +5 -0
- package/dist/index.d.ts +2 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4 -2
- package/dist/powerhouse.manifest.json +6 -27
- 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 +1 -4
- package/dist/processors/workstreams/index.d.ts +2 -4
- package/dist/processors/workstreams/index.d.ts.map +1 -1
- package/dist/processors/workstreams/index.js +43 -102
- package/dist/processors/workstreams/migrations.d.ts.map +1 -1
- package/dist/processors/workstreams/migrations.js +15 -12
- package/dist/scripts/sow-mirror/mirror_sow_state.js +114 -119
- package/dist/style.css +6885 -6085
- package/dist/subgraphs/index.d.ts +5 -1
- package/dist/subgraphs/index.d.ts.map +1 -1
- package/dist/subgraphs/index.js +5 -1
- package/dist/subgraphs/network-profile/index.d.ts +11 -0
- package/dist/subgraphs/network-profile/index.d.ts.map +1 -0
- package/dist/subgraphs/network-profile/index.js +11 -0
- package/dist/subgraphs/network-profile/resolvers.d.ts.map +1 -0
- package/dist/subgraphs/network-profile/resolvers.js +205 -0
- package/dist/subgraphs/network-profile/schema.d.ts.map +1 -0
- package/dist/subgraphs/network-profile/schema.js +139 -0
- 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 +8 -138
- package/dist/subgraphs/networks/schema.d.ts.map +1 -1
- package/dist/subgraphs/networks/schema.js +1 -66
- package/dist/subgraphs/{builders-addon → payment-terms}/index.d.ts +1 -1
- package/dist/subgraphs/payment-terms/index.d.ts.map +1 -0
- package/dist/subgraphs/{builders-addon → payment-terms}/index.js +2 -2
- package/dist/subgraphs/payment-terms/resolvers.d.ts +3 -0
- package/dist/subgraphs/payment-terms/resolvers.d.ts.map +1 -0
- package/dist/subgraphs/payment-terms/resolvers.js +277 -0
- package/dist/subgraphs/payment-terms/schema.d.ts +3 -0
- package/dist/subgraphs/payment-terms/schema.d.ts.map +1 -0
- package/dist/subgraphs/payment-terms/schema.js +324 -0
- package/dist/subgraphs/request-for-proposals/index.d.ts +11 -0
- package/dist/subgraphs/request-for-proposals/index.d.ts.map +1 -0
- package/dist/subgraphs/request-for-proposals/index.js +11 -0
- package/dist/subgraphs/request-for-proposals/resolvers.d.ts +3 -0
- package/dist/subgraphs/request-for-proposals/resolvers.d.ts.map +1 -0
- package/dist/subgraphs/request-for-proposals/resolvers.js +145 -0
- package/dist/subgraphs/request-for-proposals/schema.d.ts +3 -0
- package/dist/subgraphs/request-for-proposals/schema.d.ts.map +1 -0
- package/dist/subgraphs/request-for-proposals/schema.js +232 -0
- package/dist/subgraphs/workstream/index.d.ts +11 -0
- package/dist/subgraphs/workstream/index.d.ts.map +1 -0
- package/dist/subgraphs/workstream/index.js +11 -0
- package/dist/subgraphs/workstream/resolvers.d.ts +3 -0
- package/dist/subgraphs/workstream/resolvers.d.ts.map +1 -0
- package/dist/subgraphs/workstream/resolvers.js +181 -0
- package/dist/subgraphs/workstream/schema.d.ts +3 -0
- package/dist/subgraphs/workstream/schema.d.ts.map +1 -0
- package/dist/subgraphs/workstream/schema.js +206 -0
- package/dist/subgraphs/workstreams/index.d.ts +1 -4
- package/dist/subgraphs/workstreams/index.d.ts.map +1 -1
- package/dist/subgraphs/workstreams/index.js +0 -6
- package/dist/subgraphs/workstreams/resolvers.d.ts.map +1 -1
- package/dist/subgraphs/workstreams/resolvers.js +30 -495
- package/dist/subgraphs/workstreams/schema.d.ts.map +1 -1
- package/dist/subgraphs/workstreams/schema.js +35 -228
- package/dist/vite.config.d.ts.map +1 -1
- package/dist/vite.config.js +1 -6
- package/dist/vitest.config.d.ts +3 -0
- package/dist/vitest.config.d.ts.map +1 -0
- package/dist/vitest.config.js +8 -0
- package/package.json +90 -56
- package/dist/document-models/builders/actions.d.ts +0 -14
- package/dist/document-models/builders/actions.d.ts.map +0 -1
- package/dist/document-models/builders/actions.js +0 -4
- package/dist/document-models/builders/gen/actions.d.ts +0 -4
- package/dist/document-models/builders/gen/actions.d.ts.map +0 -1
- package/dist/document-models/builders/gen/actions.js +0 -1
- package/dist/document-models/builders/gen/builders/actions.d.ts +0 -12
- package/dist/document-models/builders/gen/builders/actions.d.ts.map +0 -1
- package/dist/document-models/builders/gen/builders/actions.js +0 -1
- package/dist/document-models/builders/gen/builders/creators.d.ts +0 -5
- package/dist/document-models/builders/gen/builders/creators.d.ts.map +0 -1
- package/dist/document-models/builders/gen/builders/creators.js +0 -4
- package/dist/document-models/builders/gen/builders/error.d.ts +0 -2
- package/dist/document-models/builders/gen/builders/error.d.ts.map +0 -1
- package/dist/document-models/builders/gen/builders/error.js +0 -1
- package/dist/document-models/builders/gen/builders/operations.d.ts +0 -8
- package/dist/document-models/builders/gen/builders/operations.d.ts.map +0 -1
- package/dist/document-models/builders/gen/builders/operations.js +0 -1
- package/dist/document-models/builders/gen/creators.d.ts +0 -3
- package/dist/document-models/builders/gen/creators.d.ts.map +0 -1
- package/dist/document-models/builders/gen/creators.js +0 -2
- package/dist/document-models/builders/gen/document-model.d.ts +0 -3
- package/dist/document-models/builders/gen/document-model.d.ts.map +0 -1
- package/dist/document-models/builders/gen/document-model.js +0 -59
- package/dist/document-models/builders/gen/document-schema.d.ts +0 -44
- package/dist/document-models/builders/gen/document-schema.d.ts.map +0 -1
- package/dist/document-models/builders/gen/document-schema.js +0 -33
- package/dist/document-models/builders/gen/document-type.d.ts +0 -2
- package/dist/document-models/builders/gen/document-type.d.ts.map +0 -1
- package/dist/document-models/builders/gen/document-type.js +0 -1
- package/dist/document-models/builders/gen/index.d.ts +0 -12
- package/dist/document-models/builders/gen/index.d.ts.map +0 -1
- package/dist/document-models/builders/gen/index.js +0 -11
- package/dist/document-models/builders/gen/ph-factories.d.ts +0 -23
- package/dist/document-models/builders/gen/ph-factories.d.ts.map +0 -1
- package/dist/document-models/builders/gen/ph-factories.js +0 -47
- package/dist/document-models/builders/gen/reducer.d.ts +0 -3
- package/dist/document-models/builders/gen/reducer.d.ts.map +0 -1
- package/dist/document-models/builders/gen/reducer.js +0 -23
- package/dist/document-models/builders/gen/schema/index.d.ts +0 -3
- package/dist/document-models/builders/gen/schema/index.d.ts.map +0 -1
- package/dist/document-models/builders/gen/schema/index.js +0 -2
- package/dist/document-models/builders/gen/schema/types.d.ts +0 -158
- package/dist/document-models/builders/gen/schema/types.d.ts.map +0 -1
- package/dist/document-models/builders/gen/schema/types.js +0 -1
- package/dist/document-models/builders/gen/schema/zod.d.ts +0 -13
- package/dist/document-models/builders/gen/schema/zod.d.ts.map +0 -1
- package/dist/document-models/builders/gen/schema/zod.js +0 -21
- package/dist/document-models/builders/gen/types.d.ts +0 -12
- package/dist/document-models/builders/gen/types.d.ts.map +0 -1
- package/dist/document-models/builders/gen/types.js +0 -1
- package/dist/document-models/builders/gen/utils.d.ts +0 -15
- package/dist/document-models/builders/gen/utils.d.ts.map +0 -1
- package/dist/document-models/builders/gen/utils.js +0 -51
- package/dist/document-models/builders/hooks.d.ts +0 -14
- package/dist/document-models/builders/hooks.d.ts.map +0 -1
- package/dist/document-models/builders/hooks.js +0 -25
- package/dist/document-models/builders/index.d.ts +0 -6
- package/dist/document-models/builders/index.d.ts.map +0 -1
- package/dist/document-models/builders/index.js +0 -5
- package/dist/document-models/builders/module.d.ts +0 -5
- package/dist/document-models/builders/module.d.ts.map +0 -1
- package/dist/document-models/builders/module.js +0 -11
- package/dist/document-models/builders/src/index.d.ts +0 -2
- package/dist/document-models/builders/src/index.d.ts.map +0 -1
- package/dist/document-models/builders/src/index.js +0 -1
- package/dist/document-models/builders/src/reducers/builders.d.ts +0 -3
- package/dist/document-models/builders/src/reducers/builders.d.ts.map +0 -1
- package/dist/document-models/builders/src/reducers/builders.js +0 -8
- package/dist/document-models/builders/src/tests/builders.test.d.ts +0 -6
- package/dist/document-models/builders/src/tests/builders.test.d.ts.map +0 -1
- package/dist/document-models/builders/src/tests/builders.test.js +0 -29
- package/dist/document-models/builders/src/tests/document-model.test.d.ts +0 -10
- package/dist/document-models/builders/src/tests/document-model.test.d.ts.map +0 -1
- package/dist/document-models/builders/src/tests/document-model.test.js +0 -104
- package/dist/document-models/builders/src/utils.d.ts +0 -2
- package/dist/document-models/builders/src/utils.d.ts.map +0 -1
- package/dist/document-models/builders/src/utils.js +0 -1
- package/dist/document-models/builders/tests/builders.test.d.ts +0 -2
- package/dist/document-models/builders/tests/builders.test.d.ts.map +0 -1
- package/dist/document-models/builders/tests/builders.test.js +0 -25
- package/dist/document-models/builders/tests/document-model.test.d.ts +0 -10
- package/dist/document-models/builders/tests/document-model.test.d.ts.map +0 -1
- package/dist/document-models/builders/tests/document-model.test.js +0 -104
- package/dist/document-models/builders/utils.d.ts +0 -14
- package/dist/document-models/builders/utils.d.ts.map +0 -1
- package/dist/document-models/builders/utils.js +0 -7
- package/dist/document-models/network-profile/gen/document-schema.d.ts +0 -80
- package/dist/document-models/network-profile/gen/document-schema.d.ts.map +0 -1
- package/dist/document-models/payment-terms/gen/document-schema.d.ts +0 -95
- package/dist/document-models/payment-terms/gen/document-schema.d.ts.map +0 -1
- package/dist/document-models/request-for-proposals/gen/document-schema.d.ts +0 -83
- package/dist/document-models/request-for-proposals/gen/document-schema.d.ts.map +0 -1
- package/dist/document-models/workstream/gen/document-schema.d.ts +0 -71
- package/dist/document-models/workstream/gen/document-schema.d.ts.map +0 -1
- package/dist/editors/builders/editor.d.ts +0 -3
- package/dist/editors/builders/editor.d.ts.map +0 -1
- package/dist/editors/builders/editor.js +0 -285
- package/dist/editors/builders/hooks/useRemoteBuilderProfiles.d.ts +0 -20
- package/dist/editors/builders/hooks/useRemoteBuilderProfiles.d.ts.map +0 -1
- package/dist/editors/builders/hooks/useRemoteBuilderProfiles.js +0 -57
- package/dist/editors/builders/module.d.ts +0 -4
- package/dist/editors/builders/module.d.ts.map +0 -1
- package/dist/editors/builders/module.js +0 -10
- package/dist/editors/builders/utils/graphql-client.d.ts +0 -41
- package/dist/editors/builders/utils/graphql-client.d.ts.map +0 -1
- package/dist/editors/builders/utils/graphql-client.js +0 -189
- package/dist/editors/editors.d.ts +0 -3
- package/dist/editors/editors.d.ts.map +0 -1
- package/dist/editors/editors.js +0 -14
- package/dist/editors/network-admin/components/DriveContents.d.ts +0 -3
- package/dist/editors/network-admin/components/DriveContents.d.ts.map +0 -1
- package/dist/editors/network-admin/components/DriveContents.js +0 -10
- package/dist/editors/network-admin/components/EmptyState.d.ts +0 -3
- package/dist/editors/network-admin/components/EmptyState.d.ts.map +0 -1
- package/dist/editors/network-admin/components/EmptyState.js +0 -10
- package/dist/editors/network-admin/components/Files.d.ts +0 -3
- package/dist/editors/network-admin/components/Files.d.ts.map +0 -1
- package/dist/editors/network-admin/components/Files.js +0 -12
- package/dist/editors/network-admin/components/Folders.d.ts +0 -3
- package/dist/editors/network-admin/components/Folders.d.ts.map +0 -1
- package/dist/editors/network-admin/components/Folders.js +0 -12
- package/dist/editors/network-admin/components/NavigationBreadcrumbs.d.ts +0 -3
- package/dist/editors/network-admin/components/NavigationBreadcrumbs.d.ts.map +0 -1
- package/dist/editors/network-admin/components/NavigationBreadcrumbs.js +0 -6
- package/dist/editors/network-admin/module.d.ts +0 -4
- package/dist/editors/network-admin/module.d.ts.map +0 -1
- package/dist/editors/network-admin/module.js +0 -10
- package/dist/editors/network-profile/components/EditName.d.ts +0 -3
- package/dist/editors/network-profile/components/EditName.d.ts.map +0 -1
- package/dist/editors/network-profile/components/EditName.js +0 -31
- package/dist/editors/network-profile/module.d.ts +0 -4
- package/dist/editors/network-profile/module.d.ts.map +0 -1
- package/dist/editors/network-profile/module.js +0 -10
- package/dist/editors/payment-terms/components/clauses-section.d.ts +0 -12
- package/dist/editors/payment-terms/components/clauses-section.d.ts.map +0 -1
- package/dist/editors/payment-terms/components/clauses-section.js +0 -269
- package/dist/editors/payment-terms/components/escrow-section.d.ts +0 -13
- package/dist/editors/payment-terms/components/escrow-section.d.ts.map +0 -1
- package/dist/editors/payment-terms/components/escrow-section.js +0 -72
- package/dist/editors/payment-terms/components/evaluation-section.d.ts +0 -13
- package/dist/editors/payment-terms/components/evaluation-section.d.ts.map +0 -1
- package/dist/editors/payment-terms/components/evaluation-section.js +0 -94
- package/dist/editors/payment-terms/components/header-section.d.ts +0 -16
- package/dist/editors/payment-terms/components/header-section.d.ts.map +0 -1
- package/dist/editors/payment-terms/components/header-section.js +0 -67
- package/dist/editors/payment-terms/components/milestones-section.d.ts +0 -11
- package/dist/editors/payment-terms/components/milestones-section.d.ts.map +0 -1
- package/dist/editors/payment-terms/components/milestones-section.js +0 -236
- package/dist/editors/payment-terms/components/parties-section.d.ts +0 -11
- package/dist/editors/payment-terms/components/parties-section.d.ts.map +0 -1
- package/dist/editors/payment-terms/components/parties-section.js +0 -36
- package/dist/editors/payment-terms/components/payment-config-section.d.ts +0 -11
- package/dist/editors/payment-terms/components/payment-config-section.d.ts.map +0 -1
- package/dist/editors/payment-terms/components/payment-config-section.js +0 -68
- package/dist/editors/payment-terms/components/time-materials-section.d.ts +0 -11
- package/dist/editors/payment-terms/components/time-materials-section.d.ts.map +0 -1
- package/dist/editors/payment-terms/components/time-materials-section.js +0 -68
- package/dist/editors/payment-terms/module.d.ts +0 -4
- package/dist/editors/payment-terms/module.d.ts.map +0 -1
- package/dist/editors/payment-terms/module.js +0 -10
- package/dist/editors/request-for-proposals/components/EditName.d.ts +0 -3
- package/dist/editors/request-for-proposals/components/EditName.d.ts.map +0 -1
- package/dist/editors/request-for-proposals/components/EditName.js +0 -31
- package/dist/editors/request-for-proposals/module.d.ts +0 -4
- package/dist/editors/request-for-proposals/module.d.ts.map +0 -1
- package/dist/editors/request-for-proposals/module.js +0 -10
- package/dist/editors/workstream/module.d.ts +0 -4
- package/dist/editors/workstream/module.d.ts.map +0 -1
- package/dist/editors/workstream/module.js +0 -10
- package/dist/subgraphs/builders-addon/index.d.ts.map +0 -1
- package/dist/subgraphs/builders-addon/resolvers.d.ts.map +0 -1
- package/dist/subgraphs/builders-addon/resolvers.js +0 -376
- package/dist/subgraphs/builders-addon/schema.d.ts.map +0 -1
- package/dist/subgraphs/builders-addon/schema.js +0 -209
- /package/dist/subgraphs/{builders-addon → network-profile}/resolvers.d.ts +0 -0
- /package/dist/subgraphs/{builders-addon → network-profile}/schema.d.ts +0 -0
|
@@ -4,207 +4,298 @@ export const documentModel = {
|
|
|
4
4
|
website: "https://www.powerhouse.inc/",
|
|
5
5
|
},
|
|
6
6
|
description: "Document model for managing payment terms, milestones, and contract clauses",
|
|
7
|
-
extension: "",
|
|
7
|
+
extension: "pterms",
|
|
8
8
|
id: "payment-terms",
|
|
9
|
-
name: "
|
|
9
|
+
name: "Payment Terms",
|
|
10
10
|
specifications: [
|
|
11
11
|
{
|
|
12
12
|
changeLog: [],
|
|
13
13
|
modules: [
|
|
14
14
|
{
|
|
15
|
-
description: "",
|
|
16
|
-
id: "
|
|
15
|
+
description: "Core payment terms operations",
|
|
16
|
+
id: "terms-module",
|
|
17
17
|
name: "terms",
|
|
18
18
|
operations: [
|
|
19
19
|
{
|
|
20
|
-
description: "",
|
|
20
|
+
description: "Set the basic payment terms information",
|
|
21
21
|
errors: [],
|
|
22
22
|
examples: [],
|
|
23
|
-
id: "
|
|
23
|
+
id: "set-basic-terms-op",
|
|
24
24
|
name: "SET_BASIC_TERMS",
|
|
25
|
-
reducer: "",
|
|
25
|
+
reducer: "state.proposer = action.input.proposer;\nstate.payer = action.input.payer;\nstate.currency = action.input.currency;\nstate.paymentModel = action.input.paymentModel;\nstate.totalAmount = action.input.totalAmount || null;",
|
|
26
26
|
schema: "input SetBasicTermsInput {\n proposer: String!\n payer: String!\n currency: PaymentCurrency!\n paymentModel: PaymentModel!\n totalAmount: Amount\n}",
|
|
27
27
|
scope: "global",
|
|
28
|
-
template: "",
|
|
28
|
+
template: "Set the basic payment terms information",
|
|
29
29
|
},
|
|
30
30
|
{
|
|
31
|
-
description: "",
|
|
31
|
+
description: "Update the payment terms status",
|
|
32
32
|
errors: [],
|
|
33
33
|
examples: [],
|
|
34
|
-
id: "
|
|
34
|
+
id: "update-status-op",
|
|
35
35
|
name: "UPDATE_STATUS",
|
|
36
|
-
reducer: "",
|
|
36
|
+
reducer: "state.status = action.input.status;",
|
|
37
37
|
schema: "input UpdateStatusInput {\n status: PaymentTermsStatus!\n}",
|
|
38
38
|
scope: "global",
|
|
39
|
-
template: "",
|
|
39
|
+
template: "Update the payment terms status",
|
|
40
40
|
},
|
|
41
41
|
{
|
|
42
|
-
description: "",
|
|
42
|
+
description: "Configure cost and materials payment terms",
|
|
43
43
|
errors: [],
|
|
44
44
|
examples: [],
|
|
45
|
-
id: "
|
|
46
|
-
name: "
|
|
47
|
-
reducer: "",
|
|
48
|
-
schema: "input
|
|
45
|
+
id: "set-time-materials-op",
|
|
46
|
+
name: "SET_COST_AND_MATERIALS",
|
|
47
|
+
reducer: "state.costAndMaterials = {\n hourlyRate: action.input.hourlyRate || null,\n variableCap: action.input.variableCap || null,\n billingFrequency: action.input.billingFrequency,\n timesheetRequired: action.input.timesheetRequired\n};",
|
|
48
|
+
schema: "input SetCostAndMaterialsInput {\n hourlyRate: Amount\n variableCap: Amount\n billingFrequency: BillingFrequency!\n timesheetRequired: Boolean!\n}",
|
|
49
49
|
scope: "global",
|
|
50
|
-
template: "",
|
|
50
|
+
template: "Configure time and materials payment terms",
|
|
51
51
|
},
|
|
52
52
|
{
|
|
53
|
-
description: "",
|
|
53
|
+
description: "Configure escrow payment details",
|
|
54
54
|
errors: [],
|
|
55
55
|
examples: [],
|
|
56
|
-
id: "
|
|
56
|
+
id: "set-escrow-op",
|
|
57
57
|
name: "SET_ESCROW_DETAILS",
|
|
58
|
-
reducer: "",
|
|
58
|
+
reducer: "state.escrowDetails = {\n amountHeld: action.input.amountHeld,\n proofOfFundsDocumentId: action.input.proofOfFundsDocumentId || null,\n releaseConditions: action.input.releaseConditions,\n escrowProvider: action.input.escrowProvider || null\n};",
|
|
59
59
|
schema: "input SetEscrowDetailsInput {\n amountHeld: Amount!\n proofOfFundsDocumentId: String\n releaseConditions: String!\n escrowProvider: String\n}",
|
|
60
60
|
scope: "global",
|
|
61
|
-
template: "",
|
|
61
|
+
template: "Configure escrow payment details",
|
|
62
62
|
},
|
|
63
63
|
{
|
|
64
|
-
description: "",
|
|
64
|
+
description: "Set evaluation terms for the payment",
|
|
65
65
|
errors: [],
|
|
66
66
|
examples: [],
|
|
67
|
-
id: "
|
|
67
|
+
id: "set-evaluation-op",
|
|
68
68
|
name: "SET_EVALUATION_TERMS",
|
|
69
|
-
reducer: "",
|
|
69
|
+
reducer: "state.evaluation = {\n evaluationFrequency: action.input.evaluationFrequency,\n evaluatorTeam: action.input.evaluatorTeam,\n criteria: action.input.criteria,\n impactsPayout: action.input.impactsPayout,\n impactsReputation: action.input.impactsReputation,\n commentsVisibleToClient: action.input.commentsVisibleToClient\n};",
|
|
70
70
|
schema: "input SetEvaluationTermsInput {\n evaluationFrequency: EvaluationFrequency!\n evaluatorTeam: String!\n criteria: [String!]!\n impactsPayout: Boolean!\n impactsReputation: Boolean!\n commentsVisibleToClient: Boolean!\n}",
|
|
71
71
|
scope: "global",
|
|
72
|
-
template: "",
|
|
72
|
+
template: "Set evaluation terms for the payment",
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
description: "Configure retainer payment terms",
|
|
76
|
+
errors: [],
|
|
77
|
+
examples: [],
|
|
78
|
+
id: "set-retainer-op",
|
|
79
|
+
name: "SET_RETAINER_DETAILS",
|
|
80
|
+
reducer: "state.retainerDetails = {\n retainerAmount: action.input.retainerAmount,\n billingFrequency: action.input.billingFrequency,\n startDate: action.input.startDate,\n endDate: action.input.endDate || null,\n autoRenew: action.input.autoRenew,\n servicesIncluded: action.input.servicesIncluded\n};",
|
|
81
|
+
schema: "input SetRetainerDetailsInput {\n retainerAmount: Amount!\n billingFrequency: BillingFrequency!\n startDate: Date!\n endDate: Date\n autoRenew: Boolean!\n servicesIncluded: String!\n}",
|
|
82
|
+
scope: "global",
|
|
83
|
+
template: "Configure retainer payment terms",
|
|
73
84
|
},
|
|
74
85
|
],
|
|
75
86
|
},
|
|
76
87
|
{
|
|
77
|
-
description: "",
|
|
78
|
-
id: "
|
|
88
|
+
description: "Milestone management operations",
|
|
89
|
+
id: "milestones-module",
|
|
79
90
|
name: "milestones",
|
|
80
91
|
operations: [
|
|
81
92
|
{
|
|
82
|
-
description: "",
|
|
83
|
-
errors: [
|
|
93
|
+
description: "Add a new milestone to the payment schedule",
|
|
94
|
+
errors: [
|
|
95
|
+
{
|
|
96
|
+
code: "DUPLICATE_MILESTONE_ID",
|
|
97
|
+
description: "A milestone with this ID already exists",
|
|
98
|
+
id: "duplicate-milestone-id",
|
|
99
|
+
name: "DuplicateMilestoneIdError",
|
|
100
|
+
template: "",
|
|
101
|
+
},
|
|
102
|
+
],
|
|
84
103
|
examples: [],
|
|
85
|
-
id: "
|
|
104
|
+
id: "add-milestone-op",
|
|
86
105
|
name: "ADD_MILESTONE",
|
|
87
|
-
reducer: "",
|
|
106
|
+
reducer: 'const existingIndex = state.milestoneSchedule.findIndex(m => m.id === action.input.id);\nif (existingIndex !== -1) {\n throw new DuplicateMilestoneIdError(`Milestone with ID ${action.input.id} already exists`);\n}\n\nconst newMilestone = {\n id: action.input.id,\n name: action.input.name,\n amount: action.input.amount,\n expectedCompletionDate: action.input.expectedCompletionDate || null,\n requiresApproval: action.input.requiresApproval,\n payoutStatus: "PENDING" as "PENDING"\n};\n\nstate.milestoneSchedule.push(newMilestone);',
|
|
88
107
|
schema: "input AddMilestoneInput {\n id: OID!\n name: String!\n amount: Amount!\n expectedCompletionDate: Date\n requiresApproval: Boolean!\n}",
|
|
89
108
|
scope: "global",
|
|
90
|
-
template: "",
|
|
109
|
+
template: "Add a new milestone to the payment schedule",
|
|
91
110
|
},
|
|
92
111
|
{
|
|
93
|
-
description: "",
|
|
94
|
-
errors: [
|
|
112
|
+
description: "Update milestone details",
|
|
113
|
+
errors: [
|
|
114
|
+
{
|
|
115
|
+
code: "MILESTONE_NOT_FOUND",
|
|
116
|
+
description: "Milestone with the specified ID was not found",
|
|
117
|
+
id: "milestone-not-found-update",
|
|
118
|
+
name: "MilestoneNotFoundError",
|
|
119
|
+
template: "",
|
|
120
|
+
},
|
|
121
|
+
],
|
|
95
122
|
examples: [],
|
|
96
|
-
id: "
|
|
123
|
+
id: "update-milestone-op",
|
|
97
124
|
name: "UPDATE_MILESTONE",
|
|
98
|
-
reducer: "",
|
|
125
|
+
reducer: "const milestoneIndex = state.milestoneSchedule.findIndex(m => m.id === action.input.id);\nif (milestoneIndex === -1) {\n throw new MilestoneNotFoundError(`Milestone with ID ${action.input.id} not found`);\n}\n\nconst milestone = state.milestoneSchedule[milestoneIndex];\nif (action.input.name) milestone.name = action.input.name;\nif (action.input.amount) milestone.amount = action.input.amount;\nif (action.input.expectedCompletionDate !== undefined) milestone.expectedCompletionDate = action.input.expectedCompletionDate || null;\nif (action.input.requiresApproval !== undefined && action.input.requiresApproval !== null) milestone.requiresApproval = action.input.requiresApproval;",
|
|
99
126
|
schema: "input UpdateMilestoneInput {\n id: OID!\n name: String\n amount: Amount\n expectedCompletionDate: Date\n requiresApproval: Boolean\n}",
|
|
100
127
|
scope: "global",
|
|
101
|
-
template: "",
|
|
128
|
+
template: "Update milestone details",
|
|
102
129
|
},
|
|
103
130
|
{
|
|
104
|
-
description: "",
|
|
105
|
-
errors: [
|
|
131
|
+
description: "Update milestone payout status",
|
|
132
|
+
errors: [
|
|
133
|
+
{
|
|
134
|
+
code: "MILESTONE_NOT_FOUND",
|
|
135
|
+
description: "Milestone with the specified ID was not found",
|
|
136
|
+
id: "milestone-not-found-status",
|
|
137
|
+
name: "MilestoneNotFoundError",
|
|
138
|
+
template: "",
|
|
139
|
+
},
|
|
140
|
+
],
|
|
106
141
|
examples: [],
|
|
107
|
-
id: "
|
|
142
|
+
id: "update-milestone-status-op",
|
|
108
143
|
name: "UPDATE_MILESTONE_STATUS",
|
|
109
|
-
reducer: "",
|
|
144
|
+
reducer: "const milestoneIndex = state.milestoneSchedule.findIndex(m => m.id === action.input.id);\nif (milestoneIndex === -1) {\n throw new MilestoneNotFoundError(`Milestone with ID ${action.input.id} not found`);\n}\n\nstate.milestoneSchedule[milestoneIndex].payoutStatus = action.input.payoutStatus;",
|
|
110
145
|
schema: "input UpdateMilestoneStatusInput {\n id: OID!\n payoutStatus: MilestonePayoutStatus!\n}",
|
|
111
146
|
scope: "global",
|
|
112
|
-
template: "",
|
|
147
|
+
template: "Update milestone payout status",
|
|
113
148
|
},
|
|
114
149
|
{
|
|
115
|
-
description: "",
|
|
116
|
-
errors: [
|
|
150
|
+
description: "Remove a milestone from the schedule",
|
|
151
|
+
errors: [
|
|
152
|
+
{
|
|
153
|
+
code: "MILESTONE_NOT_FOUND",
|
|
154
|
+
description: "Milestone with the specified ID was not found",
|
|
155
|
+
id: "milestone-not-found-delete",
|
|
156
|
+
name: "MilestoneNotFoundError",
|
|
157
|
+
template: "",
|
|
158
|
+
},
|
|
159
|
+
],
|
|
117
160
|
examples: [],
|
|
118
|
-
id: "
|
|
161
|
+
id: "delete-milestone-op",
|
|
119
162
|
name: "DELETE_MILESTONE",
|
|
120
|
-
reducer: "",
|
|
163
|
+
reducer: "const milestoneIndex = state.milestoneSchedule.findIndex(m => m.id === action.input.id);\nif (milestoneIndex === -1) {\n throw new MilestoneNotFoundError(`Milestone with ID ${action.input.id} not found`);\n}\n\nstate.milestoneSchedule.splice(milestoneIndex, 1);",
|
|
121
164
|
schema: "input DeleteMilestoneInput {\n id: OID!\n}",
|
|
122
165
|
scope: "global",
|
|
123
|
-
template: "",
|
|
166
|
+
template: "Remove a milestone from the schedule",
|
|
124
167
|
},
|
|
125
168
|
{
|
|
126
|
-
description: "",
|
|
169
|
+
description: "Reorder milestones in the schedule",
|
|
127
170
|
errors: [],
|
|
128
171
|
examples: [],
|
|
129
|
-
id: "
|
|
172
|
+
id: "reorder-milestones-op",
|
|
130
173
|
name: "REORDER_MILESTONES",
|
|
131
|
-
reducer: "",
|
|
174
|
+
reducer: "const reorderedMilestones = [];\nfor (const id of action.input.order) {\n const milestone = state.milestoneSchedule.find(m => m.id === id);\n if (milestone) {\n reorderedMilestones.push(milestone);\n }\n}\nstate.milestoneSchedule = reorderedMilestones;",
|
|
132
175
|
schema: "input ReorderMilestonesInput {\n order: [OID!]!\n}",
|
|
133
176
|
scope: "global",
|
|
134
|
-
template: "",
|
|
177
|
+
template: "Reorder milestones in the schedule",
|
|
135
178
|
},
|
|
136
179
|
],
|
|
137
180
|
},
|
|
138
181
|
{
|
|
139
|
-
description: "",
|
|
140
|
-
id: "
|
|
182
|
+
description: "Bonus and penalty clause operations",
|
|
183
|
+
id: "clauses-module",
|
|
141
184
|
name: "clauses",
|
|
142
185
|
operations: [
|
|
143
186
|
{
|
|
144
|
-
description: "",
|
|
145
|
-
errors: [
|
|
187
|
+
description: "Add a new bonus clause",
|
|
188
|
+
errors: [
|
|
189
|
+
{
|
|
190
|
+
code: "DUPLICATE_BONUS_CLAUSE_ID",
|
|
191
|
+
description: "A bonus clause with this ID already exists",
|
|
192
|
+
id: "duplicate-bonus-clause-id",
|
|
193
|
+
name: "DuplicateBonusClauseIdError",
|
|
194
|
+
template: "",
|
|
195
|
+
},
|
|
196
|
+
],
|
|
146
197
|
examples: [],
|
|
147
|
-
id: "
|
|
198
|
+
id: "add-bonus-clause-op",
|
|
148
199
|
name: "ADD_BONUS_CLAUSE",
|
|
149
|
-
reducer: "",
|
|
200
|
+
reducer: "const existingIndex = state.bonusClauses.findIndex(c => c.id === action.input.id);\nif (existingIndex !== -1) {\n throw new DuplicateBonusClauseIdError(`Bonus clause with ID ${action.input.id} already exists`);\n}\n\nconst newClause = {\n id: action.input.id,\n condition: action.input.condition,\n bonusAmount: action.input.bonusAmount,\n comment: action.input.comment || null\n};\n\nstate.bonusClauses.push(newClause);",
|
|
150
201
|
schema: "input AddBonusClauseInput {\n id: OID!\n condition: String!\n bonusAmount: Amount!\n comment: String\n}",
|
|
151
202
|
scope: "global",
|
|
152
|
-
template: "",
|
|
203
|
+
template: "Add a new bonus clause",
|
|
153
204
|
},
|
|
154
205
|
{
|
|
155
|
-
description: "",
|
|
156
|
-
errors: [
|
|
206
|
+
description: "Update bonus clause details",
|
|
207
|
+
errors: [
|
|
208
|
+
{
|
|
209
|
+
code: "BONUS_CLAUSE_NOT_FOUND",
|
|
210
|
+
description: "Bonus clause with the specified ID was not found",
|
|
211
|
+
id: "bonus-clause-not-found",
|
|
212
|
+
name: "BonusClauseNotFoundError",
|
|
213
|
+
template: "",
|
|
214
|
+
},
|
|
215
|
+
],
|
|
157
216
|
examples: [],
|
|
158
|
-
id: "
|
|
217
|
+
id: "update-bonus-clause-op",
|
|
159
218
|
name: "UPDATE_BONUS_CLAUSE",
|
|
160
|
-
reducer: "",
|
|
219
|
+
reducer: "const clauseIndex = state.bonusClauses.findIndex(c => c.id === action.input.id);\nif (clauseIndex === -1) {\n throw new BonusClauseNotFoundError(`Bonus clause with ID ${action.input.id} not found`);\n}\n\nconst clause = state.bonusClauses[clauseIndex];\nif (action.input.condition) clause.condition = action.input.condition;\nif (action.input.bonusAmount) clause.bonusAmount = action.input.bonusAmount;\nif (action.input.comment !== undefined) clause.comment = action.input.comment || null;",
|
|
161
220
|
schema: "input UpdateBonusClauseInput {\n id: OID!\n condition: String\n bonusAmount: Amount\n comment: String\n}",
|
|
162
221
|
scope: "global",
|
|
163
|
-
template: "",
|
|
222
|
+
template: "Update bonus clause details",
|
|
164
223
|
},
|
|
165
224
|
{
|
|
166
|
-
description: "",
|
|
167
|
-
errors: [
|
|
225
|
+
description: "Remove a bonus clause",
|
|
226
|
+
errors: [
|
|
227
|
+
{
|
|
228
|
+
code: "BONUS_CLAUSE_NOT_FOUND",
|
|
229
|
+
description: "Bonus clause with the specified ID was not found",
|
|
230
|
+
id: "bonus-clause-not-found-delete",
|
|
231
|
+
name: "BonusClauseNotFoundError",
|
|
232
|
+
template: "",
|
|
233
|
+
},
|
|
234
|
+
],
|
|
168
235
|
examples: [],
|
|
169
|
-
id: "
|
|
236
|
+
id: "delete-bonus-clause-op",
|
|
170
237
|
name: "DELETE_BONUS_CLAUSE",
|
|
171
|
-
reducer: "",
|
|
238
|
+
reducer: "const clauseIndex = state.bonusClauses.findIndex(c => c.id === action.input.id);\nif (clauseIndex === -1) {\n throw new BonusClauseNotFoundError(`Bonus clause with ID ${action.input.id} not found`);\n}\n\nstate.bonusClauses.splice(clauseIndex, 1);",
|
|
172
239
|
schema: "input DeleteBonusClauseInput {\n id: OID!\n}",
|
|
173
240
|
scope: "global",
|
|
174
|
-
template: "",
|
|
241
|
+
template: "Remove a bonus clause",
|
|
175
242
|
},
|
|
176
243
|
{
|
|
177
|
-
description: "",
|
|
178
|
-
errors: [
|
|
244
|
+
description: "Add a new penalty clause",
|
|
245
|
+
errors: [
|
|
246
|
+
{
|
|
247
|
+
code: "DUPLICATE_PENALTY_CLAUSE_ID",
|
|
248
|
+
description: "A penalty clause with this ID already exists",
|
|
249
|
+
id: "duplicate-penalty-clause-id",
|
|
250
|
+
name: "DuplicatePenaltyClauseIdError",
|
|
251
|
+
template: "",
|
|
252
|
+
},
|
|
253
|
+
],
|
|
179
254
|
examples: [],
|
|
180
|
-
id: "
|
|
255
|
+
id: "add-penalty-clause-op",
|
|
181
256
|
name: "ADD_PENALTY_CLAUSE",
|
|
182
|
-
reducer: "",
|
|
257
|
+
reducer: "const existingIndex = state.penaltyClauses.findIndex(c => c.id === action.input.id);\nif (existingIndex !== -1) {\n throw new DuplicatePenaltyClauseIdError(`Penalty clause with ID ${action.input.id} already exists`);\n}\n\nconst newClause = {\n id: action.input.id,\n condition: action.input.condition,\n deductionAmount: action.input.deductionAmount,\n comment: action.input.comment || null\n};\n\nstate.penaltyClauses.push(newClause);",
|
|
183
258
|
schema: "input AddPenaltyClauseInput {\n id: OID!\n condition: String!\n deductionAmount: Amount!\n comment: String\n}",
|
|
184
259
|
scope: "global",
|
|
185
|
-
template: "",
|
|
260
|
+
template: "Add a new penalty clause",
|
|
186
261
|
},
|
|
187
262
|
{
|
|
188
|
-
|
|
263
|
+
description: "Update penalty clause details",
|
|
264
|
+
errors: [
|
|
265
|
+
{
|
|
266
|
+
code: "PENALTY_CLAUSE_NOT_FOUND",
|
|
267
|
+
description: "Penalty clause with the specified ID was not found",
|
|
268
|
+
id: "penalty-clause-not-found",
|
|
269
|
+
name: "PenaltyClauseNotFoundError",
|
|
270
|
+
template: "",
|
|
271
|
+
},
|
|
272
|
+
],
|
|
273
|
+
examples: [],
|
|
274
|
+
id: "update-penalty-clause-op",
|
|
189
275
|
name: "UPDATE_PENALTY_CLAUSE",
|
|
190
|
-
|
|
276
|
+
reducer: "const clauseIndex = state.penaltyClauses.findIndex(c => c.id === action.input.id);\nif (clauseIndex === -1) {\n throw new PenaltyClauseNotFoundError(`Penalty clause with ID ${action.input.id} not found`);\n}\n\nconst clause = state.penaltyClauses[clauseIndex];\nif (action.input.condition) clause.condition = action.input.condition;\nif (action.input.deductionAmount) clause.deductionAmount = action.input.deductionAmount;\nif (action.input.comment !== undefined) clause.comment = action.input.comment || null;",
|
|
191
277
|
schema: "input UpdatePenaltyClauseInput {\n id: OID!\n condition: String\n deductionAmount: Amount\n comment: String\n}",
|
|
192
|
-
template: "",
|
|
193
|
-
reducer: "",
|
|
194
|
-
errors: [],
|
|
195
|
-
examples: [],
|
|
196
278
|
scope: "global",
|
|
279
|
+
template: "Update penalty clause details",
|
|
197
280
|
},
|
|
198
281
|
{
|
|
199
|
-
|
|
282
|
+
description: "Remove a penalty clause",
|
|
283
|
+
errors: [
|
|
284
|
+
{
|
|
285
|
+
code: "PENALTY_CLAUSE_NOT_FOUND",
|
|
286
|
+
description: "Penalty clause with the specified ID was not found",
|
|
287
|
+
id: "penalty-clause-not-found-delete",
|
|
288
|
+
name: "PenaltyClauseNotFoundError",
|
|
289
|
+
template: "",
|
|
290
|
+
},
|
|
291
|
+
],
|
|
292
|
+
examples: [],
|
|
293
|
+
id: "delete-penalty-clause-op",
|
|
200
294
|
name: "DELETE_PENALTY_CLAUSE",
|
|
201
|
-
|
|
295
|
+
reducer: "const clauseIndex = state.penaltyClauses.findIndex(c => c.id === action.input.id);\nif (clauseIndex === -1) {\n throw new PenaltyClauseNotFoundError(`Penalty clause with ID ${action.input.id} not found`);\n}\n\nstate.penaltyClauses.splice(clauseIndex, 1);",
|
|
202
296
|
schema: "input DeletePenaltyClauseInput {\n id: OID!\n}",
|
|
203
|
-
template: "",
|
|
204
|
-
reducer: "",
|
|
205
|
-
errors: [],
|
|
206
|
-
examples: [],
|
|
207
297
|
scope: "global",
|
|
298
|
+
template: "Remove a penalty clause",
|
|
208
299
|
},
|
|
209
300
|
],
|
|
210
301
|
},
|
|
@@ -212,12 +303,12 @@ export const documentModel = {
|
|
|
212
303
|
state: {
|
|
213
304
|
global: {
|
|
214
305
|
examples: [],
|
|
215
|
-
initialValue: '{\n "status": "DRAFT",\n "proposer": "",\n "payer": "",\n "currency": "USD",\n "paymentModel": "MILESTONE",\n "totalAmount": null,\n "milestoneSchedule": [],\n "
|
|
216
|
-
schema: "
|
|
306
|
+
initialValue: '{\n "status": "DRAFT",\n "proposer": "",\n "payer": "",\n "currency": "USD",\n "paymentModel": "MILESTONE",\n "totalAmount": null,\n "milestoneSchedule": [],\n "costAndMaterials": null,\n "retainerDetails": null,\n "escrowDetails": null,\n "evaluation": null,\n "bonusClauses": [],\n "penaltyClauses": []\n}',
|
|
307
|
+
schema: "enum PaymentTermsStatus {\n DRAFT\n SUBMITTED\n ACCEPTED\n CANCELLED\n}\n\nenum PaymentCurrency {\n USD\n EUR\n GBP\n}\n\nenum PaymentModel {\n MILESTONE\n COST_AND_MATERIALS\n RETAINER\n}\n\nenum MilestonePayoutStatus {\n PENDING\n READY_FOR_REVIEW\n APPROVED\n PAID\n REJECTED\n}\n\nenum BillingFrequency {\n WEEKLY\n BIWEEKLY\n MONTHLY\n}\n\nenum EvaluationFrequency {\n WEEKLY\n MONTHLY\n PER_MILESTONE\n}\n\ntype Milestone {\n id: OID!\n name: String!\n amount: Amount!\n expectedCompletionDate: Date\n requiresApproval: Boolean!\n payoutStatus: MilestonePayoutStatus!\n}\n\ntype CostAndMaterials {\n hourlyRate: Amount\n variableCap: Amount\n billingFrequency: BillingFrequency!\n timesheetRequired: Boolean!\n}\n\ntype Retainer {\n retainerAmount: Amount!\n billingFrequency: BillingFrequency!\n startDate: Date!\n endDate: Date\n autoRenew: Boolean!\n servicesIncluded: String!\n}\n\ntype Escrow {\n amountHeld: Amount!\n proofOfFundsDocumentId: String\n releaseConditions: String!\n escrowProvider: String\n}\n\ntype EvaluationTerms {\n evaluationFrequency: EvaluationFrequency!\n evaluatorTeam: String!\n criteria: [String!]!\n impactsPayout: Boolean!\n impactsReputation: Boolean!\n commentsVisibleToClient: Boolean!\n}\n\ntype BonusClause {\n id: OID!\n condition: String!\n bonusAmount: Amount!\n comment: String\n}\n\ntype PenaltyClause {\n id: OID!\n condition: String!\n deductionAmount: Amount!\n comment: String\n}\n\ntype PaymentTermsState {\n status: PaymentTermsStatus!\n proposer: String!\n payer: String!\n currency: PaymentCurrency!\n paymentModel: PaymentModel!\n totalAmount: Amount\n milestoneSchedule: [Milestone!]!\n costAndMaterials: CostAndMaterials\n retainerDetails: Retainer\n escrowDetails: Escrow\n evaluation: EvaluationTerms\n bonusClauses: [BonusClause!]!\n penaltyClauses: [PenaltyClause!]!\n}",
|
|
217
308
|
},
|
|
218
309
|
local: {
|
|
219
310
|
examples: [],
|
|
220
|
-
initialValue: "",
|
|
311
|
+
initialValue: "{}",
|
|
221
312
|
schema: "",
|
|
222
313
|
},
|
|
223
314
|
},
|
|
@@ -1,2 +1,27 @@
|
|
|
1
|
-
export
|
|
1
|
+
export type ErrorCode = "DuplicateMilestoneIdError" | "MilestoneNotFoundError";
|
|
2
|
+
export interface ReducerError {
|
|
3
|
+
errorCode: ErrorCode;
|
|
4
|
+
}
|
|
5
|
+
export declare class DuplicateMilestoneIdError extends Error implements ReducerError {
|
|
6
|
+
errorCode: ErrorCode;
|
|
7
|
+
constructor(message?: string);
|
|
8
|
+
}
|
|
9
|
+
export declare class MilestoneNotFoundError extends Error implements ReducerError {
|
|
10
|
+
errorCode: ErrorCode;
|
|
11
|
+
constructor(message?: string);
|
|
12
|
+
}
|
|
13
|
+
export declare const errors: {
|
|
14
|
+
AddMilestone: {
|
|
15
|
+
DuplicateMilestoneIdError: typeof DuplicateMilestoneIdError;
|
|
16
|
+
};
|
|
17
|
+
UpdateMilestone: {
|
|
18
|
+
MilestoneNotFoundError: typeof MilestoneNotFoundError;
|
|
19
|
+
};
|
|
20
|
+
UpdateMilestoneStatus: {
|
|
21
|
+
MilestoneNotFoundError: typeof MilestoneNotFoundError;
|
|
22
|
+
};
|
|
23
|
+
DeleteMilestone: {
|
|
24
|
+
MilestoneNotFoundError: typeof MilestoneNotFoundError;
|
|
25
|
+
};
|
|
26
|
+
};
|
|
2
27
|
//# sourceMappingURL=error.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"error.d.ts","sourceRoot":"","sources":["../../../../../document-models/payment-terms/gen/milestones/error.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"error.d.ts","sourceRoot":"","sources":["../../../../../document-models/payment-terms/gen/milestones/error.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,SAAS,GAAG,2BAA2B,GAAG,wBAAwB,CAAC;AAE/E,MAAM,WAAW,YAAY;IAC3B,SAAS,EAAE,SAAS,CAAC;CACtB;AAED,qBAAa,yBAA0B,SAAQ,KAAM,YAAW,YAAY;IAC1E,SAAS,EAAkC,SAAS,CAAC;gBACzC,OAAO,SAA8B;CAGlD;AAED,qBAAa,sBAAuB,SAAQ,KAAM,YAAW,YAAY;IACvE,SAAS,EAA+B,SAAS,CAAC;gBACtC,OAAO,SAA2B;CAG/C;AAED,eAAO,MAAM,MAAM;;;;;;;;;;;;;CAKlB,CAAC"}
|
|
@@ -1 +1,18 @@
|
|
|
1
|
-
export
|
|
1
|
+
export class DuplicateMilestoneIdError extends Error {
|
|
2
|
+
errorCode = "DuplicateMilestoneIdError";
|
|
3
|
+
constructor(message = "DuplicateMilestoneIdError") {
|
|
4
|
+
super(message);
|
|
5
|
+
}
|
|
6
|
+
}
|
|
7
|
+
export class MilestoneNotFoundError extends Error {
|
|
8
|
+
errorCode = "MilestoneNotFoundError";
|
|
9
|
+
constructor(message = "MilestoneNotFoundError") {
|
|
10
|
+
super(message);
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
export const errors = {
|
|
14
|
+
AddMilestone: { DuplicateMilestoneIdError },
|
|
15
|
+
UpdateMilestone: { MilestoneNotFoundError },
|
|
16
|
+
UpdateMilestoneStatus: { MilestoneNotFoundError },
|
|
17
|
+
DeleteMilestone: { MilestoneNotFoundError },
|
|
18
|
+
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ph-factories.d.ts","sourceRoot":"","sources":["../../../../document-models/payment-terms/gen/ph-factories.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,WAAW,EAAE,eAAe,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAEhF,OAAO,KAAK,EACV,oBAAoB,EACpB,sBAAsB,EACtB,uBAAuB,EACvB,mBAAmB,EACpB,MAAM,YAAY,CAAC;AAGpB,wBAAgB,kBAAkB,IAAI,uBAAuB,
|
|
1
|
+
{"version":3,"file":"ph-factories.d.ts","sourceRoot":"","sources":["../../../../document-models/payment-terms/gen/ph-factories.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,WAAW,EAAE,eAAe,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAEhF,OAAO,KAAK,EACV,oBAAoB,EACpB,sBAAsB,EACtB,uBAAuB,EACvB,mBAAmB,EACpB,MAAM,YAAY,CAAC;AAGpB,wBAAgB,kBAAkB,IAAI,uBAAuB,CAgB5D;AAED,wBAAgB,iBAAiB,IAAI,sBAAsB,CAE1D;AAED,wBAAgB,cAAc,IAAI,mBAAmB,CAMpD;AAED,wBAAgB,iBAAiB,CAC/B,KAAK,CAAC,EAAE,OAAO,CAAC,uBAAuB,CAAC,GACvC,uBAAuB,CAKzB;AAED,wBAAgB,gBAAgB,CAC9B,KAAK,CAAC,EAAE,OAAO,CAAC,sBAAsB,CAAC,GACtC,sBAAsB,CAKxB;AAED,wBAAgB,WAAW,CACzB,SAAS,CAAC,EAAE,OAAO,CAAC,WAAW,CAAC,EAChC,WAAW,CAAC,EAAE,OAAO,CAAC,uBAAuB,CAAC,EAC9C,UAAU,CAAC,EAAE,OAAO,CAAC,sBAAsB,CAAC,GAC3C,mBAAmB,CAMrB;AAED;;;;GAIG;AACH,wBAAgB,0BAA0B,CACxC,KAAK,CAAC,EAAE,OAAO,CAAC;IACd,IAAI,CAAC,EAAE,OAAO,CAAC,WAAW,CAAC,CAAC;IAC5B,QAAQ,CAAC,EAAE,OAAO,CAAC,eAAe,CAAC,CAAC;IACpC,MAAM,CAAC,EAAE,OAAO,CAAC,uBAAuB,CAAC,CAAC;IAC1C,KAAK,CAAC,EAAE,OAAO,CAAC,sBAAsB,CAAC,CAAC;CACzC,CAAC,GACD,oBAAoB,CAYtB"}
|
|
@@ -9,7 +9,8 @@ export function defaultGlobalState() {
|
|
|
9
9
|
paymentModel: "MILESTONE",
|
|
10
10
|
totalAmount: null,
|
|
11
11
|
milestoneSchedule: [],
|
|
12
|
-
|
|
12
|
+
costAndMaterials: null,
|
|
13
|
+
retainerDetails: null,
|
|
13
14
|
escrowDetails: null,
|
|
14
15
|
evaluation: null,
|
|
15
16
|
bonusClauses: [],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"reducer.d.ts","sourceRoot":"","sources":["../../../../document-models/payment-terms/gen/reducer.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"reducer.d.ts","sourceRoot":"","sources":["../../../../document-models/payment-terms/gen/reducer.ts"],"names":[],"mappings":"AAyPA,eAAO,MAAM,OAAO,uDAAmD,CAAC"}
|
|
@@ -2,7 +2,7 @@ import { isDocumentAction, createReducer } from "document-model/core";
|
|
|
2
2
|
import { paymentTermsTermsOperations } from "../src/reducers/terms.js";
|
|
3
3
|
import { paymentTermsMilestonesOperations } from "../src/reducers/milestones.js";
|
|
4
4
|
import { paymentTermsClausesOperations } from "../src/reducers/clauses.js";
|
|
5
|
-
import { SetBasicTermsInputSchema, UpdateStatusInputSchema,
|
|
5
|
+
import { SetBasicTermsInputSchema, UpdateStatusInputSchema, SetCostAndMaterialsInputSchema, SetEscrowDetailsInputSchema, SetEvaluationTermsInputSchema, SetRetainerDetailsInputSchema, AddMilestoneInputSchema, UpdateMilestoneInputSchema, UpdateMilestoneStatusInputSchema, DeleteMilestoneInputSchema, ReorderMilestonesInputSchema, AddBonusClauseInputSchema, UpdateBonusClauseInputSchema, DeleteBonusClauseInputSchema, AddPenaltyClauseInputSchema, UpdatePenaltyClauseInputSchema, DeletePenaltyClauseInputSchema, } from "./schema/zod.js";
|
|
6
6
|
const stateReducer = (state, action, dispatch) => {
|
|
7
7
|
if (isDocumentAction(action)) {
|
|
8
8
|
return state;
|
|
@@ -18,9 +18,9 @@ const stateReducer = (state, action, dispatch) => {
|
|
|
18
18
|
paymentTermsTermsOperations.updateStatusOperation(state[action.scope], action, dispatch);
|
|
19
19
|
break;
|
|
20
20
|
}
|
|
21
|
-
case "
|
|
22
|
-
|
|
23
|
-
paymentTermsTermsOperations.
|
|
21
|
+
case "SET_COST_AND_MATERIALS": {
|
|
22
|
+
SetCostAndMaterialsInputSchema().parse(action.input);
|
|
23
|
+
paymentTermsTermsOperations.setCostAndMaterialsOperation(state[action.scope], action, dispatch);
|
|
24
24
|
break;
|
|
25
25
|
}
|
|
26
26
|
case "SET_ESCROW_DETAILS": {
|
|
@@ -33,6 +33,11 @@ const stateReducer = (state, action, dispatch) => {
|
|
|
33
33
|
paymentTermsTermsOperations.setEvaluationTermsOperation(state[action.scope], action, dispatch);
|
|
34
34
|
break;
|
|
35
35
|
}
|
|
36
|
+
case "SET_RETAINER_DETAILS": {
|
|
37
|
+
SetRetainerDetailsInputSchema().parse(action.input);
|
|
38
|
+
paymentTermsTermsOperations.setRetainerDetailsOperation(state[action.scope], action, dispatch);
|
|
39
|
+
break;
|
|
40
|
+
}
|
|
36
41
|
case "ADD_MILESTONE": {
|
|
37
42
|
AddMilestoneInputSchema().parse(action.input);
|
|
38
43
|
paymentTermsMilestonesOperations.addMilestoneOperation(state[action.scope], action, dispatch);
|
|
@@ -172,6 +172,12 @@ export type BonusClause = {
|
|
|
172
172
|
condition: Scalars["String"]["output"];
|
|
173
173
|
id: Scalars["OID"]["output"];
|
|
174
174
|
};
|
|
175
|
+
export type CostAndMaterials = {
|
|
176
|
+
billingFrequency: BillingFrequency;
|
|
177
|
+
hourlyRate: Maybe<Scalars["Amount"]["output"]>;
|
|
178
|
+
timesheetRequired: Scalars["Boolean"]["output"];
|
|
179
|
+
variableCap: Maybe<Scalars["Amount"]["output"]>;
|
|
180
|
+
};
|
|
175
181
|
export type DeleteBonusClauseInput = {
|
|
176
182
|
id: Scalars["OID"]["input"];
|
|
177
183
|
};
|
|
@@ -206,9 +212,10 @@ export type Milestone = {
|
|
|
206
212
|
};
|
|
207
213
|
export type MilestonePayoutStatus = "APPROVED" | "PAID" | "PENDING" | "READY_FOR_REVIEW" | "REJECTED";
|
|
208
214
|
export type PaymentCurrency = "EUR" | "GBP" | "USD";
|
|
209
|
-
export type PaymentModel = "MILESTONE" | "
|
|
215
|
+
export type PaymentModel = "COST_AND_MATERIALS" | "MILESTONE" | "RETAINER";
|
|
210
216
|
export type PaymentTermsState = {
|
|
211
217
|
bonusClauses: Array<BonusClause>;
|
|
218
|
+
costAndMaterials: Maybe<CostAndMaterials>;
|
|
212
219
|
currency: PaymentCurrency;
|
|
213
220
|
escrowDetails: Maybe<Escrow>;
|
|
214
221
|
evaluation: Maybe<EvaluationTerms>;
|
|
@@ -217,8 +224,8 @@ export type PaymentTermsState = {
|
|
|
217
224
|
paymentModel: PaymentModel;
|
|
218
225
|
penaltyClauses: Array<PenaltyClause>;
|
|
219
226
|
proposer: Scalars["String"]["output"];
|
|
227
|
+
retainerDetails: Maybe<Retainer>;
|
|
220
228
|
status: PaymentTermsStatus;
|
|
221
|
-
timeAndMaterials: Maybe<TimeAndMaterials>;
|
|
222
229
|
totalAmount: Maybe<Scalars["Amount"]["output"]>;
|
|
223
230
|
};
|
|
224
231
|
export type PaymentTermsStatus = "ACCEPTED" | "CANCELLED" | "DRAFT" | "SUBMITTED";
|
|
@@ -231,6 +238,14 @@ export type PenaltyClause = {
|
|
|
231
238
|
export type ReorderMilestonesInput = {
|
|
232
239
|
order: Array<Scalars["OID"]["input"]>;
|
|
233
240
|
};
|
|
241
|
+
export type Retainer = {
|
|
242
|
+
autoRenew: Scalars["Boolean"]["output"];
|
|
243
|
+
billingFrequency: BillingFrequency;
|
|
244
|
+
endDate: Maybe<Scalars["Date"]["output"]>;
|
|
245
|
+
retainerAmount: Scalars["Amount"]["output"];
|
|
246
|
+
servicesIncluded: Scalars["String"]["output"];
|
|
247
|
+
startDate: Scalars["Date"]["output"];
|
|
248
|
+
};
|
|
234
249
|
export type SetBasicTermsInput = {
|
|
235
250
|
currency: PaymentCurrency;
|
|
236
251
|
payer: Scalars["String"]["input"];
|
|
@@ -238,6 +253,12 @@ export type SetBasicTermsInput = {
|
|
|
238
253
|
proposer: Scalars["String"]["input"];
|
|
239
254
|
totalAmount?: InputMaybe<Scalars["Amount"]["input"]>;
|
|
240
255
|
};
|
|
256
|
+
export type SetCostAndMaterialsInput = {
|
|
257
|
+
billingFrequency: BillingFrequency;
|
|
258
|
+
hourlyRate?: InputMaybe<Scalars["Amount"]["input"]>;
|
|
259
|
+
timesheetRequired: Scalars["Boolean"]["input"];
|
|
260
|
+
variableCap?: InputMaybe<Scalars["Amount"]["input"]>;
|
|
261
|
+
};
|
|
241
262
|
export type SetEscrowDetailsInput = {
|
|
242
263
|
amountHeld: Scalars["Amount"]["input"];
|
|
243
264
|
escrowProvider?: InputMaybe<Scalars["String"]["input"]>;
|
|
@@ -252,19 +273,13 @@ export type SetEvaluationTermsInput = {
|
|
|
252
273
|
impactsPayout: Scalars["Boolean"]["input"];
|
|
253
274
|
impactsReputation: Scalars["Boolean"]["input"];
|
|
254
275
|
};
|
|
255
|
-
export type
|
|
256
|
-
|
|
257
|
-
hourlyRate?: InputMaybe<Scalars["Amount"]["input"]>;
|
|
258
|
-
retainerAmount?: InputMaybe<Scalars["Amount"]["input"]>;
|
|
259
|
-
timesheetRequired: Scalars["Boolean"]["input"];
|
|
260
|
-
variableCap?: InputMaybe<Scalars["Amount"]["input"]>;
|
|
261
|
-
};
|
|
262
|
-
export type TimeAndMaterials = {
|
|
276
|
+
export type SetRetainerDetailsInput = {
|
|
277
|
+
autoRenew: Scalars["Boolean"]["input"];
|
|
263
278
|
billingFrequency: BillingFrequency;
|
|
264
|
-
|
|
265
|
-
retainerAmount:
|
|
266
|
-
|
|
267
|
-
|
|
279
|
+
endDate?: InputMaybe<Scalars["Date"]["input"]>;
|
|
280
|
+
retainerAmount: Scalars["Amount"]["input"];
|
|
281
|
+
servicesIncluded: Scalars["String"]["input"];
|
|
282
|
+
startDate: Scalars["Date"]["input"];
|
|
268
283
|
};
|
|
269
284
|
export type UpdateBonusClauseInput = {
|
|
270
285
|
bonusAmount?: InputMaybe<Scalars["Amount"]["input"]>;
|