@rippling/rippling-sdk 0.2.0-alpha.82 → 0.2.0-alpha.83
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/client.d.mts +4 -4
- package/client.d.mts.map +1 -1
- package/client.d.ts +4 -4
- package/client.d.ts.map +1 -1
- package/client.js.map +1 -1
- package/client.mjs.map +1 -1
- package/core/platform/custom-objects/category.d.mts +125 -0
- package/core/platform/custom-objects/category.d.mts.map +1 -0
- package/core/platform/custom-objects/category.d.ts +125 -0
- package/core/platform/custom-objects/category.d.ts.map +1 -0
- package/core/platform/custom-objects/category.js +188 -0
- package/core/platform/custom-objects/category.js.map +1 -0
- package/core/platform/custom-objects/category.mjs +178 -0
- package/core/platform/custom-objects/category.mjs.map +1 -0
- package/core/platform/custom-objects/definition.d.mts +147 -0
- package/core/platform/custom-objects/definition.d.mts.map +1 -0
- package/core/platform/custom-objects/definition.d.ts +147 -0
- package/core/platform/custom-objects/definition.d.ts.map +1 -0
- package/core/platform/custom-objects/definition.js +200 -0
- package/core/platform/custom-objects/definition.js.map +1 -0
- package/core/platform/custom-objects/definition.mjs +190 -0
- package/core/platform/custom-objects/definition.mjs.map +1 -0
- package/core/platform/custom-objects/fields.d.mts +302 -0
- package/core/platform/custom-objects/fields.d.mts.map +1 -0
- package/core/platform/custom-objects/fields.d.ts +302 -0
- package/core/platform/custom-objects/fields.d.ts.map +1 -0
- package/core/platform/custom-objects/fields.js +369 -0
- package/core/platform/custom-objects/fields.js.map +1 -0
- package/core/platform/custom-objects/fields.mjs +347 -0
- package/core/platform/custom-objects/fields.mjs.map +1 -0
- package/core/platform/custom-objects/function-runtime.d.mts +42 -0
- package/core/platform/custom-objects/function-runtime.d.mts.map +1 -0
- package/core/platform/custom-objects/function-runtime.d.ts +42 -0
- package/core/platform/custom-objects/function-runtime.d.ts.map +1 -0
- package/core/platform/custom-objects/function-runtime.js +38 -0
- package/core/platform/custom-objects/function-runtime.js.map +1 -0
- package/core/platform/custom-objects/function-runtime.mjs +35 -0
- package/core/platform/custom-objects/function-runtime.mjs.map +1 -0
- package/core/platform/custom-objects/lifecycle.d.mts +83 -0
- package/core/platform/custom-objects/lifecycle.d.mts.map +1 -0
- package/core/platform/custom-objects/lifecycle.d.ts +83 -0
- package/core/platform/custom-objects/lifecycle.d.ts.map +1 -0
- package/core/platform/custom-objects/lifecycle.js +372 -0
- package/core/platform/custom-objects/lifecycle.js.map +1 -0
- package/core/platform/custom-objects/lifecycle.mjs +367 -0
- package/core/platform/custom-objects/lifecycle.mjs.map +1 -0
- package/core/platform/custom-objects/manager.d.mts +354 -0
- package/core/platform/custom-objects/manager.d.mts.map +1 -0
- package/core/platform/custom-objects/manager.d.ts +354 -0
- package/core/platform/custom-objects/manager.d.ts.map +1 -0
- package/core/platform/custom-objects/manager.js +646 -0
- package/core/platform/custom-objects/manager.js.map +1 -0
- package/core/platform/custom-objects/manager.mjs +637 -0
- package/core/platform/custom-objects/manager.mjs.map +1 -0
- package/core/platform/custom-objects/provisioning.d.mts +138 -0
- package/core/platform/custom-objects/provisioning.d.mts.map +1 -0
- package/core/platform/custom-objects/provisioning.d.ts +138 -0
- package/core/platform/custom-objects/provisioning.d.ts.map +1 -0
- package/core/platform/custom-objects/provisioning.js +455 -0
- package/core/platform/custom-objects/provisioning.js.map +1 -0
- package/core/platform/custom-objects/provisioning.mjs +447 -0
- package/core/platform/custom-objects/provisioning.mjs.map +1 -0
- package/core/platform/custom-objects/rql.d.mts +122 -0
- package/core/platform/custom-objects/rql.d.mts.map +1 -0
- package/core/platform/custom-objects/rql.d.ts +122 -0
- package/core/platform/custom-objects/rql.d.ts.map +1 -0
- package/core/platform/custom-objects/rql.js +225 -0
- package/core/platform/custom-objects/rql.js.map +1 -0
- package/core/platform/custom-objects/rql.mjs +222 -0
- package/core/platform/custom-objects/rql.mjs.map +1 -0
- package/core/platform/custom-objects/schema-manager.d.mts +203 -0
- package/core/platform/custom-objects/schema-manager.d.mts.map +1 -0
- package/core/platform/custom-objects/schema-manager.d.ts +203 -0
- package/core/platform/custom-objects/schema-manager.d.ts.map +1 -0
- package/core/platform/custom-objects/schema-manager.js +256 -0
- package/core/platform/custom-objects/schema-manager.js.map +1 -0
- package/core/platform/custom-objects/schema-manager.mjs +249 -0
- package/core/platform/custom-objects/schema-manager.mjs.map +1 -0
- package/core/platform/custom-objects/typed-rql.d.mts +157 -0
- package/core/platform/custom-objects/typed-rql.d.mts.map +1 -0
- package/core/platform/custom-objects/typed-rql.d.ts +157 -0
- package/core/platform/custom-objects/typed-rql.d.ts.map +1 -0
- package/core/platform/custom-objects/typed-rql.js +583 -0
- package/core/platform/custom-objects/typed-rql.js.map +1 -0
- package/core/platform/custom-objects/typed-rql.mjs +580 -0
- package/core/platform/custom-objects/typed-rql.mjs.map +1 -0
- package/core/platform/custom-objects/types.d.mts +549 -0
- package/core/platform/custom-objects/types.d.mts.map +1 -0
- package/core/platform/custom-objects/types.d.ts +549 -0
- package/core/platform/custom-objects/types.d.ts.map +1 -0
- package/core/platform/custom-objects/types.js +20 -0
- package/core/platform/custom-objects/types.js.map +1 -0
- package/core/platform/custom-objects/types.mjs +17 -0
- package/core/platform/custom-objects/types.mjs.map +1 -0
- package/core/platform/custom-objects/validation.d.mts +97 -0
- package/core/platform/custom-objects/validation.d.mts.map +1 -0
- package/core/platform/custom-objects/validation.d.ts +97 -0
- package/core/platform/custom-objects/validation.d.ts.map +1 -0
- package/core/platform/custom-objects/validation.js +477 -0
- package/core/platform/custom-objects/validation.js.map +1 -0
- package/core/platform/custom-objects/validation.mjs +465 -0
- package/core/platform/custom-objects/validation.mjs.map +1 -0
- package/core/platform/custom-objects.d.mts +67 -0
- package/core/platform/custom-objects.d.mts.map +1 -0
- package/core/platform/custom-objects.d.ts +67 -0
- package/core/platform/custom-objects.d.ts.map +1 -0
- package/core/platform/custom-objects.js +118 -0
- package/core/platform/custom-objects.js.map +1 -0
- package/core/platform/custom-objects.mjs +45 -0
- package/core/platform/custom-objects.mjs.map +1 -0
- package/core/platform/manifest/custom-objects/action.d.mts +58 -0
- package/core/platform/manifest/custom-objects/action.d.mts.map +1 -0
- package/core/platform/manifest/custom-objects/action.d.ts +58 -0
- package/core/platform/manifest/custom-objects/action.d.ts.map +1 -0
- package/core/platform/manifest/custom-objects/action.js +44 -0
- package/core/platform/manifest/custom-objects/action.js.map +1 -0
- package/core/platform/manifest/custom-objects/action.mjs +40 -0
- package/core/platform/manifest/custom-objects/action.mjs.map +1 -0
- package/core/platform/manifest/custom-objects/conditions.d.mts +240 -0
- package/core/platform/manifest/custom-objects/conditions.d.mts.map +1 -0
- package/core/platform/manifest/custom-objects/conditions.d.ts +240 -0
- package/core/platform/manifest/custom-objects/conditions.d.ts.map +1 -0
- package/core/platform/manifest/custom-objects/conditions.js +326 -0
- package/core/platform/manifest/custom-objects/conditions.js.map +1 -0
- package/core/platform/manifest/custom-objects/conditions.mjs +321 -0
- package/core/platform/manifest/custom-objects/conditions.mjs.map +1 -0
- package/core/platform/manifest/custom-objects/existing.d.mts +87 -0
- package/core/platform/manifest/custom-objects/existing.d.mts.map +1 -0
- package/core/platform/manifest/custom-objects/existing.d.ts +87 -0
- package/core/platform/manifest/custom-objects/existing.d.ts.map +1 -0
- package/core/platform/manifest/custom-objects/existing.js +113 -0
- package/core/platform/manifest/custom-objects/existing.js.map +1 -0
- package/core/platform/manifest/custom-objects/existing.mjs +109 -0
- package/core/platform/manifest/custom-objects/existing.mjs.map +1 -0
- package/core/platform/manifest/custom-objects/field-resolution.d.mts +48 -0
- package/core/platform/manifest/custom-objects/field-resolution.d.mts.map +1 -0
- package/core/platform/manifest/custom-objects/field-resolution.d.ts +48 -0
- package/core/platform/manifest/custom-objects/field-resolution.d.ts.map +1 -0
- package/core/platform/manifest/custom-objects/field-resolution.js +61 -0
- package/core/platform/manifest/custom-objects/field-resolution.js.map +1 -0
- package/core/platform/manifest/custom-objects/field-resolution.mjs +58 -0
- package/core/platform/manifest/custom-objects/field-resolution.mjs.map +1 -0
- package/core/platform/manifest/custom-objects/function-file.d.mts +87 -0
- package/core/platform/manifest/custom-objects/function-file.d.mts.map +1 -0
- package/core/platform/manifest/custom-objects/function-file.d.ts +87 -0
- package/core/platform/manifest/custom-objects/function-file.d.ts.map +1 -0
- package/core/platform/manifest/custom-objects/function-file.js +76 -0
- package/core/platform/manifest/custom-objects/function-file.js.map +1 -0
- package/core/platform/manifest/custom-objects/function-file.mjs +69 -0
- package/core/platform/manifest/custom-objects/function-file.mjs.map +1 -0
- package/core/platform/manifest/custom-objects/list-view.d.mts +65 -0
- package/core/platform/manifest/custom-objects/list-view.d.mts.map +1 -0
- package/core/platform/manifest/custom-objects/list-view.d.ts +65 -0
- package/core/platform/manifest/custom-objects/list-view.d.ts.map +1 -0
- package/core/platform/manifest/custom-objects/list-view.js +33 -0
- package/core/platform/manifest/custom-objects/list-view.js.map +1 -0
- package/core/platform/manifest/custom-objects/list-view.mjs +30 -0
- package/core/platform/manifest/custom-objects/list-view.mjs.map +1 -0
- package/core/platform/manifest/custom-objects/object-list-page.d.mts +43 -0
- package/core/platform/manifest/custom-objects/object-list-page.d.mts.map +1 -0
- package/core/platform/manifest/custom-objects/object-list-page.d.ts +43 -0
- package/core/platform/manifest/custom-objects/object-list-page.d.ts.map +1 -0
- package/core/platform/manifest/custom-objects/object-list-page.js +54 -0
- package/core/platform/manifest/custom-objects/object-list-page.js.map +1 -0
- package/core/platform/manifest/custom-objects/object-list-page.mjs +50 -0
- package/core/platform/manifest/custom-objects/object-list-page.mjs.map +1 -0
- package/core/platform/manifest/custom-objects/page-layout.d.mts +142 -0
- package/core/platform/manifest/custom-objects/page-layout.d.mts.map +1 -0
- package/core/platform/manifest/custom-objects/page-layout.d.ts +142 -0
- package/core/platform/manifest/custom-objects/page-layout.d.ts.map +1 -0
- package/core/platform/manifest/custom-objects/page-layout.js +184 -0
- package/core/platform/manifest/custom-objects/page-layout.js.map +1 -0
- package/core/platform/manifest/custom-objects/page-layout.mjs +180 -0
- package/core/platform/manifest/custom-objects/page-layout.mjs.map +1 -0
- package/core/platform/manifest/custom-objects/register.d.mts +87 -0
- package/core/platform/manifest/custom-objects/register.d.mts.map +1 -0
- package/core/platform/manifest/custom-objects/register.d.ts +87 -0
- package/core/platform/manifest/custom-objects/register.d.ts.map +1 -0
- package/core/platform/manifest/custom-objects/register.js +395 -0
- package/core/platform/manifest/custom-objects/register.js.map +1 -0
- package/core/platform/manifest/custom-objects/register.mjs +391 -0
- package/core/platform/manifest/custom-objects/register.mjs.map +1 -0
- package/core/platform/manifest/custom-objects/rule.d.mts +113 -0
- package/core/platform/manifest/custom-objects/rule.d.mts.map +1 -0
- package/core/platform/manifest/custom-objects/rule.d.ts +113 -0
- package/core/platform/manifest/custom-objects/rule.d.ts.map +1 -0
- package/core/platform/manifest/custom-objects/rule.js +49 -0
- package/core/platform/manifest/custom-objects/rule.js.map +1 -0
- package/core/platform/manifest/custom-objects/rule.mjs +45 -0
- package/core/platform/manifest/custom-objects/rule.mjs.map +1 -0
- package/core/platform/manifest/custom-objects/sdui-page.d.mts +214 -0
- package/core/platform/manifest/custom-objects/sdui-page.d.mts.map +1 -0
- package/core/platform/manifest/custom-objects/sdui-page.d.ts +214 -0
- package/core/platform/manifest/custom-objects/sdui-page.d.ts.map +1 -0
- package/core/platform/manifest/custom-objects/sdui-page.js +194 -0
- package/core/platform/manifest/custom-objects/sdui-page.js.map +1 -0
- package/core/platform/manifest/custom-objects/sdui-page.mjs +182 -0
- package/core/platform/manifest/custom-objects/sdui-page.mjs.map +1 -0
- package/core/platform/manifest/custom-objects/typed-condition.d.mts +28 -0
- package/core/platform/manifest/custom-objects/typed-condition.d.mts.map +1 -0
- package/core/platform/manifest/custom-objects/typed-condition.d.ts +28 -0
- package/core/platform/manifest/custom-objects/typed-condition.d.ts.map +1 -0
- package/core/platform/manifest/custom-objects/typed-condition.js +434 -0
- package/core/platform/manifest/custom-objects/typed-condition.js.map +1 -0
- package/core/platform/manifest/custom-objects/typed-condition.mjs +431 -0
- package/core/platform/manifest/custom-objects/typed-condition.mjs.map +1 -0
- package/core/platform/manifest/custom-objects/types.d.mts +29 -0
- package/core/platform/manifest/custom-objects/types.d.mts.map +1 -0
- package/core/platform/manifest/custom-objects/types.d.ts +29 -0
- package/core/platform/manifest/custom-objects/types.d.ts.map +1 -0
- package/core/platform/manifest/custom-objects/types.js +3 -0
- package/core/platform/manifest/custom-objects/types.js.map +1 -0
- package/core/platform/manifest/custom-objects/types.mjs +2 -0
- package/core/platform/manifest/custom-objects/types.mjs.map +1 -0
- package/core/platform/manifest/custom-objects/validation.d.mts +44 -0
- package/core/platform/manifest/custom-objects/validation.d.mts.map +1 -0
- package/core/platform/manifest/custom-objects/validation.d.ts +44 -0
- package/core/platform/manifest/custom-objects/validation.d.ts.map +1 -0
- package/core/platform/manifest/custom-objects/validation.js +30 -0
- package/core/platform/manifest/custom-objects/validation.js.map +1 -0
- package/core/platform/manifest/custom-objects/validation.mjs +27 -0
- package/core/platform/manifest/custom-objects/validation.mjs.map +1 -0
- package/core/platform/manifest/custom-objects/workflow.d.mts +47 -0
- package/core/platform/manifest/custom-objects/workflow.d.mts.map +1 -0
- package/core/platform/manifest/custom-objects/workflow.d.ts +47 -0
- package/core/platform/manifest/custom-objects/workflow.d.ts.map +1 -0
- package/core/platform/manifest/custom-objects/workflow.js +38 -0
- package/core/platform/manifest/custom-objects/workflow.js.map +1 -0
- package/core/platform/manifest/custom-objects/workflow.mjs +34 -0
- package/core/platform/manifest/custom-objects/workflow.mjs.map +1 -0
- package/core/platform/manifest/custom-objects.d.mts +85 -0
- package/core/platform/manifest/custom-objects.d.mts.map +1 -0
- package/core/platform/manifest/custom-objects.d.ts +85 -0
- package/core/platform/manifest/custom-objects.d.ts.map +1 -0
- package/core/platform/manifest/custom-objects.js +84 -0
- package/core/platform/manifest/custom-objects.js.map +1 -0
- package/core/platform/manifest/custom-objects.mjs +55 -0
- package/core/platform/manifest/custom-objects.mjs.map +1 -0
- package/examples/manifest/custom-object-creation-workflow/custom-object-creation-workflow.ts +26 -44
- package/examples/manifest/custom-object-creation-workflow/functions/intake-request-created.ts +20 -0
- package/examples/manifest/custom-object-creation-workflow/schema.ts +29 -0
- package/examples/manifest/dental-practice-management/dental-practice-management.ts +142 -470
- package/examples/manifest/dental-practice-management/functions/chair-schedule.ts +13 -23
- package/examples/manifest/dental-practice-management/functions/complete-visit.ts +32 -55
- package/examples/manifest/dental-practice-management/functions/operatory-list.ts +13 -23
- package/examples/manifest/dental-practice-management/functions/patient-list.ts +13 -23
- package/examples/manifest/dental-practice-management/functions/treatment-plan-list.ts +13 -23
- package/examples/manifest/dental-practice-management/schema.ts +298 -0
- package/examples/manifest/existing-manifest-mutations/existing-manifest-mutations.ts +68 -23
- package/examples/manifest/field-service-dispatch/field-service-dispatch.ts +102 -375
- package/examples/manifest/field-service-dispatch/schema.ts +248 -0
- package/examples/manifest/grant-program-management/grant-program-management.ts +125 -419
- package/examples/manifest/grant-program-management/schema.ts +269 -0
- package/examples/manifest/gym-membership-management/functions/check-in-desk.ts +13 -23
- package/examples/manifest/gym-membership-management/functions/member-list.ts +13 -23
- package/examples/manifest/gym-membership-management/functions/today-schedule.ts +13 -23
- package/examples/manifest/gym-membership-management/functions/trainer-list.ts +13 -23
- package/examples/manifest/gym-membership-management/gym-membership-management.ts +92 -442
- package/examples/manifest/gym-membership-management/schema.ts +266 -0
- package/examples/manifest/procurement-approval-hub/functions/route-purchase-request.ts +20 -0
- package/examples/manifest/procurement-approval-hub/procurement-approval-hub.ts +122 -408
- package/examples/manifest/procurement-approval-hub/schema.ts +256 -0
- package/examples/manifest/simple-todo-app/functions/mark-done.ts +16 -12
- package/examples/manifest/simple-todo-app/functions/todo-list.ts +13 -23
- package/examples/manifest/simple-todo-app/schema.ts +60 -0
- package/examples/manifest/simple-todo-app/simple-todo-app.ts +40 -109
- package/examples/manifest/todo-app-without-object-list-view/functions/todo-page.ts +166 -193
- package/examples/manifest/todo-app-without-object-list-view/schema.ts +28 -0
- package/examples/manifest/todo-app-without-object-list-view/todo-app-without-object-list-view.ts +24 -47
- package/package.json +7 -13
- package/resources/custom-objects/custom-objects.d.mts +7 -0
- package/resources/custom-objects/custom-objects.d.mts.map +1 -1
- package/resources/custom-objects/custom-objects.d.ts +7 -0
- package/resources/custom-objects/custom-objects.d.ts.map +1 -1
- package/resources/custom-objects/custom-objects.js.map +1 -1
- package/resources/custom-objects/custom-objects.mjs.map +1 -1
- package/resources/custom-objects/fields.d.mts +170 -15
- package/resources/custom-objects/fields.d.mts.map +1 -1
- package/resources/custom-objects/fields.d.ts +170 -15
- package/resources/custom-objects/fields.d.ts.map +1 -1
- package/resources/index.d.mts +2 -2
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +2 -2
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs.map +1 -1
- package/resources/leave-program-evaluations.d.mts +510 -3
- package/resources/leave-program-evaluations.d.mts.map +1 -1
- package/resources/leave-program-evaluations.d.ts +510 -3
- package/resources/leave-program-evaluations.d.ts.map +1 -1
- package/resources/levels.d.mts +64 -2
- package/resources/levels.d.mts.map +1 -1
- package/resources/levels.d.ts +64 -2
- package/resources/levels.d.ts.map +1 -1
- package/resources/levels.js +22 -0
- package/resources/levels.js.map +1 -1
- package/resources/levels.mjs +22 -0
- package/resources/levels.mjs.map +1 -1
- package/resources/tracks.d.mts +45 -1
- package/resources/tracks.d.mts.map +1 -1
- package/resources/tracks.d.ts +45 -1
- package/resources/tracks.d.ts.map +1 -1
- package/resources/tracks.js +22 -0
- package/resources/tracks.js.map +1 -1
- package/resources/tracks.mjs +22 -0
- package/resources/tracks.mjs.map +1 -1
- package/src/client.ts +8 -0
- package/src/core/platform/README.md +20 -0
- package/src/core/platform/custom-objects/category.ts +294 -0
- package/src/core/platform/custom-objects/definition.ts +373 -0
- package/src/core/platform/custom-objects/fields.ts +653 -0
- package/src/core/platform/custom-objects/function-runtime.ts +76 -0
- package/src/core/platform/custom-objects/lifecycle.ts +557 -0
- package/src/core/platform/custom-objects/manager.ts +959 -0
- package/src/core/platform/custom-objects/provisioning.ts +672 -0
- package/src/core/platform/custom-objects/rql.ts +375 -0
- package/src/core/platform/custom-objects/schema-manager.ts +351 -0
- package/src/core/platform/custom-objects/typed-rql.ts +1273 -0
- package/src/core/platform/custom-objects/types.ts +753 -0
- package/src/core/platform/custom-objects/validation.ts +573 -0
- package/src/core/platform/custom-objects.ts +269 -0
- package/src/core/platform/manifest/README.md +26 -0
- package/src/core/platform/manifest/custom-objects/action.ts +87 -0
- package/src/core/platform/manifest/custom-objects/conditions.ts +762 -0
- package/src/core/platform/manifest/custom-objects/existing.ts +221 -0
- package/src/core/platform/manifest/custom-objects/field-resolution.ts +116 -0
- package/src/core/platform/manifest/custom-objects/function-file.ts +149 -0
- package/src/core/platform/manifest/custom-objects/list-view.ts +95 -0
- package/src/core/platform/manifest/custom-objects/object-list-page.ts +87 -0
- package/src/core/platform/manifest/custom-objects/page-layout.ts +380 -0
- package/src/core/platform/manifest/custom-objects/register.ts +555 -0
- package/src/core/platform/manifest/custom-objects/rule.ts +192 -0
- package/src/core/platform/manifest/custom-objects/sdui-page.ts +515 -0
- package/src/core/platform/manifest/custom-objects/typed-condition.ts +617 -0
- package/src/core/platform/manifest/custom-objects/types.ts +92 -0
- package/src/core/platform/manifest/custom-objects/validation.ts +70 -0
- package/src/core/platform/manifest/custom-objects/workflow.ts +71 -0
- package/src/core/platform/manifest/custom-objects.ts +203 -0
- package/src/pebble-sdui-web-custom-apps-shim.d.ts +3 -0
- package/src/resources/custom-objects/custom-objects.ts +8 -0
- package/src/resources/custom-objects/fields.ts +239 -14
- package/src/resources/index.ts +4 -0
- package/src/resources/leave-program-evaluations.ts +610 -3
- package/src/resources/levels.ts +93 -1
- package/src/resources/tracks.ts +70 -0
- package/src/tsconfig.json +1 -1
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Grant Program Management - programs, grants, applicants, applications,
|
|
2
|
+
* Grant Program Management - programs, grants, applicants, applications,
|
|
3
|
+
* milestones, and disbursements.
|
|
3
4
|
*
|
|
4
5
|
* gpm_program__c <- funding program and budget
|
|
5
6
|
* gpm_grant__c <- grant cycle under a program
|
|
@@ -13,26 +14,24 @@
|
|
|
13
14
|
* > examples/manifest/grant-program-management/manifest.json
|
|
14
15
|
*/
|
|
15
16
|
|
|
17
|
+
import { toCustomCategoryApiName } from '@rippling/rippling-sdk/core/platform/custom-objects';
|
|
16
18
|
import {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
TextField,
|
|
34
|
-
Validation,
|
|
35
|
-
} from '@rippling/rippling-sdk/lib/manifest';
|
|
19
|
+
defineBasicTypedPageLayout,
|
|
20
|
+
defineTypedListView,
|
|
21
|
+
defineTypedRule,
|
|
22
|
+
defineTypedValidation,
|
|
23
|
+
registerManifestCustomObjects,
|
|
24
|
+
} from '@rippling/rippling-sdk/core/platform/manifest/custom-objects';
|
|
25
|
+
import { Category, ManifestBuilder, SummaryField } from '@rippling/rippling-sdk/lib/manifest';
|
|
26
|
+
import {
|
|
27
|
+
applicantDefinition,
|
|
28
|
+
applicationDefinition,
|
|
29
|
+
disbursementDefinition,
|
|
30
|
+
grantDefinition,
|
|
31
|
+
GRANTS_CATEGORY,
|
|
32
|
+
milestoneDefinition,
|
|
33
|
+
programDefinition,
|
|
34
|
+
} from './schema';
|
|
36
35
|
|
|
37
36
|
const manifest = new ManifestBuilder({
|
|
38
37
|
key: 'grant_program_management',
|
|
@@ -41,554 +40,261 @@ const manifest = new ManifestBuilder({
|
|
|
41
40
|
});
|
|
42
41
|
|
|
43
42
|
const category = new Category(manifest, {
|
|
44
|
-
apiName:
|
|
43
|
+
apiName: toCustomCategoryApiName(GRANTS_CATEGORY),
|
|
45
44
|
name: 'Grants',
|
|
46
45
|
description: 'Grant program and funding records',
|
|
47
46
|
});
|
|
48
47
|
|
|
49
|
-
const
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
description: 'Program focus area',
|
|
66
|
-
options: ['Education', 'Workforce', 'Climate', 'Health', 'Housing', 'Community safety'],
|
|
67
|
-
required: true,
|
|
68
|
-
section: programSection,
|
|
69
|
-
});
|
|
70
|
-
|
|
71
|
-
const programBudgetCentsField = new NumberField(programObj, {
|
|
72
|
-
apiName: 'annual_budget_cents__c',
|
|
73
|
-
displayName: 'Annual budget (cents)',
|
|
74
|
-
description: 'Annual funding budget in cents',
|
|
75
|
-
decimalPlaces: 0,
|
|
76
|
-
section: programSection,
|
|
77
|
-
});
|
|
78
|
-
|
|
79
|
-
const programGuidelinesField = new LongTextField(programObj, {
|
|
80
|
-
apiName: 'guidelines__c',
|
|
81
|
-
displayName: 'Guidelines',
|
|
82
|
-
description: 'Eligibility and operating guidelines',
|
|
83
|
-
maxLength: 8000,
|
|
84
|
-
section: programSection,
|
|
85
|
-
});
|
|
86
|
-
|
|
87
|
-
const grantObj = new CustomObject(manifest, {
|
|
88
|
-
apiName: 'gpm_grant__c',
|
|
89
|
-
name: 'Grant',
|
|
90
|
-
pluralLabel: 'Grants',
|
|
91
|
-
category,
|
|
92
|
-
description: 'Grant cycle under a funding program',
|
|
93
|
-
});
|
|
94
|
-
|
|
95
|
-
const grantSection = new CustomObjectFieldSection(grantObj, {
|
|
96
|
-
name: 'Grant',
|
|
97
|
-
sectionId: 'sec_gpm_grant',
|
|
98
|
-
});
|
|
99
|
-
|
|
100
|
-
const grantProgramRef = new ParentChildField(grantObj, {
|
|
101
|
-
apiName: 'program_ref__c',
|
|
102
|
-
displayName: 'Program',
|
|
103
|
-
target: programObj,
|
|
104
|
-
relatedDataLabel: 'Grants',
|
|
105
|
-
parentChildType: 'PRIMARY',
|
|
106
|
-
enableParentOwnerInheritance: false,
|
|
107
|
-
description: 'Program this grant belongs to',
|
|
108
|
-
section: grantSection,
|
|
109
|
-
});
|
|
110
|
-
|
|
111
|
-
const grantStatusField = new RadioField(grantObj, {
|
|
112
|
-
apiName: 'status__c',
|
|
113
|
-
displayName: 'Status',
|
|
114
|
-
description: 'Grant cycle status',
|
|
115
|
-
options: ['Planning', 'Open', 'Review', 'Awarded', 'Closed'],
|
|
116
|
-
required: true,
|
|
117
|
-
section: grantSection,
|
|
118
|
-
});
|
|
119
|
-
|
|
120
|
-
const grantOpenDateField = new DateField(grantObj, {
|
|
121
|
-
apiName: 'open_date__c',
|
|
122
|
-
displayName: 'Open date',
|
|
123
|
-
description: 'Application open date',
|
|
124
|
-
section: grantSection,
|
|
125
|
-
});
|
|
126
|
-
|
|
127
|
-
const grantCloseDateField = new DateField(grantObj, {
|
|
128
|
-
apiName: 'close_date__c',
|
|
129
|
-
displayName: 'Close date',
|
|
130
|
-
description: 'Application close date',
|
|
131
|
-
section: grantSection,
|
|
132
|
-
});
|
|
133
|
-
|
|
134
|
-
const grantAwardBudgetCentsField = new NumberField(grantObj, {
|
|
135
|
-
apiName: 'award_budget_cents__c',
|
|
136
|
-
displayName: 'Award budget (cents)',
|
|
137
|
-
description: 'Budget allocated to this grant cycle',
|
|
138
|
-
decimalPlaces: 0,
|
|
139
|
-
section: grantSection,
|
|
140
|
-
});
|
|
141
|
-
|
|
142
|
-
const applicantObj = new CustomObject(manifest, {
|
|
143
|
-
apiName: 'gpm_applicant__c',
|
|
144
|
-
name: 'Applicant',
|
|
145
|
-
pluralLabel: 'Applicants',
|
|
146
|
-
category,
|
|
147
|
-
description: 'Applicant organization and contact details',
|
|
148
|
-
});
|
|
149
|
-
|
|
150
|
-
const applicantSection = new CustomObjectFieldSection(applicantObj, {
|
|
151
|
-
name: 'Applicant',
|
|
152
|
-
sectionId: 'sec_gpm_applicant',
|
|
153
|
-
});
|
|
154
|
-
|
|
155
|
-
const applicantLegalNameField = new TextField(applicantObj, {
|
|
156
|
-
apiName: 'legal_name__c',
|
|
157
|
-
displayName: 'Legal name',
|
|
158
|
-
description: 'Applicant organization legal name',
|
|
159
|
-
maxLength: 200,
|
|
160
|
-
required: true,
|
|
161
|
-
section: applicantSection,
|
|
162
|
-
});
|
|
163
|
-
|
|
164
|
-
const applicantTypeField = new RadioField(applicantObj, {
|
|
165
|
-
apiName: 'applicant_type__c',
|
|
166
|
-
displayName: 'Applicant type',
|
|
167
|
-
description: 'Applicant organization type',
|
|
168
|
-
options: ['Nonprofit', 'School', 'Government', 'Small business', 'Community group'],
|
|
169
|
-
required: true,
|
|
170
|
-
section: applicantSection,
|
|
171
|
-
});
|
|
172
|
-
|
|
173
|
-
const applicantEmailField = new EmailField(applicantObj, {
|
|
174
|
-
apiName: 'contact_email__c',
|
|
175
|
-
displayName: 'Contact email',
|
|
176
|
-
description: 'Primary applicant contact email',
|
|
177
|
-
section: applicantSection,
|
|
178
|
-
});
|
|
179
|
-
|
|
180
|
-
const applicationObj = new CustomObject(manifest, {
|
|
181
|
-
apiName: 'gpm_application__c',
|
|
182
|
-
name: 'Application',
|
|
183
|
-
pluralLabel: 'Applications',
|
|
184
|
-
category,
|
|
185
|
-
description: 'Application submitted by an applicant for a grant',
|
|
186
|
-
});
|
|
187
|
-
|
|
188
|
-
const applicationSection = new CustomObjectFieldSection(applicationObj, {
|
|
189
|
-
name: 'Application',
|
|
190
|
-
sectionId: 'sec_gpm_application',
|
|
191
|
-
});
|
|
192
|
-
|
|
193
|
-
const applicationGrantRef = new ParentChildField(applicationObj, {
|
|
194
|
-
apiName: 'grant_ref__c',
|
|
195
|
-
displayName: 'Grant',
|
|
196
|
-
target: grantObj,
|
|
197
|
-
relatedDataLabel: 'Applications',
|
|
198
|
-
parentChildType: 'PRIMARY',
|
|
199
|
-
enableParentOwnerInheritance: false,
|
|
200
|
-
description: 'Grant cycle this application targets',
|
|
201
|
-
section: applicationSection,
|
|
202
|
-
});
|
|
203
|
-
|
|
204
|
-
const applicationApplicantRef = new LookupField(applicationObj, {
|
|
205
|
-
apiName: 'applicant_ref__c',
|
|
206
|
-
displayName: 'Applicant',
|
|
207
|
-
target: applicantObj,
|
|
208
|
-
relatedDataLabel: 'Applications',
|
|
209
|
-
description: 'Applicant submitting this request',
|
|
210
|
-
required: true,
|
|
211
|
-
section: applicationSection,
|
|
212
|
-
});
|
|
213
|
-
|
|
214
|
-
const applicationStatusField = new RadioField(applicationObj, {
|
|
215
|
-
apiName: 'status__c',
|
|
216
|
-
displayName: 'Status',
|
|
217
|
-
description: 'Application review state',
|
|
218
|
-
options: ['Draft', 'Submitted', 'Eligibility review', 'Panel review', 'Awarded', 'Declined'],
|
|
219
|
-
required: true,
|
|
220
|
-
section: applicationSection,
|
|
221
|
-
});
|
|
222
|
-
|
|
223
|
-
const requestedAmountCentsField = new NumberField(applicationObj, {
|
|
224
|
-
apiName: 'requested_amount_cents__c',
|
|
225
|
-
displayName: 'Requested amount (cents)',
|
|
226
|
-
description: 'Requested funding amount in cents',
|
|
227
|
-
decimalPlaces: 0,
|
|
228
|
-
required: true,
|
|
229
|
-
section: applicationSection,
|
|
230
|
-
});
|
|
231
|
-
|
|
232
|
-
const scoreField = new NumberField(applicationObj, {
|
|
233
|
-
apiName: 'review_score__c',
|
|
234
|
-
displayName: 'Review score',
|
|
235
|
-
description: 'Panel score from 0 to 100',
|
|
236
|
-
decimalPlaces: 2,
|
|
237
|
-
section: applicationSection,
|
|
238
|
-
});
|
|
239
|
-
|
|
240
|
-
const proposalSummaryField = new LongTextField(applicationObj, {
|
|
241
|
-
apiName: 'proposal_summary__c',
|
|
242
|
-
displayName: 'Proposal summary',
|
|
243
|
-
description: 'Program plan and impact narrative',
|
|
244
|
-
maxLength: 8000,
|
|
245
|
-
section: applicationSection,
|
|
246
|
-
});
|
|
247
|
-
|
|
248
|
-
const milestoneObj = new CustomObject(manifest, {
|
|
249
|
-
apiName: 'gpm_milestone__c',
|
|
250
|
-
name: 'Milestone',
|
|
251
|
-
pluralLabel: 'Milestones',
|
|
252
|
-
category,
|
|
253
|
-
description: 'Deliverable or report due for an awarded application',
|
|
254
|
-
});
|
|
255
|
-
|
|
256
|
-
const milestoneSection = new CustomObjectFieldSection(milestoneObj, {
|
|
257
|
-
name: 'Milestone',
|
|
258
|
-
sectionId: 'sec_gpm_milestone',
|
|
259
|
-
});
|
|
260
|
-
|
|
261
|
-
const milestoneApplicationRef = new ParentChildField(milestoneObj, {
|
|
262
|
-
apiName: 'application_ref__c',
|
|
263
|
-
displayName: 'Application',
|
|
264
|
-
target: applicationObj,
|
|
265
|
-
relatedDataLabel: 'Milestones',
|
|
266
|
-
parentChildType: 'PRIMARY',
|
|
267
|
-
enableParentOwnerInheritance: true,
|
|
268
|
-
description: 'Application this milestone belongs to',
|
|
269
|
-
section: milestoneSection,
|
|
270
|
-
});
|
|
271
|
-
|
|
272
|
-
const milestoneDueDateField = new DateField(milestoneObj, {
|
|
273
|
-
apiName: 'due_date__c',
|
|
274
|
-
displayName: 'Due date',
|
|
275
|
-
description: 'Milestone due date',
|
|
276
|
-
required: true,
|
|
277
|
-
section: milestoneSection,
|
|
278
|
-
});
|
|
279
|
-
|
|
280
|
-
const milestoneStatusField = new RadioField(milestoneObj, {
|
|
281
|
-
apiName: 'status__c',
|
|
282
|
-
displayName: 'Status',
|
|
283
|
-
description: 'Milestone status',
|
|
284
|
-
options: ['Not started', 'In progress', 'Submitted', 'Accepted', 'Late'],
|
|
285
|
-
required: true,
|
|
286
|
-
section: milestoneSection,
|
|
287
|
-
});
|
|
288
|
-
|
|
289
|
-
const disbursementObj = new CustomObject(manifest, {
|
|
290
|
-
apiName: 'gpm_disbursement__c',
|
|
291
|
-
name: 'Disbursement',
|
|
292
|
-
pluralLabel: 'Disbursements',
|
|
293
|
-
category,
|
|
294
|
-
description: 'Payment tranche tied to an awarded application',
|
|
295
|
-
});
|
|
296
|
-
|
|
297
|
-
const disbursementSection = new CustomObjectFieldSection(disbursementObj, {
|
|
298
|
-
name: 'Disbursement',
|
|
299
|
-
sectionId: 'sec_gpm_disbursement',
|
|
300
|
-
});
|
|
301
|
-
|
|
302
|
-
const disbursementApplicationRef = new ParentChildField(disbursementObj, {
|
|
303
|
-
apiName: 'application_ref__c',
|
|
304
|
-
displayName: 'Application',
|
|
305
|
-
target: applicationObj,
|
|
306
|
-
relatedDataLabel: 'Disbursements',
|
|
307
|
-
parentChildType: 'PRIMARY',
|
|
308
|
-
enableParentOwnerInheritance: true,
|
|
309
|
-
description: 'Application funded by this disbursement',
|
|
310
|
-
section: disbursementSection,
|
|
311
|
-
});
|
|
312
|
-
|
|
313
|
-
const disbursementAmountCentsField = new NumberField(disbursementObj, {
|
|
314
|
-
apiName: 'amount_cents__c',
|
|
315
|
-
displayName: 'Amount (cents)',
|
|
316
|
-
description: 'Disbursement amount in cents',
|
|
317
|
-
decimalPlaces: 0,
|
|
318
|
-
required: true,
|
|
319
|
-
section: disbursementSection,
|
|
320
|
-
});
|
|
321
|
-
|
|
322
|
-
const disbursementStatusField = new RadioField(disbursementObj, {
|
|
323
|
-
apiName: 'status__c',
|
|
324
|
-
displayName: 'Status',
|
|
325
|
-
description: 'Disbursement status',
|
|
326
|
-
options: ['Scheduled', 'Approved', 'Paid', 'Held', 'Cancelled'],
|
|
327
|
-
required: true,
|
|
328
|
-
section: disbursementSection,
|
|
329
|
-
});
|
|
330
|
-
|
|
331
|
-
const disbursementDateField = new DateField(disbursementObj, {
|
|
332
|
-
apiName: 'disbursement_date__c',
|
|
333
|
-
displayName: 'Disbursement date',
|
|
334
|
-
description: 'Scheduled or actual payment date',
|
|
335
|
-
section: disbursementSection,
|
|
336
|
-
});
|
|
337
|
-
|
|
338
|
-
const grantCountOnProgram = new SummaryField(programObj, {
|
|
48
|
+
const [program, grant, applicant, application, milestone, disbursement] = registerManifestCustomObjects(
|
|
49
|
+
manifest,
|
|
50
|
+
{
|
|
51
|
+
category,
|
|
52
|
+
definitions: [
|
|
53
|
+
programDefinition,
|
|
54
|
+
grantDefinition,
|
|
55
|
+
applicantDefinition,
|
|
56
|
+
applicationDefinition,
|
|
57
|
+
milestoneDefinition,
|
|
58
|
+
disbursementDefinition,
|
|
59
|
+
] as const,
|
|
60
|
+
},
|
|
61
|
+
);
|
|
62
|
+
|
|
63
|
+
const grantCountOnProgram = new SummaryField(program.object, {
|
|
339
64
|
apiName: 'grant_count__c',
|
|
340
65
|
displayName: 'Grants',
|
|
341
|
-
aggregates:
|
|
66
|
+
aggregates: grant.fields.status,
|
|
342
67
|
using: 'COUNT',
|
|
343
|
-
lookup:
|
|
68
|
+
lookup: grant.fields.program_ref,
|
|
344
69
|
description: 'Grant cycles under this program',
|
|
345
|
-
section:
|
|
70
|
+
section: program.sections.program,
|
|
346
71
|
});
|
|
347
72
|
|
|
348
|
-
const applicationCountOnGrant = new SummaryField(
|
|
73
|
+
const applicationCountOnGrant = new SummaryField(grant.object, {
|
|
349
74
|
apiName: 'application_count__c',
|
|
350
75
|
displayName: 'Applications',
|
|
351
|
-
aggregates:
|
|
76
|
+
aggregates: application.fields.applicant_ref,
|
|
352
77
|
using: 'COUNT',
|
|
353
|
-
lookup:
|
|
78
|
+
lookup: application.fields.grant_ref,
|
|
354
79
|
description: 'Applications submitted for this grant',
|
|
355
|
-
section:
|
|
80
|
+
section: grant.sections.grant,
|
|
356
81
|
});
|
|
357
82
|
|
|
358
|
-
const requestedAmountOnGrant = new SummaryField(
|
|
83
|
+
const requestedAmountOnGrant = new SummaryField(grant.object, {
|
|
359
84
|
apiName: 'requested_amount_cents_total__c',
|
|
360
85
|
displayName: 'Requested amount total (cents)',
|
|
361
|
-
aggregates:
|
|
86
|
+
aggregates: application.fields.requested_amount_cents,
|
|
362
87
|
using: 'SUM',
|
|
363
|
-
lookup:
|
|
88
|
+
lookup: application.fields.grant_ref,
|
|
364
89
|
description: 'Total requested funding for this grant',
|
|
365
|
-
section:
|
|
90
|
+
section: grant.sections.grant,
|
|
366
91
|
});
|
|
367
92
|
|
|
368
|
-
const milestoneCountOnApplication = new SummaryField(
|
|
93
|
+
const milestoneCountOnApplication = new SummaryField(application.object, {
|
|
369
94
|
apiName: 'milestone_count__c',
|
|
370
95
|
displayName: 'Milestones',
|
|
371
|
-
aggregates:
|
|
96
|
+
aggregates: milestone.fields.status,
|
|
372
97
|
using: 'COUNT',
|
|
373
|
-
lookup:
|
|
98
|
+
lookup: milestone.fields.application_ref,
|
|
374
99
|
description: 'Milestones attached to this application',
|
|
375
|
-
section:
|
|
100
|
+
section: application.sections.application,
|
|
376
101
|
});
|
|
377
102
|
|
|
378
|
-
const disbursedAmountOnApplication = new SummaryField(
|
|
103
|
+
const disbursedAmountOnApplication = new SummaryField(application.object, {
|
|
379
104
|
apiName: 'disbursed_amount_cents__c',
|
|
380
105
|
displayName: 'Disbursed amount (cents)',
|
|
381
|
-
aggregates:
|
|
106
|
+
aggregates: disbursement.fields.amount_cents,
|
|
382
107
|
using: 'SUM',
|
|
383
|
-
lookup:
|
|
108
|
+
lookup: disbursement.fields.application_ref,
|
|
384
109
|
description: 'Total disbursements for this application',
|
|
385
|
-
section:
|
|
110
|
+
section: application.sections.application,
|
|
386
111
|
});
|
|
387
112
|
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
displayName: 'Review label',
|
|
391
|
-
description: 'Review queue label',
|
|
392
|
-
fieldType: 'TEXT',
|
|
393
|
-
maxLength: 240,
|
|
394
|
-
formula: "CONCATENATE(status__c, ' - score ', review_score__c)",
|
|
395
|
-
section: applicationSection,
|
|
396
|
-
});
|
|
397
|
-
|
|
398
|
-
new Validation(grantObj, {
|
|
113
|
+
// ── Validations & defaults ────────────────────────────────────────────────
|
|
114
|
+
defineTypedValidation(grant, {
|
|
399
115
|
ruleId: 'gpm_grant_close_after_open',
|
|
400
116
|
displayName: 'Close date must be after open date',
|
|
401
|
-
|
|
117
|
+
whenInvalid: (c) => c.lte(c.fields.close_date, c.fields.open_date),
|
|
402
118
|
errorMessage: 'Close date must be after open date.',
|
|
403
119
|
ruleDescription: 'Prevents inverted application windows',
|
|
404
120
|
state: 'ACTIVE',
|
|
405
121
|
level: 'FIELD',
|
|
406
|
-
|
|
122
|
+
field: 'close_date',
|
|
407
123
|
});
|
|
408
124
|
|
|
409
|
-
|
|
125
|
+
defineTypedValidation(application, {
|
|
410
126
|
ruleId: 'gpm_requested_amount_positive',
|
|
411
127
|
displayName: 'Requested amount must be positive',
|
|
412
|
-
|
|
128
|
+
whenInvalid: (c) => c.lte(c.fields.requested_amount_cents, 0),
|
|
413
129
|
errorMessage: 'Requested amount must be greater than zero.',
|
|
414
130
|
ruleDescription: 'Blocks zero-value applications',
|
|
415
131
|
state: 'ACTIVE',
|
|
416
132
|
level: 'FIELD',
|
|
417
|
-
|
|
133
|
+
field: 'requested_amount_cents',
|
|
418
134
|
});
|
|
419
135
|
|
|
420
|
-
|
|
136
|
+
defineTypedValidation(application, {
|
|
421
137
|
ruleId: 'gpm_review_score_range',
|
|
422
138
|
displayName: 'Review score must be 0-100',
|
|
423
|
-
|
|
139
|
+
whenInvalid: (c) => c.or(c.lt(c.fields.review_score, 0), c.gt(c.fields.review_score, 100)),
|
|
424
140
|
errorMessage: 'Review score must be between 0 and 100.',
|
|
425
141
|
ruleDescription: 'Keeps panel scores in range',
|
|
426
142
|
state: 'ACTIVE',
|
|
427
143
|
level: 'FIELD',
|
|
428
|
-
|
|
144
|
+
field: 'review_score',
|
|
429
145
|
});
|
|
430
146
|
|
|
431
|
-
|
|
147
|
+
defineTypedRule(application, {
|
|
432
148
|
flowId: 'gpm_default_application_status',
|
|
433
149
|
flowName: 'Default application status',
|
|
434
150
|
triggerType: 'CREATE',
|
|
435
151
|
description: 'New applications start as Draft',
|
|
436
|
-
actions:
|
|
152
|
+
actions: (rules) => [rules.setField('status').toValue('Draft')],
|
|
437
153
|
});
|
|
438
154
|
|
|
439
|
-
|
|
155
|
+
defineTypedRule(milestone, {
|
|
440
156
|
flowId: 'gpm_default_milestone_status',
|
|
441
157
|
flowName: 'Default milestone status',
|
|
442
158
|
triggerType: 'CREATE',
|
|
443
159
|
description: 'New milestones start Not started',
|
|
444
|
-
actions:
|
|
160
|
+
actions: (rules) => [rules.setField('status').toValue('Not started')],
|
|
445
161
|
});
|
|
446
162
|
|
|
447
|
-
|
|
163
|
+
// ── List views ─────────────────────────────────────────────────────────────
|
|
164
|
+
defineTypedListView(program, {
|
|
448
165
|
viewId: 'view_gpm_programs',
|
|
449
166
|
name: 'Programs',
|
|
450
167
|
description: 'Funding programs with budgets and grant counts',
|
|
451
|
-
fields: ['name',
|
|
168
|
+
fields: ['name', 'focus_area', 'annual_budget_cents', grantCountOnProgram],
|
|
452
169
|
orderBy: 'name',
|
|
453
170
|
sortOrder: 'ASC',
|
|
454
171
|
isPublic: true,
|
|
455
172
|
objectScope: 'all',
|
|
456
173
|
});
|
|
457
174
|
|
|
458
|
-
|
|
175
|
+
defineTypedListView(grant, {
|
|
459
176
|
viewId: 'view_gpm_grants',
|
|
460
177
|
name: 'Grants',
|
|
461
178
|
description: 'Grant cycles with application and requested amount rollups',
|
|
462
179
|
fields: [
|
|
463
180
|
'name',
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
181
|
+
'program_ref',
|
|
182
|
+
'status',
|
|
183
|
+
'open_date',
|
|
184
|
+
'close_date',
|
|
185
|
+
'award_budget_cents',
|
|
469
186
|
applicationCountOnGrant,
|
|
470
187
|
requestedAmountOnGrant,
|
|
471
188
|
],
|
|
472
|
-
orderBy:
|
|
189
|
+
orderBy: 'close_date',
|
|
473
190
|
sortOrder: 'ASC',
|
|
474
191
|
isPublic: true,
|
|
475
192
|
objectScope: 'all',
|
|
476
193
|
});
|
|
477
194
|
|
|
478
|
-
|
|
195
|
+
defineTypedListView(applicant, {
|
|
479
196
|
viewId: 'view_gpm_applicants',
|
|
480
197
|
name: 'Applicants',
|
|
481
198
|
description: 'Applicant directory',
|
|
482
|
-
fields: ['name',
|
|
483
|
-
orderBy:
|
|
199
|
+
fields: ['name', 'legal_name', 'applicant_type', 'contact_email'],
|
|
200
|
+
orderBy: 'legal_name',
|
|
484
201
|
sortOrder: 'ASC',
|
|
485
202
|
isPublic: true,
|
|
486
203
|
objectScope: 'all',
|
|
487
204
|
});
|
|
488
205
|
|
|
489
|
-
|
|
206
|
+
defineTypedListView(application, {
|
|
490
207
|
viewId: 'view_gpm_applications',
|
|
491
208
|
name: 'Applications',
|
|
492
209
|
description: 'Application review queue',
|
|
493
210
|
fields: [
|
|
494
211
|
'name',
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
212
|
+
'grant_ref',
|
|
213
|
+
'applicant_ref',
|
|
214
|
+
'status',
|
|
215
|
+
'requested_amount_cents',
|
|
216
|
+
'review_score',
|
|
500
217
|
milestoneCountOnApplication,
|
|
501
218
|
disbursedAmountOnApplication,
|
|
502
|
-
|
|
219
|
+
'review_label',
|
|
503
220
|
],
|
|
504
|
-
orderBy:
|
|
221
|
+
orderBy: 'review_score',
|
|
505
222
|
sortOrder: 'DESC',
|
|
506
223
|
isPublic: true,
|
|
507
224
|
objectScope: 'all',
|
|
508
225
|
});
|
|
509
226
|
|
|
510
|
-
|
|
227
|
+
defineTypedListView(milestone, {
|
|
511
228
|
viewId: 'view_gpm_milestones',
|
|
512
229
|
name: 'Milestones',
|
|
513
230
|
description: 'Deliverables and report deadlines',
|
|
514
|
-
fields: ['name',
|
|
515
|
-
orderBy:
|
|
231
|
+
fields: ['name', 'application_ref', 'due_date', 'status'],
|
|
232
|
+
orderBy: 'due_date',
|
|
516
233
|
sortOrder: 'ASC',
|
|
517
234
|
isPublic: true,
|
|
518
235
|
objectScope: 'all',
|
|
519
236
|
});
|
|
520
237
|
|
|
521
|
-
|
|
238
|
+
defineTypedListView(disbursement, {
|
|
522
239
|
viewId: 'view_gpm_disbursements',
|
|
523
240
|
name: 'Disbursements',
|
|
524
241
|
description: 'Payment tranches by application',
|
|
525
|
-
fields: [
|
|
526
|
-
|
|
527
|
-
disbursementApplicationRef,
|
|
528
|
-
disbursementAmountCentsField,
|
|
529
|
-
disbursementStatusField,
|
|
530
|
-
disbursementDateField,
|
|
531
|
-
],
|
|
532
|
-
orderBy: disbursementDateField,
|
|
242
|
+
fields: ['name', 'application_ref', 'amount_cents', 'status', 'disbursement_date'],
|
|
243
|
+
orderBy: 'disbursement_date',
|
|
533
244
|
sortOrder: 'ASC',
|
|
534
245
|
isPublic: true,
|
|
535
246
|
objectScope: 'all',
|
|
536
247
|
});
|
|
537
248
|
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
249
|
+
// ── Page layouts ───────────────────────────────────────────────────────────
|
|
250
|
+
defineBasicTypedPageLayout(program, {
|
|
251
|
+
section: program.sections.program,
|
|
252
|
+
fields: ['name', 'focus_area', 'annual_budget_cents', grantCountOnProgram, 'guidelines'],
|
|
541
253
|
});
|
|
542
254
|
|
|
543
|
-
|
|
544
|
-
section:
|
|
255
|
+
defineBasicTypedPageLayout(grant, {
|
|
256
|
+
section: grant.sections.grant,
|
|
545
257
|
fields: [
|
|
546
258
|
'name',
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
259
|
+
'program_ref',
|
|
260
|
+
'status',
|
|
261
|
+
'open_date',
|
|
262
|
+
'close_date',
|
|
263
|
+
'award_budget_cents',
|
|
552
264
|
applicationCountOnGrant,
|
|
553
265
|
requestedAmountOnGrant,
|
|
554
266
|
],
|
|
555
267
|
});
|
|
556
268
|
|
|
557
|
-
|
|
558
|
-
section:
|
|
559
|
-
fields: ['name',
|
|
269
|
+
defineBasicTypedPageLayout(applicant, {
|
|
270
|
+
section: applicant.sections.applicant,
|
|
271
|
+
fields: ['name', 'legal_name', 'applicant_type', 'contact_email'],
|
|
560
272
|
});
|
|
561
273
|
|
|
562
|
-
|
|
563
|
-
section:
|
|
274
|
+
defineBasicTypedPageLayout(application, {
|
|
275
|
+
section: application.sections.application,
|
|
564
276
|
fields: [
|
|
565
277
|
'name',
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
278
|
+
'grant_ref',
|
|
279
|
+
'applicant_ref',
|
|
280
|
+
'status',
|
|
281
|
+
'requested_amount_cents',
|
|
282
|
+
'review_score',
|
|
571
283
|
milestoneCountOnApplication,
|
|
572
284
|
disbursedAmountOnApplication,
|
|
573
|
-
|
|
574
|
-
|
|
285
|
+
'review_label',
|
|
286
|
+
'proposal_summary',
|
|
575
287
|
],
|
|
576
288
|
});
|
|
577
289
|
|
|
578
|
-
|
|
579
|
-
section:
|
|
580
|
-
fields: ['name',
|
|
290
|
+
defineBasicTypedPageLayout(milestone, {
|
|
291
|
+
section: milestone.sections.milestone,
|
|
292
|
+
fields: ['name', 'application_ref', 'due_date', 'status'],
|
|
581
293
|
});
|
|
582
294
|
|
|
583
|
-
|
|
584
|
-
section:
|
|
585
|
-
fields: [
|
|
586
|
-
'name',
|
|
587
|
-
disbursementApplicationRef,
|
|
588
|
-
disbursementAmountCentsField,
|
|
589
|
-
disbursementStatusField,
|
|
590
|
-
disbursementDateField,
|
|
591
|
-
],
|
|
295
|
+
defineBasicTypedPageLayout(disbursement, {
|
|
296
|
+
section: disbursement.sections.disbursement,
|
|
297
|
+
fields: ['name', 'application_ref', 'amount_cents', 'status', 'disbursement_date'],
|
|
592
298
|
});
|
|
593
299
|
|
|
594
300
|
console.log(manifest.preview());
|