From 6130efd3dbf1ac5a7386eac32f816e603fdadca8 Mon Sep 17 00:00:00 2001 From: Jeremi Joslin Date: Mon, 9 Feb 2026 10:45:06 +0700 Subject: [PATCH 1/4] feat(spp_change_request_v2): add Submit button and statusbar to all detail forms Add header with Submit for Approval / Resubmit buttons and approval state statusbar to all CR detail form views, enabling users to submit directly from the detail form. --- .../views/detail_add_member_views.xml | 46 ++++++++---- .../views/detail_change_hoh_views.xml | 37 ++++++++- .../views/detail_create_group_views.xml | 39 ++++++++-- .../views/detail_edit_group_views.xml | 42 ++++++++--- .../views/detail_edit_individual_views.xml | 48 ++++++++---- .../views/detail_exit_registrant_views.xml | 49 ++++++++++-- .../views/detail_merge_registrants_views.xml | 52 ++++++++++--- .../views/detail_remove_member_views.xml | 26 ++++++- .../views/detail_split_household_views.xml | 75 ++++++++++++++----- .../views/detail_transfer_member_views.xml | 34 ++++++++- .../views/detail_update_id_views.xml | 47 ++++++++++-- 11 files changed, 403 insertions(+), 92 deletions(-) diff --git a/spp_change_request_v2/views/detail_add_member_views.xml b/spp_change_request_v2/views/detail_add_member_views.xml index a66beaa8..d64c989c 100644 --- a/spp_change_request_v2/views/detail_add_member_views.xml +++ b/spp_change_request_v2/views/detail_add_member_views.xml @@ -6,6 +6,27 @@ spp.cr.detail.add_member
+
+

Add Member to Group

@@ -13,39 +34,38 @@ - - + + - - - + + + - - - + + + - - + + - + - + - diff --git a/spp_change_request_v2/views/detail_change_hoh_views.xml b/spp_change_request_v2/views/detail_change_hoh_views.xml index 937a62df..251879c3 100644 --- a/spp_change_request_v2/views/detail_change_hoh_views.xml +++ b/spp_change_request_v2/views/detail_change_hoh_views.xml @@ -6,6 +6,27 @@ spp.cr.detail.change_hoh
+
+
@@ -19,7 +40,11 @@ domain="[('id', 'in', available_individual_ids)]" required="1" /> - + @@ -28,11 +53,17 @@ - + - +
diff --git a/spp_change_request_v2/views/detail_create_group_views.xml b/spp_change_request_v2/views/detail_create_group_views.xml index ca023698..01e92be7 100644 --- a/spp_change_request_v2/views/detail_create_group_views.xml +++ b/spp_change_request_v2/views/detail_create_group_views.xml @@ -6,10 +6,31 @@ spp.cr.detail.create_group
+
+
- + @@ -26,16 +47,22 @@ - + - - - + + + - + diff --git a/spp_change_request_v2/views/detail_edit_group_views.xml b/spp_change_request_v2/views/detail_edit_group_views.xml index 99e3ba18..eff11c88 100644 --- a/spp_change_request_v2/views/detail_edit_group_views.xml +++ b/spp_change_request_v2/views/detail_edit_group_views.xml @@ -6,45 +6,65 @@ spp.cr.detail.edit_group +
+

Edit Group Information

- - + + - + - - + + - - + + - - + +
- +
- diff --git a/spp_change_request_v2/views/detail_edit_individual_views.xml b/spp_change_request_v2/views/detail_edit_individual_views.xml index f46d8164..8d0eb349 100644 --- a/spp_change_request_v2/views/detail_edit_individual_views.xml +++ b/spp_change_request_v2/views/detail_edit_individual_views.xml @@ -6,48 +6,68 @@ spp.cr.detail.edit_individual
+
+

Edit Individual Information

- - + + - - - - + + + + - - + + - - + + - - + +
- +
- diff --git a/spp_change_request_v2/views/detail_exit_registrant_views.xml b/spp_change_request_v2/views/detail_exit_registrant_views.xml index 8f067fd5..f31d919f 100644 --- a/spp_change_request_v2/views/detail_exit_registrant_views.xml +++ b/spp_change_request_v2/views/detail_exit_registrant_views.xml @@ -6,12 +6,36 @@ spp.cr.detail.exit_registrant
+
+
- - + + @@ -19,16 +43,29 @@ - - - + + + - +
diff --git a/spp_change_request_v2/views/detail_merge_registrants_views.xml b/spp_change_request_v2/views/detail_merge_registrants_views.xml index 8c10b60b..ea80f7e3 100644 --- a/spp_change_request_v2/views/detail_merge_registrants_views.xml +++ b/spp_change_request_v2/views/detail_merge_registrants_views.xml @@ -6,19 +6,44 @@ spp.cr.detail.merge_registrants
+
+
- + - + @@ -29,13 +54,17 @@

Select duplicate registrants to merge into the primary. - Only groupsindividuals can be selected. + Only groupsindividuals can be selected.

- + @@ -49,7 +78,10 @@ - +
diff --git a/spp_change_request_v2/views/detail_remove_member_views.xml b/spp_change_request_v2/views/detail_remove_member_views.xml index 980fc602..1d057256 100644 --- a/spp_change_request_v2/views/detail_remove_member_views.xml +++ b/spp_change_request_v2/views/detail_remove_member_views.xml @@ -6,6 +6,27 @@ spp.cr.detail.remove_member
+
+
@@ -25,7 +46,10 @@ - +
diff --git a/spp_change_request_v2/views/detail_split_household_views.xml b/spp_change_request_v2/views/detail_split_household_views.xml index fab4a07d..76e8b73e 100644 --- a/spp_change_request_v2/views/detail_split_household_views.xml +++ b/spp_change_request_v2/views/detail_split_household_views.xml @@ -6,22 +6,51 @@ spp.cr.detail.split_household
+
+
- + - - + + @@ -34,27 +63,34 @@ Select individuals to move from the source household to create a new household. The household head cannot be moved.

- + - - + + - - + + @@ -79,7 +115,10 @@ - + diff --git a/spp_change_request_v2/views/detail_transfer_member_views.xml b/spp_change_request_v2/views/detail_transfer_member_views.xml index aace4bfd..82d7435e 100644 --- a/spp_change_request_v2/views/detail_transfer_member_views.xml +++ b/spp_change_request_v2/views/detail_transfer_member_views.xml @@ -6,6 +6,27 @@ spp.cr.detail.transfer_member +
+
@@ -18,10 +39,14 @@ required="1" /> - + - + @@ -32,7 +57,10 @@
- +
diff --git a/spp_change_request_v2/views/detail_update_id_views.xml b/spp_change_request_v2/views/detail_update_id_views.xml index 30192b98..2342b6ab 100644 --- a/spp_change_request_v2/views/detail_update_id_views.xml +++ b/spp_change_request_v2/views/detail_update_id_views.xml @@ -6,6 +6,27 @@ spp.cr.detail.update_id
+
+
@@ -17,9 +38,15 @@ - - + + @@ -28,14 +55,20 @@ - - + + - + - +
From 33dbbc7f3f064da2cb15982f6bd056d46dfe47c5 Mon Sep 17 00:00:00 2001 From: Jeremi Joslin Date: Mon, 9 Feb 2026 10:44:28 +0700 Subject: [PATCH 2/4] fix(spp_change_request_v2): use Datetime.now() for membership start_date fields.Date.today() produces midnight UTC, which displays incorrectly in non-UTC timezones. The membership start_date field is a Datetime, so use fields.Datetime.now() to record the actual time the member was added. --- spp_change_request_v2/strategies/add_member.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spp_change_request_v2/strategies/add_member.py b/spp_change_request_v2/strategies/add_member.py index f7d1b6b1..8690ddda 100644 --- a/spp_change_request_v2/strategies/add_member.py +++ b/spp_change_request_v2/strategies/add_member.py @@ -54,7 +54,7 @@ def apply(self, change_request): membership_vals = { "group": group.id, "individual": individual.id, - "start_date": fields.Date.today(), + "start_date": fields.Datetime.now(), } # Handle relationship/membership type From ed508f837736e1dbe7c2957483bb9979417a40b4 Mon Sep 17 00:00:00 2001 From: Edwin Gonzales Date: Mon, 9 Feb 2026 17:17:53 +0800 Subject: [PATCH 3/4] feat(spp_change_request_v2): replace New button with create wizard on All Requests list Override the default New button in the All Requests list view to open the create wizard (spp.cr.create.wizard) instead of the form view, matching the behavior of the "New Request" menu item. Follows the same ListController patch pattern used by spp_programs. --- spp_change_request_v2/__manifest__.py | 2 + .../static/src/js/create_change_request.js | 35 +++++++++++++++++ .../xml/create_change_request_template.xml | 38 +++++++++++++++++++ 3 files changed, 75 insertions(+) create mode 100644 spp_change_request_v2/static/src/js/create_change_request.js create mode 100644 spp_change_request_v2/static/src/xml/create_change_request_template.xml diff --git a/spp_change_request_v2/__manifest__.py b/spp_change_request_v2/__manifest__.py index 3ae9b69b..58d42781 100644 --- a/spp_change_request_v2/__manifest__.py +++ b/spp_change_request_v2/__manifest__.py @@ -62,6 +62,8 @@ "assets": { "web.assets_backend": [ "spp_change_request_v2/static/src/components/**/*", + "spp_change_request_v2/static/src/js/create_change_request.js", + "spp_change_request_v2/static/src/xml/create_change_request_template.xml", ], }, "installable": True, diff --git a/spp_change_request_v2/static/src/js/create_change_request.js b/spp_change_request_v2/static/src/js/create_change_request.js new file mode 100644 index 00000000..d5c27031 --- /dev/null +++ b/spp_change_request_v2/static/src/js/create_change_request.js @@ -0,0 +1,35 @@ +/** @odoo-module **/ + +import {ListController} from "@web/views/list/list_controller"; +import {onWillStart} from "@odoo/owl"; +import {patch} from "@web/core/utils/patch"; +import {user} from "@web/core/user"; +import {useService} from "@web/core/utils/hooks"; + +patch(ListController.prototype, { + setup() { + super.setup(); + this.actionService = useService("action"); + onWillStart(async () => { + const is_admin = await user.hasGroup("spp_security.group_spp_admin"); + const is_cr_user = await user.hasGroup( + "spp_change_request_v2.group_cr_user" + ); + this.canCreateChangeRequest = is_admin || is_cr_user; + }); + }, + + async loadChangeRequestWizard() { + if (this.model.root.resModel !== "spp.change.request") { + return; + } + await this.actionService.doAction( + "spp_change_request_v2.action_cr_create_wizard", + { + onClose: async () => { + await this.model.root.load(); + }, + } + ); + }, +}); diff --git a/spp_change_request_v2/static/src/xml/create_change_request_template.xml b/spp_change_request_v2/static/src/xml/create_change_request_template.xml new file mode 100644 index 00000000..18e6088b --- /dev/null +++ b/spp_change_request_v2/static/src/xml/create_change_request_template.xml @@ -0,0 +1,38 @@ + + + + + + + + + + + + + + + + + + + + model.root.resModel != 'spp.change.request' + + + + From 9e7eb4b0f376d465f3743bcc62301f4aaa0f7e40 Mon Sep 17 00:00:00 2001 From: Edwin Gonzales Date: Tue, 10 Feb 2026 10:45:51 +0800 Subject: [PATCH 4/4] fix(spp_change_request_v2): fix test failures from vocabulary protection and missing CR types - Remove deleted default_types.xml and stale manifest comment, since CR types are now provided by spp_cr_types_base/spp_cr_types_advanced - Add get_or_create_cr_type() and get_or_create_membership_kind() test helpers in common.py so tests create required data dynamically instead of relying on env.ref() lookups that fail without type modules installed - Add CRTestCase base class with shared setup for registrants and CR creation - Fix get_or_create_membership_kind() to pass is_local=True when creating codes on system vocabularies (required by spp_vocabulary protection) - Fix AttributeError in add_member and transfer_member preview strategies: spp.vocabulary.code uses 'display' field, not 'name' - Remove redundant skipTest guards across all strategy test files - Fix JS/XML formatting (prettier) --- endpoint_route_handler/README.rst | 38 +- .../static/description/index.html | 4 +- eslint.config.cjs | 2 +- spp_alerts/README.rst | 56 +-- spp_api_v2/README.rst | 118 +++--- spp_api_v2/static/description/index.html | 8 +- spp_api_v2_change_request/README.rst | 91 +++-- .../static/description/index.html | 11 +- spp_api_v2_cycles/README.rst | 40 +- spp_api_v2_data/README.rst | 42 +-- spp_api_v2_data/static/description/index.html | 8 +- spp_api_v2_entitlements/README.rst | 68 ++-- .../static/description/index.html | 4 +- spp_api_v2_products/README.rst | 59 ++- .../static/description/index.html | 7 +- spp_api_v2_service_points/README.rst | 56 +-- .../static/description/index.html | 4 +- spp_api_v2_vocabulary/README.rst | 72 ++-- .../static/description/index.html | 8 +- spp_approval/README.rst | 147 ++++---- spp_approval/static/description/index.html | 24 +- spp_area/README.rst | 93 +++-- spp_area/static/description/index.html | 14 +- spp_area_hdx/README.rst | 96 ++--- spp_audit/README.rst | 111 +++--- spp_audit/static/description/index.html | 10 +- spp_banking/README.rst | 45 +-- spp_banking/static/description/index.html | 11 +- spp_base_common/README.rst | 57 ++- spp_base_common/static/description/index.html | 11 +- spp_base_setting/README.rst | 46 +-- .../static/description/index.html | 8 +- spp_branding_kit/README.rst | 78 ++-- spp_cel_domain/README.rst | 132 ++++--- spp_cel_domain/static/description/index.html | 29 +- spp_cel_event/README.rst | 38 +- spp_cel_event/static/description/index.html | 4 +- spp_cel_registry_search/README.rst | 57 ++- .../static/description/index.html | 10 +- spp_cel_vocabulary/README.rst | 42 +-- .../static/description/index.html | 4 +- spp_cel_widget/README.rst | 138 ++++--- spp_cel_widget/static/description/index.html | 17 +- spp_change_request_v2/README.rst | 239 ++++++------ spp_change_request_v2/__manifest__.py | 2 - spp_change_request_v2/data/default_types.xml | 279 -------------- .../static/description/index.html | 56 ++- .../static/src/js/create_change_request.js | 4 +- .../xml/create_change_request_template.xml | 14 +- .../strategies/add_member.py | 2 +- .../strategies/transfer_member.py | 2 +- spp_change_request_v2/tests/common.py | 119 ++++++ .../tests/test_add_member_strategy.py | 21 +- .../tests/test_change_hoh_strategy.py | 23 +- .../tests/test_create_group_strategy.py | 21 +- .../tests/test_e2e_workflows.py | 86 +---- .../tests/test_exit_registrant_strategy.py | 21 +- .../tests/test_merge_registrants_strategy.py | 25 +- .../tests/test_remove_member_strategy.py | 19 +- .../tests/test_split_household_strategy.py | 29 +- .../tests/test_transfer_member_strategy.py | 27 +- .../tests/test_update_id_strategy.py | 23 +- spp_claim_169/README.rst | 108 +++--- spp_consent/README.rst | 226 ++++++----- spp_consent/static/description/index.html | 55 ++- spp_cr_types_advanced/README.rst | 100 ++--- .../static/description/index.html | 66 ++-- spp_cr_types_base/README.rst | 107 +++--- .../static/description/index.html | 24 +- spp_custom_field/README.rst | 74 ++-- .../static/description/index.html | 8 +- spp_dci/README.rst | 83 ++--- spp_dci/static/description/index.html | 13 +- spp_dci_client/README.rst | 60 +-- spp_dci_client/static/description/index.html | 18 +- spp_dci_client_crvs/README.rst | 70 ++-- .../static/description/index.html | 16 +- spp_dci_client_dr/README.rst | 98 ++--- .../static/description/index.html | 20 +- spp_dci_client_ibr/README.rst | 105 +++--- .../static/description/index.html | 54 ++- spp_dci_server/README.rst | 94 ++--- spp_dci_server/static/description/index.html | 8 +- spp_demo/README.rst | 135 ++++--- spp_demo/static/description/index.html | 25 +- spp_dms/README.rst | 102 ++--- spp_dms/static/description/index.html | 11 +- spp_drims/README.rst | 127 ++++--- spp_drims/static/description/index.html | 33 +- spp_drims_sl/README.rst | 77 ++-- spp_drims_sl/static/description/index.html | 9 +- spp_drims_sl_demo/README.rst | 86 ++--- .../static/description/index.html | 8 +- spp_event_data/README.rst | 106 +++--- spp_event_data/static/description/index.html | 20 +- spp_gis/README.rst | 110 +++--- spp_gis/static/description/index.html | 15 +- spp_gis_report/README.rst | 153 ++++---- spp_gis_report/static/description/index.html | 23 +- spp_gis_report_programs/README.rst | 78 ++-- .../static/description/index.html | 17 +- spp_grm/README.rst | 126 +++---- spp_grm/static/description/index.html | 12 +- spp_grm_demo/README.rst | 66 ++-- spp_hazard/README.rst | 125 +++---- spp_hazard/static/description/index.html | 31 +- spp_hide_menus_base/README.rst | 56 +-- .../static/description/index.html | 19 +- spp_key_management/README.rst | 157 ++++---- .../static/description/index.html | 17 +- spp_mis_demo_v2/README.rst | 77 ++-- spp_mis_demo_v2/static/description/index.html | 3 +- spp_programs/README.rst | 352 +++++++++--------- spp_programs/static/description/index.html | 75 ++-- spp_registry/README.rst | 131 +++---- spp_registry/static/description/index.html | 41 +- spp_registry_search/README.rst | 94 ++--- .../static/description/index.html | 14 +- spp_security/README.rst | 55 ++- spp_security/static/description/index.html | 17 +- spp_service_points/README.rst | 72 ++-- .../static/description/index.html | 14 +- spp_source_tracking/README.rst | 89 +++-- .../static/description/index.html | 9 +- spp_starter_social_registry/README.rst | 20 +- spp_starter_sp_mis/README.rst | 74 ++-- .../static/description/index.html | 8 +- spp_studio/README.rst | 142 ++++--- spp_studio/static/description/index.html | 25 +- spp_studio_api_v2/README.rst | 103 +++-- .../static/description/index.html | 21 +- spp_studio_change_requests/README.rst | 102 +++-- .../static/description/index.html | 28 +- spp_studio_events/README.rst | 128 ++++--- .../static/description/index.html | 31 +- spp_user_roles/README.rst | 94 ++--- spp_user_roles/static/description/index.html | 19 +- spp_versioning/README.rst | 64 ++-- spp_versioning/static/description/index.html | 7 +- spp_vocabulary/README.rst | 92 +++-- spp_vocabulary/static/description/index.html | 16 +- 141 files changed, 3786 insertions(+), 4312 deletions(-) delete mode 100644 spp_change_request_v2/data/default_types.xml diff --git a/endpoint_route_handler/README.rst b/endpoint_route_handler/README.rst index bcf37b6f..5ea91c0a 100644 --- a/endpoint_route_handler/README.rst +++ b/endpoint_route_handler/README.rst @@ -119,31 +119,31 @@ You can see a real life example on shopfloor.app model. Known issues / Roadmap ====================== -- add api docs helpers +- add api docs helpers -- allow multiple HTTP methods on the same endpoint +- allow multiple HTTP methods on the same endpoint -- multiple values for route and methods +- multiple values for route and methods - keep the same in the ui for now, later own we can imagine a - multi-value selection or just add text field w/ proper validation - and cleanup + keep the same in the ui for now, later own we can imagine a + multi-value selection or just add text field w/ proper validation + and cleanup - remove the route field in the table of endpoint_route + remove the route field in the table of endpoint_route - support a comma separated list of routes maybe support comma - separated list of methods use only routing.routes for generating - the rule sort and freeze its values to update the endpoint hash + support a comma separated list of routes maybe support comma + separated list of methods use only routing.routes for generating + the rule sort and freeze its values to update the endpoint hash - catch dup route exception on the sync to detect duplicated routes - and use the endpoint_hash to retrieve the real record (note: we - could store more info in the routing information which will stay - in the map) + catch dup route exception on the sync to detect duplicated routes + and use the endpoint_hash to retrieve the real record (note: we + could store more info in the routing information which will stay in + the map) - for customizing the rule behavior the endpoint the hook is to - override the registry lookup + for customizing the rule behavior the endpoint the hook is to + override the registry lookup - make EndpointRule class overridable on the registry + make EndpointRule class overridable on the registry NOTE in v16 we won't care anymore about odoo controller so the lookup of the controller can be simplified to a basic py obj that holds the @@ -170,8 +170,8 @@ Authors Contributors ------------ -- Simone Orsi -- Nguyen Minh Chien +- Simone Orsi +- Nguyen Minh Chien Maintainers ----------- diff --git a/endpoint_route_handler/static/description/index.html b/endpoint_route_handler/static/description/index.html index 0e4b7c3b..2bbee3c1 100644 --- a/endpoint_route_handler/static/description/index.html +++ b/endpoint_route_handler/static/description/index.html @@ -482,8 +482,8 @@

Known issues / Roadmap

the rule sort and freeze its values to update the endpoint hash

catch dup route exception on the sync to detect duplicated routes and use the endpoint_hash to retrieve the real record (note: we -could store more info in the routing information which will stay -in the map)

+could store more info in the routing information which will stay in +the map)

for customizing the rule behavior the endpoint the hook is to override the registry lookup

make EndpointRule class overridable on the registry

diff --git a/eslint.config.cjs b/eslint.config.cjs index fcbc5be9..1b5fef12 100644 --- a/eslint.config.cjs +++ b/eslint.config.cjs @@ -207,7 +207,7 @@ const config = [ }, }, { - files: ["**/*.esm.js", "**/*test.js"], + files: ["**/*.esm.js", "**/*test.js", "**/static/src/**/*.js"], languageOptions: { ecmaVersion: 2024, diff --git a/spp_alerts/README.rst b/spp_alerts/README.rst index c52aafec..eb007e39 100644 --- a/spp_alerts/README.rst +++ b/spp_alerts/README.rst @@ -35,27 +35,27 @@ domain-specific conditions. Key Capabilities ~~~~~~~~~~~~~~~~ -- Track alert lifecycle through state machine: active → acknowledged → - resolved -- Record resolution details including user, timestamp, and notes -- Classify alerts by type using ``spp.vocabulary`` codes (threshold, - expiry, deadline, manual, system) -- Prioritize alerts as low, medium, high, or critical -- Send mail notifications via ``mail.thread`` integration -- Auto-generate alert references in ALR-YYYY-NNNNN format +- Track alert lifecycle through state machine: active → acknowledged → + resolved +- Record resolution details including user, timestamp, and notes +- Classify alerts by type using ``spp.vocabulary`` codes (threshold, + expiry, deadline, manual, system) +- Prioritize alerts as low, medium, high, or critical +- Send mail notifications via ``mail.thread`` integration +- Auto-generate alert references in ALR-YYYY-NNNNN format Key Models ~~~~~~~~~~ -+--------------------+------------------------------------------------+ -| Model | Description | -+====================+================================================+ -| ``spp.alert`` | Alert instance with state tracking and | -| | resolution workflow | -+--------------------+------------------------------------------------+ -| ``spp.alert.rule`` | Rule configuration for monitoring criteria and | -| | thresholds | -+--------------------+------------------------------------------------+ ++--------------------+-------------------------------------------------+ +| Model | Description | ++====================+=================================================+ +| ``spp.alert`` | Alert instance with state tracking and | +| | resolution workflow | ++--------------------+-------------------------------------------------+ +| ``spp.alert.rule`` | Rule configuration for monitoring criteria and | +| | thresholds | ++--------------------+-------------------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -71,9 +71,9 @@ After installing: UI Location ~~~~~~~~~~~ -- **Menu**: Settings > Technical > Alerts > Alerts -- **Configuration**: Settings > Technical > Alerts > Alert Rules -- **Form Tabs**: Details, Resolution (alerts); Thresholds (rules) +- **Menu**: Settings > Technical > Alerts > Alerts +- **Configuration**: Settings > Technical > Alerts > Alert Rules +- **Form Tabs**: Details, Resolution (alerts); Thresholds (rules) Security ~~~~~~~~ @@ -89,14 +89,14 @@ Group Access Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``spp.alert`` to add domain-specific fields (e.g., stock - levels, document references) -- Inherit ``spp.alert.rule`` to add custom threshold or evaluation - criteria -- Override ``action_acknowledge()`` or ``action_resolve()`` to add - custom workflow steps -- Consumer modules implement alert checking via cron jobs or event - handlers that evaluate rules and call ``create()`` on ``spp.alert`` +- Inherit ``spp.alert`` to add domain-specific fields (e.g., stock + levels, document references) +- Inherit ``spp.alert.rule`` to add custom threshold or evaluation + criteria +- Override ``action_acknowledge()`` or ``action_resolve()`` to add + custom workflow steps +- Consumer modules implement alert checking via cron jobs or event + handlers that evaluate rules and call ``create()`` on ``spp.alert`` Dependencies ~~~~~~~~~~~~ diff --git a/spp_api_v2/README.rst b/spp_api_v2/README.rst index a05edc06..ad203fcd 100644 --- a/spp_api_v2/README.rst +++ b/spp_api_v2/README.rst @@ -31,38 +31,38 @@ all identifiers use namespace URIs for global interoperability. Key Capabilities ---------------- -- **OAuth 2.0 Authentication**: Client credentials flow with - scrypt-hashed secrets, scoped access -- **Consent-Based Access Control**: All reads require active consent, - filtered by organization type -- **External Identifiers Only**: Namespace URIs for lookups, vocabulary - IDs for coded values -- **Source Tracking**: Records data provenance per ADR-008 -- **Extension Registry**: Domain modules register custom fields via - ``spp.api.extension`` -- **Batch Operations**: Create/update multiple registrants per request +- **OAuth 2.0 Authentication**: Client credentials flow with + scrypt-hashed secrets, scoped access +- **Consent-Based Access Control**: All reads require active consent, + filtered by organization type +- **External Identifiers Only**: Namespace URIs for lookups, vocabulary + IDs for coded values +- **Source Tracking**: Records data provenance per ADR-008 +- **Extension Registry**: Domain modules register custom fields via + ``spp.api.extension`` +- **Batch Operations**: Create/update multiple registrants per request Key Models ---------- -+---------------------------+-----------------------------------------+ -| Model | Description | -+===========================+=========================================+ -| ``spp.api.client`` | OAuth 2.0 credentials, organization | -| | verification | -+---------------------------+-----------------------------------------+ -| ``spp.api.client.scope`` | Resource/action permissions | -+---------------------------+-----------------------------------------+ -| ``spp.api.path`` | Endpoint configuration and filters | -+---------------------------+-----------------------------------------+ -| ``spp.api.path.filter`` | Field-level filter configurations | -+---------------------------+-----------------------------------------+ -| ``spp.api.filter.preset`` | Saved filter combinations | -+---------------------------+-----------------------------------------+ -| ``spp.api.extension`` | Domain field registry | -+---------------------------+-----------------------------------------+ -| ``spp.consent.scope`` | Resource types per consent | -+---------------------------+-----------------------------------------+ ++---------------------------+------------------------------------------+ +| Model | Description | ++===========================+==========================================+ +| ``spp.api.client`` | OAuth 2.0 credentials, organization | +| | verification | ++---------------------------+------------------------------------------+ +| ``spp.api.client.scope`` | Resource/action permissions | ++---------------------------+------------------------------------------+ +| ``spp.api.path`` | Endpoint configuration and filters | ++---------------------------+------------------------------------------+ +| ``spp.api.path.filter`` | Field-level filter configurations | ++---------------------------+------------------------------------------+ +| ``spp.api.filter.preset`` | Saved filter combinations | ++---------------------------+------------------------------------------+ +| ``spp.api.extension`` | Domain field registry | ++---------------------------+------------------------------------------+ +| ``spp.consent.scope`` | Resource types per consent | ++---------------------------+------------------------------------------+ UI Location ----------- @@ -70,29 +70,29 @@ UI Location Navigate to **Registry > Configuration > API V2** for all API configuration. Available submenus: -- **API Clients** - Manage OAuth credentials and organization - verification -- **API Extensions** - View registered custom field extensions -- **API Paths** - Configure available endpoints and static filters -- **API Filters** - Define queryable field filters per path -- **Filter Presets** - Create named filter combinations +- **API Clients** - Manage OAuth credentials and organization + verification +- **API Extensions** - View registered custom field extensions +- **API Paths** - Configure available endpoints and static filters +- **API Filters** - Define queryable field filters per path +- **Filter Presets** - Create named filter combinations **API Client Form Tabs:** -- **Consent & Security** - Consent requirements, legal basis, - organization type verification -- **Scopes** - Resource/action permissions and program restrictions -- **Description** - Client documentation +- **Consent & Security** - Consent requirements, legal basis, + organization type verification +- **Scopes** - Resource/action permissions and program restrictions +- **Description** - Client documentation **API Extension Form Tabs:** -- **Fields** - Registered custom fields from domain modules -- **JSON Schema** - Auto-generated schema for extension fields +- **Fields** - Registered custom fields from domain modules +- **JSON Schema** - Auto-generated schema for extension fields **API Path Form Tabs:** -- **Filters** - Field-level filter configurations (inline editable) -- **Presets** - Saved filter combinations (inline editable) +- **Filters** - Field-level filter configurations (inline editable) +- **Presets** - Saved filter combinations (inline editable) Configuration ------------- @@ -111,27 +111,27 @@ API endpoints available at ``/api/v2/`` (token endpoint: Security -------- -+--------------------------+------------------------------------------+ -| Group | Access | -+==========================+==========================================+ -| ``group_api_v2_viewer`` | Read-only: all API configuration and | -| | consent | -+--------------------------+------------------------------------------+ -| ``group_api_v2_officer`` | Read/Write: all models (no | -| | create/delete), full CRUD on consent | -| | scopes | -+--------------------------+------------------------------------------+ -| ``group_api_v2_manager`` | Full CRUD: clients, scopes, paths, | -| | filters, presets, extensions; | -| | Read/Write/Create on consent (no delete) | -+--------------------------+------------------------------------------+ ++--------------------------+-------------------------------------------+ +| Group | Access | ++==========================+===========================================+ +| ``group_api_v2_viewer`` | Read-only: all API configuration and | +| | consent | ++--------------------------+-------------------------------------------+ +| ``group_api_v2_officer`` | Read/Write: all models (no | +| | create/delete), full CRUD on consent | +| | scopes | ++--------------------------+-------------------------------------------+ +| ``group_api_v2_manager`` | Full CRUD: clients, scopes, paths, | +| | filters, presets, extensions; | +| | Read/Write/Create on consent (no delete) | ++--------------------------+-------------------------------------------+ Extension Points ---------------- -- Inherit ``spp.api.extension`` to register custom fields -- Override ``_get_fastapi_routers()`` in ``fastapi.endpoint`` for - custom endpoints +- Inherit ``spp.api.extension`` to register custom fields +- Override ``_get_fastapi_routers()`` in ``fastapi.endpoint`` for custom + endpoints Dependencies ------------ diff --git a/spp_api_v2/static/description/index.html b/spp_api_v2/static/description/index.html index 0e3ac85b..09fec322 100644 --- a/spp_api_v2/static/description/index.html +++ b/spp_api_v2/static/description/index.html @@ -398,8 +398,8 @@

Key Capabilities

Key Models

--++ @@ -509,8 +509,8 @@

Security

Extension Points

  • Inherit spp.api.extension to register custom fields
  • -
  • Override _get_fastapi_routers() in fastapi.endpoint for -custom endpoints
  • +
  • Override _get_fastapi_routers() in fastapi.endpoint for custom +endpoints
diff --git a/spp_api_v2_change_request/README.rst b/spp_api_v2_change_request/README.rst index da93d182..46de4ee4 100644 --- a/spp_api_v2_change_request/README.rst +++ b/spp_api_v2_change_request/README.rst @@ -35,36 +35,35 @@ numbers (CR/2024/00001) instead of database IDs for all operations. Key Capabilities ~~~~~~~~~~~~~~~~ -- Create change requests in draft status with registrant and detail - data -- Read individual change requests by reference or search with filters - (registrant, type, status, dates) -- Update detail data on draft change requests with optimistic locking - via If-Match headers -- Submit draft requests for approval workflow -- Approve, reject, or request revision on pending requests (requires - approval scope) -- Apply approved change requests to registrant records -- Reset rejected/revision requests to draft for resubmission +- Create change requests in draft status with registrant and detail data +- Read individual change requests by reference or search with filters + (registrant, type, status, dates) +- Update detail data on draft change requests with optimistic locking + via If-Match headers +- Submit draft requests for approval workflow +- Approve, reject, or request revision on pending requests (requires + approval scope) +- Apply approved change requests to registrant records +- Reset rejected/revision requests to draft for resubmission Key Models ~~~~~~~~~~ This module extends existing models and does not define new ones. -+-----------------------------+---------------------------------------+ -| Model | Usage | -+=============================+=======================================+ -| ``fastapi.endpoint`` | Extended to register ChangeRequest | -| | router with API V2 | -+-----------------------------+---------------------------------------+ -| ``spp.change.request`` | CRUD operations via REST API | -+-----------------------------+---------------------------------------+ -| ``spp.change.request.type`` | Looked up by code in create requests | -+-----------------------------+---------------------------------------+ -| ``spp.registry.id`` | Used to resolve registrant | -| | identifiers (system|value) | -+-----------------------------+---------------------------------------+ ++-----------------------------+----------------------------------------+ +| Model | Usage | ++=============================+========================================+ +| ``fastapi.endpoint`` | Extended to register ChangeRequest | +| | router with API V2 | ++-----------------------------+----------------------------------------+ +| ``spp.change.request`` | CRUD operations via REST API | ++-----------------------------+----------------------------------------+ +| ``spp.change.request.type`` | Looked up by code in create requests | ++-----------------------------+----------------------------------------+ +| ``spp.registry.id`` | Used to resolve registrant identifiers | +| | (system|value) | ++-----------------------------+----------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -78,26 +77,26 @@ To configure OAuth 2.0 clients with appropriate scopes: by ``spp_api_v2``) 2. Configure OAuth 2.0 clients with appropriate scopes: - - ``change_request:read`` - Read and search change requests - - ``change_request:create`` - Create new change requests - - ``change_request:update`` - Update, submit, and reset requests - - ``change_request:approve`` - Approve, reject, or request revision - - ``change_request:apply`` - Apply approved changes to registrants + - ``change_request:read`` - Read and search change requests + - ``change_request:create`` - Create new change requests + - ``change_request:update`` - Update, submit, and reset requests + - ``change_request:approve`` - Approve, reject, or request revision + - ``change_request:apply`` - Apply approved changes to registrants API Endpoints ~~~~~~~~~~~~~ -- ``POST /ChangeRequest`` - Create new change request -- ``GET /ChangeRequest/{reference}`` - Read by reference -- ``GET /ChangeRequest`` - Search with filters -- ``PUT /ChangeRequest/{reference}`` - Update detail data -- ``POST /ChangeRequest/{reference}/$submit`` - Submit for approval -- ``POST /ChangeRequest/{reference}/$approve`` - Approve request -- ``POST /ChangeRequest/{reference}/$reject`` - Reject request -- ``POST /ChangeRequest/{reference}/$request-revision`` - Request - revision -- ``POST /ChangeRequest/{reference}/$apply`` - Apply to registrant -- ``POST /ChangeRequest/{reference}/$reset`` - Reset to draft +- ``POST /ChangeRequest`` - Create new change request +- ``GET /ChangeRequest/{reference}`` - Read by reference +- ``GET /ChangeRequest`` - Search with filters +- ``PUT /ChangeRequest/{reference}`` - Update detail data +- ``POST /ChangeRequest/{reference}/$submit`` - Submit for approval +- ``POST /ChangeRequest/{reference}/$approve`` - Approve request +- ``POST /ChangeRequest/{reference}/$reject`` - Reject request +- ``POST /ChangeRequest/{reference}/$request-revision`` - Request + revision +- ``POST /ChangeRequest/{reference}/$apply`` - Apply to registrant +- ``POST /ChangeRequest/{reference}/$reset`` - Reset to draft Security ~~~~~~~~ @@ -110,12 +109,12 @@ enforces scope checks on each endpoint. Users must authenticate via the Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``ChangeRequestService`` to customize serialization, - validation, or business logic -- Override router endpoint functions to add custom validation or side - effects -- Extend the API schema by inheriting the Pydantic models in - ``schemas/change_request.py`` +- Inherit ``ChangeRequestService`` to customize serialization, + validation, or business logic +- Override router endpoint functions to add custom validation or side + effects +- Extend the API schema by inheriting the Pydantic models in + ``schemas/change_request.py`` UI Location ~~~~~~~~~~~ diff --git a/spp_api_v2_change_request/static/description/index.html b/spp_api_v2_change_request/static/description/index.html index 0462e9c5..488a58c0 100644 --- a/spp_api_v2_change_request/static/description/index.html +++ b/spp_api_v2_change_request/static/description/index.html @@ -383,8 +383,7 @@

OpenSPP API V2 - Change Request

Key Capabilities

    -
  • Create change requests in draft status with registrant and detail -data
  • +
  • Create change requests in draft status with registrant and detail data
  • Read individual change requests by reference or search with filters (registrant, type, status, dates)
  • Update detail data on draft change requests with optimistic locking @@ -401,8 +400,8 @@

    Key Models

    This module extends existing models and does not define new ones.

Model
--++ @@ -421,8 +420,8 @@

Key Models

- +
Model Looked up by code in create requests
spp.registry.idUsed to resolve registrant -identifiers (system|value)Used to resolve registrant identifiers +(system|value)
diff --git a/spp_api_v2_cycles/README.rst b/spp_api_v2_cycles/README.rst index 4d72c04e..f1160191 100644 --- a/spp_api_v2_cycles/README.rst +++ b/spp_api_v2_cycles/README.rst @@ -31,18 +31,18 @@ and requires OAuth 2.0 authentication with resource-based scopes. Key Capabilities ~~~~~~~~~~~~~~~~ -- **Read Cycle**: Retrieve cycle details by name via - ``GET /Cycle/{identifier}`` -- **Search Cycles**: Filter cycles by program, state, start/end dates, - or last updated timestamp -- **Pagination**: Support for offset-based pagination with configurable - page size (max 100) -- **Statistics**: Expose beneficiary count, entitlement count, payment - count, and total amounts -- **Cycle Navigation**: Reference to previous and next cycles in - sequence -- **OAuth Scopes**: Extend API client scopes with ``cycle`` resource - type for read operations +- **Read Cycle**: Retrieve cycle details by name via + ``GET /Cycle/{identifier}`` +- **Search Cycles**: Filter cycles by program, state, start/end dates, + or last updated timestamp +- **Pagination**: Support for offset-based pagination with configurable + page size (max 100) +- **Statistics**: Expose beneficiary count, entitlement count, payment + count, and total amounts +- **Cycle Navigation**: Reference to previous and next cycles in + sequence +- **OAuth Scopes**: Extend API client scopes with ``cycle`` resource + type for read operations Key Models ~~~~~~~~~~ @@ -71,8 +71,8 @@ UI Location No standalone menu. API endpoints are available at: -- ``/api/v2/spp/Cycle`` - Search cycles -- ``/api/v2/spp/Cycle/{identifier}`` - Read cycle by name +- ``/api/v2/spp/Cycle`` - Search cycles +- ``/api/v2/spp/Cycle/{identifier}`` - Read cycle by name Security ~~~~~~~~ @@ -88,12 +88,12 @@ existing models. Extension Points ~~~~~~~~~~~~~~~~ -- Override ``CycleService.to_api_schema()`` to add custom fields to the - API response -- Inherit ``Cycle`` schema to add domain-specific attributes in the - ``extension`` field -- Add search filters by extending ``CycleService.search()`` to support - additional query parameters +- Override ``CycleService.to_api_schema()`` to add custom fields to the + API response +- Inherit ``Cycle`` schema to add domain-specific attributes in the + ``extension`` field +- Add search filters by extending ``CycleService.search()`` to support + additional query parameters Dependencies ~~~~~~~~~~~~ diff --git a/spp_api_v2_data/README.rst b/spp_api_v2_data/README.rst index 5ce73391..dbb818f2 100644 --- a/spp_api_v2_data/README.rst +++ b/spp_api_v2_data/README.rst @@ -32,14 +32,14 @@ identifiers for subject resolution and provider-based access control. Key Capabilities ~~~~~~~~~~~~~~~~ -- **Push values**: Bulk upsert variable values from external systems - with validation and error reporting -- **Pull values**: Retrieve cached variable values by subject external - IDs and period keys -- **Invalidate cache**: Mark cached values as stale to force refresh on - next computation -- **List variables**: Query available variables with provider and - source type filtering +- **Push values**: Bulk upsert variable values from external systems + with validation and error reporting +- **Pull values**: Retrieve cached variable values by subject external + IDs and period keys +- **Invalidate cache**: Mark cached values as stale to force refresh on + next computation +- **List variables**: Query available variables with provider and source + type filtering Key Models ~~~~~~~~~~ @@ -73,13 +73,13 @@ No standalone menus (API-only module). **API Endpoints**: -- ``POST /api/v2/Data/push`` - Push variable values from external - systems -- ``GET /api/v2/Data/pull`` - Pull cached variable values for subjects -- ``POST /api/v2/Data/invalidate`` - Invalidate cached values to force - refresh -- ``GET /api/v2/Data/variables`` - List available variables with - filtering +- ``POST /api/v2/Data/push`` - Push variable values from external + systems +- ``GET /api/v2/Data/pull`` - Pull cached variable values for subjects +- ``POST /api/v2/Data/invalidate`` - Invalidate cached values to force + refresh +- ``GET /api/v2/Data/variables`` - List available variables with + filtering Security ~~~~~~~~ @@ -100,12 +100,12 @@ operations. Extension Points ~~~~~~~~~~~~~~~~ -- Override ``_resolve_subject_id()`` in ``routers/data.py`` to - customize external identifier resolution -- Extend Pydantic schemas in ``schemas/data.py`` to add metadata fields - for domain-specific use cases -- Inherit ``DataValueInput`` or ``DataValueOutput`` for additional - validation logic +- Override ``_resolve_subject_id()`` in ``routers/data.py`` to customize + external identifier resolution +- Extend Pydantic schemas in ``schemas/data.py`` to add metadata fields + for domain-specific use cases +- Inherit ``DataValueInput`` or ``DataValueOutput`` for additional + validation logic Dependencies ~~~~~~~~~~~~ diff --git a/spp_api_v2_data/static/description/index.html b/spp_api_v2_data/static/description/index.html index ef39e4d4..21932005 100644 --- a/spp_api_v2_data/static/description/index.html +++ b/spp_api_v2_data/static/description/index.html @@ -389,8 +389,8 @@

Key Capabilities

IDs and period keys
  • Invalidate cache: Mark cached values as stale to force refresh on next computation
  • -
  • List variables: Query available variables with provider and -source type filtering
  • +
  • List variables: Query available variables with provider and source +type filtering
  • @@ -472,8 +472,8 @@

    Security

    Extension Points

      -
    • Override _resolve_subject_id() in routers/data.py to -customize external identifier resolution
    • +
    • Override _resolve_subject_id() in routers/data.py to customize +external identifier resolution
    • Extend Pydantic schemas in schemas/data.py to add metadata fields for domain-specific use cases
    • Inherit DataValueInput or DataValueOutput for additional diff --git a/spp_api_v2_entitlements/README.rst b/spp_api_v2_entitlements/README.rst index aeb5e5c5..e53f0786 100644 --- a/spp_api_v2_entitlements/README.rst +++ b/spp_api_v2_entitlements/README.rst @@ -31,29 +31,29 @@ by beneficiary, program, cycle, state, and validity dates. Key Capabilities ~~~~~~~~~~~~~~~~ -- **Read Entitlement**: Retrieve entitlement by code (UUID-based - identifier) via ``GET /Entitlement/{identifier}`` -- **Search Entitlements**: Query with filters (beneficiary, program, - cycle, state, type, dates) via ``GET /Entitlement`` -- **Cash and In-Kind**: Supports both ``spp.entitlement`` (cash) and - ``spp.entitlement.inkind`` models -- **Pagination**: Returns paginated bundles with next/previous links - (max 100 per page) -- **Scope-Based Access**: Requires ``entitlement:read`` OAuth scope for - all operations +- **Read Entitlement**: Retrieve entitlement by code (UUID-based + identifier) via ``GET /Entitlement/{identifier}`` +- **Search Entitlements**: Query with filters (beneficiary, program, + cycle, state, type, dates) via ``GET /Entitlement`` +- **Cash and In-Kind**: Supports both ``spp.entitlement`` (cash) and + ``spp.entitlement.inkind`` models +- **Pagination**: Returns paginated bundles with next/previous links + (max 100 per page) +- **Scope-Based Access**: Requires ``entitlement:read`` OAuth scope for + all operations Key Models ~~~~~~~~~~ -+--------------------------+------------------------------------------+ -| Model | Description | -+==========================+==========================================+ -| ``spp.api.client.scope`` | Extended to add ``entitlement`` as | -| | resource type | -+--------------------------+------------------------------------------+ -| ``fastapi.endpoint`` | Extended to register entitlement router | -| | for ``api_v2`` app | -+--------------------------+------------------------------------------+ ++--------------------------+-------------------------------------------+ +| Model | Description | ++==========================+===========================================+ +| ``spp.api.client.scope`` | Extended to add ``entitlement`` as | +| | resource type | ++--------------------------+-------------------------------------------+ +| ``fastapi.endpoint`` | Extended to register entitlement router | +| | for ``api_v2`` app | ++--------------------------+-------------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -71,9 +71,9 @@ UI Location No UI components. This is a backend API module accessed via HTTP: -- **Read**: ``GET /api/v2/spp/Entitlement/{code}`` -- **Search**: - ``GET /api/v2/spp/Entitlement?beneficiary={system|value}&program={name}...`` +- **Read**: ``GET /api/v2/spp/Entitlement/{code}`` +- **Search**: + ``GET /api/v2/spp/Entitlement?beneficiary={system|value}&program={name}...`` Security ~~~~~~~~ @@ -81,22 +81,22 @@ Security No model access rules defined in this module. Security is enforced via OAuth 2.0 client scopes: -- API clients must have ``entitlement:read`` scope (via - ``spp.api.client.scope`` records) -- Authorization is validated at the router level via - ``api_client.has_scope("entitlement", "read")`` -- Underlying entitlement model access is governed by ``spp_programs`` - module security +- API clients must have ``entitlement:read`` scope (via + ``spp.api.client.scope`` records) +- Authorization is validated at the router level via + ``api_client.has_scope("entitlement", "read")`` +- Underlying entitlement model access is governed by ``spp_programs`` + module security Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``EntitlementService`` and override ``to_api_schema()`` to - add custom fields to the API response -- Extend ``Entitlement`` Pydantic schema to expose additional - entitlement attributes -- Override ``_search_cash()`` or ``_search_inkind()`` to customize - search domain logic +- Inherit ``EntitlementService`` and override ``to_api_schema()`` to add + custom fields to the API response +- Extend ``Entitlement`` Pydantic schema to expose additional + entitlement attributes +- Override ``_search_cash()`` or ``_search_inkind()`` to customize + search domain logic Dependencies ~~~~~~~~~~~~ diff --git a/spp_api_v2_entitlements/static/description/index.html b/spp_api_v2_entitlements/static/description/index.html index 7a4a7847..4d965711 100644 --- a/spp_api_v2_entitlements/static/description/index.html +++ b/spp_api_v2_entitlements/static/description/index.html @@ -454,8 +454,8 @@

      Security

      Extension Points

        -
      • Inherit EntitlementService and override to_api_schema() to -add custom fields to the API response
      • +
      • Inherit EntitlementService and override to_api_schema() to add +custom fields to the API response
      • Extend Entitlement Pydantic schema to expose additional entitlement attributes
      • Override _search_cash() or _search_inkind() to customize diff --git a/spp_api_v2_products/README.rst b/spp_api_v2_products/README.rst index 137c75c1..c39dd4b9 100644 --- a/spp_api_v2_products/README.rst +++ b/spp_api_v2_products/README.rst @@ -32,29 +32,28 @@ external identifiers. Key Capabilities ~~~~~~~~~~~~~~~~ -- Search and retrieve products by default_code (SKU) or name -- Query product categories for classification and filtering -- List units of measure with category filtering -- Paginated search with filters: name, code, category, last updated - date -- OAuth 2.0 authentication with "product" resource scope -- Returns JSON responses with references to related resources - (category, UoM) +- Search and retrieve products by default_code (SKU) or name +- Query product categories for classification and filtering +- List units of measure with category filtering +- Paginated search with filters: name, code, category, last updated date +- OAuth 2.0 authentication with "product" resource scope +- Returns JSON responses with references to related resources (category, + UoM) Key Models ~~~~~~~~~~ This module extends existing models rather than introducing new ones: -+--------------------------+------------------------------------------+ -| Model | Extension | -+==========================+==========================================+ -| ``spp.api.client.scope`` | Adds "product" resource type for scope | -| | management | -+--------------------------+------------------------------------------+ -| ``fastapi.endpoint`` | Registers Product, ProductCategory, UoM | -| | routers | -+--------------------------+------------------------------------------+ ++--------------------------+-------------------------------------------+ +| Model | Extension | ++==========================+===========================================+ +| ``spp.api.client.scope`` | Adds "product" resource type for scope | +| | management | ++--------------------------+-------------------------------------------+ +| ``fastapi.endpoint`` | Registers Product, ProductCategory, UoM | +| | routers | ++--------------------------+-------------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -73,14 +72,14 @@ No standalone menu. This is an API-only module. **API Endpoints**: -- ``GET /api/v2/spp/Product`` - Search products -- ``GET /api/v2/spp/Product/{identifier}`` - Read product by code or - name -- ``GET /api/v2/spp/ProductCategory`` - Search categories -- ``GET /api/v2/spp/ProductCategory/{identifier}`` - Read category by - name -- ``GET /api/v2/spp/UnitOfMeasure`` - Search units of measure -- ``GET /api/v2/spp/UnitOfMeasure/{identifier}`` - Read UoM by name +- ``GET /api/v2/spp/Product`` - Search products +- ``GET /api/v2/spp/Product/{identifier}`` - Read product by code or + name +- ``GET /api/v2/spp/ProductCategory`` - Search categories +- ``GET /api/v2/spp/ProductCategory/{identifier}`` - Read category by + name +- ``GET /api/v2/spp/UnitOfMeasure`` - Search units of measure +- ``GET /api/v2/spp/UnitOfMeasure/{identifier}`` - Read UoM by name **Configuration**: Registry > Configuration > API V2 > API Clients @@ -100,11 +99,11 @@ layer through OAuth scopes. Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``ProductService``, ``ProductCategoryService``, or - ``UomService`` to customize API responses -- Override ``to_api_schema()`` methods to add fields to Product, - ProductCategory, or UnitOfMeasure schemas -- Override ``search()`` methods to add custom filtering logic +- Inherit ``ProductService``, ``ProductCategoryService``, or + ``UomService`` to customize API responses +- Override ``to_api_schema()`` methods to add fields to Product, + ProductCategory, or UnitOfMeasure schemas +- Override ``search()`` methods to add custom filtering logic Dependencies ~~~~~~~~~~~~ diff --git a/spp_api_v2_products/static/description/index.html b/spp_api_v2_products/static/description/index.html index f5833575..7793c6b1 100644 --- a/spp_api_v2_products/static/description/index.html +++ b/spp_api_v2_products/static/description/index.html @@ -386,11 +386,10 @@

        Key Capabilities

      • Search and retrieve products by default_code (SKU) or name
      • Query product categories for classification and filtering
      • List units of measure with category filtering
      • -
      • Paginated search with filters: name, code, category, last updated -date
      • +
      • Paginated search with filters: name, code, category, last updated date
      • OAuth 2.0 authentication with “product” resource scope
      • -
      • Returns JSON responses with references to related resources -(category, UoM)
      • +
      • Returns JSON responses with references to related resources (category, +UoM)
      diff --git a/spp_api_v2_service_points/README.rst b/spp_api_v2_service_points/README.rst index 685988ea..67efa9d7 100644 --- a/spp_api_v2_service_points/README.rst +++ b/spp_api_v2_service_points/README.rst @@ -31,30 +31,30 @@ external identifiers to avoid exposing database IDs. Key Capabilities ~~~~~~~~~~~~~~~~ -- Search service points by name, area, country, contract status, and - last updated date -- Read individual service points by identifier (name) -- Paginate search results with configurable page size (1-100 records) -- Filter service points by contract active status and geographic - criteria -- Return metadata including version IDs and last updated timestamps for - optimistic locking -- Enforce OAuth 2.0 authentication and scope-based authorization +- Search service points by name, area, country, contract status, and + last updated date +- Read individual service points by identifier (name) +- Paginate search results with configurable page size (1-100 records) +- Filter service points by contract active status and geographic + criteria +- Return metadata including version IDs and last updated timestamps for + optimistic locking +- Enforce OAuth 2.0 authentication and scope-based authorization Extended Models ~~~~~~~~~~~~~~~ This module extends existing models from dependencies: -+--------------------------+------------------------------------------+ -| Model | Description | -+==========================+==========================================+ -| ``spp.api.client.scope`` | Extended to add "service_point" resource | -| | type for OAuth scopes | -+--------------------------+------------------------------------------+ -| ``fastapi.endpoint`` | Extended to register Service Point | -| | router in API V2 app | -+--------------------------+------------------------------------------+ ++--------------------------+-------------------------------------------+ +| Model | Description | ++==========================+===========================================+ +| ``spp.api.client.scope`` | Extended to add "service_point" resource | +| | type for OAuth scopes | ++--------------------------+-------------------------------------------+ +| ``fastapi.endpoint`` | Extended to register Service Point router | +| | in API V2 app | ++--------------------------+-------------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -72,10 +72,10 @@ base module: API Endpoints ~~~~~~~~~~~~~ -- ``GET /api/v2/spp/ServicePoint/{identifier}`` - Read service point by - identifier (URL-encoded name) -- ``GET /api/v2/spp/ServicePoint?name=&area=&country=&contractActive=&_lastUpdated=&_count=&_offset=`` - - Search service points +- ``GET /api/v2/spp/ServicePoint/{identifier}`` - Read service point by + identifier (URL-encoded name) +- ``GET /api/v2/spp/ServicePoint?name=&area=&country=&contractActive=&_lastUpdated=&_count=&_offset=`` + - Search service points Security ~~~~~~~~ @@ -88,12 +88,12 @@ client with appropriate scope. No model-level access rules defined Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``ServicePointService.to_api_schema()`` to add custom fields - to API response -- Override ``ServicePointService.search()`` to customize search domain - logic -- Extend ``ServicePoint`` schema to add module-specific fields in - ``extension`` attribute +- Inherit ``ServicePointService.to_api_schema()`` to add custom fields + to API response +- Override ``ServicePointService.search()`` to customize search domain + logic +- Extend ``ServicePoint`` schema to add module-specific fields in + ``extension`` attribute Dependencies ~~~~~~~~~~~~ diff --git a/spp_api_v2_service_points/static/description/index.html b/spp_api_v2_service_points/static/description/index.html index 7fa89e8c..35c42373 100644 --- a/spp_api_v2_service_points/static/description/index.html +++ b/spp_api_v2_service_points/static/description/index.html @@ -412,8 +412,8 @@

      Extended Models

      type for OAuth scopes fastapi.endpoint -Extended to register Service Point -router in API V2 app +Extended to register Service Point router +in API V2 app diff --git a/spp_api_v2_vocabulary/README.rst b/spp_api_v2_vocabulary/README.rst index 31127350..9f0e420e 100644 --- a/spp_api_v2_vocabulary/README.rst +++ b/spp_api_v2_vocabulary/README.rst @@ -33,44 +33,44 @@ present. Key Capabilities ~~~~~~~~~~~~~~~~ -- List all available vocabularies with domain filtering and pagination -- Retrieve vocabulary metadata including name, version, description, - and reference URL -- Fetch codes within a vocabulary with support for hierarchical - structures -- Filter codes by parent (for hierarchical vocabularies) and - include/exclude deprecated codes -- Validate namespace URIs for security (path traversal, null bytes, - control characters) +- List all available vocabularies with domain filtering and pagination +- Retrieve vocabulary metadata including name, version, description, and + reference URL +- Fetch codes within a vocabulary with support for hierarchical + structures +- Filter codes by parent (for hierarchical vocabularies) and + include/exclude deprecated codes +- Validate namespace URIs for security (path traversal, null bytes, + control characters) Key Models ~~~~~~~~~~ -+--------------------------+------------------------------------------+ -| Model | Description | -+==========================+==========================================+ -| ``spp.vocabulary`` | Vocabulary definitions exposed via GET | -| | endpoints | -+--------------------------+------------------------------------------+ -| ``spp.vocabulary.code`` | Individual codes within vocabularies | -+--------------------------+------------------------------------------+ -| ``spp.api.client.scope`` | Extended to add "vocabulary" resource | -| | type for OAuth | -+--------------------------+------------------------------------------+ -| ``fastapi.endpoint`` | Extended to register Vocabulary router | -| | in API V2 | -+--------------------------+------------------------------------------+ ++--------------------------+-------------------------------------------+ +| Model | Description | ++==========================+===========================================+ +| ``spp.vocabulary`` | Vocabulary definitions exposed via GET | +| | endpoints | ++--------------------------+-------------------------------------------+ +| ``spp.vocabulary.code`` | Individual codes within vocabularies | ++--------------------------+-------------------------------------------+ +| ``spp.api.client.scope`` | Extended to add "vocabulary" resource | +| | type for OAuth | ++--------------------------+-------------------------------------------+ +| ``fastapi.endpoint`` | Extended to register Vocabulary router in | +| | API V2 | ++--------------------------+-------------------------------------------+ API Endpoints ~~~~~~~~~~~~~ -- ``GET /Vocabulary`` - List all vocabularies (supports ``domain``, - ``_count``, ``_offset`` query params) -- ``GET /Vocabulary/{namespace_uri}`` - Get vocabulary details by - namespace URI (URL-encoded) -- ``GET /Vocabulary/{namespace_uri}/codes`` - Get codes within a - vocabulary (supports ``parent_code``, ``include_deprecated``, - ``_count``, ``_offset``) +- ``GET /Vocabulary`` - List all vocabularies (supports ``domain``, + ``_count``, ``_offset`` query params) +- ``GET /Vocabulary/{namespace_uri}`` - Get vocabulary details by + namespace URI (URL-encoded) +- ``GET /Vocabulary/{namespace_uri}/codes`` - Get codes within a + vocabulary (supports ``parent_code``, ``include_deprecated``, + ``_count``, ``_offset``) Configuration ~~~~~~~~~~~~~ @@ -88,12 +88,12 @@ modules: Security ~~~~~~~~ -- Requires OAuth 2.0 authentication via ``spp_api_v2`` framework -- Requires "vocabulary" scope with "read" action on API client -- No Odoo security groups required (vocabularies are public data, - endpoints use sudo()) -- Validates namespace URI and parent_code parameters for injection - attacks +- Requires OAuth 2.0 authentication via ``spp_api_v2`` framework +- Requires "vocabulary" scope with "read" action on API client +- No Odoo security groups required (vocabularies are public data, + endpoints use sudo()) +- Validates namespace URI and parent_code parameters for injection + attacks Dependencies ~~~~~~~~~~~~ diff --git a/spp_api_v2_vocabulary/static/description/index.html b/spp_api_v2_vocabulary/static/description/index.html index e573000f..b8ef7d2d 100644 --- a/spp_api_v2_vocabulary/static/description/index.html +++ b/spp_api_v2_vocabulary/static/description/index.html @@ -385,8 +385,8 @@

      OpenSPP API V2 - Vocabulary

      Key Capabilities

      • List all available vocabularies with domain filtering and pagination
      • -
      • Retrieve vocabulary metadata including name, version, description, -and reference URL
      • +
      • Retrieve vocabulary metadata including name, version, description, and +reference URL
      • Fetch codes within a vocabulary with support for hierarchical structures
      • Filter codes by parent (for hierarchical vocabularies) and @@ -420,8 +420,8 @@

        Key Models

        type for OAuth fastapi.endpoint -Extended to register Vocabulary router -in API V2 +Extended to register Vocabulary router in +API V2 diff --git a/spp_approval/README.rst b/spp_approval/README.rst index a9d96c47..60e3abba 100644 --- a/spp_approval/README.rst +++ b/spp_approval/README.rst @@ -32,50 +32,50 @@ submit/approve/reject actions with audit trails and optimistic locking. Key Capabilities ~~~~~~~~~~~~~~~~ -- **Approval Mixin**: Add ``spp.approval.mixin`` to any model to enable - approval workflow with state tracking (``draft``, ``pending``, - ``approved``, ``rejected``, ``revision``) -- **Multi-Tier Workflows**: Define sequential approval tiers with - configurable approver types (security group, specific users, - submitter's manager, or dynamic field) -- **CEL Rules**: Conditional approval routing using Common Expression - Language domain filters -- **Freeze Periods**: System-wide approval suspension during election - bans, audits, or maintenance windows -- **SLA Tracking**: Track approval deadlines per tier with escalation - support -- **Revision Requests**: Approvers can request revisions instead of - outright rejection -- **Optimistic Locking**: Prevents concurrent approval conflicts via - version-based locking +- **Approval Mixin**: Add ``spp.approval.mixin`` to any model to enable + approval workflow with state tracking (``draft``, ``pending``, + ``approved``, ``rejected``, ``revision``) +- **Multi-Tier Workflows**: Define sequential approval tiers with + configurable approver types (security group, specific users, + submitter's manager, or dynamic field) +- **CEL Rules**: Conditional approval routing using Common Expression + Language domain filters +- **Freeze Periods**: System-wide approval suspension during election + bans, audits, or maintenance windows +- **SLA Tracking**: Track approval deadlines per tier with escalation + support +- **Revision Requests**: Approvers can request revisions instead of + outright rejection +- **Optimistic Locking**: Prevents concurrent approval conflicts via + version-based locking Key Models ~~~~~~~~~~ -+------------------------------+--------------------------------------+ -| Model | Description | -+==============================+======================================+ -| ``spp.approval.mixin`` | Abstract mixin providing approval | -| | workflow to inheriting models | -+------------------------------+--------------------------------------+ -| ``spp.approval.definition`` | Configures approval rules, | -| | approvers, and conditions per model | -+------------------------------+--------------------------------------+ -| ``spp.approval.tier`` | Individual tier in a multi-tier | -| | approval sequence | -+------------------------------+--------------------------------------+ -| ``spp.approval.review`` | Tracks individual approval/rejection | -| | actions | -+------------------------------+--------------------------------------+ -| ``spp.approval.tier.review`` | Tracks progress through multi-tier | -| | workflows | -+------------------------------+--------------------------------------+ -| ``spp.approval.freeze`` | Defines system-wide freeze periods | -| | blocking approvals | -+------------------------------+--------------------------------------+ -| ``spp.approval.config`` | System-wide approval configuration | -| | settings | -+------------------------------+--------------------------------------+ ++------------------------------+---------------------------------------+ +| Model | Description | ++==============================+=======================================+ +| ``spp.approval.mixin`` | Abstract mixin providing approval | +| | workflow to inheriting models | ++------------------------------+---------------------------------------+ +| ``spp.approval.definition`` | Configures approval rules, approvers, | +| | and conditions per model | ++------------------------------+---------------------------------------+ +| ``spp.approval.tier`` | Individual tier in a multi-tier | +| | approval sequence | ++------------------------------+---------------------------------------+ +| ``spp.approval.review`` | Tracks individual approval/rejection | +| | actions | ++------------------------------+---------------------------------------+ +| ``spp.approval.tier.review`` | Tracks progress through multi-tier | +| | workflows | ++------------------------------+---------------------------------------+ +| ``spp.approval.freeze`` | Defines system-wide freeze periods | +| | blocking approvals | ++------------------------------+---------------------------------------+ +| ``spp.approval.config`` | System-wide approval configuration | +| | settings | ++------------------------------+---------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -93,43 +93,40 @@ After installing: UI Location ~~~~~~~~~~~ -- **Menu**: Approvals > My Approvals > Pending Approvals -- **Configuration**: Approvals > Configuration > Approval Definitions -- **Freeze Periods**: Approvals > Configuration > Freeze Periods -- **Mixin Integration**: Approval buttons appear on forms of models - inheriting the mixin +- **Menu**: Approvals > My Approvals > Pending Approvals +- **Configuration**: Approvals > Configuration > Approval Definitions +- **Freeze Periods**: Approvals > Configuration > Freeze Periods +- **Mixin Integration**: Approval buttons appear on forms of models + inheriting the mixin Tabs ~~~~ On **Approval Definition** forms: -- **Conditions**: Domain filter to determine which records require this - approval -- **Behavior**: Approval settings (require comment, auto-approve, - notifications) -- **SLA & Escalation**: SLA tracking and escalation rules +- **Conditions**: Domain filter to determine which records require this + approval +- **Behavior**: Approval settings (require comment, auto-approve, + notifications) +- **SLA & Escalation**: SLA tracking and escalation rules Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| ``spp_ | Read approval records | -| approval.group_approval_viewer`` | | -+----------------------------------+----------------------------------+ -| ``spp_a | Read/Write/Create (no delete) | -| pproval.group_approval_officer`` | | -+----------------------------------+----------------------------------+ -| ``spp_a | Read/Write/Create on all models | -| pproval.group_approval_manager`` | (delete only for reviews/config; | -| | definitions and freezes require | -| | admin) | -+----------------------------------+----------------------------------+ -| ``spp_ap | Approve/reject assigned reviews | -| proval.group_approval_approver`` | | -+----------------------------------+----------------------------------+ ++------------------------------------------+----------------------------------+ +| Group | Access | ++==========================================+==================================+ +| ``spp_approval.group_approval_viewer`` | Read approval records | ++------------------------------------------+----------------------------------+ +| ``spp_approval.group_approval_officer`` | Read/Write/Create (no delete) | ++------------------------------------------+----------------------------------+ +| ``spp_approval.group_approval_manager`` | Read/Write/Create on all models | +| | (delete only for reviews/config; | +| | definitions and freezes require | +| | admin) | ++------------------------------------------+----------------------------------+ +| ``spp_approval.group_approval_approver`` | Approve/reject assigned reviews | ++------------------------------------------+----------------------------------+ Note: ``approval_definition`` and ``approval_freeze`` models block deletion for managers via Python override - only system administrators @@ -138,14 +135,14 @@ can delete these records. Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``spp.approval.mixin`` to add approval workflow to any model - inheriting ``mail.thread`` -- Override ``_on_submit()``, ``_on_approve()``, ``_on_reject()``, - ``_on_request_revision()`` hooks for custom logic -- Override ``_get_approval_definition()`` to provide record-specific - approval rules (e.g., from a type field) -- Extend ``spp.approval.definition`` to add custom approver types or - matching logic +- Inherit ``spp.approval.mixin`` to add approval workflow to any model + inheriting ``mail.thread`` +- Override ``_on_submit()``, ``_on_approve()``, ``_on_reject()``, + ``_on_request_revision()`` hooks for custom logic +- Override ``_get_approval_definition()`` to provide record-specific + approval rules (e.g., from a type field) +- Extend ``spp.approval.definition`` to add custom approver types or + matching logic Dependencies ~~~~~~~~~~~~ diff --git a/spp_approval/static/description/index.html b/spp_approval/static/description/index.html index 9395467d..edc6161b 100644 --- a/spp_approval/static/description/index.html +++ b/spp_approval/static/description/index.html @@ -405,8 +405,8 @@

        Key Capabilities

        Key Models

        --++ @@ -419,8 +419,8 @@

        Key Models

        workflow to inheriting models - +
        Model
        spp.approval.definitionConfigures approval rules, -approvers, and conditions per modelConfigures approval rules, approvers, +and conditions per model
        spp.approval.tier Individual tier in a multi-tier @@ -483,8 +483,8 @@

        Tabs

        Security

        --++ @@ -492,23 +492,19 @@

        Security

        - + - + - + - + diff --git a/spp_area/README.rst b/spp_area/README.rst index 02321e30..bd1ab16b 100644 --- a/spp_area/README.rst +++ b/spp_area/README.rst @@ -32,44 +32,44 @@ area types. Key Capabilities ~~~~~~~~~~~~~~~~ -- Define hierarchical area structures with up to 10 levels (country, - province, district, etc.) -- Assign unique codes and multi-language names to each area -- Import bulk area data from Excel files in COD (Common Operational - Dataset) format from HDX -- Tag areas with classifications (urban, remote, priority) for - filtering and reporting -- Link registrants and groups to their geographical areas -- Restrict user access to specific geographic areas via role-based area - assignments -- Automatically detect and activate required languages during import +- Define hierarchical area structures with up to 10 levels (country, + province, district, etc.) +- Assign unique codes and multi-language names to each area +- Import bulk area data from Excel files in COD (Common Operational + Dataset) format from HDX +- Tag areas with classifications (urban, remote, priority) for filtering + and reporting +- Link registrants and groups to their geographical areas +- Restrict user access to specific geographic areas via role-based area + assignments +- Automatically detect and activate required languages during import Key Models ~~~~~~~~~~ -+----------------------------------+----------------------------------+ -| Model | Description | -+==================================+==================================+ -| ``spp.area`` | Hierarchical geographical area | -| | with code and name | -+----------------------------------+----------------------------------+ -| ``spp.area.kind`` | Area type definition (country, | -| | province, district, etc.) | -+----------------------------------+----------------------------------+ -| ``spp.area.tag`` | Classification tags for areas | -+----------------------------------+----------------------------------+ -| ``spp.area.import`` | Excel import wizard with | -| | validation and bulk processing | -+----------------------------------+----------------------------------+ -| ``spp.area.import.raw`` | Staging table for import | -| | validation | -+----------------------------------+----------------------------------+ -| ``spp.area.import.json`` | Parsed JSON storage from Excel | -| | files | -+----------------------------------+----------------------------------+ -| ``s | Wizard for activating languages | -| pp.area.import.language.wizard`` | during import | -+----------------------------------+----------------------------------+ ++-------------------------------------+----------------------------------+ +| Model | Description | ++=====================================+==================================+ +| ``spp.area`` | Hierarchical geographical area | +| | with code and name | ++-------------------------------------+----------------------------------+ +| ``spp.area.kind`` | Area type definition (country, | +| | province, district, etc.) | ++-------------------------------------+----------------------------------+ +| ``spp.area.tag`` | Classification tags for areas | ++-------------------------------------+----------------------------------+ +| ``spp.area.import`` | Excel import wizard with | +| | validation and bulk processing | ++-------------------------------------+----------------------------------+ +| ``spp.area.import.raw`` | Staging table for import | +| | validation | ++-------------------------------------+----------------------------------+ +| ``spp.area.import.json`` | Parsed JSON storage from Excel | +| | files | ++-------------------------------------+----------------------------------+ +| ``spp.area.import.language.wizard`` | Wizard for activating languages | +| | during import | ++-------------------------------------+----------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -87,12 +87,12 @@ After installing: UI Location ~~~~~~~~~~~ -- **Area Menu**: Area > Areas > Area -- **Area Type Menu**: Area > Areas > Area Type -- **Area Tags Menu**: Area > Areas > Area Tags -- **Import Menu**: Area > Areas > Area Import -- **Registrant Form**: Area field appears on registrant and group - profile forms +- **Area Menu**: Area > Areas > Area +- **Area Type Menu**: Area > Areas > Area Type +- **Area Tags Menu**: Area > Areas > Area Tags +- **Import Menu**: Area > Areas > Area Import +- **Registrant Form**: Area field appears on registrant and group + profile forms Views and Tabs ~~~~~~~~~~~~~~ @@ -120,13 +120,12 @@ Group Access Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``spp.area`` to add custom fields or computed attributes -- Override ``_prepare_domain()`` in models to customize area-based - filtering logic -- Extend ``spp.area.import.raw`` to add custom validation rules for - imports -- Inherit ``spp.area.tag`` to add domain-specific classification - schemes +- Inherit ``spp.area`` to add custom fields or computed attributes +- Override ``_prepare_domain()`` in models to customize area-based + filtering logic +- Extend ``spp.area.import.raw`` to add custom validation rules for + imports +- Inherit ``spp.area.tag`` to add domain-specific classification schemes Dependencies ~~~~~~~~~~~~ diff --git a/spp_area/static/description/index.html b/spp_area/static/description/index.html index 05ad5632..14eebee6 100644 --- a/spp_area/static/description/index.html +++ b/spp_area/static/description/index.html @@ -388,8 +388,8 @@

        Key Capabilities

      • Assign unique codes and multi-language names to each area
      • Import bulk area data from Excel files in COD (Common Operational Dataset) format from HDX
      • -
      • Tag areas with classifications (urban, remote, priority) for -filtering and reporting
      • +
      • Tag areas with classifications (urban, remote, priority) for filtering +and reporting
      • Link registrants and groups to their geographical areas
      • Restrict user access to specific geographic areas via role-based area assignments
      • @@ -400,8 +400,8 @@

        Key Capabilities

        Key Models

        Group
        spp_ -approval.group_approval_viewer
        spp_approval.group_approval_viewer Read approval records
        spp_a -pproval.group_approval_officer
        spp_approval.group_approval_officer Read/Write/Create (no delete)
        spp_a -pproval.group_approval_manager
        spp_approval.group_approval_manager Read/Write/Create on all models (delete only for reviews/config; definitions and freezes require admin)
        spp_ap -proval.group_approval_approver
        spp_approval.group_approval_approver Approve/reject assigned reviews
        --++ @@ -432,8 +432,7 @@

        Key Models

        - + @@ -525,8 +524,7 @@

        Extension Points

        filtering logic
      • Extend spp.area.import.raw to add custom validation rules for imports
      • -
      • Inherit spp.area.tag to add domain-specific classification -schemes
      • +
      • Inherit spp.area.tag to add domain-specific classification schemes
      • diff --git a/spp_area_hdx/README.rst b/spp_area_hdx/README.rst index 2f169731..ff094d8e 100644 --- a/spp_area_hdx/README.rst +++ b/spp_area_hdx/README.rst @@ -35,36 +35,36 @@ area lookup using PostGIS spatial queries. Key Capabilities ~~~~~~~~~~~~~~~~ -- Sync COD dataset metadata from HDX API by country -- Auto-detect field mappings from GeoJSON (P-code, name, parent P-code) - using HXL tags -- Import admin boundaries with polygons from HDX or manually uploaded - GeoJSON files -- Match imported features to existing areas by P-code or create new - areas -- GPS-based area lookup using PostGIS ``ST_Contains`` for - point-in-polygon queries -- Standardize area identification with HDX P-codes for inter-agency - coordination +- Sync COD dataset metadata from HDX API by country +- Auto-detect field mappings from GeoJSON (P-code, name, parent P-code) + using HXL tags +- Import admin boundaries with polygons from HDX or manually uploaded + GeoJSON files +- Match imported features to existing areas by P-code or create new + areas +- GPS-based area lookup using PostGIS ``ST_Contains`` for + point-in-polygon queries +- Standardize area identification with HDX P-codes for inter-agency + coordination Key Models ~~~~~~~~~~ -+-------------------------------+-------------------------------------+ -| Model | Description | -+===============================+=====================================+ -| ``spp.hdx.cod.source`` | Tracks COD datasets available from | -| | HDX (one per country) | -+-------------------------------+-------------------------------------+ -| ``spp.hdx.cod.resource`` | Individual admin level dataset | -| | within a COD (e.g., Level 3) | -+-------------------------------+-------------------------------------+ -| ``spp.hdx.cod.import.wizard`` | Multi-step wizard to download from | -| | HDX or upload GeoJSON | -+-------------------------------+-------------------------------------+ -| ``spp.area`` (extended) | Adds ``hdx_pcode`` field and GPS | -| | lookup methods | -+-------------------------------+-------------------------------------+ ++-------------------------------+--------------------------------------+ +| Model | Description | ++===============================+======================================+ +| ``spp.hdx.cod.source`` | Tracks COD datasets available from | +| | HDX (one per country) | ++-------------------------------+--------------------------------------+ +| ``spp.hdx.cod.resource`` | Individual admin level dataset | +| | within a COD (e.g., Level 3) | ++-------------------------------+--------------------------------------+ +| ``spp.hdx.cod.import.wizard`` | Multi-step wizard to download from | +| | HDX or upload GeoJSON | ++-------------------------------+--------------------------------------+ +| ``spp.area`` (extended) | Adds ``hdx_pcode`` field and GPS | +| | lookup methods | ++-------------------------------+--------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -83,36 +83,36 @@ After installing: UI Location ~~~~~~~~~~~ -- **Menu**: Area > Areas > HDX Integration > COD Sources -- **Import**: Area > Areas > HDX Integration > Import COD -- **Area Records**: Extended with HDX P-code field visible in area form - view +- **Menu**: Area > Areas > HDX Integration > COD Sources +- **Import**: Area > Areas > HDX Integration > Import COD +- **Area Records**: Extended with HDX P-code field visible in area form + view Security ~~~~~~~~ -+-----------------------+---------------------------------------------+ -| Group | Access | -+=======================+=============================================+ -| ``group_hdx_user`` | Read access to COD sources and resources | -+-----------------------+---------------------------------------------+ -| ``group_hdx_manager`` | Full CRUD on sources/resources, sync from | -| | HDX, run imports | -+-----------------------+---------------------------------------------+ ++-----------------------+----------------------------------------------+ +| Group | Access | ++=======================+==============================================+ +| ``group_hdx_user`` | Read access to COD sources and resources | ++-----------------------+----------------------------------------------+ +| ``group_hdx_manager`` | Full CRUD on sources/resources, sync from | +| | HDX, run imports | ++-----------------------+----------------------------------------------+ Extension Points ~~~~~~~~~~~~~~~~ -- ``spp.area.find_by_coordinates(latitude, longitude, level=None)`` - - Find area containing GPS point -- ``spp.area.find_all_containing(latitude, longitude)`` - Find all - areas in hierarchy containing point -- ``spp.area.find_by_pcode(pcode)`` - Find area by HDX P-code or - fallback to code field -- Inherit ``spp.hdx.cod.source`` to add country-specific dataset - discovery logic -- Inherit ``spp.hdx.cod.import.wizard._process_features()`` to - customize import behavior +- ``spp.area.find_by_coordinates(latitude, longitude, level=None)`` - + Find area containing GPS point +- ``spp.area.find_all_containing(latitude, longitude)`` - Find all areas + in hierarchy containing point +- ``spp.area.find_by_pcode(pcode)`` - Find area by HDX P-code or + fallback to code field +- Inherit ``spp.hdx.cod.source`` to add country-specific dataset + discovery logic +- Inherit ``spp.hdx.cod.import.wizard._process_features()`` to customize + import behavior Dependencies ~~~~~~~~~~~~ diff --git a/spp_audit/README.rst b/spp_audit/README.rst index dc68f6f5..994087b1 100644 --- a/spp_audit/README.rst +++ b/spp_audit/README.rst @@ -34,34 +34,34 @@ disabled through compromised database access. Key Capabilities ~~~~~~~~~~~~~~~~ -- **Automatic Operation Logging**: Intercepts create, write, and unlink - operations on configured models via method decoration -- **Lifecycle Action Logging**: Explicitly logs state transitions like - activate, deactivate, approve, reject through - ``log_lifecycle_action()`` API -- **File Access Tracking**: Records download, preview, and export - actions when enabled for specific models -- **Multi-Backend Dispatch**: Writes to database (UI-visible), JSONL - files (daily rotation), syslog, and HTTP endpoints concurrently -- **Tamper-Resistant Config**: Environment variables and ``odoo.conf`` - override database parameters to prevent audit disabling -- **Self-Protection**: Logs changes to ``spp.audit.rule`` records - directly to non-database backends -- **Optional Chatter Integration**: Posts audit summaries to record's - mail.thread when explicitly enabled +- **Automatic Operation Logging**: Intercepts create, write, and unlink + operations on configured models via method decoration +- **Lifecycle Action Logging**: Explicitly logs state transitions like + activate, deactivate, approve, reject through + ``log_lifecycle_action()`` API +- **File Access Tracking**: Records download, preview, and export + actions when enabled for specific models +- **Multi-Backend Dispatch**: Writes to database (UI-visible), JSONL + files (daily rotation), syslog, and HTTP endpoints concurrently +- **Tamper-Resistant Config**: Environment variables and ``odoo.conf`` + override database parameters to prevent audit disabling +- **Self-Protection**: Logs changes to ``spp.audit.rule`` records + directly to non-database backends +- **Optional Chatter Integration**: Posts audit summaries to record's + mail.thread when explicitly enabled Key Models ~~~~~~~~~~ -+--------------------+------------------------------------------------+ -| Model | Description | -+====================+================================================+ -| ``spp.audit.rule`` | Defines which models and operations to audit, | -| | with field filters | -+--------------------+------------------------------------------------+ -| ``spp.audit.log`` | Database-stored audit entries with old/new | -| | value comparison | -+--------------------+------------------------------------------------+ ++--------------------+-------------------------------------------------+ +| Model | Description | ++====================+=================================================+ +| ``spp.audit.rule`` | Defines which models and operations to audit, | +| | with field filters | ++--------------------+-------------------------------------------------+ +| ``spp.audit.log`` | Database-stored audit entries with old/new | +| | value comparison | ++--------------------+-------------------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -74,12 +74,12 @@ After installing: 3. Enable additional backends via environment variables or ``odoo.conf``: - - ``OPENSPP_AUDIT_BACKEND_FILE=true`` / - ``spp_audit_backend_file = true`` - - ``OPENSPP_AUDIT_BACKEND_SYSLOG=true`` / - ``spp_audit_backend_syslog = true`` - - ``OPENSPP_AUDIT_BACKEND_HTTP=true`` / - ``spp_audit_backend_http = true`` + - ``OPENSPP_AUDIT_BACKEND_FILE=true`` / + ``spp_audit_backend_file = true`` + - ``OPENSPP_AUDIT_BACKEND_SYSLOG=true`` / + ``spp_audit_backend_syslog = true`` + - ``OPENSPP_AUDIT_BACKEND_HTTP=true`` / + ``spp_audit_backend_http = true`` 4. Configure backend-specific settings (file path, HTTP endpoint, syslog host) @@ -87,33 +87,32 @@ After installing: UI Location ~~~~~~~~~~~ -- **Menu**: Audit Log > Audit > Rule (configure audit rules) -- **Menu**: Audit Log > Audit > Log (view database-stored audit - entries) -- **Action**: "View logs" action menu appears on audited model forms - when ``is_view_logs`` enabled +- **Menu**: Audit Log > Audit > Rule (configure audit rules) +- **Menu**: Audit Log > Audit > Log (view database-stored audit entries) +- **Action**: "View logs" action menu appears on audited model forms + when ``is_view_logs`` enabled **Tabs (Audit Log form)**: -- **Changes**: Displays old/new field values in table format +- **Changes**: Displays old/new field values in table format **Tabs (Audit Rule form)**: -- **Related Rules**: Shows child rules when parent model inherits - mail.thread +- **Related Rules**: Shows child rules when parent model inherits + mail.thread Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| ` | Full CRUD on audit rules and | -| `spp_audit.group_audit_manager`` | logs | -+----------------------------------+----------------------------------+ -| ``spp_security.group_spp_admin`` | Includes audit manager | -| | privileges (via imply) | -+----------------------------------+----------------------------------+ ++-----------------------------------+----------------------------------+ +| Group | Access | ++===================================+==================================+ +| ``spp_audit.group_audit_manager`` | Full CRUD on audit rules and | +| | logs | ++-----------------------------------+----------------------------------+ +| ``spp_security.group_spp_admin`` | Includes audit manager | +| | privileges (via imply) | ++-----------------------------------+----------------------------------+ Audit logs cannot be deleted by default (``ALLOW_DELETE = False`` in code, despite ``perm_unlink=1`` in access rules). @@ -121,15 +120,15 @@ code, despite ``perm_unlink=1`` in access rules). Extension Points ~~~~~~~~~~~~~~~~ -- Call - ``log_lifecycle_action(model_name, record_id, action, old_values, new_values)`` - to explicitly log state transitions -- Inherit ``spp.audit.backend`` and register new backend types via - ``AuditBackendRegistry.register_backend()`` -- Override ``_format_data_to_log()`` to customize field value - sanitization -- Extend ``spp.audit.rule`` with additional logging flags for - domain-specific actions +- Call + ``log_lifecycle_action(model_name, record_id, action, old_values, new_values)`` + to explicitly log state transitions +- Inherit ``spp.audit.backend`` and register new backend types via + ``AuditBackendRegistry.register_backend()`` +- Override ``_format_data_to_log()`` to customize field value + sanitization +- Extend ``spp.audit.rule`` with additional logging flags for + domain-specific actions Dependencies ~~~~~~~~~~~~ diff --git a/spp_audit/static/description/index.html b/spp_audit/static/description/index.html index e4b3dc2d..2bf395d3 100644 --- a/spp_audit/static/description/index.html +++ b/spp_audit/static/description/index.html @@ -451,8 +451,7 @@

        Configuration

        UI Location

        • Menu: Audit Log > Audit > Rule (configure audit rules)
        • -
        • Menu: Audit Log > Audit > Log (view database-stored audit -entries)
        • +
        • Menu: Audit Log > Audit > Log (view database-stored audit entries)
        • Action: “View logs” action menu appears on audited model forms when is_view_logs enabled
        @@ -470,8 +469,8 @@

        UI Location

        Security

        Model Parsed JSON storage from Excel files
        s -pp.area.import.language.wizard
        spp.area.import.language.wizard Wizard for activating languages during import
        --++ @@ -479,8 +478,7 @@

        Security

        - + diff --git a/spp_banking/README.rst b/spp_banking/README.rst index 7ab2571c..ff47021f 100644 --- a/spp_banking/README.rst +++ b/spp_banking/README.rst @@ -31,22 +31,23 @@ IBANs using the schwifty library. Extends the standard Odoo Key Capabilities ~~~~~~~~~~~~~~~~ -- Store multiple bank accounts per registrant with account number, - bank, and account type -- Automatically generate IBAN from bank country code, BIC, and account - number -- Display bank details in individual and group registry forms under the - financial section -- Validate and format IBANs according to country-specific standards +- Store multiple bank accounts per registrant with account number, bank, + and account type +- Automatically generate IBAN from bank country code, BIC, and account + number +- Display bank details in individual and group registry forms under the + financial section +- Validate and format IBANs according to country-specific standards Key Models ~~~~~~~~~~ -+----------------------+------------------------------------------------------+ -| Model | Description | -+======================+======================================================+ -| ``res.partner.bank`` | Bank account details with automatic IBAN computation | -+----------------------+------------------------------------------------------+ ++----------------------+-----------------------------------------------+ +| Model | Description | ++======================+===============================================+ +| ``res.partner.bank`` | Bank account details with automatic IBAN | +| | computation | ++----------------------+-----------------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -57,12 +58,12 @@ directly to registrant profiles. UI Location ~~~~~~~~~~~ -- **No standalone menu**: Bank account fields are added to existing - registrant forms -- **Individuals**: Navigate to a registrant, view the "Profile" tab, - bank accounts appear in the Financial Information section -- **Groups**: Navigate to a group registrant, view the "Profile" tab, - bank accounts appear in the Financial Information section +- **No standalone menu**: Bank account fields are added to existing + registrant forms +- **Individuals**: Navigate to a registrant, view the "Profile" tab, + bank accounts appear in the Financial Information section +- **Groups**: Navigate to a group registrant, view the "Profile" tab, + bank accounts appear in the Financial Information section Bank accounts are displayed as an editable list with fields for bank, account number, and computed IBAN. @@ -81,10 +82,10 @@ Group Access Extension Points ~~~~~~~~~~~~~~~~ -- Override ``_compute_account_number()`` in ``res.partner.bank`` to - customize IBAN generation logic -- Inherit ``res.partner.bank`` to add additional banking fields or - validation rules +- Override ``_compute_account_number()`` in ``res.partner.bank`` to + customize IBAN generation logic +- Inherit ``res.partner.bank`` to add additional banking fields or + validation rules Dependencies ~~~~~~~~~~~~ diff --git a/spp_banking/static/description/index.html b/spp_banking/static/description/index.html index 69bdc102..6dff894b 100644 --- a/spp_banking/static/description/index.html +++ b/spp_banking/static/description/index.html @@ -382,8 +382,8 @@

        OpenSPP Banking: Bank Details

        Key Capabilities

          -
        • Store multiple bank accounts per registrant with account number, -bank, and account type
        • +
        • Store multiple bank accounts per registrant with account number, bank, +and account type
        • Automatically generate IBAN from bank country code, BIC, and account number
        • Display bank details in individual and group registry forms under the @@ -395,8 +395,8 @@

          Key Capabilities

          Key Models

        Group
        ` -spp_audit.group_audit_manager`
        spp_audit.group_audit_manager Full CRUD on audit rules and logs
        --++ @@ -405,7 +405,8 @@

        Key Models

        - +
        Model
        res.partner.bankBank account details with automatic IBAN computationBank account details with automatic IBAN +computation
        diff --git a/spp_base_common/README.rst b/spp_base_common/README.rst index 94edbe5f..2a13a393 100644 --- a/spp_base_common/README.rst +++ b/spp_base_common/README.rst @@ -32,32 +32,31 @@ validation rules and UI theming across the platform. Key Capabilities ~~~~~~~~~~~~~~~~ -- Define configurable phone validation rules with digit count and - prefix requirements -- Automatically validate phone numbers on create/write against active - validation rules -- Customize menu icons for Registry, Apps, Settings, and standard Odoo - modules -- Configure global and local registrar user roles with implied - permissions -- Auto-populate partner phone field from structured phone number - records +- Define configurable phone validation rules with digit count and prefix + requirements +- Automatically validate phone numbers on create/write against active + validation rules +- Customize menu icons for Registry, Apps, Settings, and standard Odoo + modules +- Configure global and local registrar user roles with implied + permissions +- Auto-populate partner phone field from structured phone number records Key Models ~~~~~~~~~~ -+--------------------------+------------------------------------------+ -| Model | Description | -+==========================+==========================================+ -| ``spp.phone.validation`` | Configurable phone validation rule | -| | (prefix, digits) | -+--------------------------+------------------------------------------+ ++--------------------------+-------------------------------------------+ +| Model | Description | ++==========================+===========================================+ +| ``spp.phone.validation`` | Configurable phone validation rule | +| | (prefix, digits) | ++--------------------------+-------------------------------------------+ **Extensions:** -- ``spp.phone.number`` - Adds automatic validation on save -- ``res.partner`` - Adds phone auto-population from phone_number_ids -- ``ir.module.module`` - Adds menu icon update on module install +- ``spp.phone.number`` - Adds automatic validation on save +- ``res.partner`` - Adds phone auto-population from phone_number_ids +- ``ir.module.module`` - Adds menu icon update on module install Configuration ~~~~~~~~~~~~~ @@ -77,10 +76,10 @@ UI Location **No standalone menu.** Phone validation configuration is accessible through: -- Technical views (debug mode) via Settings > Technical > Database - Structure > Models -- Registry main menu gets custom OpenSPP icon -- Apps and Settings menus get custom OpenSPP icons +- Technical views (debug mode) via Settings > Technical > Database + Structure > Models +- Registry main menu gets custom OpenSPP icon +- Apps and Settings menus get custom OpenSPP icons Security ~~~~~~~~ @@ -101,12 +100,12 @@ Additional access rules grant registry groups appropriate permissions on Extension Points ~~~~~~~~~~~~~~~~ -- Override ``_onchange_phone_validation()`` in ``spp.phone.number`` to - customize validation logic -- Extend ``ICON_MAP`` in ``ir.module.module`` to add menu icons for - additional modules -- Inherit global/local role definitions in ``data/global_roles.xml`` - and ``data/local_roles.xml`` +- Override ``_onchange_phone_validation()`` in ``spp.phone.number`` to + customize validation logic +- Extend ``ICON_MAP`` in ``ir.module.module`` to add menu icons for + additional modules +- Inherit global/local role definitions in ``data/global_roles.xml`` and + ``data/local_roles.xml`` Dependencies ~~~~~~~~~~~~ diff --git a/spp_base_common/static/description/index.html b/spp_base_common/static/description/index.html index 19f50ba7..deb093e7 100644 --- a/spp_base_common/static/description/index.html +++ b/spp_base_common/static/description/index.html @@ -383,16 +383,15 @@

        OpenSPP Base (Common)

        Key Capabilities

          -
        • Define configurable phone validation rules with digit count and -prefix requirements
        • +
        • Define configurable phone validation rules with digit count and prefix +requirements
        • Automatically validate phone numbers on create/write against active validation rules
        • Customize menu icons for Registry, Apps, Settings, and standard Odoo modules
        • Configure global and local registrar user roles with implied permissions
        • -
        • Auto-populate partner phone field from structured phone number -records
        • +
        • Auto-populate partner phone field from structured phone number records
        @@ -482,8 +481,8 @@

        Extension Points

        customize validation logic
      • Extend ICON_MAP in ir.module.module to add menu icons for additional modules
      • -
      • Inherit global/local role definitions in data/global_roles.xml -and data/local_roles.xml
      • +
      • Inherit global/local role definitions in data/global_roles.xml and +data/local_roles.xml
      • diff --git a/spp_base_setting/README.rst b/spp_base_setting/README.rst index 6ab98b2a..a8d8b66b 100644 --- a/spp_base_setting/README.rst +++ b/spp_base_setting/README.rst @@ -33,13 +33,13 @@ deployments. Key Capabilities ~~~~~~~~~~~~~~~~ -- Define Country Offices as administrative units using company records - with custom form and list views -- Organize hierarchical office structures through parent-child company - relationships -- Expose user and group management in the Registry configuration menu -- Provide standardized Country Office form including address, contact - details, currency, and branding +- Define Country Offices as administrative units using company records + with custom form and list views +- Organize hierarchical office structures through parent-child company + relationships +- Expose user and group management in the Registry configuration menu +- Provide standardized Country Office form including address, contact + details, currency, and branding Key Models ~~~~~~~~~~ @@ -67,19 +67,19 @@ After installing: UI Location ~~~~~~~~~~~ -- **User Management**: Registry > Configuration > Users -- **Group Management**: Registry > Configuration > Groups (system - admins only, ``base.group_no_one``) -- **Country Offices**: No standalone menu; accessed via - ``action_res_country_office`` action or Settings +- **User Management**: Registry > Configuration > Users +- **Group Management**: Registry > Configuration > Groups (system admins + only, ``base.group_no_one``) +- **Country Offices**: No standalone menu; accessed via + ``action_res_country_office`` action or Settings Form Views ~~~~~~~~~~ The Country Office form (``view_country_office_form``) includes one tab: -- **General Information**: Address fields, phone, email, website, VAT, - currency, and parent office +- **General Information**: Address fields, phone, email, website, VAT, + currency, and parent office Security ~~~~~~~~ @@ -88,19 +88,19 @@ This module does not define custom security groups. Access to Country Office management and user/group configuration follows standard Odoo security rules: -- User management requires standard Odoo access rights -- Group management restricted to ``base.group_no_one`` (system admins) -- Country Office (company) records follow ``res.company`` access rules +- User management requires standard Odoo access rights +- Group management restricted to ``base.group_no_one`` (system admins) +- Country Office (company) records follow ``res.company`` access rules Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``res.company`` to add Country Office-specific fields (e.g., - office codes, regional metadata) -- Override ``view_country_office_form`` to customize the Country Office - form layout -- Extend the "social_media" placeholder group in the Country Office - form to add social media fields +- Inherit ``res.company`` to add Country Office-specific fields (e.g., + office codes, regional metadata) +- Override ``view_country_office_form`` to customize the Country Office + form layout +- Extend the "social_media" placeholder group in the Country Office form + to add social media fields Dependencies ~~~~~~~~~~~~ diff --git a/spp_base_setting/static/description/index.html b/spp_base_setting/static/description/index.html index dd6f7161..cb60c225 100644 --- a/spp_base_setting/static/description/index.html +++ b/spp_base_setting/static/description/index.html @@ -434,8 +434,8 @@

        Configuration

        UI Location

        • User Management: Registry > Configuration > Users
        • -
        • Group Management: Registry > Configuration > Groups (system -admins only, base.group_no_one)
        • +
        • Group Management: Registry > Configuration > Groups (system admins +only, base.group_no_one)
        • Country Offices: No standalone menu; accessed via action_res_country_office action or Settings
        @@ -466,8 +466,8 @@

        Extension Points

        office codes, regional metadata)
      • Override view_country_office_form to customize the Country Office form layout
      • -
      • Extend the “social_media” placeholder group in the Country Office -form to add social media fields
      • +
      • Extend the “social_media” placeholder group in the Country Office form +to add social media fields
      • diff --git a/spp_branding_kit/README.rst b/spp_branding_kit/README.rst index 29684e65..fd222ac2 100644 --- a/spp_branding_kit/README.rst +++ b/spp_branding_kit/README.rst @@ -35,41 +35,41 @@ system messages, email signatures, and report footers. Works with Key Capabilities ~~~~~~~~~~~~~~~~ -- URL routing: ``/openspp/programs/123`` works as an alias for - ``/odoo/programs/123`` -- Telemetry control: redirect to OpenSPP endpoint or disable entirely - via configuration -- Session branding: injects OpenSPP system name and version into web - client session -- Email signatures: replaces default Odoo signature with OpenSPP - branding -- Report customization: updates company report headers and footers with - OpenSPP text -- Post-install debranding: disables Odoo brand promotion messages, - update notification crons, and theme store menu -- Module filtering: adds "OpenSPP Apps" menu to filter and view - OpenSPP-specific applications +- URL routing: ``/openspp/programs/123`` works as an alias for + ``/odoo/programs/123`` +- Telemetry control: redirect to OpenSPP endpoint or disable entirely + via configuration +- Session branding: injects OpenSPP system name and version into web + client session +- Email signatures: replaces default Odoo signature with OpenSPP + branding +- Report customization: updates company report headers and footers with + OpenSPP text +- Post-install debranding: disables Odoo brand promotion messages, + update notification crons, and theme store menu +- Module filtering: adds "OpenSPP Apps" menu to filter and view + OpenSPP-specific applications Key Models ~~~~~~~~~~ This module does not introduce new models. It extends existing models: -+-------------------------+-------------------------------------------+ -| Model | Extension Purpose | -+=========================+===========================================+ -| ``res.users`` | Custom email signature, removes Odoo | -| | account URL | -+-------------------------+-------------------------------------------+ -| ``res.config.settings`` | Adds branding and telemetry configuration | -| | fields | -+-------------------------+-------------------------------------------+ -| ``ir.http`` | Injects OpenSPP branding into web client | -| | session info | -+-------------------------+-------------------------------------------+ -| ``ir.module.module`` | Provides utility to count | -| | paid/proprietary apps | -+-------------------------+-------------------------------------------+ ++-------------------------+--------------------------------------------+ +| Model | Extension Purpose | ++=========================+============================================+ +| ``res.users`` | Custom email signature, removes Odoo | +| | account URL | ++-------------------------+--------------------------------------------+ +| ``res.config.settings`` | Adds branding and telemetry configuration | +| | fields | ++-------------------------+--------------------------------------------+ +| ``ir.http`` | Injects OpenSPP branding into web client | +| | session info | ++-------------------------+--------------------------------------------+ +| ``ir.module.module`` | Provides utility to count paid/proprietary | +| | apps | ++-------------------------+--------------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -93,8 +93,8 @@ update notifications, and theme store menu. Menu Location ~~~~~~~~~~~~~ -- **Apps > OpenSPP Apps** - View and filter OpenSPP-specific - applications +- **Apps > OpenSPP Apps** - View and filter OpenSPP-specific + applications Security ~~~~~~~~ @@ -106,14 +106,14 @@ Configuration access follows standard Odoo settings permissions Extension Points ~~~~~~~~~~~~~~~~ -- Override ``get_branding_config(env)`` in ``utils.py`` to customize - branding data injected into session -- Inherit ``res.users`` to further customize email signatures or user - menu elements -- Inherit ``ir.http.session_info()`` to add custom branding keys to web - client session -- Patch JavaScript router in ``static/src/js/router_patch.js`` to - customize URL prefix beyond ``/openspp`` +- Override ``get_branding_config(env)`` in ``utils.py`` to customize + branding data injected into session +- Inherit ``res.users`` to further customize email signatures or user + menu elements +- Inherit ``ir.http.session_info()`` to add custom branding keys to web + client session +- Patch JavaScript router in ``static/src/js/router_patch.js`` to + customize URL prefix beyond ``/openspp`` Dependencies ~~~~~~~~~~~~ diff --git a/spp_cel_domain/README.rst b/spp_cel_domain/README.rst index ed72e949..c317e538 100644 --- a/spp_cel_domain/README.rst +++ b/spp_cel_domain/README.rst @@ -32,51 +32,49 @@ data providers, and cached values with TTL-based expiration. Key Capabilities ~~~~~~~~~~~~~~~~ -- Define variables mapping to model fields, constants, computed values, - member aggregations, or external APIs -- Write filter and formula expressions using CEL syntax with variable - references -- Resolve variable references into expanded CEL expressions before - compilation -- Configure external data providers with authentication, TTL, and ID - mapping for API-based data sources -- Cache computed and external variable values with TTL-based expiration - and manual invalidation -- Support historical data queries with configurable period granularity - (daily, monthly, quarterly, yearly) -- Evaluate expressions against context data for testing and validation +- Define variables mapping to model fields, constants, computed values, + member aggregations, or external APIs +- Write filter and formula expressions using CEL syntax with variable + references +- Resolve variable references into expanded CEL expressions before + compilation +- Configure external data providers with authentication, TTL, and ID + mapping for API-based data sources +- Cache computed and external variable values with TTL-based expiration + and manual invalidation +- Support historical data queries with configurable period granularity + (daily, monthly, quarterly, yearly) +- Evaluate expressions against context data for testing and validation Key Models ~~~~~~~~~~ -+-------------------------------+-------------------------------------+ -| Model | Description | -+===============================+=====================================+ -| ``spp.cel.variable`` | Variable definitions with source | -| | type, CEL accessor, and caching | -+-------------------------------+-------------------------------------+ -| ``spp.cel.variable.category`` | Variable categories for | -| | organization | -+-------------------------------+-------------------------------------+ -| ``spp.cel.expression`` | Business rule expressions with CEL | -| | syntax and variable tracking | -+-------------------------------+-------------------------------------+ -| ``spp.data.provider`` | External data provider | -| | configuration with auth and | -| | connection settings | -+-------------------------------+-------------------------------------+ -| ``spp.data.credential`` | Secure encrypted credential storage | -| | for external providers | -+-------------------------------+-------------------------------------+ -| ``spp.data.value`` | Cached variable values with period | -| | keys and expiration tracking | -+-------------------------------+-------------------------------------+ -| ``spp.cel.service`` | Service facade for compiling and | -| | evaluating CEL expressions | -+-------------------------------+-------------------------------------+ -| ``spp.cel.variable.resolver`` | Resolves variable references into | -| | expanded CEL expressions | -+-------------------------------+-------------------------------------+ ++-------------------------------+--------------------------------------+ +| Model | Description | ++===============================+======================================+ +| ``spp.cel.variable`` | Variable definitions with source | +| | type, CEL accessor, and caching | ++-------------------------------+--------------------------------------+ +| ``spp.cel.variable.category`` | Variable categories for organization | ++-------------------------------+--------------------------------------+ +| ``spp.cel.expression`` | Business rule expressions with CEL | +| | syntax and variable tracking | ++-------------------------------+--------------------------------------+ +| ``spp.data.provider`` | External data provider configuration | +| | with auth and connection settings | ++-------------------------------+--------------------------------------+ +| ``spp.data.credential`` | Secure encrypted credential storage | +| | for external providers | ++-------------------------------+--------------------------------------+ +| ``spp.data.value`` | Cached variable values with period | +| | keys and expiration tracking | ++-------------------------------+--------------------------------------+ +| ``spp.cel.service`` | Service facade for compiling and | +| | evaluating CEL expressions | ++-------------------------------+--------------------------------------+ +| ``spp.cel.variable.resolver`` | Resolves variable references into | +| | expanded CEL expressions | ++-------------------------------+--------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -97,40 +95,40 @@ After installing: UI Location ~~~~~~~~~~~ -- **Menu**: Custom > CEL Domain -- **Submenus**: Data Management > Data Providers, Data Management > - Data Cache -- **Tools**: Tools > Rule Preview wizard for testing expressions -- **Variable/Expression UI**: Provided by ``spp_studio`` module +- **Menu**: Custom > CEL Domain +- **Submenus**: Data Management > Data Providers, Data Management > Data + Cache +- **Tools**: Tools > Rule Preview wizard for testing expressions +- **Variable/Expression UI**: Provided by ``spp_studio`` module Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| ``spp_cel_ | Read variables, expressions, and | -| domain.group_cel_domain_viewer`` | data cache | -+----------------------------------+----------------------------------+ -| ``spp_cel_d | Full CRUD on variables, | -| omain.group_cel_domain_manager`` | expressions, providers, and | -| | cache | -+----------------------------------+----------------------------------+ -| ``spp_cel | Full CRUD on credentials and | -| _domain.group_cel_domain_admin`` | sensitive configs | -+----------------------------------+----------------------------------+ ++---------------------------------------------+----------------------------------+ +| Group | Access | ++=============================================+==================================+ +| ``spp_cel_domain.group_cel_domain_viewer`` | Read variables, expressions, and | +| | data cache | ++---------------------------------------------+----------------------------------+ +| ``spp_cel_domain.group_cel_domain_manager`` | Full CRUD on variables, | +| | expressions, providers, and | +| | cache | ++---------------------------------------------+----------------------------------+ +| ``spp_cel_domain.group_cel_domain_admin`` | Full CRUD on credentials and | +| | sensitive configs | ++---------------------------------------------+----------------------------------+ Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``spp.cel.variable`` to add custom source types or validation - logic -- Register custom CEL functions via ``spp.cel.function.registry`` -- Override ``spp.cel.variable._compute_cel_expression()`` to customize - aggregate expression generation -- Implement custom data providers by inheriting ``spp.data.provider`` -- Add profile configurations in ``spp.cel.registry`` for new evaluation - contexts +- Inherit ``spp.cel.variable`` to add custom source types or validation + logic +- Register custom CEL functions via ``spp.cel.function.registry`` +- Override ``spp.cel.variable._compute_cel_expression()`` to customize + aggregate expression generation +- Implement custom data providers by inheriting ``spp.data.provider`` +- Add profile configurations in ``spp.cel.registry`` for new evaluation + contexts Dependencies ~~~~~~~~~~~~ diff --git a/spp_cel_domain/static/description/index.html b/spp_cel_domain/static/description/index.html index 950289aa..4870e5e3 100644 --- a/spp_cel_domain/static/description/index.html +++ b/spp_cel_domain/static/description/index.html @@ -402,8 +402,8 @@

        Key Capabilities

        Key Models

        --++ @@ -416,17 +416,15 @@

        Key Models

        type, CEL accessor, and caching - + - +
        Model
        spp.cel.variable.categoryVariable categories for -organizationVariable categories for organization
        spp.cel.expression Business rule expressions with CEL syntax and variable tracking
        spp.data.providerExternal data provider -configuration with auth and -connection settingsExternal data provider configuration +with auth and connection settings
        spp.data.credential Secure encrypted credential storage @@ -467,8 +465,8 @@

        Configuration

        UI Location

        • Menu: Custom > CEL Domain
        • -
        • Submenus: Data Management > Data Providers, Data Management > -Data Cache
        • +
        • Submenus: Data Management > Data Providers, Data Management > Data +Cache
        • Tools: Tools > Rule Preview wizard for testing expressions
        • Variable/Expression UI: Provided by spp_studio module
        @@ -477,8 +475,8 @@

        UI Location

        Security

        --++ @@ -486,19 +484,16 @@

        Security

        - + - + - + diff --git a/spp_cel_event/README.rst b/spp_cel_event/README.rst index 3bc77713..d34c2c7a 100644 --- a/spp_cel_event/README.rst +++ b/spp_cel_event/README.rst @@ -35,15 +35,15 @@ with Python fallback for complex cases. Key Capabilities ~~~~~~~~~~~~~~~~ -- Query event field values with temporal filtering (within_days, - within_months, named periods) and selection modes (active, latest, - latest_active, first, any) -- Check event existence with date-based filtering -- Aggregate event data using count, sum, avg, min, max functions -- Generate period strings using helper functions (this_year, - this_quarter, etc.) -- Optimize queries using SQL fast paths with automatic fallback to - Python evaluation +- Query event field values with temporal filtering (within_days, + within_months, named periods) and selection modes (active, latest, + latest_active, first, any) +- Check event existence with date-based filtering +- Aggregate event data using count, sum, avg, min, max functions +- Generate period strings using helper functions (this_year, + this_quarter, etc.) +- Optimize queries using SQL fast paths with automatic fallback to + Python evaluation Key Models ~~~~~~~~~~ @@ -74,9 +74,9 @@ optimal query performance. UI Location ~~~~~~~~~~~ -- **Menu**: Studio > Rules > Variables > All Variables -- **Form**: Event aggregation fields appear in the Source Configuration - section when **Aggregate Target** is set to "Events" +- **Menu**: Studio > Rules > Variables > All Variables +- **Form**: Event aggregation fields appear in the Source Configuration + section when **Aggregate Target** is set to "Events" Security ~~~~~~~~ @@ -87,13 +87,13 @@ No module-specific security. Access control inherits from Extension Points ~~~~~~~~~~~~~~~~ -- Override ``spp.cel.translator._to_plan()`` to add custom event query - plan nodes -- Override ``spp.cel.executor._exec_event_value_sql()`` to customize - SQL execution logic -- Extend period helper functions in ``models/cel_event_functions.py`` -- Implement custom aggregation functions following the - events_count/sum/avg pattern +- Override ``spp.cel.translator._to_plan()`` to add custom event query + plan nodes +- Override ``spp.cel.executor._exec_event_value_sql()`` to customize SQL + execution logic +- Extend period helper functions in ``models/cel_event_functions.py`` +- Implement custom aggregation functions following the + events_count/sum/avg pattern Dependencies ~~~~~~~~~~~~ diff --git a/spp_cel_event/static/description/index.html b/spp_cel_event/static/description/index.html index 01a3dab6..daa0c3e7 100644 --- a/spp_cel_event/static/description/index.html +++ b/spp_cel_event/static/description/index.html @@ -451,8 +451,8 @@

        Extension Points

        • Override spp.cel.translator._to_plan() to add custom event query plan nodes
        • -
        • Override spp.cel.executor._exec_event_value_sql() to customize -SQL execution logic
        • +
        • Override spp.cel.executor._exec_event_value_sql() to customize SQL +execution logic
        • Extend period helper functions in models/cel_event_functions.py
        • Implement custom aggregation functions following the events_count/sum/avg pattern
        • diff --git a/spp_cel_registry_search/README.rst b/spp_cel_registry_search/README.rst index 50816c49..2cc9c2f8 100644 --- a/spp_cel_registry_search/README.rst +++ b/spp_cel_registry_search/README.rst @@ -35,16 +35,16 @@ eligibility criteria, or custom data fields. Auto-installs when Key Capabilities ~~~~~~~~~~~~~~~~ -- **CEL Expression Editor**: Write and validate CEL expressions with - syntax highlighting, autocomplete, and real-time validation -- **Profile Selection**: Search across Individuals or Groups with - profile-specific field validation -- **Live Validation**: See match counts before executing the search, - with inline error messages for invalid syntax -- **Clickable Results**: View search results in a list, click any - registrant to open their form view -- **Result Limiting**: Displays up to 50 results with a count indicator - when more matches exist +- **CEL Expression Editor**: Write and validate CEL expressions with + syntax highlighting, autocomplete, and real-time validation +- **Profile Selection**: Search across Individuals or Groups with + profile-specific field validation +- **Live Validation**: See match counts before executing the search, + with inline error messages for invalid syntax +- **Clickable Results**: View search results in a list, click any + registrant to open their form view +- **Result Limiting**: Displays up to 50 results with a count indicator + when more matches exist Key Models ~~~~~~~~~~ @@ -63,22 +63,21 @@ menu appears automatically under Registry. UI Location ~~~~~~~~~~~ -- **Menu**: Registry > Advanced Search -- **URL Path**: ``/odoo/registry-cel`` -- **Results**: Click any search result to open the registrant form view +- **Menu**: Registry > Advanced Search +- **URL Path**: ``/odoo/registry-cel`` +- **Results**: Click any search result to open the registrant form view Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| ``spp_cel_registr | Access to Advanced Search portal | -| y_search.group_cel_search_user`` | | -+----------------------------------+----------------------------------+ -| ``spp_r | Automatically includes CEL | -| egistry.group_registry_officer`` | Search access | -+----------------------------------+----------------------------------+ ++---------------------------------------------------+----------------------------------+ +| Group | Access | ++===================================================+==================================+ +| ``spp_cel_registry_search.group_cel_search_user`` | Access to Advanced Search portal | ++---------------------------------------------------+----------------------------------+ +| ``spp_registry.group_registry_officer`` | Automatically includes CEL | +| | Search access | ++---------------------------------------------------+----------------------------------+ The ``group_cel_search_user`` group implies ``spp_registry.group_registry_viewer``, ensuring users can only search @@ -87,13 +86,13 @@ registrants they have permission to view. Extension Points ~~~~~~~~~~~~~~~~ -- **Inherit ``CelSearchPortal`` component**: Override - ``performSearch()`` to customize query logic or add filters -- **Extend result display**: Modify the QWeb template - ``spp_cel_registry_search.CelSearchPortal`` to show additional - registrant fields -- **Add custom actions**: Override ``openRegistrant()`` to trigger - custom workflows when clicking search results +- **Inherit ``CelSearchPortal`` component**: Override + ``performSearch()`` to customize query logic or add filters +- **Extend result display**: Modify the QWeb template + ``spp_cel_registry_search.CelSearchPortal`` to show additional + registrant fields +- **Add custom actions**: Override ``openRegistrant()`` to trigger + custom workflows when clicking search results Dependencies ~~~~~~~~~~~~ diff --git a/spp_cel_registry_search/static/description/index.html b/spp_cel_registry_search/static/description/index.html index e7b9babe..82ed09bf 100644 --- a/spp_cel_registry_search/static/description/index.html +++ b/spp_cel_registry_search/static/description/index.html @@ -419,8 +419,8 @@

          UI Location

          Security

        Group
        spp_cel_ -domain.group_cel_domain_viewer
        spp_cel_domain.group_cel_domain_viewer Read variables, expressions, and data cache
        spp_cel_d -omain.group_cel_domain_manager
        spp_cel_domain.group_cel_domain_manager Full CRUD on variables, expressions, providers, and cache
        spp_cel -_domain.group_cel_domain_admin
        spp_cel_domain.group_cel_domain_admin Full CRUD on credentials and sensitive configs
        --++ @@ -428,12 +428,10 @@

        Security

        - + - + diff --git a/spp_cel_vocabulary/README.rst b/spp_cel_vocabulary/README.rst index b7b591bb..32a40b2e 100644 --- a/spp_cel_vocabulary/README.rst +++ b/spp_cel_vocabulary/README.rst @@ -35,20 +35,20 @@ vocabulary function calls into Odoo domains. Auto-installs when both Key Capabilities ~~~~~~~~~~~~~~~~ -- **CEL Function Registration**: Registers vocabulary functions - (``code()``, ``in_group()``, ``code_eq()``, ``head()``) with the CEL - function registry for use in eligibility expressions -- **Domain Translation**: Extends ``spp.cel.translator`` to translate - vocabulary function calls into Odoo domains that check ``uri`` and - ``reference_uri`` fields -- **Semantic Helpers**: Provides shorthand functions (``is_female()``, - ``is_male()``, ``is_head()``, ``is_pregnant()``) that map to - predefined concept groups -- **Concept Group Management**: Creates standard concept groups on - installation (gender, household roles, pregnancy status, hazards, age - groups, disability) -- **Local Code Support**: Handles semantic equality for local codes - that map to standard codes via ``reference_uri`` +- **CEL Function Registration**: Registers vocabulary functions + (``code()``, ``in_group()``, ``code_eq()``, ``head()``) with the CEL + function registry for use in eligibility expressions +- **Domain Translation**: Extends ``spp.cel.translator`` to translate + vocabulary function calls into Odoo domains that check ``uri`` and + ``reference_uri`` fields +- **Semantic Helpers**: Provides shorthand functions (``is_female()``, + ``is_male()``, ``is_head()``, ``is_pregnant()``) that map to + predefined concept groups +- **Concept Group Management**: Creates standard concept groups on + installation (gender, household roles, pregnancy status, hazards, age + groups, disability) +- **Local Code Support**: Handles semantic equality for local codes that + map to standard codes via ``reference_uri`` Key Models ~~~~~~~~~~ @@ -115,13 +115,13 @@ via ``post_init_hook``. Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``spp.cel.translator`` and override ``_to_plan()`` to add - custom vocabulary function translations -- Add new semantic helper functions to - ``services/cel_vocabulary_functions.py`` and register them in - ``VOCABULARY_FUNCTIONS`` dict -- Create additional concept groups via data files or UI to support - domain-specific eligibility patterns +- Inherit ``spp.cel.translator`` and override ``_to_plan()`` to add + custom vocabulary function translations +- Add new semantic helper functions to + ``services/cel_vocabulary_functions.py`` and register them in + ``VOCABULARY_FUNCTIONS`` dict +- Create additional concept groups via data files or UI to support + domain-specific eligibility patterns Dependencies ~~~~~~~~~~~~ diff --git a/spp_cel_vocabulary/static/description/index.html b/spp_cel_vocabulary/static/description/index.html index 8723e78f..81bc21a3 100644 --- a/spp_cel_vocabulary/static/description/index.html +++ b/spp_cel_vocabulary/static/description/index.html @@ -395,8 +395,8 @@

        Key Capabilities

      • Concept Group Management: Creates standard concept groups on installation (gender, household roles, pregnancy status, hazards, age groups, disability)
      • -
      • Local Code Support: Handles semantic equality for local codes -that map to standard codes via reference_uri
      • +
      • Local Code Support: Handles semantic equality for local codes that +map to standard codes via reference_uri
      • diff --git a/spp_cel_widget/README.rst b/spp_cel_widget/README.rst index 2c1bf8b9..0e00b779 100644 --- a/spp_cel_widget/README.rst +++ b/spp_cel_widget/README.rst @@ -32,32 +32,32 @@ modules that require expression editing. Key Capabilities ~~~~~~~~~~~~~~~~ -- **Syntax highlighting**: Keywords, operators, strings, and functions - are color-coded for readability -- **Autocompletion**: Press Ctrl+Space to see available fields, - functions, and operators for the current profile -- **Live validation**: Expressions are validated as you type, with - inline error highlighting and match counts -- **Symbol browser**: Browse available fields, CEL variables, library - expressions, and functions via a sidebar -- **Profile-based context**: Automatically loads symbols for registry - individuals, groups, entitlements, memberships, or custom profiles -- **HTTP API**: JSONRPC endpoints for symbol retrieval and validation - from frontend or external tools +- **Syntax highlighting**: Keywords, operators, strings, and functions + are color-coded for readability +- **Autocompletion**: Press Ctrl+Space to see available fields, + functions, and operators for the current profile +- **Live validation**: Expressions are validated as you type, with + inline error highlighting and match counts +- **Symbol browser**: Browse available fields, CEL variables, library + expressions, and functions via a sidebar +- **Profile-based context**: Automatically loads symbols for registry + individuals, groups, entitlements, memberships, or custom profiles +- **HTTP API**: JSONRPC endpoints for symbol retrieval and validation + from frontend or external tools Key Models ~~~~~~~~~~ -+-----------------------------+---------------------------------------+ -| Model | Description | -+=============================+=======================================+ -| ``spp.cel.symbol.provider`` | Abstract model that extracts symbols | -| | for autocompletion and validates | -| | expressions | -+-----------------------------+---------------------------------------+ -| ``spp.cel.widget.demo`` | Transient wizard for testing the | -| | widget (debug mode only) | -+-----------------------------+---------------------------------------+ ++-----------------------------+----------------------------------------+ +| Model | Description | ++=============================+========================================+ +| ``spp.cel.symbol.provider`` | Abstract model that extracts symbols | +| | for autocompletion and validates | +| | expressions | ++-----------------------------+----------------------------------------+ +| ``spp.cel.widget.demo`` | Transient wizard for testing the | +| | widget (debug mode only) | ++-----------------------------+----------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -73,76 +73,74 @@ After installing, use the widget in any form view by adding Optional widget parameters: -- ``cel_profile``: Profile name (default: ``registry_individuals``) -- ``profile_field``: Read profile from a field on the record -- ``expression_type``: Expression type (filter, formula, scoring, - validation, other) -- ``expression_type_field``: Read expression type from a field -- ``output_type``: Expected output type (boolean, number, string, - money) -- ``output_type_field``: Read output type from a field +- ``cel_profile``: Profile name (default: ``registry_individuals``) +- ``profile_field``: Read profile from a field on the record +- ``expression_type``: Expression type (filter, formula, scoring, + validation, other) +- ``expression_type_field``: Read expression type from a field +- ``output_type``: Expected output type (boolean, number, string, money) +- ``output_type_field``: Read output type from a field UI Location ~~~~~~~~~~~ -- **Demo Wizard**: Settings > Technical > CEL Widget Demo (debug mode - only) -- **Widget Usage**: Add to any form view with - ``widget="cel_expression"`` +- **Demo Wizard**: Settings > Technical > CEL Widget Demo (debug mode + only) +- **Widget Usage**: Add to any form view with + ``widget="cel_expression"`` Tabs in Demo Wizard ~~~~~~~~~~~~~~~~~~~ -- **Dynamic Testing**: Test expressions with different profiles and see - validation results -- **By Profile**: Test expressions for specific profiles (individuals, - groups, entitlements) -- **Read-only Mode**: Verify the widget displays correctly in readonly - mode -- **Help**: Keyboard shortcuts, features, and example expressions +- **Dynamic Testing**: Test expressions with different profiles and see + validation results +- **By Profile**: Test expressions for specific profiles (individuals, + groups, entitlements) +- **Read-only Mode**: Verify the widget displays correctly in readonly + mode +- **Help**: Keyboard shortcuts, features, and example expressions Security ~~~~~~~~ -+--------------------+-----------------------+-----------------------+ -| Group | Model | Access | -+====================+=======================+=======================+ -| Internal User | HTTP endpoints | Can call widget | -| | | JSONRPC endpoints | -| | | (auth="user") | -+--------------------+-----------------------+-----------------------+ -| Settings | `` | Full CRUD (read, | -| | spp.cel.widget.demo`` | write, create, | -| | | delete) | -+--------------------+-----------------------+-----------------------+ -| Technical Features | Menu visibility | Can see demo menu in | -| | | Settings > Technical | -+--------------------+-----------------------+-----------------------+ ++--------------------+-------------------------+------------------------+ +| Group | Model | Access | ++====================+=========================+========================+ +| Internal User | HTTP endpoints | Can call widget | +| | | JSONRPC endpoints | +| | | (auth="user") | ++--------------------+-------------------------+------------------------+ +| Settings | ``spp.cel.widget.demo`` | Full CRUD (read, | +| | | write, create, delete) | ++--------------------+-------------------------+------------------------+ +| Technical Features | Menu visibility | Can see demo menu in | +| | | Settings > Technical | ++--------------------+-------------------------+------------------------+ HTTP Endpoints ~~~~~~~~~~~~~~ All endpoints use JSONRPC authentication (``auth="user"``): -- **``/spp_cel/symbols/``**: Get symbols for a CEL profile - (variables, functions, operators, keywords) -- **``/spp_cel/validate``**: Validate expression and return errors, - warnings, match count -- **``/spp_cel/profiles``**: Get list of available CEL profiles with - descriptions +- **``/spp_cel/symbols/``**: Get symbols for a CEL profile + (variables, functions, operators, keywords) +- **``/spp_cel/validate``**: Validate expression and return errors, + warnings, match count +- **``/spp_cel/profiles``**: Get list of available CEL profiles with + descriptions Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``spp.cel.symbol.provider`` and override - ``get_symbols_for_profile()`` to add custom symbol sources -- Use the ``CelEditor`` JavaScript component standalone in client - actions for custom editors -- Add custom profiles to ``spp.cel.registry`` for domain-specific - contexts -- Customize the ``_get_model_fields()`` method to filter which fields - appear in autocompletion -- Use HTTP endpoints from external tools or custom frontend components +- Inherit ``spp.cel.symbol.provider`` and override + ``get_symbols_for_profile()`` to add custom symbol sources +- Use the ``CelEditor`` JavaScript component standalone in client + actions for custom editors +- Add custom profiles to ``spp.cel.registry`` for domain-specific + contexts +- Customize the ``_get_model_fields()`` method to filter which fields + appear in autocompletion +- Use HTTP endpoints from external tools or custom frontend components Dependencies ~~~~~~~~~~~~ diff --git a/spp_cel_widget/static/description/index.html b/spp_cel_widget/static/description/index.html index 4dc87fad..f7d9f553 100644 --- a/spp_cel_widget/static/description/index.html +++ b/spp_cel_widget/static/description/index.html @@ -401,8 +401,8 @@

        Key Capabilities

        Key Models

        Group
        spp_cel_registr -y_search.group_cel_search_user
        spp_cel_registry_search.group_cel_search_user Access to Advanced Search portal
        spp_r -egistry.group_registry_officer
        spp_registry.group_registry_officer Automatically includes CEL Search access
        --++ @@ -438,8 +438,7 @@

        Configuration

      • expression_type: Expression type (filter, formula, scoring, validation, other)
      • expression_type_field: Read expression type from a field
      • -
      • output_type: Expected output type (boolean, number, string, -money)
      • +
      • output_type: Expected output type (boolean, number, string, money)
      • output_type_field: Read output type from a field
      • @@ -468,8 +467,8 @@

        Tabs in Demo Wizard

        Security

        Model
        --++ @@ -486,11 +485,9 @@

        Security

        (auth=”user”) - + +write, create, delete) diff --git a/spp_change_request_v2/README.rst b/spp_change_request_v2/README.rst index c91a9344..1e1d6ae8 100644 --- a/spp_change_request_v2/README.rst +++ b/spp_change_request_v2/README.rst @@ -32,94 +32,93 @@ group/household registrant data, with validation and audit trails. Key Capabilities ~~~~~~~~~~~~~~~~ -- Create change requests using configurable request types with custom - detail models -- Multi-tier approval workflows with automatic routing based on - approval definitions -- Detect conflicting change requests (same registrant, same group, or - same field) -- Prevent duplicate submissions with configurable similarity thresholds -- Validate required fields and documents before submission -- Preview changes before applying them to registrant records -- Apply changes via field mapping or custom strategies -- Track audit trail of all state changes via event data -- Attach supporting documents organized in DMS directories +- Create change requests using configurable request types with custom + detail models +- Multi-tier approval workflows with automatic routing based on approval + definitions +- Detect conflicting change requests (same registrant, same group, or + same field) +- Prevent duplicate submissions with configurable similarity thresholds +- Validate required fields and documents before submission +- Preview changes before applying them to registrant records +- Apply changes via field mapping or custom strategies +- Track audit trail of all state changes via event data +- Attach supporting documents organized in DMS directories Key Models ~~~~~~~~~~ -+----------------------------------+----------------------------------+ -| Model | Description | -+==================================+==================================+ -| ``spp.change.request`` | Main change request record with | -| | approval workflow | -+----------------------------------+----------------------------------+ -| ``spp.change.request.type`` | Configuration for CR types: | -| | target, detail model, workflow | -+----------------------------------+----------------------------------+ -| ``s | Field mappings for automatic | -| pp.change.request.type.mapping`` | application | -+----------------------------------+----------------------------------+ -| ``spp.cr.conflict.rule`` | Rules for detecting conflicting | -| | change requests | -+----------------------------------+----------------------------------+ -| ``spp.cr.duplicate.config`` | Configuration for duplicate | -| | detection thresholds | -+----------------------------------+----------------------------------+ -| ``spp.cr.conflict.mixin`` | Mixin providing conflict and | -| | duplicate detection | -+----------------------------------+----------------------------------+ -| ``spp.cr.detail.base`` | Base model for all change | -| | request detail types | -+----------------------------------+----------------------------------+ -| ``spp.cr.detail.add_member`` | Detail model for adding members | -| | to groups | -+----------------------------------+----------------------------------+ -| ` | Detail model for editing | -| `spp.cr.detail.edit_individual`` | individual registrant data | -+----------------------------------+----------------------------------+ -| ``spp.cr.detail.edit_group`` | Detail model for editing | -| | group/household data | -+----------------------------------+----------------------------------+ -| ``spp.cr.detail.remove_member`` | Detail model for removing | -| | members from groups | -+----------------------------------+----------------------------------+ -| ``spp.cr.detail.change_hoh`` | Detail model for changing head | -| | of household | -+----------------------------------+----------------------------------+ -| ` | Detail model for marking | -| `spp.cr.detail.exit_registrant`` | registrants as exited | -+----------------------------------+----------------------------------+ -| ` | Detail model for transferring | -| `spp.cr.detail.transfer_member`` | members between groups | -+----------------------------------+----------------------------------+ -| ``spp.cr.detail.update_id`` | Detail model for updating | -| | registrant ID numbers | -+----------------------------------+----------------------------------+ -| ``spp.cr.detail.create_group`` | Detail model for creating new | -| | groups/households | -+----------------------------------+----------------------------------+ -| ``s | Detail model for merging | -| pp.cr.detail.merge_registrants`` | duplicate registrant records | -+----------------------------------+----------------------------------+ -| ` | Detail model for splitting | -| `spp.cr.detail.split_household`` | households into separate groups | -+----------------------------------+----------------------------------+ ++-------------------------------------+----------------------------------+ +| Model | Description | ++=====================================+==================================+ +| ``spp.change.request`` | Main change request record with | +| | approval workflow | ++-------------------------------------+----------------------------------+ +| ``spp.change.request.type`` | Configuration for CR types: | +| | target, detail model, workflow | ++-------------------------------------+----------------------------------+ +| ``spp.change.request.type.mapping`` | Field mappings for automatic | +| | application | ++-------------------------------------+----------------------------------+ +| ``spp.cr.conflict.rule`` | Rules for detecting conflicting | +| | change requests | ++-------------------------------------+----------------------------------+ +| ``spp.cr.duplicate.config`` | Configuration for duplicate | +| | detection thresholds | ++-------------------------------------+----------------------------------+ +| ``spp.cr.conflict.mixin`` | Mixin providing conflict and | +| | duplicate detection | ++-------------------------------------+----------------------------------+ +| ``spp.cr.detail.base`` | Base model for all change | +| | request detail types | ++-------------------------------------+----------------------------------+ +| ``spp.cr.detail.add_member`` | Detail model for adding members | +| | to groups | ++-------------------------------------+----------------------------------+ +| ``spp.cr.detail.edit_individual`` | Detail model for editing | +| | individual registrant data | ++-------------------------------------+----------------------------------+ +| ``spp.cr.detail.edit_group`` | Detail model for editing | +| | group/household data | ++-------------------------------------+----------------------------------+ +| ``spp.cr.detail.remove_member`` | Detail model for removing | +| | members from groups | ++-------------------------------------+----------------------------------+ +| ``spp.cr.detail.change_hoh`` | Detail model for changing head | +| | of household | ++-------------------------------------+----------------------------------+ +| ``spp.cr.detail.exit_registrant`` | Detail model for marking | +| | registrants as exited | ++-------------------------------------+----------------------------------+ +| ``spp.cr.detail.transfer_member`` | Detail model for transferring | +| | members between groups | ++-------------------------------------+----------------------------------+ +| ``spp.cr.detail.update_id`` | Detail model for updating | +| | registrant ID numbers | ++-------------------------------------+----------------------------------+ +| ``spp.cr.detail.create_group`` | Detail model for creating new | +| | groups/households | ++-------------------------------------+----------------------------------+ +| ``spp.cr.detail.merge_registrants`` | Detail model for merging | +| | duplicate registrant records | ++-------------------------------------+----------------------------------+ +| ``spp.cr.detail.split_household`` | Detail model for splitting | +| | households into separate groups | ++-------------------------------------+----------------------------------+ Form Tabs ~~~~~~~~~ Change request form view includes the following tabs: -- **Details**: Split-pane view showing current registrant data and - proposed changes -- **Documents**: Upload and manage supporting documents via DMS - integration -- **Notes**: Description and internal notes fields -- **Revision Requested**: Feedback from reviewers (visible when changes - requested) -- **Status History**: Timeline of approval reviews and state - transitions +- **Details**: Split-pane view showing current registrant data and + proposed changes +- **Documents**: Upload and manage supporting documents via DMS + integration +- **Notes**: Description and internal notes fields +- **Revision Requested**: Feedback from reviewers (visible when changes + requested) +- **Status History**: Timeline of approval reviews and state transitions Configuration ~~~~~~~~~~~~~ @@ -141,58 +140,58 @@ After installing: UI Location ~~~~~~~~~~~ -- **Menu**: Change Requests (top-level menu) +- **Menu**: Change Requests (top-level menu) - - **All Requests**: View all change requests with filtering - - **New Request**: Launch wizard to create change request - - **Pending Approval**: Queue of requests awaiting validator action - (validators only) - - **Reporting > Analytics**: Pivot and graph views for change - request analysis (managers only) - - **Configuration**: Change request types, conflict rules, duplicate - detection (managers only) + - **All Requests**: View all change requests with filtering + - **New Request**: Launch wizard to create change request + - **Pending Approval**: Queue of requests awaiting validator action + (validators only) + - **Reporting > Analytics**: Pivot and graph views for change request + analysis (managers only) + - **Configuration**: Change request types, conflict rules, duplicate + detection (managers only) -- **Registrant Profile**: Change requests appear in registrant form - under smart buttons and related tabs -- **Wizards**: New Request wizard for guided CR creation, batch - approval for validators +- **Registrant Profile**: Change requests appear in registrant form + under smart buttons and related tabs +- **Wizards**: New Request wizard for guided CR creation, batch approval + for validators Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| ``spp_c | Create and submit change | -| hange_request_v2.group_cr_user`` | requests (read/write/create) | -+----------------------------------+----------------------------------+ -| ``spp_change | Approve/reject, field-level | -| _request_v2.group_cr_validator`` | validation (read/write/create) | -+----------------------------------+----------------------------------+ -| ``spp_change_re | HQ-level approval with registry | -| quest_v2.group_cr_validator_hq`` | write (read/write/create) | -+----------------------------------+----------------------------------+ -| ``spp_chan | Full CRUD including | -| ge_request_v2.group_cr_manager`` | configuration | -+----------------------------------+----------------------------------+ -| ``spp_change_request | Override blocking conflict | -| _v2.group_cr_conflict_approver`` | detections | -| | (specialized/functional) | -+----------------------------------+----------------------------------+ ++------------------------------------------------------+----------------------------------+ +| Group | Access | ++======================================================+==================================+ +| ``spp_change_request_v2.group_cr_user`` | Create and submit change | +| | requests (read/write/create) | ++------------------------------------------------------+----------------------------------+ +| ``spp_change_request_v2.group_cr_validator`` | Approve/reject, field-level | +| | validation (read/write/create) | ++------------------------------------------------------+----------------------------------+ +| ``spp_change_request_v2.group_cr_validator_hq`` | HQ-level approval with registry | +| | write (read/write/create) | ++------------------------------------------------------+----------------------------------+ +| ``spp_change_request_v2.group_cr_manager`` | Full CRUD including | +| | configuration | ++------------------------------------------------------+----------------------------------+ +| ``spp_change_request_v2.group_cr_conflict_approver`` | Override blocking conflict | +| | detections | +| | (specialized/functional) | ++------------------------------------------------------+----------------------------------+ Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``spp.change.request.type`` and override - ``get_apply_strategy()`` to add custom application logic -- Inherit ``spp.cr.conflict.mixin`` and override - ``_check_custom_conflicts()`` for custom conflict detection -- Create new detail models inheriting ``spp.cr.detail.base`` for custom - change request types -- Override ``_validate_documents()`` on ``spp.change.request`` for - custom document validation -- Use ``_pre_enrollment_hook()`` and ``_post_enrollment_hook()`` - patterns for side effects during application +- Inherit ``spp.change.request.type`` and override + ``get_apply_strategy()`` to add custom application logic +- Inherit ``spp.cr.conflict.mixin`` and override + ``_check_custom_conflicts()`` for custom conflict detection +- Create new detail models inheriting ``spp.cr.detail.base`` for custom + change request types +- Override ``_validate_documents()`` on ``spp.change.request`` for + custom document validation +- Use ``_pre_enrollment_hook()`` and ``_post_enrollment_hook()`` + patterns for side effects during application Dependencies ~~~~~~~~~~~~ diff --git a/spp_change_request_v2/__manifest__.py b/spp_change_request_v2/__manifest__.py index 58d42781..72481b0c 100644 --- a/spp_change_request_v2/__manifest__.py +++ b/spp_change_request_v2/__manifest__.py @@ -56,8 +56,6 @@ "data/sequences.xml", "data/event_types.xml", "data/user_roles.xml", - # Note: Default CR types are now provided by spp_cr_types_base and spp_cr_types_advanced - # "data/default_types.xml", ], "assets": { "web.assets_backend": [ diff --git a/spp_change_request_v2/data/default_types.xml b/spp_change_request_v2/data/default_types.xml deleted file mode 100644 index 2048a3bb..00000000 --- a/spp_change_request_v2/data/default_types.xml +++ /dev/null @@ -1,279 +0,0 @@ - - - - - - - Add Group Member - add_member - Add a new member to an existing group/household - group - spp.cr.detail.add_member - - custom - spp.cr.apply.add_member - fa-user-plus - 10 - - - - - Edit Individual Information - edit_individual - Update personal information for an individual registrant - individual - spp.cr.detail.edit_individual - - field_mapping - fa-user-edit - 20 - - - - - - given_name - given_name - 10 - - - - family_name - family_name - 20 - - - - birthdate - birthdate - 30 - - - - gender_id - gender_id - 40 - - - - phone - phone - 50 - - - - email - email - 60 - - - - address_line1 - street - 70 - - - - address_line2 - street2 - 80 - - - - city - city - 90 - - - - postal_code - zip - 100 - - - - - Edit Group Information - edit_group - Update information for a group/household - group - spp.cr.detail.edit_group - - field_mapping - fa-users-cog - 30 - - - - - - group_name - name - 10 - - - - phone - phone - 20 - - - - email - email - 30 - - - - address_line1 - street - 40 - - - - address_line2 - street2 - 50 - - - - city - city - 60 - - - - postal_code - zip - 70 - - - - - - - - - Remove Group Member - remove_member - Remove a member from an existing group/household - group - spp.cr.detail.remove_member - - custom - spp.cr.apply.remove_member - fa-user-minus - 40 - - - - - Change Head of Household - change_hoh - Change the head of household for a group - group - spp.cr.detail.change_hoh - - custom - spp.cr.apply.change_hoh - fa-user-shield - 50 - - - - - Transfer Member - transfer_member - Transfer a member from one group to another - group - spp.cr.detail.transfer_member - - custom - spp.cr.apply.transfer_member - fa-exchange-alt - 60 - - - - - - - - - Exit Registrant - exit_registrant - Deactivate or exit a registrant from the system - both - spp.cr.detail.exit_registrant - - custom - spp.cr.apply.exit_registrant - fa-user-slash - 70 - - - - - Update ID Document - update_id - Add, update, or remove identification documents - both - spp.cr.detail.update_id - - custom - spp.cr.apply.update_id - fa-id-card - 80 - - - - - - - - - Create New Group - create_group - Create a new group/household - group - spp.cr.detail.create_group - - custom - spp.cr.apply.create_group - fa-home - 90 - - - - - Split Household - split_household - Split a household into two separate groups - group - spp.cr.detail.split_household - - custom - spp.cr.apply.split_household - fa-code-branch - 100 - - - - - - - - - Merge Registrants - merge_registrants - Merge duplicate registrant records - both - spp.cr.detail.merge_registrants - - custom - spp.cr.apply.merge_registrants - fa-compress-arrows-alt - 110 - - - diff --git a/spp_change_request_v2/static/description/index.html b/spp_change_request_v2/static/description/index.html index 5a98b441..dc4c1450 100644 --- a/spp_change_request_v2/static/description/index.html +++ b/spp_change_request_v2/static/description/index.html @@ -385,8 +385,8 @@

        Key Capabilities

        • Create change requests using configurable request types with custom detail models
        • -
        • Multi-tier approval workflows with automatic routing based on -approval definitions
        • +
        • Multi-tier approval workflows with automatic routing based on approval +definitions
        • Detect conflicting change requests (same registrant, same group, or same field)
        • Prevent duplicate submissions with configurable similarity thresholds
        • @@ -401,8 +401,8 @@

          Key Capabilities

          Key Models

        Settings`` -spp.cel.widget.demo``spp.cel.widget.demo Full CRUD (read, -write, create, -delete)
        Technical Features Menu visibility
        --++ @@ -418,8 +418,7 @@

        Key Models

        - + @@ -443,8 +442,7 @@

        Key Models

        - + @@ -460,13 +458,11 @@

        Key Models

        - + - + @@ -478,13 +474,11 @@

        Key Models

        - + - + @@ -502,8 +496,7 @@

        Form Tabs

      • Notes: Description and internal notes fields
      • Revision Requested: Feedback from reviewers (visible when changes requested)
      • -
      • Status History: Timeline of approval reviews and state -transitions
      • +
      • Status History: Timeline of approval reviews and state transitions
      • @@ -531,24 +524,24 @@

        UI Location

      • New Request: Launch wizard to create change request
      • Pending Approval: Queue of requests awaiting validator action (validators only)
      • -
      • Reporting > Analytics: Pivot and graph views for change -request analysis (managers only)
      • +
      • Reporting > Analytics: Pivot and graph views for change request +analysis (managers only)
      • Configuration: Change request types, conflict rules, duplicate detection (managers only)
      • Registrant Profile: Change requests appear in registrant form under smart buttons and related tabs
      • -
      • Wizards: New Request wizard for guided CR creation, batch -approval for validators
      • +
      • Wizards: New Request wizard for guided CR creation, batch approval +for validators
      • Security

        Model Configuration for CR types: target, detail model, workflow
        s -pp.change.request.type.mapping
        spp.change.request.type.mapping Field mappings for automatic application
        Detail model for adding members to groups
        ` -spp.cr.detail.edit_individual`
        spp.cr.detail.edit_individual Detail model for editing individual registrant data
        Detail model for changing head of household
        ` -spp.cr.detail.exit_registrant`
        spp.cr.detail.exit_registrant Detail model for marking registrants as exited
        ` -spp.cr.detail.transfer_member`
        spp.cr.detail.transfer_member Detail model for transferring members between groups
        Detail model for creating new groups/households
        s -pp.cr.detail.merge_registrants
        spp.cr.detail.merge_registrants Detail model for merging duplicate registrant records
        ` -spp.cr.detail.split_household`
        spp.cr.detail.split_household Detail model for splitting households into separate groups
        --++ @@ -556,28 +549,23 @@

        Security

        - + - + - + - + - + diff --git a/spp_change_request_v2/static/src/js/create_change_request.js b/spp_change_request_v2/static/src/js/create_change_request.js index d5c27031..e9a8ee0f 100644 --- a/spp_change_request_v2/static/src/js/create_change_request.js +++ b/spp_change_request_v2/static/src/js/create_change_request.js @@ -1,10 +1,10 @@ -/** @odoo-module **/ +/* @odoo-module */ import {ListController} from "@web/views/list/list_controller"; import {onWillStart} from "@odoo/owl"; import {patch} from "@web/core/utils/patch"; -import {user} from "@web/core/user"; import {useService} from "@web/core/utils/hooks"; +import {user} from "@web/core/user"; patch(ListController.prototype, { setup() { diff --git a/spp_change_request_v2/static/src/xml/create_change_request_template.xml b/spp_change_request_v2/static/src/xml/create_change_request_template.xml index 18e6088b..331cebe4 100644 --- a/spp_change_request_v2/static/src/xml/create_change_request_template.xml +++ b/spp_change_request_v2/static/src/xml/create_change_request_template.xml @@ -2,7 +2,10 @@ - + - + @@ -31,7 +37,9 @@ - model.root.resModel != 'spp.change.request' + model.root.resModel != 'spp.change.request' diff --git a/spp_change_request_v2/strategies/add_member.py b/spp_change_request_v2/strategies/add_member.py index 8690ddda..79c1bcbb 100644 --- a/spp_change_request_v2/strategies/add_member.py +++ b/spp_change_request_v2/strategies/add_member.py @@ -85,5 +85,5 @@ def preview(self, change_request): "_action": "create_member", "member_name": detail.member_name, "group": change_request.registrant_id.name, - "relationship": detail.relationship_id.name if detail.relationship_id else None, + "relationship": detail.relationship_id.display if detail.relationship_id else None, } diff --git a/spp_change_request_v2/strategies/transfer_member.py b/spp_change_request_v2/strategies/transfer_member.py index 53ddf242..1abbf5e9 100644 --- a/spp_change_request_v2/strategies/transfer_member.py +++ b/spp_change_request_v2/strategies/transfer_member.py @@ -91,7 +91,7 @@ def preview(self, change_request): "member_name": detail.member_name, "source_group": detail.source_group_name, "target_group": detail.target_group_name, - "new_role": detail.new_role_id.name if detail.new_role_id else None, + "new_role": detail.new_role_id.display if detail.new_role_id else None, "transfer_date": str(detail.transfer_date), "reason": detail.transfer_reason, } diff --git a/spp_change_request_v2/tests/common.py b/spp_change_request_v2/tests/common.py index f67a64b9..c6ec1882 100644 --- a/spp_change_request_v2/tests/common.py +++ b/spp_change_request_v2/tests/common.py @@ -2,6 +2,125 @@ from odoo.tests import TransactionCase, tagged +# Definitions for CR types needed by strategy tests. +# These mirror what spp_cr_types_base / spp_cr_types_advanced install via XML. +CR_TYPE_DEFS = { + "add_member": { + "name": "Add Group Member", + "target_type": "group", + "detail_model": "spp.cr.detail.add_member", + "apply_strategy": "custom", + "apply_model": "spp.cr.apply.add_member", + }, + "remove_member": { + "name": "Remove Group Member", + "target_type": "group", + "detail_model": "spp.cr.detail.remove_member", + "apply_strategy": "custom", + "apply_model": "spp.cr.apply.remove_member", + }, + "change_hoh": { + "name": "Change Head of Household", + "target_type": "group", + "detail_model": "spp.cr.detail.change_hoh", + "apply_strategy": "custom", + "apply_model": "spp.cr.apply.change_hoh", + }, + "exit_registrant": { + "name": "Exit Registrant", + "target_type": "both", + "detail_model": "spp.cr.detail.exit_registrant", + "apply_strategy": "custom", + "apply_model": "spp.cr.apply.exit_registrant", + }, + "transfer_member": { + "name": "Transfer Member", + "target_type": "group", + "detail_model": "spp.cr.detail.transfer_member", + "apply_strategy": "custom", + "apply_model": "spp.cr.apply.transfer_member", + }, + "update_id": { + "name": "Update ID Document", + "target_type": "both", + "detail_model": "spp.cr.detail.update_id", + "apply_strategy": "custom", + "apply_model": "spp.cr.apply.update_id", + }, + "create_group": { + "name": "Create Group", + "target_type": "group", + "detail_model": "spp.cr.detail.create_group", + "apply_strategy": "custom", + "apply_model": "spp.cr.apply.create_group", + }, + "split_household": { + "name": "Split Household", + "target_type": "group", + "detail_model": "spp.cr.detail.split_household", + "apply_strategy": "custom", + "apply_model": "spp.cr.apply.split_household", + }, + "merge_registrants": { + "name": "Merge Registrants", + "target_type": "both", + "detail_model": "spp.cr.detail.merge_registrants", + "apply_strategy": "custom", + "apply_model": "spp.cr.apply.merge_registrants", + }, + "edit_individual": { + "name": "Edit Individual", + "target_type": "individual", + "detail_model": "spp.cr.detail.edit_individual", + "apply_strategy": "field_mapping", + }, + "edit_group": { + "name": "Edit Group", + "target_type": "group", + "detail_model": "spp.cr.detail.edit_group", + "apply_strategy": "field_mapping", + }, +} + + +def get_or_create_cr_type(env, code): + """Get a CR type by code, creating it if not found (for tests).""" + cr_type = env["spp.change.request.type"].search([("code", "=", code)], limit=1) + if not cr_type: + defs = CR_TYPE_DEFS[code] + cr_type = env["spp.change.request.type"].create({"code": code, **defs}) + return cr_type + + +# Vocabulary codes that may not be installed (commented out in default data). +_MEMBERSHIP_TYPE_CODES = { + "spouse": {"display": "Spouse", "sequence": 3}, + "child": {"display": "Child", "sequence": 2}, + "other": {"display": "Other", "sequence": 10}, +} + +MEMBERSHIP_TYPE_NS = "urn:openspp:vocab:group-membership-type" + + +def get_or_create_membership_kind(env, code): + """Get a membership type vocabulary code, creating it if not found.""" + kind = env["spp.vocabulary.code"].get_code(MEMBERSHIP_TYPE_NS, code) + if not kind: + vocab = env["spp.vocabulary"].search( + [("namespace_uri", "=", MEMBERSHIP_TYPE_NS)], limit=1 + ) + defs = _MEMBERSHIP_TYPE_CODES[code] + kind = env["spp.vocabulary.code"].create( + { + "vocabulary_id": vocab.id, + "code": code, + "display": defs["display"], + "sequence": defs["sequence"], + "is_local": True, + } + ) + return kind + @tagged("post_install", "-at_install") class CRTestCase(TransactionCase): diff --git a/spp_change_request_v2/tests/test_add_member_strategy.py b/spp_change_request_v2/tests/test_add_member_strategy.py index 8036d2ed..d54db2ac 100644 --- a/spp_change_request_v2/tests/test_add_member_strategy.py +++ b/spp_change_request_v2/tests/test_add_member_strategy.py @@ -4,6 +4,8 @@ from odoo.exceptions import UserError from odoo.tests import TransactionCase +from .common import get_or_create_cr_type + class TestAddMemberStrategy(TransactionCase): """Tests for Add Member custom strategy.""" @@ -32,17 +34,11 @@ def setUpClass(cls): } ) - # Get CR type - cls.cr_type = cls.env.ref( - "spp_change_request_v2.cr_type_add_member", - raise_if_not_found=False, - ) + # Get or create CR type + cls.cr_type = get_or_create_cr_type(cls.env, "add_member") def test_add_member_creates_individual(self): """Test adding member creates individual registrant.""" - if not self.cr_type: - self.skipTest("Add member CR type not found") - cr = self.cr_model.create( { "request_type_id": self.cr_type.id, @@ -76,9 +72,6 @@ def test_add_member_creates_individual(self): def test_add_member_creates_membership(self): """Test membership link created.""" - if not self.cr_type: - self.skipTest("Add member CR type not found") - cr = self.cr_model.create( { "request_type_id": self.cr_type.id, @@ -110,9 +103,6 @@ def test_add_member_creates_membership(self): def test_add_member_to_individual_fails(self): """Test adding member to individual registrant fails.""" - if not self.cr_type: - self.skipTest("Add member CR type not found") - cr = self.cr_model.create( { "request_type_id": self.cr_type.id, @@ -138,9 +128,6 @@ def test_add_member_to_individual_fails(self): def test_add_member_preview(self): """Test preview returns expected structure.""" - if not self.cr_type: - self.skipTest("Add member CR type not found") - cr = self.cr_model.create( { "request_type_id": self.cr_type.id, diff --git a/spp_change_request_v2/tests/test_change_hoh_strategy.py b/spp_change_request_v2/tests/test_change_hoh_strategy.py index c1899e64..d5ccf004 100644 --- a/spp_change_request_v2/tests/test_change_hoh_strategy.py +++ b/spp_change_request_v2/tests/test_change_hoh_strategy.py @@ -5,6 +5,8 @@ from odoo.exceptions import UserError from odoo.tests import TransactionCase +from .common import get_or_create_cr_type, get_or_create_membership_kind + class TestChangeHOHStrategy(TransactionCase): """Tests for Change Head of Household custom strategy.""" @@ -19,8 +21,8 @@ def setUpClass(cls): # Get head membership kind from vocabulary cls.head_kind = cls.env["spp.vocabulary.code"].get_code("urn:openspp:vocab:group-membership-type", "head") - # Get spouse kind from vocabulary - cls.spouse_kind = cls.env["spp.vocabulary.code"].get_code("urn:openspp:vocab:group-membership-type", "spouse") + # Get or create spouse kind from vocabulary + cls.spouse_kind = get_or_create_membership_kind(cls.env, "spouse") # Create test group cls.group = cls.partner_model.create( @@ -64,16 +66,11 @@ def setUpClass(cls): } ) - # Get CR type - cls.cr_type = cls.env.ref( - "spp_change_request_v2.cr_type_change_hoh", - raise_if_not_found=False, - ) + # Get or create CR type + cls.cr_type = get_or_create_cr_type(cls.env, "change_hoh") def test_change_hoh_transfers_role(self): """Test changing HOH transfers head role.""" - if not self.cr_type or not self.head_kind: - self.skipTest("Change HOH CR type or head kind not found") cr = self.cr_model.create( { @@ -109,8 +106,6 @@ def test_change_hoh_transfers_role(self): def test_change_hoh_assigns_new_role_to_previous(self): """Test previous head gets new role assigned.""" - if not self.cr_type or not self.head_kind: - self.skipTest("Change HOH CR type or head kind not found") cr = self.cr_model.create( { @@ -141,8 +136,6 @@ def test_change_hoh_assigns_new_role_to_previous(self): def test_change_hoh_on_individual_fails(self): """Test cannot change HOH on individual registrant.""" - if not self.cr_type: - self.skipTest("Change HOH CR type not found") cr = self.cr_model.create( { @@ -169,8 +162,6 @@ def test_change_hoh_on_individual_fails(self): def test_change_hoh_all_reasons(self): """Test all change reasons work.""" - if not self.cr_type: - self.skipTest("Change HOH CR type not found") reasons = [ "deceased", @@ -244,8 +235,6 @@ def test_change_hoh_all_reasons(self): def test_change_hoh_preview(self): """Test preview returns expected structure.""" - if not self.cr_type: - self.skipTest("Change HOH CR type not found") cr = self.cr_model.create( { diff --git a/spp_change_request_v2/tests/test_create_group_strategy.py b/spp_change_request_v2/tests/test_create_group_strategy.py index ae549ad7..c07fc7a1 100644 --- a/spp_change_request_v2/tests/test_create_group_strategy.py +++ b/spp_change_request_v2/tests/test_create_group_strategy.py @@ -4,6 +4,8 @@ from odoo.exceptions import UserError from odoo.tests import TransactionCase +from .common import get_or_create_cr_type + class TestCreateGroupStrategy(TransactionCase): """Tests for Create Group custom strategy.""" @@ -39,15 +41,10 @@ def setUpClass(cls): } ) - cls.cr_type = cls.env.ref( - "spp_change_request_v2.cr_type_create_group", - raise_if_not_found=False, - ) + cls.cr_type = get_or_create_cr_type(cls.env, "create_group") def test_create_group_basic(self): """Test creating new group.""" - if not self.cr_type: - self.skipTest("Create group CR type not found") cr = self.cr_model.create( { @@ -83,8 +80,6 @@ def test_create_group_basic(self): def test_create_group_with_existing_head(self): """Test creating group with existing individual as head.""" - if not self.cr_type: - self.skipTest("Create group CR type not found") cr = self.cr_model.create( { @@ -126,8 +121,6 @@ def test_create_group_with_existing_head(self): def test_create_group_with_new_head(self): """Test creating group with new individual as head.""" - if not self.cr_type: - self.skipTest("Create group CR type not found") cr = self.cr_model.create( { @@ -165,7 +158,7 @@ def test_create_group_with_new_head(self): self.assertTrue(membership) new_head = membership.individual - self.assertEqual(new_head.name, "Juan Dela Cruz") + self.assertEqual(new_head.name, "DELA CRUZ, JUAN") self.assertEqual(new_head.given_name, "Juan") self.assertEqual(new_head.family_name, "Dela Cruz") self.assertTrue(new_head.is_registrant) @@ -173,8 +166,6 @@ def test_create_group_with_new_head(self): def test_create_group_without_name_fails(self): """Test creating group without name fails.""" - if not self.cr_type: - self.skipTest("Create group CR type not found") cr = self.cr_model.create( { @@ -200,8 +191,6 @@ def test_create_group_without_name_fails(self): def test_create_group_new_head_requires_name(self): """Test creating new head requires name.""" - if not self.cr_type: - self.skipTest("Create group CR type not found") cr = self.cr_model.create( { @@ -228,8 +217,6 @@ def test_create_group_new_head_requires_name(self): def test_create_group_preview(self): """Test preview returns expected structure.""" - if not self.cr_type: - self.skipTest("Create group CR type not found") cr = self.cr_model.create( { diff --git a/spp_change_request_v2/tests/test_e2e_workflows.py b/spp_change_request_v2/tests/test_e2e_workflows.py index 2eb69c9c..62553ac7 100644 --- a/spp_change_request_v2/tests/test_e2e_workflows.py +++ b/spp_change_request_v2/tests/test_e2e_workflows.py @@ -8,6 +8,8 @@ from odoo import Command, fields from odoo.tests import TransactionCase +from .common import get_or_create_cr_type, get_or_create_membership_kind + class TestE2EWorkflows(TransactionCase): """End-to-End workflow tests.""" @@ -24,11 +26,9 @@ def setUpClass(cls): # Get head membership kind from vocabulary cls.head_kind = cls.env["spp.vocabulary.code"].get_code("urn:openspp:vocab:group-membership-type", "head") - # Get spouse kind from vocabulary - cls.spouse_kind = cls.env["spp.vocabulary.code"].get_code("urn:openspp:vocab:group-membership-type", "spouse") - - # Get child kind from vocabulary - cls.child_kind = cls.env["spp.vocabulary.code"].get_code("urn:openspp:vocab:group-membership-type", "child") + # Get or create spouse/child kinds from vocabulary + cls.spouse_kind = get_or_create_membership_kind(cls.env, "spouse") + cls.child_kind = get_or_create_membership_kind(cls.env, "child") # Create ID type cls.national_id = cls.id_type_model.create( @@ -38,43 +38,16 @@ def setUpClass(cls): } ) - # Get CR types - cls.add_member_type = cls.env.ref( - "spp_change_request_v2.cr_type_add_member", - raise_if_not_found=False, - ) - cls.remove_member_type = cls.env.ref( - "spp_change_request_v2.cr_type_remove_member", - raise_if_not_found=False, - ) - cls.change_hoh_type = cls.env.ref( - "spp_change_request_v2.cr_type_change_hoh", - raise_if_not_found=False, - ) - cls.exit_registrant_type = cls.env.ref( - "spp_change_request_v2.cr_type_exit_registrant", - raise_if_not_found=False, - ) - cls.transfer_member_type = cls.env.ref( - "spp_change_request_v2.cr_type_transfer_member", - raise_if_not_found=False, - ) - cls.update_id_type = cls.env.ref( - "spp_change_request_v2.cr_type_update_id", - raise_if_not_found=False, - ) - cls.create_group_type = cls.env.ref( - "spp_change_request_v2.cr_type_create_group", - raise_if_not_found=False, - ) - cls.split_household_type = cls.env.ref( - "spp_change_request_v2.cr_type_split_household", - raise_if_not_found=False, - ) - cls.merge_registrants_type = cls.env.ref( - "spp_change_request_v2.cr_type_merge_registrants", - raise_if_not_found=False, - ) + # Get or create CR types + cls.add_member_type = get_or_create_cr_type(cls.env, "add_member") + cls.remove_member_type = get_or_create_cr_type(cls.env, "remove_member") + cls.change_hoh_type = get_or_create_cr_type(cls.env, "change_hoh") + cls.exit_registrant_type = get_or_create_cr_type(cls.env, "exit_registrant") + cls.transfer_member_type = get_or_create_cr_type(cls.env, "transfer_member") + cls.update_id_type = get_or_create_cr_type(cls.env, "update_id") + cls.create_group_type = get_or_create_cr_type(cls.env, "create_group") + cls.split_household_type = get_or_create_cr_type(cls.env, "split_household") + cls.merge_registrants_type = get_or_create_cr_type(cls.env, "merge_registrants") def _approve_and_apply(self, cr): """Helper to approve and apply a CR.""" @@ -96,9 +69,6 @@ def test_scenario_new_household_registration(self): 3. Add child members 4. Add ID documents """ - if not all([self.create_group_type, self.add_member_type, self.update_id_type]): - self.skipTest("Required CR types not found") - # Step 1: Create new group with head placeholder = self.partner_model.create( { @@ -141,7 +111,7 @@ def test_scenario_new_household_registration(self): ] ) head = head_membership.individual - self.assertEqual(head.name, "Juan Dela Cruz") + self.assertEqual(head.name, "DELA CRUZ, JUAN") # Step 2: Add spouse cr2 = self.cr_model.create( @@ -162,7 +132,7 @@ def test_scenario_new_household_registration(self): self._approve_and_apply(cr2) spouse = detail2.created_individual_id - self.assertEqual(spouse.name, "Maria Dela Cruz") + self.assertEqual(spouse.name, "DELA CRUZ, MARIA") # Step 3: Add children for i, name in enumerate(["Pedro", "Ana"]): @@ -232,9 +202,6 @@ def test_scenario_marriage_household_split(self): 2. Adult child gets married - split household 3. Add spouse to new household """ - if not all([self.split_household_type, self.add_member_type]): - self.skipTest("Required CR types not found") - # Setup: Create original household original = self.partner_model.create( { @@ -365,9 +332,6 @@ def test_scenario_hoh_deceased(self): 2. Change head of household to spouse 3. Exit deceased head """ - if not all([self.change_hoh_type, self.exit_registrant_type]): - self.skipTest("Required CR types not found") - # Setup household = self.partner_model.create( { @@ -466,9 +430,6 @@ def test_scenario_duplicate_cleanup(self): 2. Merge duplicates into primary record 3. Verify data consolidated correctly """ - if not self.merge_registrants_type: - self.skipTest("Merge registrants CR type not found") - # Setup: Create "duplicate" records primary = self.partner_model.create( { @@ -554,9 +515,6 @@ def test_scenario_member_transfer(self): 2. Transfer member from source to target 3. Verify membership changes """ - if not self.transfer_member_type: - self.skipTest("Transfer member CR type not found") - # Setup source = self.partner_model.create( { @@ -635,16 +593,6 @@ def test_scenario_full_lifecycle(self): 5. Exit remaining member (e.g., emigration) 6. Exit household """ - if not all( - [ - self.create_group_type, - self.add_member_type, - self.remove_member_type, - self.exit_registrant_type, - ] - ): - self.skipTest("Required CR types not found") - # Step 1: Create household placeholder = self.partner_model.create( { diff --git a/spp_change_request_v2/tests/test_exit_registrant_strategy.py b/spp_change_request_v2/tests/test_exit_registrant_strategy.py index 1ca5cb9d..5d44916f 100644 --- a/spp_change_request_v2/tests/test_exit_registrant_strategy.py +++ b/spp_change_request_v2/tests/test_exit_registrant_strategy.py @@ -4,6 +4,8 @@ from odoo import fields from odoo.tests import TransactionCase +from .common import get_or_create_cr_type + class TestExitRegistrantStrategy(TransactionCase): """Tests for Exit Registrant custom strategy.""" @@ -49,16 +51,11 @@ def setUpClass(cls): } ) - # Get CR type - cls.cr_type = cls.env.ref( - "spp_change_request_v2.cr_type_exit_registrant", - raise_if_not_found=False, - ) + # Get or create CR type + cls.cr_type = get_or_create_cr_type(cls.env, "exit_registrant") def test_exit_individual_deactivates(self): """Test exiting individual sets disabled date.""" - if not self.cr_type: - self.skipTest("Exit registrant CR type not found") cr = self.cr_model.create( { @@ -85,8 +82,6 @@ def test_exit_individual_deactivates(self): def test_exit_individual_ends_memberships(self): """Test exiting individual ends active memberships.""" - if not self.cr_type: - self.skipTest("Exit registrant CR type not found") cr = self.cr_model.create( { @@ -114,8 +109,6 @@ def test_exit_individual_ends_memberships(self): def test_exit_group_deactivates(self): """Test exiting group sets disabled date.""" - if not self.cr_type: - self.skipTest("Exit registrant CR type not found") # Create new group to test group = self.partner_model.create( @@ -151,8 +144,6 @@ def test_exit_group_deactivates(self): def test_exit_group_ends_all_memberships(self): """Test exiting group ends all member memberships.""" - if not self.cr_type: - self.skipTest("Exit registrant CR type not found") # Create group with members group = self.partner_model.create( @@ -217,8 +208,6 @@ def test_exit_group_ends_all_memberships(self): def test_exit_all_reasons(self): """Test all exit reasons work correctly.""" - if not self.cr_type: - self.skipTest("Exit registrant CR type not found") reasons = [ "deceased", @@ -263,8 +252,6 @@ def test_exit_all_reasons(self): def test_exit_preview(self): """Test preview returns expected structure.""" - if not self.cr_type: - self.skipTest("Exit registrant CR type not found") cr = self.cr_model.create( { diff --git a/spp_change_request_v2/tests/test_merge_registrants_strategy.py b/spp_change_request_v2/tests/test_merge_registrants_strategy.py index 96108c5d..362b5400 100644 --- a/spp_change_request_v2/tests/test_merge_registrants_strategy.py +++ b/spp_change_request_v2/tests/test_merge_registrants_strategy.py @@ -5,6 +5,8 @@ from odoo.exceptions import ValidationError from odoo.tests import TransactionCase +from .common import get_or_create_cr_type + class TestMergeRegistrantsStrategy(TransactionCase): """Tests for Merge Registrants custom strategy.""" @@ -79,16 +81,11 @@ def setUpClass(cls): } ) - # Get CR type - cls.cr_type = cls.env.ref( - "spp_change_request_v2.cr_type_merge_registrants", - raise_if_not_found=False, - ) + # Get or create CR type + cls.cr_type = get_or_create_cr_type(cls.env, "merge_registrants") def test_merge_deactivates_duplicates(self): """Test merging deactivates duplicate registrants.""" - if not self.cr_type: - self.skipTest("Merge registrants CR type not found") cr = self.cr_model.create( { @@ -118,8 +115,6 @@ def test_merge_deactivates_duplicates(self): def test_merge_transfers_memberships(self): """Test merging transfers memberships to primary.""" - if not self.cr_type: - self.skipTest("Merge registrants CR type not found") cr = self.cr_model.create( { @@ -149,8 +144,6 @@ def test_merge_transfers_memberships(self): def test_merge_transfers_ids(self): """Test merging transfers IDs to primary.""" - if not self.cr_type: - self.skipTest("Merge registrants CR type not found") cr = self.cr_model.create( { @@ -180,8 +173,6 @@ def test_merge_transfers_ids(self): def test_merge_multiple_duplicates(self): """Test merging multiple duplicates at once.""" - if not self.cr_type: - self.skipTest("Merge registrants CR type not found") # Create more duplicates dup3 = self.partner_model.create( @@ -221,8 +212,6 @@ def test_merge_multiple_duplicates(self): def test_merge_same_type_only(self): """Test cannot merge individuals with groups.""" - if not self.cr_type: - self.skipTest("Merge registrants CR type not found") cr = self.cr_model.create( { @@ -244,8 +233,6 @@ def test_merge_same_type_only(self): def test_merge_cannot_include_primary(self): """Test cannot include primary in duplicates list.""" - if not self.cr_type: - self.skipTest("Merge registrants CR type not found") cr = self.cr_model.create( { @@ -267,8 +254,6 @@ def test_merge_cannot_include_primary(self): def test_merge_all_reasons(self): """Test all merge reasons work.""" - if not self.cr_type: - self.skipTest("Merge registrants CR type not found") reasons = [ "duplicate_entry", @@ -320,8 +305,6 @@ def test_merge_all_reasons(self): def test_merge_preview(self): """Test preview returns expected structure.""" - if not self.cr_type: - self.skipTest("Merge registrants CR type not found") cr = self.cr_model.create( { diff --git a/spp_change_request_v2/tests/test_remove_member_strategy.py b/spp_change_request_v2/tests/test_remove_member_strategy.py index d3a44844..931132a6 100644 --- a/spp_change_request_v2/tests/test_remove_member_strategy.py +++ b/spp_change_request_v2/tests/test_remove_member_strategy.py @@ -5,6 +5,8 @@ from odoo.exceptions import UserError from odoo.tests import TransactionCase +from .common import get_or_create_cr_type + class TestRemoveMemberStrategy(TransactionCase): """Tests for Remove Member custom strategy.""" @@ -57,16 +59,11 @@ def setUpClass(cls): } ) - # Get CR type - cls.cr_type = cls.env.ref( - "spp_change_request_v2.cr_type_remove_member", - raise_if_not_found=False, - ) + # Get or create CR type + cls.cr_type = get_or_create_cr_type(cls.env, "remove_member") def test_remove_member_ends_membership(self): """Test removing member sets ended_date on membership.""" - if not self.cr_type: - self.skipTest("Remove member CR type not found") cr = self.cr_model.create( { @@ -94,8 +91,6 @@ def test_remove_member_ends_membership(self): def test_remove_member_inactive_fails(self): """Test removing already inactive member fails.""" - if not self.cr_type: - self.skipTest("Remove member CR type not found") # End membership first self.membership2.write({"ended_date": fields.Datetime.now()}) @@ -125,8 +120,6 @@ def test_remove_member_inactive_fails(self): def test_remove_member_from_individual_fails(self): """Test cannot remove member from individual registrant.""" - if not self.cr_type: - self.skipTest("Remove member CR type not found") cr = self.cr_model.create( { @@ -153,8 +146,6 @@ def test_remove_member_from_individual_fails(self): def test_remove_member_preview(self): """Test preview returns expected structure.""" - if not self.cr_type: - self.skipTest("Remove member CR type not found") cr = self.cr_model.create( { @@ -180,8 +171,6 @@ def test_remove_member_preview(self): def test_remove_member_all_reasons(self): """Test all removal reasons work correctly.""" - if not self.cr_type: - self.skipTest("Remove member CR type not found") reasons = [ "left_household", diff --git a/spp_change_request_v2/tests/test_split_household_strategy.py b/spp_change_request_v2/tests/test_split_household_strategy.py index 106f7719..af889f2f 100644 --- a/spp_change_request_v2/tests/test_split_household_strategy.py +++ b/spp_change_request_v2/tests/test_split_household_strategy.py @@ -5,6 +5,8 @@ from odoo.exceptions import ValidationError from odoo.tests import TransactionCase +from .common import get_or_create_cr_type + class TestSplitHouseholdStrategy(TransactionCase): """Tests for Split Household custom strategy.""" @@ -96,16 +98,11 @@ def setUpClass(cls): } ) - # Get CR type - cls.cr_type = cls.env.ref( - "spp_change_request_v2.cr_type_split_household", - raise_if_not_found=False, - ) + # Get or create CR type + cls.cr_type = get_or_create_cr_type(cls.env, "split_household") def test_split_creates_new_group(self): """Test splitting creates new group.""" - if not self.cr_type: - self.skipTest("Split household CR type not found") cr = self.cr_model.create( { @@ -140,8 +137,6 @@ def test_split_creates_new_group(self): def test_split_copies_address(self): """Test splitting copies address from source.""" - if not self.cr_type: - self.skipTest("Split household CR type not found") cr = self.cr_model.create( { @@ -173,8 +168,6 @@ def test_split_copies_address(self): def test_split_transfers_members(self): """Test splitting transfers selected members.""" - if not self.cr_type: - self.skipTest("Split household CR type not found") cr = self.cr_model.create( { @@ -218,8 +211,6 @@ def test_split_transfers_members(self): def test_split_assigns_head_role(self): """Test splitting assigns head role to new head.""" - if not self.cr_type or not self.head_kind: - self.skipTest("Split household CR type or head kind not found") cr = self.cr_model.create( { @@ -256,8 +247,6 @@ def test_split_assigns_head_role(self): def test_split_cannot_move_all_members(self): """Test cannot move all members from source group.""" - if not self.cr_type: - self.skipTest("Split household CR type not found") # Create group with only 2 members small_group = self.partner_model.create( @@ -306,8 +295,6 @@ def test_split_cannot_move_all_members(self): def test_split_head_must_be_in_split(self): """Test new head must be in members to split.""" - if not self.cr_type: - self.skipTest("Split household CR type not found") cr = self.cr_model.create( { @@ -321,8 +308,8 @@ def test_split_head_must_be_in_split(self): with self.assertRaises(ValidationError): detail.write( { - "members_to_split_ids": [(6, 0, [self.membership3.id])], - "new_head_membership_id": self.membership4.id, # Not in split list + "registrant_member_to_split_ids": [(6, 0, [self.member3.id])], + "new_head_individual_id": self.member4.id, # Not in split list "new_group_name": "Invalid Head", "split_reason": "other", "effective_date": fields.Date.today(), @@ -331,8 +318,6 @@ def test_split_head_must_be_in_split(self): def test_split_all_reasons(self): """Test all split reasons work.""" - if not self.cr_type: - self.skipTest("Split household CR type not found") reasons = [ "marriage", @@ -407,8 +392,6 @@ def test_split_all_reasons(self): def test_split_preview(self): """Test preview returns expected structure.""" - if not self.cr_type: - self.skipTest("Split household CR type not found") cr = self.cr_model.create( { diff --git a/spp_change_request_v2/tests/test_transfer_member_strategy.py b/spp_change_request_v2/tests/test_transfer_member_strategy.py index b4e075b0..e12cbb29 100644 --- a/spp_change_request_v2/tests/test_transfer_member_strategy.py +++ b/spp_change_request_v2/tests/test_transfer_member_strategy.py @@ -5,6 +5,8 @@ from odoo.exceptions import UserError from odoo.tests import TransactionCase +from .common import get_or_create_cr_type, get_or_create_membership_kind + class TestTransferMemberStrategy(TransactionCase): """Tests for Transfer Member custom strategy.""" @@ -16,8 +18,8 @@ def setUpClass(cls): cls.membership_model = cls.env["spp.group.membership"] cls.cr_model = cls.env["spp.change.request"] - # Get membership kind from vocabulary - cls.member_kind = cls.env["spp.vocabulary.code"].get_code("urn:openspp:vocab:group-membership-type", "other") + # Get or create membership kind from vocabulary + cls.member_kind = get_or_create_membership_kind(cls.env, "other") # Create source group cls.source_group = cls.partner_model.create( @@ -55,16 +57,11 @@ def setUpClass(cls): } ) - # Get CR type - cls.cr_type = cls.env.ref( - "spp_change_request_v2.cr_type_transfer_member", - raise_if_not_found=False, - ) + # Get or create CR type + cls.cr_type = get_or_create_cr_type(cls.env, "transfer_member") def test_transfer_member_creates_new_membership(self): """Test transferring member creates membership in target group.""" - if not self.cr_type: - self.skipTest("Transfer member CR type not found") cr = self.cr_model.create( { @@ -105,8 +102,6 @@ def test_transfer_member_creates_new_membership(self): def test_transfer_member_with_role(self): """Test transferring member assigns new role.""" - if not self.cr_type: - self.skipTest("Transfer member CR type not found") # Create new member individual = self.partner_model.create( @@ -157,8 +152,6 @@ def test_transfer_member_with_role(self): def test_transfer_to_same_group_fails(self): """Test cannot transfer to same group.""" - if not self.cr_type: - self.skipTest("Transfer member CR type not found") cr = self.cr_model.create( { @@ -181,8 +174,6 @@ def test_transfer_to_same_group_fails(self): def test_transfer_existing_member_fails(self): """Test cannot transfer if already member of target group.""" - if not self.cr_type: - self.skipTest("Transfer member CR type not found") # Create individual already in target group individual = self.partner_model.create( @@ -235,8 +226,6 @@ def test_transfer_existing_member_fails(self): def test_transfer_inactive_membership_fails(self): """Test cannot transfer inactive membership.""" - if not self.cr_type: - self.skipTest("Transfer member CR type not found") # Create and end membership individual = self.partner_model.create( @@ -281,8 +270,6 @@ def test_transfer_inactive_membership_fails(self): def test_transfer_all_reasons(self): """Test all transfer reasons work.""" - if not self.cr_type: - self.skipTest("Transfer member CR type not found") reasons = [ "marriage", @@ -340,8 +327,6 @@ def test_transfer_all_reasons(self): def test_transfer_preview(self): """Test preview returns expected structure.""" - if not self.cr_type: - self.skipTest("Transfer member CR type not found") cr = self.cr_model.create( { diff --git a/spp_change_request_v2/tests/test_update_id_strategy.py b/spp_change_request_v2/tests/test_update_id_strategy.py index f67bef45..791ec412 100644 --- a/spp_change_request_v2/tests/test_update_id_strategy.py +++ b/spp_change_request_v2/tests/test_update_id_strategy.py @@ -5,6 +5,8 @@ from odoo.exceptions import UserError from odoo.tests import TransactionCase +from .common import get_or_create_cr_type + class TestUpdateIDStrategy(TransactionCase): """Tests for Update ID Document custom strategy.""" @@ -55,16 +57,11 @@ def setUpClass(cls): } ) - # Get CR type - cls.cr_type = cls.env.ref( - "spp_change_request_v2.cr_type_update_id", - raise_if_not_found=False, - ) + # Get or create CR type + cls.cr_type = get_or_create_cr_type(cls.env, "update_id") def test_add_new_id(self): """Test adding new ID document.""" - if not self.cr_type: - self.skipTest("Update ID CR type not found") cr = self.cr_model.create( { @@ -101,8 +98,6 @@ def test_add_new_id(self): def test_add_duplicate_id_type_fails(self): """Test adding duplicate ID type fails.""" - if not self.cr_type: - self.skipTest("Update ID CR type not found") cr = self.cr_model.create( { @@ -129,8 +124,6 @@ def test_add_duplicate_id_type_fails(self): def test_update_existing_id(self): """Test updating existing ID document.""" - if not self.cr_type: - self.skipTest("Update ID CR type not found") cr = self.cr_model.create( { @@ -159,8 +152,6 @@ def test_update_existing_id(self): def test_remove_id(self): """Test removing (invalidating) ID document.""" - if not self.cr_type: - self.skipTest("Update ID CR type not found") # Create ID to remove id_to_remove = self.id_model.create( @@ -197,8 +188,6 @@ def test_remove_id(self): def test_update_without_existing_id_fails(self): """Test update operation requires existing ID.""" - if not self.cr_type: - self.skipTest("Update ID CR type not found") cr = self.cr_model.create( { @@ -226,8 +215,6 @@ def test_update_without_existing_id_fails(self): def test_add_requires_value(self): """Test add operation requires ID value.""" - if not self.cr_type: - self.skipTest("Update ID CR type not found") cr = self.cr_model.create( { @@ -254,8 +241,6 @@ def test_add_requires_value(self): def test_update_id_preview(self): """Test preview returns expected structure.""" - if not self.cr_type: - self.skipTest("Update ID CR type not found") cr = self.cr_model.create( { diff --git a/spp_claim_169/README.rst b/spp_claim_169/README.rst index 7e9c2df7..5ad50a64 100644 --- a/spp_claim_169/README.rst +++ b/spp_claim_169/README.rst @@ -35,43 +35,43 @@ lifecycle tracking. Key Capabilities ~~~~~~~~~~~~~~~~ -- Generate signed QR credentials using MOSIP Claim 169 standard with - Ed25519 or EC keys -- Configure mappings from partner fields to numbered claim attributes - (1-99) -- Track credential lifecycle with automatic expiration and manual - revocation -- Verify credential authenticity using public key verification -- Transform data with multiple formats: direct copy, date formatting, - gender codes, address combination, and CEL expressions -- Batch generate credentials for multiple registrants with configurable - replacement modes -- Audit credential generation, revocation, and download events +- Generate signed QR credentials using MOSIP Claim 169 standard with + Ed25519 or EC keys +- Configure mappings from partner fields to numbered claim attributes + (1-99) +- Track credential lifecycle with automatic expiration and manual + revocation +- Verify credential authenticity using public key verification +- Transform data with multiple formats: direct copy, date formatting, + gender codes, address combination, and CEL expressions +- Batch generate credentials for multiple registrants with configurable + replacement modes +- Audit credential generation, revocation, and download events Key Models ~~~~~~~~~~ -+----------------------------------+----------------------------------+ -| Model | Description | -+==================================+==================================+ -| ``spp.claim169.credential`` | Stores issued credentials with | -| | QR codes and validity dates | -+----------------------------------+----------------------------------+ -| ``spp.claim169.issuer.config`` | Defines issuer identity and | -| | signing keys | -+----------------------------------+----------------------------------+ -| `` | Maps partner fields to claim | -| spp.claim169.attribute.mapping`` | attribute numbers | -+----------------------------------+----------------------------------+ -| ``spp.claim169.service`` | Service for credential | -| | generation and verification | -+----------------------------------+----------------------------------+ -| ``s | Wizard for batch credential | -| pp.claim169.generate.qr.wizard`` | generation | -+----------------------------------+----------------------------------+ -| ` | Wizard for credential | -| `spp.claim169.verify.qr.wizard`` | verification | -+----------------------------------+----------------------------------+ ++-------------------------------------+----------------------------------+ +| Model | Description | ++=====================================+==================================+ +| ``spp.claim169.credential`` | Stores issued credentials with | +| | QR codes and validity dates | ++-------------------------------------+----------------------------------+ +| ``spp.claim169.issuer.config`` | Defines issuer identity and | +| | signing keys | ++-------------------------------------+----------------------------------+ +| ``spp.claim169.attribute.mapping`` | Maps partner fields to claim | +| | attribute numbers | ++-------------------------------------+----------------------------------+ +| ``spp.claim169.service`` | Service for credential | +| | generation and verification | ++-------------------------------------+----------------------------------+ +| ``spp.claim169.generate.qr.wizard`` | Wizard for batch credential | +| | generation | ++-------------------------------------+----------------------------------+ +| ``spp.claim169.verify.qr.wizard`` | Wizard for credential | +| | verification | ++-------------------------------------+----------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -93,38 +93,36 @@ After installing: UI Location ~~~~~~~~~~~ -- **Configuration**: Registry > Configuration > QR Credentials +- **Configuration**: Registry > Configuration > QR Credentials - - Issuer Configurations - - Attribute Mappings + - Issuer Configurations + - Attribute Mappings -- **Credentials**: Accessed from registrant profile under "QR - Credentials" section on Identity tab -- **Generate**: Button on partner form opens generation wizard -- **Verify**: Use verification wizard to validate credentials +- **Credentials**: Accessed from registrant profile under "QR + Credentials" section on Identity tab +- **Generate**: Button on partner form opens generation wizard +- **Verify**: Use verification wizard to validate credentials Security ~~~~~~~~ -+------------------------+--------------+---------------+-----------+ -| Group | Credentials | Configuration | Wizards | -+========================+==============+===============+===========+ -| ``spp_claim_169 | Read, Create | Read only | Full CRUD | -| .group_claim169_user`` | | | | -+------------------------+--------------+---------------+-----------+ -| ``spp_claim_169.gr | Full CRUD | Full CRUD | Full CRUD | -| oup_claim169_manager`` | | | | -+------------------------+--------------+---------------+-----------+ ++------------------------------------------+--------------+---------------+-----------+ +| Group | Credentials | Configuration | Wizards | ++==========================================+==============+===============+===========+ +| ``spp_claim_169.group_claim169_user`` | Read, Create | Read only | Full CRUD | ++------------------------------------------+--------------+---------------+-----------+ +| ``spp_claim_169.group_claim169_manager`` | Full CRUD | Full CRUD | Full CRUD | ++------------------------------------------+--------------+---------------+-----------+ Extension Points ~~~~~~~~~~~~~~~~ -- Override ``spp.claim169.attribute.mapping._transform_value()`` to add - custom transformation types -- Inherit ``spp.claim169.service._build_claim169_input()`` to customize - claim structure -- Extend ``spp.claim169.credential`` to add domain-specific metadata - fields +- Override ``spp.claim169.attribute.mapping._transform_value()`` to add + custom transformation types +- Inherit ``spp.claim169.service._build_claim169_input()`` to customize + claim structure +- Extend ``spp.claim169.credential`` to add domain-specific metadata + fields Dependencies ~~~~~~~~~~~~ diff --git a/spp_consent/README.rst b/spp_consent/README.rst index 45339709..baa6fc7b 100644 --- a/spp_consent/README.rst +++ b/spp_consent/README.rst @@ -37,66 +37,65 @@ groups. Key Capabilities ~~~~~~~~~~~~~~~~ -- Record consent with ISO 27560 four-section structure (metadata, - parties, processing, consent specifics) -- Track consent lifecycle with state validation: requested → - given/refused, given → renewed/withdrawn/expired/invalidated -- Two-mode recipients: specific organizations OR organization - categories (e.g., "all NGOs but not private sector") -- Maintain audit history per GDPR Article 7 requirements (who, what, - when, why, how) -- Handle delegation (guardian, parent, power of attorney) with evidence - attachment support -- Enforce notice-as-boundary: consent terms cannot exceed privacy - notice scope -- Export consent records as JSON-LD or generate ISO 27560 receipts for - interoperability -- Automatically expire consents via scheduled cron job (batch - processing) -- Protect consent terms from modification after given (immutable - fields) +- Record consent with ISO 27560 four-section structure (metadata, + parties, processing, consent specifics) +- Track consent lifecycle with state validation: requested → + given/refused, given → renewed/withdrawn/expired/invalidated +- Two-mode recipients: specific organizations OR organization categories + (e.g., "all NGOs but not private sector") +- Maintain audit history per GDPR Article 7 requirements (who, what, + when, why, how) +- Handle delegation (guardian, parent, power of attorney) with evidence + attachment support +- Enforce notice-as-boundary: consent terms cannot exceed privacy notice + scope +- Export consent records as JSON-LD or generate ISO 27560 receipts for + interoperability +- Automatically expire consents via scheduled cron job (batch + processing) +- Protect consent terms from modification after given (immutable fields) Key Models ~~~~~~~~~~ -+----------------------------------+----------------------------------+ -| Model | Description | -+==================================+==================================+ -| ``spp.consent`` | Consent record implementing ISO | -| | 27560 structure with DPV fields | -+----------------------------------+----------------------------------+ -| ``spp.consent.history`` | Audit trail of consent changes | -| | (action, status, user, | -| | timestamp) | -+----------------------------------+----------------------------------+ -| ``spp.consent.notice`` | Privacy notices per ISO 29184 | -| | with version tracking | -+----------------------------------+----------------------------------+ -| ``spp.consent.purpose`` | DPV-aligned purpose taxonomy | -| | (service delivery, research, | -| | etc.) | -+----------------------------------+----------------------------------+ -| ``spp.consent.personal.data`` | DPV-aligned data categories | -| | (GDPR Article 9 sensitivity | -| | tagging) | -+----------------------------------+----------------------------------+ -| ``spp.consent.processing`` | DPV-aligned processing | -| | operations (collect, store, | -| | share, etc.) | -+----------------------------------+----------------------------------+ -| ``spp.consent.org.type`` | Organization type categories for | -| | category-based consent | -+----------------------------------+----------------------------------+ -| ``spp.consent.mixin`` | Abstract mixin to add consent | -| | tracking to any model | -+----------------------------------+----------------------------------+ -| ``spp.record.consent.wizard`` | Wizard for recording individual | -| | consent | -+----------------------------------+----------------------------------+ -| `` | Wizard for bulk consent | -| spp.bulk.record.consent.wizard`` | recording across multiple | -| | beneficiaries | -+----------------------------------+----------------------------------+ ++------------------------------------+----------------------------------+ +| Model | Description | ++====================================+==================================+ +| ``spp.consent`` | Consent record implementing ISO | +| | 27560 structure with DPV fields | ++------------------------------------+----------------------------------+ +| ``spp.consent.history`` | Audit trail of consent changes | +| | (action, status, user, | +| | timestamp) | ++------------------------------------+----------------------------------+ +| ``spp.consent.notice`` | Privacy notices per ISO 29184 | +| | with version tracking | ++------------------------------------+----------------------------------+ +| ``spp.consent.purpose`` | DPV-aligned purpose taxonomy | +| | (service delivery, research, | +| | etc.) | ++------------------------------------+----------------------------------+ +| ``spp.consent.personal.data`` | DPV-aligned data categories | +| | (GDPR Article 9 sensitivity | +| | tagging) | ++------------------------------------+----------------------------------+ +| ``spp.consent.processing`` | DPV-aligned processing | +| | operations (collect, store, | +| | share, etc.) | ++------------------------------------+----------------------------------+ +| ``spp.consent.org.type`` | Organization type categories for | +| | category-based consent | ++------------------------------------+----------------------------------+ +| ``spp.consent.mixin`` | Abstract mixin to add consent | +| | tracking to any model | ++------------------------------------+----------------------------------+ +| ``spp.record.consent.wizard`` | Wizard for recording individual | +| | consent | ++------------------------------------+----------------------------------+ +| ``spp.bulk.record.consent.wizard`` | Wizard for bulk consent | +| | recording across multiple | +| | beneficiaries | ++------------------------------------+----------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -117,58 +116,55 @@ After installing: UI Location ~~~~~~~~~~~ -- **Menu**: Registry > Configuration > Consent Management > Consent - Records -- **Configuration Submenus**: - - - Registry > Configuration > Consent Management > Configuration > - Purposes (DPV) - - Registry > Configuration > Consent Management > Configuration > - Personal Data Categories - - Registry > Configuration > Consent Management > Configuration > - Processing Operations - - Registry > Configuration > Consent Management > Configuration > - Privacy Notices - - Registry > Configuration > Consent Management > Configuration > - Organization Types - -- **Registrant Access**: "Record Consent" stat button on individual and - group forms (added by ``spp.consent.mixin``) -- **Form Tabs**: Consent form has Processing, Consent Details, Audit - Trail, and Technical tabs -- **Notice Tabs**: Privacy Notice form has Summary, Full Notice, ISO - 29184 Elements, Contact, DPV Taxonomy, and Consent Boundaries tabs +- **Menu**: Registry > Configuration > Consent Management > Consent + Records +- **Configuration Submenus**: + + - Registry > Configuration > Consent Management > Configuration > + Purposes (DPV) + - Registry > Configuration > Consent Management > Configuration > + Personal Data Categories + - Registry > Configuration > Consent Management > Configuration > + Processing Operations + - Registry > Configuration > Consent Management > Configuration > + Privacy Notices + - Registry > Configuration > Consent Management > Configuration > + Organization Types + +- **Registrant Access**: "Record Consent" stat button on individual and + group forms (added by ``spp.consent.mixin``) +- **Form Tabs**: Consent form has Processing, Consent Details, Audit + Trail, and Technical tabs +- **Notice Tabs**: Privacy Notice form has Summary, Full Notice, ISO + 29184 Elements, Contact, DPV Taxonomy, and Consent Boundaries tabs Security ~~~~~~~~ -+----------------------+----------------------+----------------------+ -| Group | Model | Access | -+======================+======================+======================+ -| ``spp_registry.gro | All models | Read | -| up_registry_viewer`` | | | -+----------------------+----------------------+----------------------+ -| ``spp_registry.grou | ``spp.consent`` | Read/Write/Create | -| p_registry_officer`` | | (no delete) | -+----------------------+----------------------+----------------------+ -| ``spp_registry.grou | Wizards | Read/Write/Create | -| p_registry_officer`` | | (no delete) | -+----------------------+----------------------+----------------------+ -| ``spp_registry.grou | DPV taxonomies and | Read | -| p_registry_officer`` | notices | | -+----------------------+----------------------+----------------------+ -| ``spp_registry.grou | ``spp.consent`` | Full CRUD | -| p_registry_manager`` | | | -+----------------------+----------------------+----------------------+ -| ``spp_registry.grou | ``s | Read/Create (no | -| p_registry_manager`` | pp.consent.history`` | write/delete) | -+----------------------+----------------------+----------------------+ -| ``spp_registry.grou | Taxonomies, notices, | Full CRUD | -| p_registry_manager`` | org types | | -+----------------------+----------------------+----------------------+ -| ``spp_securi | All models | Full CRUD | -| ty.group_spp_admin`` | | | -+----------------------+----------------------+----------------------+ ++-----------------------------------------+-------------------------+----------------------+ +| Group | Model | Access | ++=========================================+=========================+======================+ +| ``spp_registry.group_registry_viewer`` | All models | Read | ++-----------------------------------------+-------------------------+----------------------+ +| ``spp_registry.group_registry_officer`` | ``spp.consent`` | Read/Write/Create | +| | | (no delete) | ++-----------------------------------------+-------------------------+----------------------+ +| ``spp_registry.group_registry_officer`` | Wizards | Read/Write/Create | +| | | (no delete) | ++-----------------------------------------+-------------------------+----------------------+ +| ``spp_registry.group_registry_officer`` | DPV taxonomies and | Read | +| | notices | | ++-----------------------------------------+-------------------------+----------------------+ +| ``spp_registry.group_registry_manager`` | ``spp.consent`` | Full CRUD | ++-----------------------------------------+-------------------------+----------------------+ +| ``spp_registry.group_registry_manager`` | ``spp.consent.history`` | Read/Create (no | +| | | write/delete) | ++-----------------------------------------+-------------------------+----------------------+ +| ``spp_registry.group_registry_manager`` | Taxonomies, notices, | Full CRUD | +| | org types | | ++-----------------------------------------+-------------------------+----------------------+ +| ``spp_security.group_spp_admin`` | All models | Full CRUD | ++-----------------------------------------+-------------------------+----------------------+ Note: Configuration menu requires ``spp_security.group_spp_admin`` or ``spp_registry.group_registry_config_admin``. @@ -176,17 +172,17 @@ Note: Configuration menu requires ``spp_security.group_spp_admin`` or Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``spp.consent.mixin`` to add consent tracking to custom - models (provides ``consent_ids`` field and wizard launcher) -- Override ``check_consent()`` on ``spp.consent`` to add custom consent - validation logic for API filtering -- Extend DPV taxonomy models (``spp.consent.purpose``, - ``spp.consent.personal.data``, ``spp.consent.processing``) with - domain-specific terms -- Override ``_compute_consent_summary()`` on ``res.partner`` to - customize cached consent summary for fast API lookups -- Inherit ``spp.consent`` and add hook methods for consent lifecycle - events (e.g., ``_on_consent_given``, ``_on_consent_withdrawn``) +- Inherit ``spp.consent.mixin`` to add consent tracking to custom models + (provides ``consent_ids`` field and wizard launcher) +- Override ``check_consent()`` on ``spp.consent`` to add custom consent + validation logic for API filtering +- Extend DPV taxonomy models (``spp.consent.purpose``, + ``spp.consent.personal.data``, ``spp.consent.processing``) with + domain-specific terms +- Override ``_compute_consent_summary()`` on ``res.partner`` to + customize cached consent summary for fast API lookups +- Inherit ``spp.consent`` and add hook methods for consent lifecycle + events (e.g., ``_on_consent_given``, ``_on_consent_withdrawn``) Dependencies ~~~~~~~~~~~~ diff --git a/spp_consent/static/description/index.html b/spp_consent/static/description/index.html index 80b51103..2ac2c6a3 100644 --- a/spp_consent/static/description/index.html +++ b/spp_consent/static/description/index.html @@ -389,28 +389,27 @@

        Key Capabilities

        parties, processing, consent specifics)
      • Track consent lifecycle with state validation: requested → given/refused, given → renewed/withdrawn/expired/invalidated
      • -
      • Two-mode recipients: specific organizations OR organization -categories (e.g., “all NGOs but not private sector”)
      • +
      • Two-mode recipients: specific organizations OR organization categories +(e.g., “all NGOs but not private sector”)
      • Maintain audit history per GDPR Article 7 requirements (who, what, when, why, how)
      • Handle delegation (guardian, parent, power of attorney) with evidence attachment support
      • -
      • Enforce notice-as-boundary: consent terms cannot exceed privacy -notice scope
      • +
      • Enforce notice-as-boundary: consent terms cannot exceed privacy notice +scope
      • Export consent records as JSON-LD or generate ISO 27560 receipts for interoperability
      • Automatically expire consents via scheduled cron job (batch processing)
      • -
      • Protect consent terms from modification after given (immutable -fields)
      • +
      • Protect consent terms from modification after given (immutable fields)
      • Key Models

        Group
        spp_c -hange_request_v2.group_cr_user
        spp_change_request_v2.group_cr_user Create and submit change requests (read/write/create)
        spp_change -_request_v2.group_cr_validator
        spp_change_request_v2.group_cr_validator Approve/reject, field-level validation (read/write/create)
        spp_change_re -quest_v2.group_cr_validator_hq
        spp_change_request_v2.group_cr_validator_hq HQ-level approval with registry write (read/write/create)
        spp_chan -ge_request_v2.group_cr_manager
        spp_change_request_v2.group_cr_manager Full CRUD including configuration
        spp_change_request -_v2.group_cr_conflict_approver
        spp_change_request_v2.group_cr_conflict_approver Override blocking conflict detections (specialized/functional)
        --++ @@ -458,8 +457,7 @@

        Key Models

        - + @@ -513,9 +511,9 @@

        UI Location

        Security

        Model Wizard for recording individual consent
        `` -spp.bulk.record.consent.wizard``
        spp.bulk.record.consent.wizard Wizard for bulk consent recording across multiple beneficiaries
        ---+++ @@ -524,49 +522,40 @@

        Security

        - + - + - + - + - + - - + + - + - + @@ -578,8 +567,8 @@

        Security

        Extension Points

          -
        • Inherit spp.consent.mixin to add consent tracking to custom -models (provides consent_ids field and wizard launcher)
        • +
        • Inherit spp.consent.mixin to add consent tracking to custom models +(provides consent_ids field and wizard launcher)
        • Override check_consent() on spp.consent to add custom consent validation logic for API filtering
        • Extend DPV taxonomy models (spp.consent.purpose, diff --git a/spp_cr_types_advanced/README.rst b/spp_cr_types_advanced/README.rst index 2e6ca5f7..97560720 100644 --- a/spp_cr_types_advanced/README.rst +++ b/spp_cr_types_advanced/README.rst @@ -37,16 +37,16 @@ logic. Key Capabilities ~~~~~~~~~~~~~~~~ -- **Membership operations**: Add member, remove member, change head of - household, transfer member between groups -- **Group operations**: Create new groups, split households into - separate groups -- **Registrant lifecycle**: Exit and deactivate registrants from the - system -- **Data quality**: Merge duplicate registrant records with full data - consolidation -- All types use ``apply_strategy='custom'`` with Python models that - cannot be modified via Studio +- **Membership operations**: Add member, remove member, change head of + household, transfer member between groups +- **Group operations**: Create new groups, split households into + separate groups +- **Registrant lifecycle**: Exit and deactivate registrants from the + system +- **Data quality**: Merge duplicate registrant records with full data + consolidation +- All types use ``apply_strategy='custom'`` with Python models that + cannot be modified via Studio Models Secured by This Module ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -55,33 +55,33 @@ This module does not define models. It provides data records for ``spp.change.request.type`` and security rules for detail/apply models defined in ``spp_change_request_v2``: -+----------------------+----------------------+----------------------+ -| Detail Model | Apply Model | Purpose | -+======================+======================+======================+ -| ``spp.cr | ``spp.c | Add new member to | -| .detail.add_member`` | r.apply.add_member`` | group | -+----------------------+----------------------+----------------------+ -| ``spp.cr.de | ``spp.cr.a | Remove member from | -| tail.remove_member`` | pply.remove_member`` | group | -+----------------------+----------------------+----------------------+ -| ``spp.cr | ``spp.c | Change head of | -| .detail.change_hoh`` | r.apply.change_hoh`` | household | -+----------------------+----------------------+----------------------+ -| ``spp.cr.deta | ``spp.cr.app | Transfer member | -| il.transfer_member`` | ly.transfer_member`` | between groups | -+----------------------+----------------------+----------------------+ -| ``spp.cr.deta | ``spp.cr.app | Deactivate | -| il.exit_registrant`` | ly.exit_registrant`` | registrant | -+----------------------+----------------------+----------------------+ -| ``spp.cr.d | ``spp.cr. | Create new | -| etail.create_group`` | apply.create_group`` | group/household | -+----------------------+----------------------+----------------------+ -| ``spp.cr.deta | ``spp.cr.app | Split household into | -| il.split_household`` | ly.split_household`` | two groups | -+----------------------+----------------------+----------------------+ -| ``spp.cr.detail | ``spp.cr.apply | Merge duplicate | -| .merge_registrants`` | .merge_registrants`` | registrant records | -+----------------------+----------------------+----------------------+ ++-------------------------------------+------------------------------------+----------------------+ +| Detail Model | Apply Model | Purpose | ++=====================================+====================================+======================+ +| ``spp.cr.detail.add_member`` | ``spp.cr.apply.add_member`` | Add new member to | +| | | group | ++-------------------------------------+------------------------------------+----------------------+ +| ``spp.cr.detail.remove_member`` | ``spp.cr.apply.remove_member`` | Remove member from | +| | | group | ++-------------------------------------+------------------------------------+----------------------+ +| ``spp.cr.detail.change_hoh`` | ``spp.cr.apply.change_hoh`` | Change head of | +| | | household | ++-------------------------------------+------------------------------------+----------------------+ +| ``spp.cr.detail.transfer_member`` | ``spp.cr.apply.transfer_member`` | Transfer member | +| | | between groups | ++-------------------------------------+------------------------------------+----------------------+ +| ``spp.cr.detail.exit_registrant`` | ``spp.cr.apply.exit_registrant`` | Deactivate | +| | | registrant | ++-------------------------------------+------------------------------------+----------------------+ +| ``spp.cr.detail.create_group`` | ``spp.cr.apply.create_group`` | Create new | +| | | group/household | ++-------------------------------------+------------------------------------+----------------------+ +| ``spp.cr.detail.split_household`` | ``spp.cr.apply.split_household`` | Split household into | +| | | two groups | ++-------------------------------------+------------------------------------+----------------------+ +| ``spp.cr.detail.merge_registrants`` | ``spp.cr.apply.merge_registrants`` | Merge duplicate | +| | | registrant records | ++-------------------------------------+------------------------------------+----------------------+ Configuration ~~~~~~~~~~~~~ @@ -98,13 +98,13 @@ After installing: UI Location ~~~~~~~~~~~ -- **Configuration**: Change Requests > Configuration > Change Request - Types -- **Create Requests**: Forms accessible from registrant profiles based - on ``target_type`` (individual/group/both) -- **Type Codes**: ``add_member``, ``remove_member``, ``change_hoh``, - ``transfer_member``, ``exit_registrant``, ``create_group``, - ``split_household``, ``merge_registrants`` +- **Configuration**: Change Requests > Configuration > Change Request + Types +- **Create Requests**: Forms accessible from registrant profiles based + on ``target_type`` (individual/group/both) +- **Type Codes**: ``add_member``, ``remove_member``, ``change_hoh``, + ``transfer_member``, ``exit_registrant``, ``create_group``, + ``split_household``, ``merge_registrants`` Security ~~~~~~~~ @@ -121,12 +121,12 @@ Security rules apply to all eight detail models. Extension Points ~~~~~~~~~~~~~~~~ -- Override apply strategies in - ``spp_change_request_v2/strategies/*.py`` to customize behavior -- Inherit detail models in ``spp_change_request_v2/details/*.py`` to - add fields -- Clone type definitions if ``is_studio_cloneable`` is enabled to - create variants +- Override apply strategies in ``spp_change_request_v2/strategies/*.py`` + to customize behavior +- Inherit detail models in ``spp_change_request_v2/details/*.py`` to add + fields +- Clone type definitions if ``is_studio_cloneable`` is enabled to create + variants Dependencies ~~~~~~~~~~~~ diff --git a/spp_cr_types_advanced/static/description/index.html b/spp_cr_types_advanced/static/description/index.html index 226066a4..ad6c8e11 100644 --- a/spp_cr_types_advanced/static/description/index.html +++ b/spp_cr_types_advanced/static/description/index.html @@ -404,9 +404,9 @@

          Models Secured by This Module

          defined in spp_change_request_v2:

        Group
        spp_registry.gro -up_registry_viewer
        spp_registry.group_registry_viewer All models Read
        spp_registry.grou -p_registry_officer
        spp_registry.group_registry_officer spp.consent Read/Write/Create (no delete)
        spp_registry.grou -p_registry_officer
        spp_registry.group_registry_officer Wizards Read/Write/Create (no delete)
        spp_registry.grou -p_registry_officer
        spp_registry.group_registry_officer DPV taxonomies and notices Read
        spp_registry.grou -p_registry_manager
        spp_registry.group_registry_manager spp.consent Full CRUD
        spp_registry.grou -p_registry_managers -pp.consent.history
        spp_registry.group_registry_managerspp.consent.history Read/Create (no write/delete)
        spp_registry.grou -p_registry_manager
        spp_registry.group_registry_manager Taxonomies, notices, org types Full CRUD
        spp_securi -ty.group_spp_admin
        spp_security.group_spp_admin All models Full CRUD
        ---+++ @@ -415,59 +415,43 @@

        Models Secured by This Module

        - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + @@ -524,12 +508,12 @@

        Security

        Extension Points

          -
        • Override apply strategies in -spp_change_request_v2/strategies/*.py to customize behavior
        • -
        • Inherit detail models in spp_change_request_v2/details/*.py to -add fields
        • -
        • Clone type definitions if is_studio_cloneable is enabled to -create variants
        • +
        • Override apply strategies in spp_change_request_v2/strategies/*.py +to customize behavior
        • +
        • Inherit detail models in spp_change_request_v2/details/*.py to add +fields
        • +
        • Clone type definitions if is_studio_cloneable is enabled to create +variants
        diff --git a/spp_cr_types_base/README.rst b/spp_cr_types_base/README.rst index 8ad79781..244b0c81 100644 --- a/spp_cr_types_base/README.rst +++ b/spp_cr_types_base/README.rst @@ -32,41 +32,41 @@ parent module. Key Capabilities ~~~~~~~~~~~~~~~~ -- **Edit Individual Information**: Updates personal data (name, - birthdate, gender), contact information (phone, email), and address - fields using field mapping strategy -- **Edit Group Information**: Updates group/household name, contact - information, and address using field mapping strategy -- **Update ID Document**: Adds, updates, or removes identification - documents using custom application logic with operation selection - (add/update/remove) -- **Field Mapping Configuration**: Pre-configured mappings between - detail model fields and target registrant fields for automatic data - transfer -- **Studio Customization**: All CR types are marked as editable and - cloneable in Studio for implementation-specific requirements +- **Edit Individual Information**: Updates personal data (name, + birthdate, gender), contact information (phone, email), and address + fields using field mapping strategy +- **Edit Group Information**: Updates group/household name, contact + information, and address using field mapping strategy +- **Update ID Document**: Adds, updates, or removes identification + documents using custom application logic with operation selection + (add/update/remove) +- **Field Mapping Configuration**: Pre-configured mappings between + detail model fields and target registrant fields for automatic data + transfer +- **Studio Customization**: All CR types are marked as editable and + cloneable in Studio for implementation-specific requirements Key Models ~~~~~~~~~~ -+----------------------------------+----------------------------------+ -| Model | Description | -+==================================+==================================+ -| ` | Detail form for individual | -| `spp.cr.detail.edit_individual`` | information changes | -+----------------------------------+----------------------------------+ -| ``spp.cr.detail.edit_group`` | Detail form for group/household | -| | information | -+----------------------------------+----------------------------------+ -| ``spp.cr.detail.update_id`` | Detail form for ID document | -| | operations | -+----------------------------------+----------------------------------+ -| ``spp.change.request.type`` | CR type configurations (defined | -| | in parent) | -+----------------------------------+----------------------------------+ -| ``s | Field mappings for field_mapping | -| pp.change.request.type.mapping`` | strategy | -+----------------------------------+----------------------------------+ ++-------------------------------------+----------------------------------+ +| Model | Description | ++=====================================+==================================+ +| ``spp.cr.detail.edit_individual`` | Detail form for individual | +| | information changes | ++-------------------------------------+----------------------------------+ +| ``spp.cr.detail.edit_group`` | Detail form for group/household | +| | information | ++-------------------------------------+----------------------------------+ +| ``spp.cr.detail.update_id`` | Detail form for ID document | +| | operations | ++-------------------------------------+----------------------------------+ +| ``spp.change.request.type`` | CR type configurations (defined | +| | in parent) | ++-------------------------------------+----------------------------------+ +| ``spp.change.request.type.mapping`` | Field mappings for field_mapping | +| | strategy | ++-------------------------------------+----------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -84,37 +84,36 @@ After installing: UI Location ~~~~~~~~~~~ -- **CR Type Selection**: Types appear in the creation wizard at - **Change Requests > New Request** -- **Configuration**: Change Requests > Configuration > Change Request - Types -- **Detail Forms**: Accessed when creating or editing a change request - of the corresponding type +- **CR Type Selection**: Types appear in the creation wizard at **Change + Requests > New Request** +- **Configuration**: Change Requests > Configuration > Change Request + Types +- **Detail Forms**: Accessed when creating or editing a change request + of the corresponding type Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| ``spp_c | Read/write/create detail models | -| hange_request_v2.group_cr_user`` | (no delete) | -+----------------------------------+----------------------------------+ -| ``spp_chan | Full CRUD on detail models | -| ge_request_v2.group_cr_manager`` | | -+----------------------------------+----------------------------------+ ++--------------------------------------------+----------------------------------+ +| Group | Access | ++============================================+==================================+ +| ``spp_change_request_v2.group_cr_user`` | Read/write/create detail models | +| | (no delete) | ++--------------------------------------------+----------------------------------+ +| ``spp_change_request_v2.group_cr_manager`` | Full CRUD on detail models | ++--------------------------------------------+----------------------------------+ Extension Points ~~~~~~~~~~~~~~~~ -- Clone any base type via Studio to create domain-specific variants - (e.g., "Edit Farmer Profile") -- Add custom fields to detail models via Studio; field mappings - auto-discover new fields in dropdown -- Inherit ``spp.cr.apply.update_id`` and override ``apply()`` method to - customize ID document application logic -- Mark types as ``is_studio_editable=False`` in inherited modules to - prevent runtime modification +- Clone any base type via Studio to create domain-specific variants + (e.g., "Edit Farmer Profile") +- Add custom fields to detail models via Studio; field mappings + auto-discover new fields in dropdown +- Inherit ``spp.cr.apply.update_id`` and override ``apply()`` method to + customize ID document application logic +- Mark types as ``is_studio_editable=False`` in inherited modules to + prevent runtime modification Dependencies ~~~~~~~~~~~~ diff --git a/spp_cr_types_base/static/description/index.html b/spp_cr_types_base/static/description/index.html index c8667660..a665e56a 100644 --- a/spp_cr_types_base/static/description/index.html +++ b/spp_cr_types_base/static/description/index.html @@ -402,8 +402,8 @@

        Key Capabilities

        Key Models

        Detail Model
        spp.cr -.detail.add_memberspp.c -r.apply.add_member
        spp.cr.detail.add_memberspp.cr.apply.add_member Add new member to group
        spp.cr.de -tail.remove_memberspp.cr.a -pply.remove_member
        spp.cr.detail.remove_memberspp.cr.apply.remove_member Remove member from group
        spp.cr -.detail.change_hohspp.c -r.apply.change_hoh
        spp.cr.detail.change_hohspp.cr.apply.change_hoh Change head of household
        spp.cr.deta -il.transfer_memberspp.cr.app -ly.transfer_member
        spp.cr.detail.transfer_memberspp.cr.apply.transfer_member Transfer member between groups
        spp.cr.deta -il.exit_registrantspp.cr.app -ly.exit_registrant
        spp.cr.detail.exit_registrantspp.cr.apply.exit_registrant Deactivate registrant
        spp.cr.d -etail.create_groupspp.cr. -apply.create_group
        spp.cr.detail.create_groupspp.cr.apply.create_group Create new group/household
        spp.cr.deta -il.split_householdspp.cr.app -ly.split_household
        spp.cr.detail.split_householdspp.cr.apply.split_household Split household into two groups
        spp.cr.detail -.merge_registrantsspp.cr.apply -.merge_registrants
        spp.cr.detail.merge_registrantsspp.cr.apply.merge_registrants Merge duplicate registrant records
        --++ @@ -411,8 +411,7 @@

        Key Models

        - + @@ -428,8 +427,7 @@

        Key Models

        - + @@ -452,8 +450,8 @@

        Configuration

        UI Location

          -
        • CR Type Selection: Types appear in the creation wizard at -Change Requests > New Request
        • +
        • CR Type Selection: Types appear in the creation wizard at Change +Requests > New Request
        • Configuration: Change Requests > Configuration > Change Request Types
        • Detail Forms: Accessed when creating or editing a change request @@ -464,8 +462,8 @@

          UI Location

          Security

        Model
        ` -spp.cr.detail.edit_individual`
        spp.cr.detail.edit_individual Detail form for individual information changes
        CR type configurations (defined in parent)
        s -pp.change.request.type.mapping
        spp.change.request.type.mapping Field mappings for field_mapping strategy
        --++ @@ -473,13 +471,11 @@

        Security

        - + - + diff --git a/spp_custom_field/README.rst b/spp_custom_field/README.rst index 7803088c..dee00089 100644 --- a/spp_custom_field/README.rst +++ b/spp_custom_field/README.rst @@ -32,31 +32,31 @@ grouping and read-only indicator fields for program metrics. Key Capabilities ~~~~~~~~~~~~~~~~ -- Define custom fields with ``x_cst_grp_*`` (group) or ``x_cst_indv_*`` - (individual) naming pattern -- Define read-only indicator fields with ``x_ind_grp_*`` or - ``x_ind_indv_*`` naming pattern -- Organize fields into named groups with sequence-based ordering -- Automatically inject fields into registrant forms based on registrant - type -- Display custom fields under "Additional Details" tab, indicators - under "Indicators" tab +- Define custom fields with ``x_cst_grp_*`` (group) or ``x_cst_indv_*`` + (individual) naming pattern +- Define read-only indicator fields with ``x_ind_grp_*`` or + ``x_ind_indv_*`` naming pattern +- Organize fields into named groups with sequence-based ordering +- Automatically inject fields into registrant forms based on registrant + type +- Display custom fields under "Additional Details" tab, indicators under + "Indicators" tab Key Models ~~~~~~~~~~ -+------------------------------+--------------------------------------+ -| Model | Description | -+==============================+======================================+ -| ``spp.custom.field.group`` | Groups custom fields for organized | -| | display in UI | -+------------------------------+--------------------------------------+ -| ``ir.model.fields`` (extend) | Adds ``field_group_id`` and | -| | ``sequence`` for field order | -+------------------------------+--------------------------------------+ -| ``res.partner`` (extend) | Dynamically injects custom fields | -| | into forms | -+------------------------------+--------------------------------------+ ++------------------------------+---------------------------------------+ +| Model | Description | ++==============================+=======================================+ +| ``spp.custom.field.group`` | Groups custom fields for organized | +| | display in UI | ++------------------------------+---------------------------------------+ +| ``ir.model.fields`` (extend) | Adds ``field_group_id`` and | +| | ``sequence`` for field order | ++------------------------------+---------------------------------------+ +| ``res.partner`` (extend) | Dynamically injects custom fields | +| | into forms | ++------------------------------+---------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -69,22 +69,22 @@ After installing: 3. Navigate to **Settings > Technical > Database Structure > Models** 4. Select **Contact (res.partner)** and create custom fields: - - For group registrants: ``x_cst_grp_fieldname`` or - ``x_ind_grp_fieldname`` - - For individuals: ``x_cst_indv_fieldname`` or - ``x_ind_indv_fieldname`` + - For group registrants: ``x_cst_grp_fieldname`` or + ``x_ind_grp_fieldname`` + - For individuals: ``x_cst_indv_fieldname`` or + ``x_ind_indv_fieldname`` 5. Assign ``field_group_id`` and ``sequence`` to organize field display UI Location ~~~~~~~~~~~ -- **Field Groups**: No menu defined; access via Settings > Technical > - Actions > Window Actions -- **Custom fields**: Appear on registrant forms under "Additional - Details" tab -- **Indicator fields**: Appear on registrant forms under "Indicators" - tab (read-only) +- **Field Groups**: No menu defined; access via Settings > Technical > + Actions > Window Actions +- **Custom fields**: Appear on registrant forms under "Additional + Details" tab +- **Indicator fields**: Appear on registrant forms under "Indicators" + tab (read-only) Security ~~~~~~~~ @@ -99,12 +99,12 @@ Group Access Extension Points ~~~~~~~~~~~~~~~~ -- Override ``_inject_custom_pages()`` to customize tab and field - injection logic -- Override ``_group_fields_by_group()`` to modify field grouping and - sorting -- Extend ``spp.custom.field.group`` to add metadata or classification - fields +- Override ``_inject_custom_pages()`` to customize tab and field + injection logic +- Override ``_group_fields_by_group()`` to modify field grouping and + sorting +- Extend ``spp.custom.field.group`` to add metadata or classification + fields Dependencies ~~~~~~~~~~~~ diff --git a/spp_custom_field/static/description/index.html b/spp_custom_field/static/description/index.html index 11158acd..d306aa0d 100644 --- a/spp_custom_field/static/description/index.html +++ b/spp_custom_field/static/description/index.html @@ -390,16 +390,16 @@

        Key Capabilities

      • Organize fields into named groups with sequence-based ordering
      • Automatically inject fields into registrant forms based on registrant type
      • -
      • Display custom fields under “Additional Details” tab, indicators -under “Indicators” tab
      • +
      • Display custom fields under “Additional Details” tab, indicators under +“Indicators” tab
      • Key Models

        Group
        spp_c -hange_request_v2.group_cr_user
        spp_change_request_v2.group_cr_user Read/write/create detail models (no delete)
        spp_chan -ge_request_v2.group_cr_manager
        spp_change_request_v2.group_cr_manager Full CRUD on detail models
        --++ diff --git a/spp_dci/README.rst b/spp_dci/README.rst index 7a604afa..6632e288 100644 --- a/spp_dci/README.rst +++ b/spp_dci/README.rst @@ -35,46 +35,45 @@ registry integrations. Key Capabilities ~~~~~~~~~~~~~~~~ -- Manage signing keys with Ed25519 and RSA-256 algorithms, state-based - lifecycle (draft → active → revoked) -- Generate HTTP signatures following draft-cavage specification for - outbound message authentication -- Verify incoming HTTP signatures using JWKS public key discovery -- Validate DCI message structure using Pydantic schemas (envelope, - header, payload) -- Export standard identifier types (UIN, BRN, MRN, DRN) with DCI - namespace URIs -- Build and sign DCI response envelopes with centralized helper - functions +- Manage signing keys with Ed25519 and RSA-256 algorithms, state-based + lifecycle (draft → active → revoked) +- Generate HTTP signatures following draft-cavage specification for + outbound message authentication +- Verify incoming HTTP signatures using JWKS public key discovery +- Validate DCI message structure using Pydantic schemas (envelope, + header, payload) +- Export standard identifier types (UIN, BRN, MRN, DRN) with DCI + namespace URIs +- Build and sign DCI response envelopes with centralized helper + functions Key Models ~~~~~~~~~~ -+-------------------------+-------------------------------------------+ -| Model | Description | -+=========================+===========================================+ -| ``spp.dci.signing.key`` | Cryptographic signing key with lifecycle | -| | state management | -+-------------------------+-------------------------------------------+ ++-------------------------+--------------------------------------------+ +| Model | Description | ++=========================+============================================+ +| ``spp.dci.signing.key`` | Cryptographic signing key with lifecycle | +| | state management | ++-------------------------+--------------------------------------------+ Pydantic Schemas ~~~~~~~~~~~~~~~~ Exported in ``spp_dci.schemas`` for import by DCI server/client modules: -- **Envelope**: ``DCIEnvelope``, ``DCIMessageHeader``, - ``DCICallbackHeader`` - Three-part message structure -- **Common**: ``Identifier``, ``Name``, ``Address``, ``GeoLocation``, - ``Place``, ``AdditionalAttribute``, ``Period`` - Shared data types -- **Person/Group**: ``Person``, ``RelatedPerson``, ``DisabilityInfo``, - ``Group``, ``Member`` - Registry entities -- **Search**: ``SearchRequest``, ``SearchResponse``, - ``SearchCriteria``, ``Pagination``, ``Expression`` - Search - operations -- **Subscription**: ``SubscribeRequest``, ``SubscribeResponse``, - ``UnsubscribeRequest``, ``TxnStatusRequest`` - Event subscriptions -- **Receipt**: ``ReceiptRequest``, ``ReceiptResponse``, - ``BeneficiaryRef``, ``ReceiptInformation`` - Delivery confirmations +- **Envelope**: ``DCIEnvelope``, ``DCIMessageHeader``, + ``DCICallbackHeader`` - Three-part message structure +- **Common**: ``Identifier``, ``Name``, ``Address``, ``GeoLocation``, + ``Place``, ``AdditionalAttribute``, ``Period`` - Shared data types +- **Person/Group**: ``Person``, ``RelatedPerson``, ``DisabilityInfo``, + ``Group``, ``Member`` - Registry entities +- **Search**: ``SearchRequest``, ``SearchResponse``, ``SearchCriteria``, + ``Pagination``, ``Expression`` - Search operations +- **Subscription**: ``SubscribeRequest``, ``SubscribeResponse``, + ``UnsubscribeRequest``, ``TxnStatusRequest`` - Event subscriptions +- **Receipt**: ``ReceiptRequest``, ``ReceiptResponse``, + ``BeneficiaryRef``, ``ReceiptInformation`` - Delivery confirmations Configuration ~~~~~~~~~~~~~ @@ -107,18 +106,18 @@ Group Access Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``spp.dci.signing.key`` to add key rotation policies or HSM - integration -- Use ``DCISigner(private_key, sender_id, key_id, algorithm)`` to sign - outbound messages -- Use ``DCIVerifier(public_key, algorithm)`` to verify incoming - signatures -- Import schemas from ``spp_dci.schemas`` for message validation in - custom endpoints -- Override ``get_sender_id(env)`` in ``response_helpers`` to customize - sender identification -- Use ``build_signed_envelope()`` helper to construct DCI responses - with proper headers and signatures +- Inherit ``spp.dci.signing.key`` to add key rotation policies or HSM + integration +- Use ``DCISigner(private_key, sender_id, key_id, algorithm)`` to sign + outbound messages +- Use ``DCIVerifier(public_key, algorithm)`` to verify incoming + signatures +- Import schemas from ``spp_dci.schemas`` for message validation in + custom endpoints +- Override ``get_sender_id(env)`` in ``response_helpers`` to customize + sender identification +- Use ``build_signed_envelope()`` helper to construct DCI responses with + proper headers and signatures Dependencies ~~~~~~~~~~~~ diff --git a/spp_dci/static/description/index.html b/spp_dci/static/description/index.html index 7bf49887..f2153a22 100644 --- a/spp_dci/static/description/index.html +++ b/spp_dci/static/description/index.html @@ -400,8 +400,8 @@

        Key Capabilities

        Key Models

        Model
        --++ @@ -426,9 +426,8 @@

        Pydantic Schemas

        Place, AdditionalAttribute, Period - Shared data types
      • Person/Group: Person, RelatedPerson, DisabilityInfo, Group, Member - Registry entities
      • -
      • Search: SearchRequest, SearchResponse, -SearchCriteria, Pagination, Expression - Search -operations
      • +
      • Search: SearchRequest, SearchResponse, SearchCriteria, +Pagination, Expression - Search operations
      • Subscription: SubscribeRequest, SubscribeResponse, UnsubscribeRequest, TxnStatusRequest - Event subscriptions
      • Receipt: ReceiptRequest, ReceiptResponse, @@ -487,8 +486,8 @@

        Extension Points

        custom endpoints
      • Override get_sender_id(env) in response_helpers to customize sender identification
      • -
      • Use build_signed_envelope() helper to construct DCI responses -with proper headers and signatures
      • +
      • Use build_signed_envelope() helper to construct DCI responses with +proper headers and signatures
      • diff --git a/spp_dci_client/README.rst b/spp_dci_client/README.rst index 9698fcfa..2a033ea3 100644 --- a/spp_dci_client/README.rst +++ b/spp_dci_client/README.rst @@ -35,33 +35,33 @@ and Python service class for search, subscribe, and status operations. Key Capabilities ~~~~~~~~~~~~~~~~ -- Configure external DCI registry endpoints with OAuth2 or Bearer token - authentication -- Cache OAuth2 tokens with automatic refresh to minimize token requests -- Sign outgoing DCI requests using JWK keys from ``spp_dci`` -- Execute synchronous and asynchronous search operations (by ID, - predicate, expression, date range) -- Subscribe to and unsubscribe from registry event notifications -- Check transaction status for asynchronous operations -- Test connection with one-click validation and error diagnostics -- Format HTTP and connection errors into user-friendly messages +- Configure external DCI registry endpoints with OAuth2 or Bearer token + authentication +- Cache OAuth2 tokens with automatic refresh to minimize token requests +- Sign outgoing DCI requests using JWK keys from ``spp_dci`` +- Execute synchronous and asynchronous search operations (by ID, + predicate, expression, date range) +- Subscribe to and unsubscribe from registry event notifications +- Check transaction status for asynchronous operations +- Test connection with one-click validation and error diagnostics +- Format HTTP and connection errors into user-friendly messages Key Models ~~~~~~~~~~ -+-------------------------+-------------------------------------------+ -| Model | Description | -+=========================+===========================================+ -| ``spp.dci.data.source`` | Connection configuration for external DCI | -| | registries | -+-------------------------+-------------------------------------------+ ++-------------------------+--------------------------------------------+ +| Model | Description | ++=========================+============================================+ +| ``spp.dci.data.source`` | Connection configuration for external DCI | +| | registries | ++-------------------------+--------------------------------------------+ Python Service Classes ~~~~~~~~~~~~~~~~~~~~~~ -- **``DCIClient(data_source, env)``**: Main API client for executing - DCI protocol operations (search, subscribe, txn_status). Instantiate - with a data source record and environment. +- **``DCIClient(data_source, env)``**: Main API client for executing DCI + protocol operations (search, subscribe, txn_status). Instantiate with + a data source record and environment. Configuration ~~~~~~~~~~~~~ @@ -80,9 +80,9 @@ After installing: UI Location ~~~~~~~~~~~ -- **Menu**: Settings > Technical > DCI > Configuration > Data Sources -- **Form**: Includes connection test button in header, configuration - groups, and two notebook tabs ("Connection Status" and "Notes") +- **Menu**: Settings > Technical > DCI > Configuration > Data Sources +- **Form**: Includes connection test button in header, configuration + groups, and two notebook tabs ("Connection Status" and "Notes") Security ~~~~~~~~ @@ -97,14 +97,14 @@ Group Access Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``spp.dci.data.source`` to add registry-specific - configuration fields -- Instantiate ``DCIClient(data_source, env)`` from custom code to - execute DCI operations -- Override ``_get_registry_type()`` or ``_get_receiver_id()`` for - custom registry routing -- Use ``format_http_error()`` and ``format_connection_error()`` for - consistent error handling +- Inherit ``spp.dci.data.source`` to add registry-specific configuration + fields +- Instantiate ``DCIClient(data_source, env)`` from custom code to + execute DCI operations +- Override ``_get_registry_type()`` or ``_get_receiver_id()`` for custom + registry routing +- Use ``format_http_error()`` and ``format_connection_error()`` for + consistent error handling Usage Example ~~~~~~~~~~~~~ diff --git a/spp_dci_client/static/description/index.html b/spp_dci_client/static/description/index.html index 2ddcbb60..d8db0888 100644 --- a/spp_dci_client/static/description/index.html +++ b/spp_dci_client/static/description/index.html @@ -399,8 +399,8 @@

        Key Capabilities

        Key Models

        Model
        --++ @@ -418,9 +418,9 @@

        Key Models

        Python Service Classes

          -
        • ``DCIClient(data_source, env)``: Main API client for executing -DCI protocol operations (search, subscribe, txn_status). Instantiate -with a data source record and environment.
        • +
        • ``DCIClient(data_source, env)``: Main API client for executing DCI +protocol operations (search, subscribe, txn_status). Instantiate with +a data source record and environment.
        @@ -470,12 +470,12 @@

        Security

        Extension Points

          -
        • Inherit spp.dci.data.source to add registry-specific -configuration fields
        • +
        • Inherit spp.dci.data.source to add registry-specific configuration +fields
        • Instantiate DCIClient(data_source, env) from custom code to execute DCI operations
        • -
        • Override _get_registry_type() or _get_receiver_id() for -custom registry routing
        • +
        • Override _get_registry_type() or _get_receiver_id() for custom +registry routing
        • Use format_http_error() and format_connection_error() for consistent error handling
        diff --git a/spp_dci_client_crvs/README.rst b/spp_dci_client_crvs/README.rst index 91542c82..975f771e 100644 --- a/spp_dci_client_crvs/README.rst +++ b/spp_dci_client_crvs/README.rst @@ -34,31 +34,31 @@ stored public keys of trusted CRVS registries. Key Capabilities ~~~~~~~~~~~~~~~~ -- Receive and log vital events: birth, death, marriage, divorce from - CRVS systems -- Match events to registry partners using identifiers (BRN, DRN, MRN, - UIN) -- Update partner records: birthdate, death status, civil status, - registry identifiers -- Process events with state tracking: received → processing → - processed/error -- Verify DCI callback signatures using JWKS public keys from trusted - CRVS registries -- Fetch and store CRVS public keys automatically from JWKS endpoints -- Retry failed event processing through UI actions +- Receive and log vital events: birth, death, marriage, divorce from + CRVS systems +- Match events to registry partners using identifiers (BRN, DRN, MRN, + UIN) +- Update partner records: birthdate, death status, civil status, + registry identifiers +- Process events with state tracking: received → processing → + processed/error +- Verify DCI callback signatures using JWKS public keys from trusted + CRVS registries +- Fetch and store CRVS public keys automatically from JWKS endpoints +- Retry failed event processing through UI actions Key Models ~~~~~~~~~~ -+-------------------------+-------------------------------------------+ -| Model | Description | -+=========================+===========================================+ -| ``spp.dci.crvs.event`` | Vital event log with identifier, type, | -| | date, processing state | -+-------------------------+-------------------------------------------+ -| ``spp.dci.crvs.sender`` | Trusted CRVS registry with sender ID and | -| | public key | -+-------------------------+-------------------------------------------+ ++-------------------------+--------------------------------------------+ +| Model | Description | ++=========================+============================================+ +| ``spp.dci.crvs.event`` | Vital event log with identifier, type, | +| | date, processing state | ++-------------------------+--------------------------------------------+ +| ``spp.dci.crvs.sender`` | Trusted CRVS registry with sender ID and | +| | public key | ++-------------------------+--------------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -76,11 +76,11 @@ After installing: UI Location ~~~~~~~~~~~ -- **Events**: Settings > Technical > DCI > Activity Logs > CRVS Events -- **Sender Registry**: Settings > Technical > DCI > Configuration > - CRVS Sender Registry -- **Event form tabs**: "Raw Data", "Notes" -- **Sender form tabs**: "Public Key", "Notes" +- **Events**: Settings > Technical > DCI > Activity Logs > CRVS Events +- **Sender Registry**: Settings > Technical > DCI > Configuration > CRVS + Sender Registry +- **Event form tabs**: "Raw Data", "Notes" +- **Sender form tabs**: "Public Key", "Notes" Security ~~~~~~~~ @@ -95,15 +95,15 @@ Group CRVS Event Access CRVS Sender Access Extension Points ~~~~~~~~~~~~~~~~ -- Override ``_process_birth_event()``, ``_process_death_event()``, - ``_process_marriage_event()``, ``_process_divorce_event()`` to - customize partner record updates based on event type -- Override ``_find_person_by_identifier()`` to implement custom - matching logic -- Inherit ``spp.dci.crvs.event`` to add fields for domain-specific - event metadata -- Use ``CRVSService`` class for programmatic access to verify_birth(), - check_death(), subscribe_events() +- Override ``_process_birth_event()``, ``_process_death_event()``, + ``_process_marriage_event()``, ``_process_divorce_event()`` to + customize partner record updates based on event type +- Override ``_find_person_by_identifier()`` to implement custom matching + logic +- Inherit ``spp.dci.crvs.event`` to add fields for domain-specific event + metadata +- Use ``CRVSService`` class for programmatic access to verify_birth(), + check_death(), subscribe_events() Dependencies ~~~~~~~~~~~~ diff --git a/spp_dci_client_crvs/static/description/index.html b/spp_dci_client_crvs/static/description/index.html index 181c5292..dc4bc431 100644 --- a/spp_dci_client_crvs/static/description/index.html +++ b/spp_dci_client_crvs/static/description/index.html @@ -400,8 +400,8 @@

        Key Capabilities

        Key Models

        Model
        --++ @@ -437,8 +437,8 @@

        Configuration

        UI Location

        • Events: Settings > Technical > DCI > Activity Logs > CRVS Events
        • -
        • Sender Registry: Settings > Technical > DCI > Configuration > -CRVS Sender Registry
        • +
        • Sender Registry: Settings > Technical > DCI > Configuration > CRVS +Sender Registry
        • Event form tabs: “Raw Data”, “Notes”
        • Sender form tabs: “Public Key”, “Notes”
        @@ -475,10 +475,10 @@

        Extension Points

      • Override _process_birth_event(), _process_death_event(), _process_marriage_event(), _process_divorce_event() to customize partner record updates based on event type
      • -
      • Override _find_person_by_identifier() to implement custom -matching logic
      • -
      • Inherit spp.dci.crvs.event to add fields for domain-specific -event metadata
      • +
      • Override _find_person_by_identifier() to implement custom matching +logic
      • +
      • Inherit spp.dci.crvs.event to add fields for domain-specific event +metadata
      • Use CRVSService class for programmatic access to verify_birth(), check_death(), subscribe_events()
      • diff --git a/spp_dci_client_dr/README.rst b/spp_dci_client_dr/README.rst index c683d990..033d9a63 100644 --- a/spp_dci_client_dr/README.rst +++ b/spp_dci_client_dr/README.rst @@ -35,28 +35,28 @@ systems. Key Capabilities ~~~~~~~~~~~~~~~~ -- Query disability status from remote DR systems using DCI client -- Cache disability data in local records with sync status tracking - (synced, stale, error) -- Receive async search response callbacks via FastAPI endpoints -- Verify callback signatures using Ed25519 or RSA-256 algorithms -- Match DR responses to OpenSPP registrants by UIN, DRN, or National ID -- Refresh cached data manually or programmatically +- Query disability status from remote DR systems using DCI client +- Cache disability data in local records with sync status tracking + (synced, stale, error) +- Receive async search response callbacks via FastAPI endpoints +- Verify callback signatures using Ed25519 or RSA-256 algorithms +- Match DR responses to OpenSPP registrants by UIN, DRN, or National ID +- Refresh cached data manually or programmatically Key Models ~~~~~~~~~~ -+-------------------------------+-------------------------------------+ -| Model | Description | -+===============================+=====================================+ -| ``spp.dci.disability.status`` | Cached disability data: PWD flag, | -| | disability types, functional | -| | scores, raw data | -+-------------------------------+-------------------------------------+ -| ``spp.dci.dr.sender`` | Trusted DR registry entries with | -| | sender_id, public keys, and JWKS | -| | endpoints | -+-------------------------------+-------------------------------------+ ++-------------------------------+--------------------------------------+ +| Model | Description | ++===============================+======================================+ +| ``spp.dci.disability.status`` | Cached disability data: PWD flag, | +| | disability types, functional scores, | +| | raw data | ++-------------------------------+--------------------------------------+ +| ``spp.dci.dr.sender`` | Trusted DR registry entries with | +| | sender_id, public keys, and JWKS | +| | endpoints | ++-------------------------------+--------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -85,54 +85,54 @@ To query disability status programmatically: UI Location ~~~~~~~~~~~ -- **Menu**: Settings > Technical > DCI > Activity Logs > Disability - Status -- **Configuration**: Settings > Technical > DCI > Configuration > DR - Senders -- **Callback Endpoints**: ``/dci_api/dr/on-search``, - ``/dci_api/dr/on-subscribe`` +- **Menu**: Settings > Technical > DCI > Activity Logs > Disability + Status +- **Configuration**: Settings > Technical > DCI > Configuration > DR + Senders +- **Callback Endpoints**: ``/dci_api/dr/on-search``, + ``/dci_api/dr/on-subscribe`` Tabs ~~~~ Disability Status form: -- **Disability Information**: Disability types and functional scores - (JSON) -- **Raw Data**: Original JSON data received from DR system -- **Notes**: Additional notes about disability status -- **Error Details**: Error message if sync failed (visible only when - error exists) +- **Disability Information**: Disability types and functional scores + (JSON) +- **Raw Data**: Original JSON data received from DR system +- **Notes**: Additional notes about disability status +- **Error Details**: Error message if sync failed (visible only when + error exists) DR Sender form: -- **Public Key**: PEM-encoded public key for signature verification -- **Notes**: Additional notes about the DR registry +- **Public Key**: PEM-encoded public key for signature verification +- **Notes**: Additional notes about the DR registry Security ~~~~~~~~ -+-----------------------+---------------------------------------------+ -| Group | Access | -+=======================+=============================================+ -| ``base.group_system`` | Full CRUD on disability status and DR | -| | sender registry | -+-----------------------+---------------------------------------------+ -| ``base.group_user`` | Read/Write/Create disability status, | -| | read-only DR sender registry | -+-----------------------+---------------------------------------------+ ++-----------------------+----------------------------------------------+ +| Group | Access | ++=======================+==============================================+ +| ``base.group_system`` | Full CRUD on disability status and DR sender | +| | registry | ++-----------------------+----------------------------------------------+ +| ``base.group_user`` | Read/Write/Create disability status, | +| | read-only DR sender registry | ++-----------------------+----------------------------------------------+ Extension Points ~~~~~~~~~~~~~~~~ -- Override ``DRService._extract_disability_data()`` to customize - parsing of DR response fields -- Override ``DRService._extract_functional_scores()`` to handle custom - score formats -- Inherit ``spp.dci.disability.status`` to add domain-specific - disability fields -- Extend callback router at ``spp_dci_client_dr.routers.callback`` to - handle additional DR callback types +- Override ``DRService._extract_disability_data()`` to customize parsing + of DR response fields +- Override ``DRService._extract_functional_scores()`` to handle custom + score formats +- Inherit ``spp.dci.disability.status`` to add domain-specific + disability fields +- Extend callback router at ``spp_dci_client_dr.routers.callback`` to + handle additional DR callback types Dependencies ~~~~~~~~~~~~ diff --git a/spp_dci_client_dr/static/description/index.html b/spp_dci_client_dr/static/description/index.html index 36dff838..5181b22b 100644 --- a/spp_dci_client_dr/static/description/index.html +++ b/spp_dci_client_dr/static/description/index.html @@ -396,8 +396,8 @@

        Key Capabilities

        Key Models

        Model
        --++ @@ -407,8 +407,8 @@

        Key Models

        +disability types, functional scores, +raw data
        Model
        spp.dci.disability.status Cached disability data: PWD flag, -disability types, functional -scores, raw data
        spp.dci.dr.sender Trusted DR registry entries with @@ -472,8 +472,8 @@

        Tabs

        Security

        --++ @@ -482,8 +482,8 @@

        Security

        - +
        Group
        base.group_systemFull CRUD on disability status and DR -sender registryFull CRUD on disability status and DR sender +registry
        base.group_user Read/Write/Create disability status, @@ -495,8 +495,8 @@

        Security

        Extension Points

          -
        • Override DRService._extract_disability_data() to customize -parsing of DR response fields
        • +
        • Override DRService._extract_disability_data() to customize parsing +of DR response fields
        • Override DRService._extract_functional_scores() to handle custom score formats
        • Inherit spp.dci.disability.status to add domain-specific diff --git a/spp_dci_client_ibr/README.rst b/spp_dci_client_ibr/README.rst index 75171439..1f482d2e 100644 --- a/spp_dci_client_ibr/README.rst +++ b/spp_dci_client_ibr/README.rst @@ -35,33 +35,32 @@ infrastructure. Key Capabilities ~~~~~~~~~~~~~~~~ -- Check registrants for duplicate enrollments in external IBR systems - using DCI protocol -- Store duplication check results with match status, matched programs, - and raw API responses -- Manage trusted IBR sender registries with automatic JWKS public key - fetching -- Receive async search response callbacks at ``/dci_api/ibr/on-search`` - endpoint -- Verify callback signatures using Ed25519 or RSA-256 algorithms -- Track duplication check lifecycle: ready → checking → - completed/failed +- Check registrants for duplicate enrollments in external IBR systems + using DCI protocol +- Store duplication check results with match status, matched programs, + and raw API responses +- Manage trusted IBR sender registries with automatic JWKS public key + fetching +- Receive async search response callbacks at ``/dci_api/ibr/on-search`` + endpoint +- Verify callback signatures using Ed25519 or RSA-256 algorithms +- Track duplication check lifecycle: ready → checking → completed/failed Key Models ~~~~~~~~~~ -+-------------------------------+-------------------------------------+ -| Model | Description | -+===============================+=====================================+ -| ``spp.dci.duplication.check`` | Stores duplication check requests | -| | and results from IBR | -+-------------------------------+-------------------------------------+ -| ``spp.dci.ibr.sender`` | Registry of trusted IBR systems | -| | with public keys | -+-------------------------------+-------------------------------------+ -| ``fastapi.endpoint`` | Inherited to add IBR callback | -| | router to DCI API endpoint | -+-------------------------------+-------------------------------------+ ++-------------------------------+--------------------------------------+ +| Model | Description | ++===============================+======================================+ +| ``spp.dci.duplication.check`` | Stores duplication check requests | +| | and results from IBR | ++-------------------------------+--------------------------------------+ +| ``spp.dci.ibr.sender`` | Registry of trusted IBR systems with | +| | public keys | ++-------------------------------+--------------------------------------+ +| ``fastapi.endpoint`` | Inherited to add IBR callback router | +| | to DCI API endpoint | ++-------------------------------+--------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -78,46 +77,42 @@ After installing: UI Location ~~~~~~~~~~~ -- **IBR Duplication Checks**: Settings > Technical > DCI > Activity - Logs > IBR Duplication Checks -- **IBR Senders**: Settings > Technical > DCI > Configuration > IBR - Senders -- **FastAPI Callbacks**: ``/dci_api/ibr/on-search`` and - ``/dci_api/ibr/on-subscribe`` +- **IBR Duplication Checks**: Settings > Technical > DCI > Activity Logs + > IBR Duplication Checks +- **IBR Senders**: Settings > Technical > DCI > Configuration > IBR + Senders +- **FastAPI Callbacks**: ``/dci_api/ibr/on-search`` and + ``/dci_api/ibr/on-subscribe`` Security ~~~~~~~~ -+----------------------+----------------------+----------------------+ -| Group | Model | Access | -+======================+======================+======================+ -| ``spp_registry.gro | ``spp.dci | Read | -| up_registry_viewer`` | .duplication.check`` | | -+----------------------+----------------------+----------------------+ -| ``spp_registry.grou | ``spp.dci | Read/Write/Create | -| p_registry_officer`` | .duplication.check`` | (no delete) | -+----------------------+----------------------+----------------------+ -| ``spp_registry.grou | ``spp.dci | Full CRUD | -| p_registry_manager`` | .duplication.check`` | | -+----------------------+----------------------+----------------------+ -| ` | `` | Full CRUD | -| `base.group_system`` | spp.dci.ibr.sender`` | | -+----------------------+----------------------+----------------------+ -| ``base.group_user`` | `` | Read | -| | spp.dci.ibr.sender`` | | -+----------------------+----------------------+----------------------+ ++-----------------------------------------+-------------------------------+----------------------+ +| Group | Model | Access | ++=========================================+===============================+======================+ +| ``spp_registry.group_registry_viewer`` | ``spp.dci.duplication.check`` | Read | ++-----------------------------------------+-------------------------------+----------------------+ +| ``spp_registry.group_registry_officer`` | ``spp.dci.duplication.check`` | Read/Write/Create | +| | | (no delete) | ++-----------------------------------------+-------------------------------+----------------------+ +| ``spp_registry.group_registry_manager`` | ``spp.dci.duplication.check`` | Full CRUD | ++-----------------------------------------+-------------------------------+----------------------+ +| ``base.group_system`` | ``spp.dci.ibr.sender`` | Full CRUD | ++-----------------------------------------+-------------------------------+----------------------+ +| ``base.group_user`` | ``spp.dci.ibr.sender`` | Read | ++-----------------------------------------+-------------------------------+----------------------+ Extension Points ~~~~~~~~~~~~~~~~ -- Override ``_process_ibr_search_result()`` in ``routers/callback.py`` - to customize result processing -- Inherit ``spp.dci.duplication.check`` to add domain-specific fields - or validation -- Extend ``fastapi.endpoint._get_fastapi_routers()`` to add additional - IBR-related routes -- Override ``spp.dci.ibr.sender._jwk_to_pem()`` to support additional - key formats +- Override ``_process_ibr_search_result()`` in ``routers/callback.py`` + to customize result processing +- Inherit ``spp.dci.duplication.check`` to add domain-specific fields or + validation +- Extend ``fastapi.endpoint._get_fastapi_routers()`` to add additional + IBR-related routes +- Override ``spp.dci.ibr.sender._jwk_to_pem()`` to support additional + key formats Dependencies ~~~~~~~~~~~~ diff --git a/spp_dci_client_ibr/static/description/index.html b/spp_dci_client_ibr/static/description/index.html index b3a14a8d..8438cc5a 100644 --- a/spp_dci_client_ibr/static/description/index.html +++ b/spp_dci_client_ibr/static/description/index.html @@ -392,16 +392,15 @@

          Key Capabilities

        • Receive async search response callbacks at /dci_api/ibr/on-search endpoint
        • Verify callback signatures using Ed25519 or RSA-256 algorithms
        • -
        • Track duplication check lifecycle: ready → checking → -completed/failed
        • +
        • Track duplication check lifecycle: ready → checking → completed/failed

        Key Models

        --++ @@ -414,12 +413,12 @@

        Key Models

        and results from IBR - + - +
        Model
        spp.dci.ibr.senderRegistry of trusted IBR systems -with public keysRegistry of trusted IBR systems with +public keys
        fastapi.endpointInherited to add IBR callback -router to DCI API endpointInherited to add IBR callback router +to DCI API endpoint
        @@ -439,8 +438,8 @@

        Configuration

        UI Location

          -
        • IBR Duplication Checks: Settings > Technical > DCI > Activity -Logs > IBR Duplication Checks
        • +
        • IBR Duplication Checks: Settings > Technical > DCI > Activity Logs +> IBR Duplication Checks
        • IBR Senders: Settings > Technical > DCI > Configuration > IBR Senders
        • FastAPI Callbacks: /dci_api/ibr/on-search and @@ -451,9 +450,9 @@

          UI Location

          Security

          +--+ @@ -462,34 +461,25 @@

          Security

          - - + + - - + + - - + + - - + + - + @@ -500,8 +490,8 @@

          Extension Points

          • Override _process_ibr_search_result() in routers/callback.py to customize result processing
          • -
          • Inherit spp.dci.duplication.check to add domain-specific fields -or validation
          • +
          • Inherit spp.dci.duplication.check to add domain-specific fields or +validation
          • Extend fastapi.endpoint._get_fastapi_routers() to add additional IBR-related routes
          • Override spp.dci.ibr.sender._jwk_to_pem() to support additional diff --git a/spp_dci_server/README.rst b/spp_dci_server/README.rst index e8584053..05ccca97 100644 --- a/spp_dci_server/README.rst +++ b/spp_dci_server/README.rst @@ -35,44 +35,44 @@ JWKS-based public key distribution. Key Capabilities ~~~~~~~~~~~~~~~~ -- **FastAPI Endpoints**: Exposes DCI-compliant REST API at - ``/dci_api/v1`` with automatic OpenAPI documentation -- **HTTP Signature Verification**: Validates inbound requests using - Ed25519/RSA signatures against sender public keys -- **Async Transaction Processing**: Queues search, subscribe, and - unsubscribe operations for background processing with automatic - callbacks -- **Event Subscriptions**: Manages external system subscriptions to - registry events (registration, update, delete) with notification - delivery -- **JWKS Distribution**: Publishes server public keys at - ``/.well-known/jwks.json`` for signature verification by clients -- **Rate Limiting**: Enforces per-sender request limits (per-minute and - per-day) with automatic counter resets -- **Callback Retry**: Retries failed callbacks with exponential backoff - (3 attempts) and SSRF protection +- **FastAPI Endpoints**: Exposes DCI-compliant REST API at + ``/dci_api/v1`` with automatic OpenAPI documentation +- **HTTP Signature Verification**: Validates inbound requests using + Ed25519/RSA signatures against sender public keys +- **Async Transaction Processing**: Queues search, subscribe, and + unsubscribe operations for background processing with automatic + callbacks +- **Event Subscriptions**: Manages external system subscriptions to + registry events (registration, update, delete) with notification + delivery +- **JWKS Distribution**: Publishes server public keys at + ``/.well-known/jwks.json`` for signature verification by clients +- **Rate Limiting**: Enforces per-sender request limits (per-minute and + per-day) with automatic counter resets +- **Callback Retry**: Retries failed callbacks with exponential backoff + (3 attempts) and SSRF protection Key Models ~~~~~~~~~~ -+------------------------------+--------------------------------------+ -| Model | Description | -+==============================+======================================+ -| ``spp.dci.sender.registry`` | External DCI senders with public | -| | keys for signature verification | -+------------------------------+--------------------------------------+ -| ``spp.dci.transaction`` | Async DCI request tracking (search, | -| | subscribe, unsubscribe) | -+------------------------------+--------------------------------------+ -| ``spp.dci.subscription`` | Event subscriptions with callback | -| | URIs and filter expressions | -+------------------------------+--------------------------------------+ -| ``spp.dci.notification.log`` | Audit trail of sent notifications | -| | with receipt tracking | -+------------------------------+--------------------------------------+ -| ``spp.dci.server.key`` | Server signing keys for outbound | -| | responses and notifications | -+------------------------------+--------------------------------------+ ++------------------------------+---------------------------------------+ +| Model | Description | ++==============================+=======================================+ +| ``spp.dci.sender.registry`` | External DCI senders with public keys | +| | for signature verification | ++------------------------------+---------------------------------------+ +| ``spp.dci.transaction`` | Async DCI request tracking (search, | +| | subscribe, unsubscribe) | ++------------------------------+---------------------------------------+ +| ``spp.dci.subscription`` | Event subscriptions with callback | +| | URIs and filter expressions | ++------------------------------+---------------------------------------+ +| ``spp.dci.notification.log`` | Audit trail of sent notifications | +| | with receipt tracking | ++------------------------------+---------------------------------------+ +| ``spp.dci.server.key`` | Server signing keys for outbound | +| | responses and notifications | ++------------------------------+---------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -93,11 +93,11 @@ installation. To manage keys manually, use the technical interface for UI Location ~~~~~~~~~~~ -- **Menu**: Settings > DCI > Configuration > Sender Registry -- **Menu**: Settings > DCI > Configuration > Transactions -- **Menu**: Settings > DCI > Configuration > Subscriptions -- **API**: ``/dci_api/v1`` (OpenAPI docs at ``/dci_api/v1/docs``) -- **JWKS**: ``/dci_api/v1/.well-known/jwks.json`` +- **Menu**: Settings > DCI > Configuration > Sender Registry +- **Menu**: Settings > DCI > Configuration > Transactions +- **Menu**: Settings > DCI > Configuration > Subscriptions +- **API**: ``/dci_api/v1`` (OpenAPI docs at ``/dci_api/v1/docs``) +- **JWKS**: ``/dci_api/v1/.well-known/jwks.json`` Security ~~~~~~~~ @@ -115,14 +115,14 @@ public keys. Extension Points ~~~~~~~~~~~~~~~~ -- Override ``DCIErrorResponseMiddleware.dispatch()`` to customize error - response formatting -- Inherit ``fastapi.endpoint`` with ``app='dci_api'`` to add custom - routers via ``_get_fastapi_routers()`` -- Override ``spp.dci.transaction.process_async_*()`` methods to - customize async processing logic -- Inherit ``spp.dci.subscription._build_notification()`` to add custom - notification fields +- Override ``DCIErrorResponseMiddleware.dispatch()`` to customize error + response formatting +- Inherit ``fastapi.endpoint`` with ``app='dci_api'`` to add custom + routers via ``_get_fastapi_routers()`` +- Override ``spp.dci.transaction.process_async_*()`` methods to + customize async processing logic +- Inherit ``spp.dci.subscription._build_notification()`` to add custom + notification fields Dependencies ~~~~~~~~~~~~ diff --git a/spp_dci_server/static/description/index.html b/spp_dci_server/static/description/index.html index 68fa08a9..2dc7a90b 100644 --- a/spp_dci_server/static/description/index.html +++ b/spp_dci_server/static/description/index.html @@ -405,8 +405,8 @@

            Key Capabilities

            Key Models

          Group
          spp_registry.gro -up_registry_viewerspp.dci -.duplication.check
          spp_registry.group_registry_viewerspp.dci.duplication.check Read
          spp_registry.grou -p_registry_officerspp.dci -.duplication.check
          spp_registry.group_registry_officerspp.dci.duplication.check Read/Write/Create (no delete)
          spp_registry.grou -p_registry_managerspp.dci -.duplication.check
          spp_registry.group_registry_managerspp.dci.duplication.check Full CRUD
          ` -base.group_system``` -spp.dci.ibr.sender``
          base.group_systemspp.dci.ibr.sender Full CRUD
          base.group_user`` -spp.dci.ibr.sender``spp.dci.ibr.sender Read
          --++ @@ -415,8 +415,8 @@

          Key Models

          - +
          Model
          spp.dci.sender.registryExternal DCI senders with public -keys for signature verificationExternal DCI senders with public keys +for signature verification
          spp.dci.transaction Async DCI request tracking (search, diff --git a/spp_demo/README.rst b/spp_demo/README.rst index 5e6a48b1..fa343532 100644 --- a/spp_demo/README.rst +++ b/spp_demo/README.rst @@ -32,42 +32,42 @@ for large datasets. Key Capabilities ~~~~~~~~~~~~~~~~ -- Generate random registrants using Faker library with locale-specific - providers (Kenya, Laos, Sri Lanka) -- Create fixed demo stories with memorable names for repeatable demos - (e.g., "Maria Santos", "Juan Dela Cruz") -- Generate IDs from regex patterns with validation and error logging -- Batch process large datasets using queue_job (configurable threshold) -- Configure percentages for IDs, GPS coordinates, and bank accounts -- Track generation failures with diagnostic logging -- Extend ``res.country`` with Faker locale and GPS boundaries -- Create demo user accounts (viewer, officer, supervisor, manager, - admin) +- Generate random registrants using Faker library with locale-specific + providers (Kenya, Laos, Sri Lanka) +- Create fixed demo stories with memorable names for repeatable demos + (e.g., "Maria Santos", "Juan Dela Cruz") +- Generate IDs from regex patterns with validation and error logging +- Batch process large datasets using queue_job (configurable threshold) +- Configure percentages for IDs, GPS coordinates, and bank accounts +- Track generation failures with diagnostic logging +- Extend ``res.country`` with Faker locale and GPS boundaries +- Create demo user accounts (viewer, officer, supervisor, manager, + admin) Key Models ~~~~~~~~~~ -+----------------------------------+----------------------------------+ -| Model | Description | -+==================================+==================================+ -| ``spp.demo.data.generator`` | Main generator with | -| | configuration and batch controls | -+----------------------------------+----------------------------------+ -| ``spp.demo.data.generation.log`` | Logs failed generation attempts | -| | with diagnostics | -+----------------------------------+----------------------------------+ -| ``spp.demo.data.id.types`` | ID type configuration for | -| | individual/group generation | -+----------------------------------+----------------------------------+ -| ``spp.demo.data.bank.types`` | Bank type configuration for | -| | account generation | -+----------------------------------+----------------------------------+ -| ``spp.apps.wizard`` | Wizard for installing missing | -| | demo modules | -+----------------------------------+----------------------------------+ -| ``spp.missing.module`` | Transient model for tracking | -| | missing modules | -+----------------------------------+----------------------------------+ ++----------------------------------+-----------------------------------+ +| Model | Description | ++==================================+===================================+ +| ``spp.demo.data.generator`` | Main generator with configuration | +| | and batch controls | ++----------------------------------+-----------------------------------+ +| ``spp.demo.data.generation.log`` | Logs failed generation attempts | +| | with diagnostics | ++----------------------------------+-----------------------------------+ +| ``spp.demo.data.id.types`` | ID type configuration for | +| | individual/group generation | ++----------------------------------+-----------------------------------+ +| ``spp.demo.data.bank.types`` | Bank type configuration for | +| | account generation | ++----------------------------------+-----------------------------------+ +| ``spp.apps.wizard`` | Wizard for installing missing | +| | demo modules | ++----------------------------------+-----------------------------------+ +| ``spp.missing.module`` | Transient model for tracking | +| | missing modules | ++----------------------------------+-----------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -77,9 +77,9 @@ After installing: 1. Navigate to **Settings > General Settings > SPP Demo Data Generator Settings** to set defaults: - - Number of groups - - Members per group range - - Batch size and queue job threshold + - Number of groups + - Members per group range + - Batch size and queue job threshold 2. Access generator via action ``spp_demo.action_demo_data_generator`` (no standalone menu) @@ -90,47 +90,46 @@ After installing: UI Location ~~~~~~~~~~~ -- **Action**: ``spp_demo.action_demo_data_generator`` (no standalone - menu item) -- **Configuration**: Settings > General Settings > SPP Demo Data - Generator Settings -- **Form tabs**: Generated Groups, Generated Individuals, ID Types, - Bank Types, Generation Logs +- **Action**: ``spp_demo.action_demo_data_generator`` (no standalone + menu item) +- **Configuration**: Settings > General Settings > SPP Demo Data + Generator Settings +- **Form tabs**: Generated Groups, Generated Individuals, ID Types, Bank + Types, Generation Logs Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| ``base.group_system`` | Full CRUD on all models | -+----------------------------------+----------------------------------+ -| ``sp | Read access to all models | -| p_registry.group_registry_read`` | | -+----------------------------------+----------------------------------+ -| ``spp | Read/Write on generator and logs | -| _registry.group_registry_write`` | (delete ID/Bank types) | -+----------------------------------+----------------------------------+ -| ``spp_ | Read/Create access (delete | -| registry.group_registry_create`` | ID/Bank types) | -+----------------------------------+----------------------------------+ ++----------------------------------------+----------------------------------+ +| Group | Access | ++========================================+==================================+ +| ``base.group_system`` | Full CRUD on all models | ++----------------------------------------+----------------------------------+ +| ``spp_registry.group_registry_read`` | Read access to all models | ++----------------------------------------+----------------------------------+ +| ``spp_registry.group_registry_write`` | Read/Write on generator and logs | +| | (delete ID/Bank types) | ++----------------------------------------+----------------------------------+ +| ``spp_registry.group_registry_create`` | Read/Create access (delete | +| | ID/Bank types) | ++----------------------------------------+----------------------------------+ Extension Points ~~~~~~~~~~~~~~~~ -- Override ``_create_individual_story()``, ``_create_farmer_story()``, - ``_create_household_story()`` for custom story generation -- Add custom stories to ``models/demo_stories.py`` (``DEMO_STORIES`` or - ``BACKGROUND_STORIES`` lists) -- Extend ``res.country`` with ``faker_locale`` field for custom locale - providers -- Use utility methods: - - - ``create_individual_from_params(name, gender, age, extra_vals)`` - - Create individual without full generator session - - ``create_group_from_params(name, extra_vals)`` - Create group from - parameters - - ``lookup_gender_id(gender)`` - Look up gender vocabulary code ID +- Override ``_create_individual_story()``, ``_create_farmer_story()``, + ``_create_household_story()`` for custom story generation +- Add custom stories to ``models/demo_stories.py`` (``DEMO_STORIES`` or + ``BACKGROUND_STORIES`` lists) +- Extend ``res.country`` with ``faker_locale`` field for custom locale + providers +- Use utility methods: + + - ``create_individual_from_params(name, gender, age, extra_vals)`` - + Create individual without full generator session + - ``create_group_from_params(name, extra_vals)`` - Create group from + parameters + - ``lookup_gender_id(gender)`` - Look up gender vocabulary code ID Dependencies ~~~~~~~~~~~~ diff --git a/spp_demo/static/description/index.html b/spp_demo/static/description/index.html index 34e54bdf..6daff4c9 100644 --- a/spp_demo/static/description/index.html +++ b/spp_demo/static/description/index.html @@ -400,8 +400,8 @@

          Key Capabilities

          Key Models

          --++ @@ -410,8 +410,8 @@

          Key Models

          - +
          Model
          spp.demo.data.generatorMain generator with -configuration and batch controlsMain generator with configuration +and batch controls
          spp.demo.data.generation.log Logs failed generation attempts @@ -461,16 +461,16 @@

          UI Location

          menu item)
        • Configuration: Settings > General Settings > SPP Demo Data Generator Settings
        • -
        • Form tabs: Generated Groups, Generated Individuals, ID Types, -Bank Types, Generation Logs
        • +
        • Form tabs: Generated Groups, Generated Individuals, ID Types, Bank +Types, Generation Logs
        • Security

          --++ @@ -481,17 +481,14 @@

          Security

          - + - + - + diff --git a/spp_dms/README.rst b/spp_dms/README.rst index 25e90754..bd92a025 100644 --- a/spp_dms/README.rst +++ b/spp_dms/README.rst @@ -32,39 +32,39 @@ and size limits. Key Capabilities ~~~~~~~~~~~~~~~~ -- Organize files in nested directory structures with root directories - and subdirectories -- Automatically capture file metadata on upload: size, MIME type, - extension, SHA512 checksum -- Enable optional versioning per file with automatic snapshots on - content changes and manual restore -- Enforce file type restrictions (allowed/blocked extensions, MIME - types) and size limits per category -- Generate thumbnails automatically for image files using Pillow -- Compute directory statistics recursively: total file count, - subdirectory count, and cumulative size +- Organize files in nested directory structures with root directories + and subdirectories +- Automatically capture file metadata on upload: size, MIME type, + extension, SHA512 checksum +- Enable optional versioning per file with automatic snapshots on + content changes and manual restore +- Enforce file type restrictions (allowed/blocked extensions, MIME + types) and size limits per category +- Generate thumbnails automatically for image files using Pillow +- Compute directory statistics recursively: total file count, + subdirectory count, and cumulative size Key Models ~~~~~~~~~~ -+----------------------------------+----------------------------------+ -| Model | Description | -+==================================+==================================+ -| ``spp.dms.directory`` | Directory with parent/child | -| | hierarchy and file storage | -+----------------------------------+----------------------------------+ -| ``spp.dms.file`` | File record with binary content | -| | and optional versioning | -+----------------------------------+----------------------------------+ -| ``spp.dms.file.version`` | Version snapshot with content, | -| | checksum, and comment | -+----------------------------------+----------------------------------+ -| ``spp.dms.category`` | File classification with | -| | validation rules | -+----------------------------------+----------------------------------+ -| `` | Transient wizard for restoring | -| spp.dms.restore.version.wizard`` | file versions | -+----------------------------------+----------------------------------+ ++------------------------------------+----------------------------------+ +| Model | Description | ++====================================+==================================+ +| ``spp.dms.directory`` | Directory with parent/child | +| | hierarchy and file storage | ++------------------------------------+----------------------------------+ +| ``spp.dms.file`` | File record with binary content | +| | and optional versioning | ++------------------------------------+----------------------------------+ +| ``spp.dms.file.version`` | Version snapshot with content, | +| | checksum, and comment | ++------------------------------------+----------------------------------+ +| ``spp.dms.category`` | File classification with | +| | validation rules | ++------------------------------------+----------------------------------+ +| ``spp.dms.restore.version.wizard`` | Transient wizard for restoring | +| | file versions | ++------------------------------------+----------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -81,36 +81,36 @@ After installing: UI Location ~~~~~~~~~~~ -- **Files**: DMS > Files -- **Directories**: DMS > Directories -- **Configuration**: DMS > Configuration > Categories -- **Version History**: Accessed via stat button on file forms when - versioning is enabled +- **Files**: DMS > Files +- **Directories**: DMS > Directories +- **Configuration**: DMS > Configuration > Categories +- **Version History**: Accessed via stat button on file forms when + versioning is enabled Security ~~~~~~~~ -+-------------------------------+-------------------------------------+ -| Group | Access | -+===============================+=====================================+ -| ``spp_dms.group_dms_viewer`` | Read directories, files, versions, | -| | categories | -+-------------------------------+-------------------------------------+ -| ``spp_dms.group_dms_officer`` | Create/edit files and directories | -| | (no delete) | -+-------------------------------+-------------------------------------+ -| ``spp_dms.group_dms_manager`` | Full CRUD on all models including | -| | categories | -+-------------------------------+-------------------------------------+ ++-------------------------------+--------------------------------------+ +| Group | Access | ++===============================+======================================+ +| ``spp_dms.group_dms_viewer`` | Read directories, files, versions, | +| | categories | ++-------------------------------+--------------------------------------+ +| ``spp_dms.group_dms_officer`` | Create/edit files and directories | +| | (no delete) | ++-------------------------------+--------------------------------------+ +| ``spp_dms.group_dms_manager`` | Full CRUD on all models including | +| | categories | ++-------------------------------+--------------------------------------+ Extension Points ~~~~~~~~~~~~~~~~ -- Override ``validate_file()`` on ``spp.dms.category`` to add custom - validation logic -- Inherit ``spp.dms.file`` to add domain-specific metadata fields -- Override ``_create_new_version()`` on ``spp.dms.file`` to customize - versioning behavior +- Override ``validate_file()`` on ``spp.dms.category`` to add custom + validation logic +- Inherit ``spp.dms.file`` to add domain-specific metadata fields +- Override ``_create_new_version()`` on ``spp.dms.file`` to customize + versioning behavior Dependencies ~~~~~~~~~~~~ diff --git a/spp_dms/static/description/index.html b/spp_dms/static/description/index.html index b423af3d..518b5eb0 100644 --- a/spp_dms/static/description/index.html +++ b/spp_dms/static/description/index.html @@ -400,8 +400,8 @@

          Key Capabilities

          Key Models

          Group
          base.group_system Full CRUD on all models
          sp -p_registry.group_registry_read
          spp_registry.group_registry_read Read access to all models
          spp -_registry.group_registry_write
          spp_registry.group_registry_write Read/Write on generator and logs (delete ID/Bank types)
          spp_ -registry.group_registry_create
          spp_registry.group_registry_create Read/Create access (delete ID/Bank types)
          --++ @@ -425,8 +425,7 @@

          Key Models

          - + @@ -459,8 +458,8 @@

          UI Location

          Security

          Model File classification with validation rules
          `` -spp.dms.restore.version.wizard``
          spp.dms.restore.version.wizard Transient wizard for restoring file versions
          --++ diff --git a/spp_drims/README.rst b/spp_drims/README.rst index 39d271c2..34928965 100644 --- a/spp_drims/README.rst +++ b/spp_drims/README.rst @@ -36,22 +36,22 @@ breaches. Key Capabilities ~~~~~~~~~~~~~~~~ -- Record incoming donations with state machine (announced, received, - inspected, stocked) and inspection workflow -- Submit supply requests for affected areas with approval workflow, SLA - tracking, and priority handling -- Allocate stock using FIFO/FEFO logic and create dispatch pickings - with beneficiary area tracking -- Track returned items with condition assessment and disposition - routing (restock, repair, dispose) -- Generate alerts automatically for low stock thresholds, expiring - inventory, and overdue requests -- Create request templates for rapid response to recurring emergency - scenarios -- Monitor fulfillment progress with allocation percentage, dispatch - status, and delivery tracking -- Assign personnel to warehouses and service points with role and - cluster tracking +- Record incoming donations with state machine (announced, received, + inspected, stocked) and inspection workflow +- Submit supply requests for affected areas with approval workflow, SLA + tracking, and priority handling +- Allocate stock using FIFO/FEFO logic and create dispatch pickings with + beneficiary area tracking +- Track returned items with condition assessment and disposition routing + (restock, repair, dispose) +- Generate alerts automatically for low stock thresholds, expiring + inventory, and overdue requests +- Create request templates for rapid response to recurring emergency + scenarios +- Monitor fulfillment progress with allocation percentage, dispatch + status, and delivery tracking +- Assign personnel to warehouses and service points with role and + cluster tracking Key Models ~~~~~~~~~~ @@ -102,9 +102,9 @@ After installing: 4. Verify scheduled actions are active under **Settings > Technical > Scheduled Actions**: - - DRIMS: Check Low Stock (daily) - - DRIMS: Check Expiry Dates (daily) - - DRIMS: Check SLA Breaches (hourly) + - DRIMS: Check Low Stock (daily) + - DRIMS: Check Expiry Dates (daily) + - DRIMS: Check SLA Breaches (hourly) 5. Create request templates under **DRIMS > Configuration > Request Templates** for common scenarios @@ -114,59 +114,58 @@ After installing: UI Location ~~~~~~~~~~~ -- **Dashboard**: DRIMS > Dashboard (KPIs, recent activity, pending - approvals) -- **Donations**: DRIMS > Receive Supplies > Donations -- **Requests**: DRIMS > Fulfill Requests > All Requests -- **Dispatches**: DRIMS > Fulfill Requests > Dispatches -- **Returns**: DRIMS > Receive Supplies > Returns -- **Alerts**: DRIMS > Monitoring > Alerts -- **Personnel**: DRIMS > Monitoring > Personnel -- **Inventory**: DRIMS > Inventory > Stock On Hand, Warehouses, - Products +- **Dashboard**: DRIMS > Dashboard (KPIs, recent activity, pending + approvals) +- **Donations**: DRIMS > Receive Supplies > Donations +- **Requests**: DRIMS > Fulfill Requests > All Requests +- **Dispatches**: DRIMS > Fulfill Requests > Dispatches +- **Returns**: DRIMS > Receive Supplies > Returns +- **Alerts**: DRIMS > Monitoring > Alerts +- **Personnel**: DRIMS > Monitoring > Personnel +- **Inventory**: DRIMS > Inventory > Stock On Hand, Warehouses, Products Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| ``spp_drims.group_drims_viewer`` | Read-only access to donations, | -| | requests, dispatches | -+----------------------------------+----------------------------------+ -| ` | Create and edit donations, | -| `spp_drims.group_drims_officer`` | requests, returns (no delete) | -+----------------------------------+----------------------------------+ -| `` | Approve or reject supply | -| spp_drims.group_drims_approver`` | requests | -+----------------------------------+----------------------------------+ -| ` | Full CRUD including deletion and | -| `spp_drims.group_drims_manager`` | configuration | -+----------------------------------+----------------------------------+ -| ``spp_drim | Receive donations, manage stock, | -| s.group_drims_warehouse_worker`` | process dispatches | -+----------------------------------+----------------------------------+ -| ``spp_d | Create requests and confirm | -| rims.group_drims_field_officer`` | deliveries in the field | -+----------------------------------+----------------------------------+ -| ``spp_drims.grou | Coordinate requests and | -| p_drims_coordinator_supervisor`` | distributions within assigned | -| | areas | -+----------------------------------+----------------------------------+ ++--------------------------------------------------+----------------------------------+ +| Group | Access | ++==================================================+==================================+ +| ``spp_drims.group_drims_viewer`` | Read-only access to donations, | +| | requests, dispatches | ++--------------------------------------------------+----------------------------------+ +| ``spp_drims.group_drims_officer`` | Create and edit donations, | +| | requests, returns (no delete) | ++--------------------------------------------------+----------------------------------+ +| ``spp_drims.group_drims_approver`` | Approve or reject supply | +| | requests | ++--------------------------------------------------+----------------------------------+ +| ``spp_drims.group_drims_manager`` | Full CRUD including deletion and | +| | configuration | ++--------------------------------------------------+----------------------------------+ +| ``spp_drims.group_drims_warehouse_worker`` | Receive donations, manage stock, | +| | process dispatches | ++--------------------------------------------------+----------------------------------+ +| ``spp_drims.group_drims_field_officer`` | Create requests and confirm | +| | deliveries in the field | ++--------------------------------------------------+----------------------------------+ +| ``spp_drims.group_drims_coordinator_supervisor`` | Coordinate requests and | +| | distributions within assigned | +| | areas | ++--------------------------------------------------+----------------------------------+ Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``spp.drims.alert`` and override ``_cron_check_*`` methods to - add custom alert types -- Extend ``spp.drims.request`` and override ``_allocate_stock_fifo()`` - to customize allocation logic -- Add fields to ``stock.warehouse`` to track additional warehouse - metadata for DRIMS operations -- Inherit ``spp.drims.donation`` and override - ``_create_receipt_picking()`` to customize stock receipt behavior -- Override ``spp.drims.request._on_approve()`` and ``_on_reject()`` - hooks to add custom approval actions +- Inherit ``spp.drims.alert`` and override ``_cron_check_*`` methods to + add custom alert types +- Extend ``spp.drims.request`` and override ``_allocate_stock_fifo()`` + to customize allocation logic +- Add fields to ``stock.warehouse`` to track additional warehouse + metadata for DRIMS operations +- Inherit ``spp.drims.donation`` and override + ``_create_receipt_picking()`` to customize stock receipt behavior +- Override ``spp.drims.request._on_approve()`` and ``_on_reject()`` + hooks to add custom approval actions Dependencies ~~~~~~~~~~~~ diff --git a/spp_drims/static/description/index.html b/spp_drims/static/description/index.html index fd0cbaa1..45d16407 100644 --- a/spp_drims/static/description/index.html +++ b/spp_drims/static/description/index.html @@ -388,10 +388,10 @@

          Key Capabilities

          inspected, stocked) and inspection workflow
        • Submit supply requests for affected areas with approval workflow, SLA tracking, and priority handling
        • -
        • Allocate stock using FIFO/FEFO logic and create dispatch pickings -with beneficiary area tracking
        • -
        • Track returned items with condition assessment and disposition -routing (restock, repair, dispose)
        • +
        • Allocate stock using FIFO/FEFO logic and create dispatch pickings with +beneficiary area tracking
        • +
        • Track returned items with condition assessment and disposition routing +(restock, repair, dispose)
        • Generate alerts automatically for low stock thresholds, expiring inventory, and overdue requests
        • Create request templates for rapid response to recurring emergency @@ -490,16 +490,15 @@

          UI Location

        • Returns: DRIMS > Receive Supplies > Returns
        • Alerts: DRIMS > Monitoring > Alerts
        • Personnel: DRIMS > Monitoring > Personnel
        • -
        • Inventory: DRIMS > Inventory > Stock On Hand, Warehouses, -Products
        • +
        • Inventory: DRIMS > Inventory > Stock On Hand, Warehouses, Products
        • Security

          Group
          --++ @@ -511,33 +510,27 @@

          Security

          - + - + - + - + - + - + diff --git a/spp_drims_sl/README.rst b/spp_drims_sl/README.rst index 4c7f755d..8e296412 100644 --- a/spp_drims_sl/README.rst +++ b/spp_drims_sl/README.rst @@ -36,49 +36,48 @@ no models or views. Key Configuration Data ~~~~~~~~~~~~~~~~~~~~~~ -- **Company Setup**: Configures main company as "Disaster Management - Centre - Sri Lanka" with LKR currency and Sri Lanka country -- **Geographic Structure**: Defines 4-level administrative hierarchy - (Province → District → DS Division → GN Division) via - ``spp.area.kind`` records -- **Agency Network**: Creates 16 ``res.partner`` records for government - agencies, military, UN agencies, and NGOs with DRIMS organization - roles -- **Warehouse Network**: Provisions 11 ``stock.warehouse`` records (2 - national-level, 9 provincial-level) with capacity and emergency - contact metadata -- **Hazard Taxonomy**: Hierarchical natural disaster categories - (floods, landslides, drought, cyclones, monsoons) via - ``spp.hazard.category`` -- **Relief Products**: 30 ``product.product`` records across 8 - categories with expiry tracking enabled via ``product_expiry`` module -- **Approval Workflows**: 4 ``spp.approval.definition`` records with - value-based routing (life-threatening fast-track, small/medium/large - value tiers) -- **Vocabulary Extensions**: 15 Sri Lanka-specific - ``spp.vocabulary.code`` records for priority levels, transport modes, - hazard types, and agency types -- **Reference Numbers**: Overrides ``ir.sequence`` records with SL - prefixes (DON-SL, REQ-SL, WB-SL, INC-SL) -- **Demo Users**: 13 ``res.users`` spanning roles from field officers - to warehouse staff to approvers +- **Company Setup**: Configures main company as "Disaster Management + Centre - Sri Lanka" with LKR currency and Sri Lanka country +- **Geographic Structure**: Defines 4-level administrative hierarchy + (Province → District → DS Division → GN Division) via + ``spp.area.kind`` records +- **Agency Network**: Creates 16 ``res.partner`` records for government + agencies, military, UN agencies, and NGOs with DRIMS organization + roles +- **Warehouse Network**: Provisions 11 ``stock.warehouse`` records (2 + national-level, 9 provincial-level) with capacity and emergency + contact metadata +- **Hazard Taxonomy**: Hierarchical natural disaster categories (floods, + landslides, drought, cyclones, monsoons) via ``spp.hazard.category`` +- **Relief Products**: 30 ``product.product`` records across 8 + categories with expiry tracking enabled via ``product_expiry`` module +- **Approval Workflows**: 4 ``spp.approval.definition`` records with + value-based routing (life-threatening fast-track, small/medium/large + value tiers) +- **Vocabulary Extensions**: 15 Sri Lanka-specific + ``spp.vocabulary.code`` records for priority levels, transport modes, + hazard types, and agency types +- **Reference Numbers**: Overrides ``ir.sequence`` records with SL + prefixes (DON-SL, REQ-SL, WB-SL, INC-SL) +- **Demo Users**: 13 ``res.users`` spanning roles from field officers to + warehouse staff to approvers Approval Workflow Tiers ~~~~~~~~~~~~~~~~~~~~~~~ -+-----------------------------+-----------------------------+--------+ -| Condition | Approvers | SLA | -+=============================+=============================+========+ -| Priority = Life-Threatening | Single manager (fast-track) | 0 days | -+-----------------------------+-----------------------------+--------+ -| Value < 100,000 LKR | District approver | 1 day | -+-----------------------------+-----------------------------+--------+ -| Value 100,000 - 500,000 LKR | District → Provincial | 2 days | -| | (2-tier) | | -+-----------------------------+-----------------------------+--------+ -| Value > 500,000 LKR | District → Provincial → | 3 days | -| | National DMC (3-tier) | | -+-----------------------------+-----------------------------+--------+ ++------------------------------+------------------------------+--------+ +| Condition | Approvers | SLA | ++==============================+==============================+========+ +| Priority = Life-Threatening | Single manager (fast-track) | 0 days | ++------------------------------+------------------------------+--------+ +| Value < 100,000 LKR | District approver | 1 day | ++------------------------------+------------------------------+--------+ +| Value 100,000 - 500,000 LKR | District → Provincial | 2 days | +| | (2-tier) | | ++------------------------------+------------------------------+--------+ +| Value > 500,000 LKR | District → Provincial → | 3 days | +| | National DMC (3-tier) | | ++------------------------------+------------------------------+--------+ Configuration ~~~~~~~~~~~~~ diff --git a/spp_drims_sl/static/description/index.html b/spp_drims_sl/static/description/index.html index ecf119a3..f84d20e0 100644 --- a/spp_drims_sl/static/description/index.html +++ b/spp_drims_sl/static/description/index.html @@ -395,9 +395,8 @@

          Key Configuration Data

        • Warehouse Network: Provisions 11 stock.warehouse records (2 national-level, 9 provincial-level) with capacity and emergency contact metadata
        • -
        • Hazard Taxonomy: Hierarchical natural disaster categories -(floods, landslides, drought, cyclones, monsoons) via -spp.hazard.category
        • +
        • Hazard Taxonomy: Hierarchical natural disaster categories (floods, +landslides, drought, cyclones, monsoons) via spp.hazard.category
        • Relief Products: 30 product.product records across 8 categories with expiry tracking enabled via product_expiry module
        • Approval Workflows: 4 spp.approval.definition records with @@ -408,8 +407,8 @@

          Key Configuration Data

          hazard types, and agency types
        • Reference Numbers: Overrides ir.sequence records with SL prefixes (DON-SL, REQ-SL, WB-SL, INC-SL)
        • -
        • Demo Users: 13 res.users spanning roles from field officers -to warehouse staff to approvers
        • +
        • Demo Users: 13 res.users spanning roles from field officers to +warehouse staff to approvers
        • diff --git a/spp_drims_sl_demo/README.rst b/spp_drims_sl_demo/README.rst index 587cb639..c757ffe3 100644 --- a/spp_drims_sl_demo/README.rst +++ b/spp_drims_sl_demo/README.rst @@ -35,35 +35,35 @@ Excel data and HDX polygon files for GIS visualization. Key Capabilities ~~~~~~~~~~~~~~~~ -- Import Sri Lanka administrative boundaries from Excel and HDX GeoJSON - files (provinces, districts, DS/GN divisions) -- Generate disaster incidents with affected areas, severity levels, and - coordination modes -- Create donations from UN agencies and NGOs at various workflow states -- Generate relief requests with priorities, SLA deadlines, - life-threatening flags, and OCHA cluster assignments -- Populate warehouses with relief items, lot tracking, and expiry dates -- Create personnel deployments with roles, organizations, clusters, and - contact information -- Generate low stock, SLA breach, and SLA warning alerts and trigger - alert engine cron jobs -- Create completed dispatch pickings with beneficiary counts and POD - data for dashboard KPIs -- Configure GIS reports for choropleth visualization of request - distribution and affected populations +- Import Sri Lanka administrative boundaries from Excel and HDX GeoJSON + files (provinces, districts, DS/GN divisions) +- Generate disaster incidents with affected areas, severity levels, and + coordination modes +- Create donations from UN agencies and NGOs at various workflow states +- Generate relief requests with priorities, SLA deadlines, + life-threatening flags, and OCHA cluster assignments +- Populate warehouses with relief items, lot tracking, and expiry dates +- Create personnel deployments with roles, organizations, clusters, and + contact information +- Generate low stock, SLA breach, and SLA warning alerts and trigger + alert engine cron jobs +- Create completed dispatch pickings with beneficiary counts and POD + data for dashboard KPIs +- Configure GIS reports for choropleth visualization of request + distribution and affected populations Key Models ~~~~~~~~~~ -+-------------------------------+-------------------------------------+ -| Model | Description | -+===============================+=====================================+ -| ``spp.drims.demo.generator`` | Transient wizard that orchestrates | -| | demo data generation | -+-------------------------------+-------------------------------------+ -| ``spp.gis.report`` (extended) | Adds ``spp.drims.request`` as | -| | supported GIS report data source | -+-------------------------------+-------------------------------------+ ++-------------------------------+--------------------------------------+ +| Model | Description | ++===============================+======================================+ +| ``spp.drims.demo.generator`` | Transient wizard that orchestrates | +| | demo data generation | ++-------------------------------+--------------------------------------+ +| ``spp.gis.report`` (extended) | Adds ``spp.drims.request`` as | +| | supported GIS report data source | ++-------------------------------+--------------------------------------+ Usage ~~~~~ @@ -81,22 +81,22 @@ alerts. Full generation takes 2-5 minutes. Demo Data Included ~~~~~~~~~~~~~~~~~~ -- **Relief Products**: 27 product templates across 7 categories (Food & - Nutrition, Water & Beverages, Medical & Health, Shelter & Housing, - Hygiene & WASH, Clothing & Bedding, Equipment & Tools) -- **Demo Users**: 6 users with password ``demo``: kumari (field - officer), rajitha (approver), silva (manager), perera (warehouse - worker), fernando (coordinator), secretary (viewer) -- **GIS Reports**: 5 pre-configured reports for request distribution, - affected population, pending approvals, relief value, and fulfillment - progress +- **Relief Products**: 27 product templates across 7 categories (Food & + Nutrition, Water & Beverages, Medical & Health, Shelter & Housing, + Hygiene & WASH, Clothing & Bedding, Equipment & Tools) +- **Demo Users**: 6 users with password ``demo``: kumari (field + officer), rajitha (approver), silva (manager), perera (warehouse + worker), fernando (coordinator), secretary (viewer) +- **GIS Reports**: 5 pre-configured reports for request distribution, + affected population, pending approvals, relief value, and fulfillment + progress UI Location ~~~~~~~~~~~ -- **Menu**: Settings > Demo Data > Load DRIMS Demo -- **Dashboard**: After loading, system redirects to Social Protection > - DRIMS > Dashboard +- **Menu**: Settings > Demo Data > Load DRIMS Demo +- **Dashboard**: After loading, system redirects to Social Protection > + DRIMS > Dashboard Security ~~~~~~~~ @@ -110,12 +110,12 @@ Group Access Extension Points ~~~~~~~~~~~~~~~~ -- Override ``_generate_incidents()`` to customize incident scenarios - for country-specific disaster types -- Inherit ``spp.drims.demo.generator`` to add custom demo data - generation steps -- Override area import methods to support alternative data sources - beyond Excel/HDX +- Override ``_generate_incidents()`` to customize incident scenarios for + country-specific disaster types +- Inherit ``spp.drims.demo.generator`` to add custom demo data + generation steps +- Override area import methods to support alternative data sources + beyond Excel/HDX Dependencies ~~~~~~~~~~~~ diff --git a/spp_drims_sl_demo/static/description/index.html b/spp_drims_sl_demo/static/description/index.html index 4385cc3b..a049d025 100644 --- a/spp_drims_sl_demo/static/description/index.html +++ b/spp_drims_sl_demo/static/description/index.html @@ -405,8 +405,8 @@

          Key Capabilities

          Key Models

          Group Read-only access to donations, requests, dispatches
          ` -spp_drims.group_drims_officer`
          spp_drims.group_drims_officer Create and edit donations, requests, returns (no delete)
          `` -spp_drims.group_drims_approver``
          spp_drims.group_drims_approver Approve or reject supply requests
          ` -spp_drims.group_drims_manager`
          spp_drims.group_drims_manager Full CRUD including deletion and configuration
          spp_drim -s.group_drims_warehouse_worker
          spp_drims.group_drims_warehouse_worker Receive donations, manage stock, process dispatches
          spp_d -rims.group_drims_field_officer
          spp_drims.group_drims_field_officer Create requests and confirm deliveries in the field
          spp_drims.grou -p_drims_coordinator_supervisor
          spp_drims.group_drims_coordinator_supervisor Coordinate requests and distributions within assigned areas
          --++ @@ -481,8 +481,8 @@

          Security

          Extension Points

            -
          • Override _generate_incidents() to customize incident scenarios -for country-specific disaster types
          • +
          • Override _generate_incidents() to customize incident scenarios for +country-specific disaster types
          • Inherit spp.drims.demo.generator to add custom demo data generation steps
          • Override area import methods to support alternative data sources diff --git a/spp_event_data/README.rst b/spp_event_data/README.rst index 2fa84a7d..fa7b4a08 100644 --- a/spp_event_data/README.rst +++ b/spp_event_data/README.rst @@ -32,46 +32,46 @@ request generation when event data differs from registrant records. Key Capabilities ~~~~~~~~~~~~~~~~ -- Configure event types with categories (survey, visit, sync, manual), - target types, and storage modes -- Record events with collection metadata (date, collector, source - reference) and expiry tracking -- Store event data in JSON, define custom fields, or link to dedicated - Odoo models -- Automatically supersede previous active events when new ones arrive - for the same registrant -- Auto-expire events after a configurable number of days via scheduled - cron -- Require approval for new events before activation using configurable - workflows -- Integrate with external sources (ODK Central, KoBoToolbox, APIs) with - field mapping and transformations -- Generate change requests when event data differs from registrant - fields (requires ``spp_change_request``) -- Track event history with state transitions: draft → pending → active - → superseded/expired/cancelled +- Configure event types with categories (survey, visit, sync, manual), + target types, and storage modes +- Record events with collection metadata (date, collector, source + reference) and expiry tracking +- Store event data in JSON, define custom fields, or link to dedicated + Odoo models +- Automatically supersede previous active events when new ones arrive + for the same registrant +- Auto-expire events after a configurable number of days via scheduled + cron +- Require approval for new events before activation using configurable + workflows +- Integrate with external sources (ODK Central, KoBoToolbox, APIs) with + field mapping and transformations +- Generate change requests when event data differs from registrant + fields (requires ``spp_change_request``) +- Track event history with state transitions: draft → pending → active → + superseded/expired/cancelled Key Models ~~~~~~~~~~ -+-----------------------------+---------------------------------------+ -| Model | Description | -+=============================+=======================================+ -| ``spp.event.data`` | Event record with registrant link, | -| | collection metadata | -+-----------------------------+---------------------------------------+ -| ``spp.event.type`` | Event type configuration (category, | -| | lifecycle, source) | -+-----------------------------+---------------------------------------+ -| ``spp.event.field`` | Custom field definition for | -| | JSON-based event types | -+-----------------------------+---------------------------------------+ -| ``spp.event.type.mapping`` | Field mapping for external source | -| | data transformation | -+-----------------------------+---------------------------------------+ -| ``spp.create.event.wizard`` | Wizard to create new event records | -| | from registrant form | -+-----------------------------+---------------------------------------+ ++-----------------------------+----------------------------------------+ +| Model | Description | ++=============================+========================================+ +| ``spp.event.data`` | Event record with registrant link, | +| | collection metadata | ++-----------------------------+----------------------------------------+ +| ``spp.event.type`` | Event type configuration (category, | +| | lifecycle, source) | ++-----------------------------+----------------------------------------+ +| ``spp.event.field`` | Custom field definition for JSON-based | +| | event types | ++-----------------------------+----------------------------------------+ +| ``spp.event.type.mapping`` | Field mapping for external source data | +| | transformation | ++-----------------------------+----------------------------------------+ +| ``spp.create.event.wizard`` | Wizard to create new event records | +| | from registrant form | ++-----------------------------+----------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -94,14 +94,14 @@ After installing: UI Location ~~~~~~~~~~~ -- **Registrant Form**: "Event Data" stat button in button box opens - create wizard -- **Registrant Form**: Events section displays event history list with - state badges -- **Event Data**: Access via window action ``action_spp_event_data`` - (no menu defined in this module) -- **Event Form Tabs**: Event Data, Source, History, Legacy Data, - Approval +- **Registrant Form**: "Event Data" stat button in button box opens + create wizard +- **Registrant Form**: Events section displays event history list with + state badges +- **Event Data**: Access via window action ``action_spp_event_data`` (no + menu defined in this module) +- **Event Form Tabs**: Event Data, Source, History, Legacy Data, + Approval Security ~~~~~~~~ @@ -121,15 +121,15 @@ Group Access Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``spp.event.type`` and override ``get_connector()`` to add - custom external source connectors -- Inherit ``spp.event.data`` and override ``_create_change_requests()`` - to customize change request logic -- Use ``_get_active_event_id()``, ``get_active_event()``, and - ``get_event_data_value()`` methods on ``res.partner`` for O(1) event - lookup -- Call ``_refresh_active_event_cache()`` on registrants when events are - activated/deactivated for cache consistency +- Inherit ``spp.event.type`` and override ``get_connector()`` to add + custom external source connectors +- Inherit ``spp.event.data`` and override ``_create_change_requests()`` + to customize change request logic +- Use ``_get_active_event_id()``, ``get_active_event()``, and + ``get_event_data_value()`` methods on ``res.partner`` for O(1) event + lookup +- Call ``_refresh_active_event_cache()`` on registrants when events are + activated/deactivated for cache consistency Dependencies ~~~~~~~~~~~~ diff --git a/spp_event_data/static/description/index.html b/spp_event_data/static/description/index.html index a3cce47b..e9f0ca51 100644 --- a/spp_event_data/static/description/index.html +++ b/spp_event_data/static/description/index.html @@ -399,16 +399,16 @@

            Key Capabilities

            field mapping and transformations
          • Generate change requests when event data differs from registrant fields (requires spp_change_request)
          • -
          • Track event history with state transitions: draft → pending → active -→ superseded/expired/cancelled
          • +
          • Track event history with state transitions: draft → pending → active → +superseded/expired/cancelled

          Key Models

          Model
          --++ @@ -425,12 +425,12 @@

          Key Models

          lifecycle, source) - + - +
          Model
          spp.event.fieldCustom field definition for -JSON-based event typesCustom field definition for JSON-based +event types
          spp.event.type.mappingField mapping for external source -data transformationField mapping for external source data +transformation
          spp.create.event.wizard Wizard to create new event records @@ -464,8 +464,8 @@

          UI Location

          create wizard
        • Registrant Form: Events section displays event history list with state badges
        • -
        • Event Data: Access via window action action_spp_event_data -(no menu defined in this module)
        • +
        • Event Data: Access via window action action_spp_event_data (no +menu defined in this module)
        • Event Form Tabs: Event Data, Source, History, Legacy Data, Approval
        • diff --git a/spp_gis/README.rst b/spp_gis/README.rst index 3526e789..8dcad8f1 100644 --- a/spp_gis/README.rst +++ b/spp_gis/README.rst @@ -32,37 +32,37 @@ polygon fields. Key Capabilities ~~~~~~~~~~~~~~~~ -- Define geo fields (``geo_point``, ``geo_line``, ``geo_polygon``) on - any model using PostGIS spatial types -- Visualize records on interactive maps via the GIS view type -- Configure background raster layers (OpenStreetMap, WMS, satellite - imagery) -- Configure data layers with basic or choropleth (color-by-value) - rendering -- Perform spatial queries (intersects, contains, within, - distance-based) via ``gis_locational_query()`` -- Import area boundaries from GeoJSON/shapefiles via area import wizard -- Manage color schemes for thematic mapping with sequential, diverging, - or qualitative palettes +- Define geo fields (``geo_point``, ``geo_line``, ``geo_polygon``) on + any model using PostGIS spatial types +- Visualize records on interactive maps via the GIS view type +- Configure background raster layers (OpenStreetMap, WMS, satellite + imagery) +- Configure data layers with basic or choropleth (color-by-value) + rendering +- Perform spatial queries (intersects, contains, within, distance-based) + via ``gis_locational_query()`` +- Import area boundaries from GeoJSON/shapefiles via area import wizard +- Manage color schemes for thematic mapping with sequential, diverging, + or qualitative palettes Key Models ~~~~~~~~~~ -+-------------------------------+-------------------------------------+ -| Model | Description | -+===============================+=====================================+ -| ``spp.gis.raster.layer`` | Background map layers (OSM, WMS, | -| | image) | -+-------------------------------+-------------------------------------+ -| ``spp.gis.data.layer`` | Vector data layers referencing geo | -| | fields from any model | -+-------------------------------+-------------------------------------+ -| ``spp.gis.color.scheme`` | Color palettes for choropleth and | -| | thematic visualizations | -+-------------------------------+-------------------------------------+ -| ``spp.gis.raster.layer.type`` | Raster layer type definitions (WMS | -| | services) | -+-------------------------------+-------------------------------------+ ++-------------------------------+--------------------------------------+ +| Model | Description | ++===============================+======================================+ +| ``spp.gis.raster.layer`` | Background map layers (OSM, WMS, | +| | image) | ++-------------------------------+--------------------------------------+ +| ``spp.gis.data.layer`` | Vector data layers referencing geo | +| | fields from any model | ++-------------------------------+--------------------------------------+ +| ``spp.gis.color.scheme`` | Color palettes for choropleth and | +| | thematic visualizations | ++-------------------------------+--------------------------------------+ +| ``spp.gis.raster.layer.type`` | Raster layer type definitions (WMS | +| | services) | ++-------------------------------+--------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -80,42 +80,42 @@ After installing: UI Location ~~~~~~~~~~~ -- **GIS View**: Available as a view mode on models with geo fields - (e.g., ``spp.area``) -- **Area Form**: "Coordinates" and "Polygon" tabs appear when editing - areas (Social Protection > Configuration > Areas) -- **No standalone menu**: This module does not define menu items; GIS - functionality is accessed through existing models +- **GIS View**: Available as a view mode on models with geo fields + (e.g., ``spp.area``) +- **Area Form**: "Coordinates" and "Polygon" tabs appear when editing + areas (Social Protection > Configuration > Areas) +- **No standalone menu**: This module does not define menu items; GIS + functionality is accessed through existing models Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| ``spp_security.group_spp_admin`` | Full CRUD on all GIS models | -+----------------------------------+----------------------------------+ -| ``sp | Read-only on color schemes and | -| p_registry.group_registry_read`` | layers | -+----------------------------------+----------------------------------+ -| ``spp_gis.group_gis_user`` | View GIS data and maps | -+----------------------------------+----------------------------------+ -| ``spp_gis.group_gis_admin`` | Full GIS management including | -| | configuration | -+----------------------------------+----------------------------------+ ++--------------------------------------+----------------------------------+ +| Group | Access | ++======================================+==================================+ +| ``spp_security.group_spp_admin`` | Full CRUD on all GIS models | ++--------------------------------------+----------------------------------+ +| ``spp_registry.group_registry_read`` | Read-only on color schemes and | +| | layers | ++--------------------------------------+----------------------------------+ +| ``spp_gis.group_gis_user`` | View GIS data and maps | ++--------------------------------------+----------------------------------+ +| ``spp_gis.group_gis_admin`` | Full GIS management including | +| | configuration | ++--------------------------------------+----------------------------------+ Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``base`` and call - ``gis_locational_query(longitude, latitude, layer_type, spatial_relation)`` - for location-based searches -- Override ``_get_choropleth_config()`` on ``spp.gis.data.layer`` to - customize thematic mapping logic -- Inherit any model and add ``geo_point``, ``geo_line``, or - ``geo_polygon`` fields to enable spatial storage -- Create GIS views by setting ``type="gis"`` in ``ir.ui.view`` XML and - linking ``spp.gis.data.layer`` records +- Inherit ``base`` and call + ``gis_locational_query(longitude, latitude, layer_type, spatial_relation)`` + for location-based searches +- Override ``_get_choropleth_config()`` on ``spp.gis.data.layer`` to + customize thematic mapping logic +- Inherit any model and add ``geo_point``, ``geo_line``, or + ``geo_polygon`` fields to enable spatial storage +- Create GIS views by setting ``type="gis"`` in ``ir.ui.view`` XML and + linking ``spp.gis.data.layer`` records Dependencies ~~~~~~~~~~~~ diff --git a/spp_gis/static/description/index.html b/spp_gis/static/description/index.html index 1884b267..ae86a3f0 100644 --- a/spp_gis/static/description/index.html +++ b/spp_gis/static/description/index.html @@ -390,8 +390,8 @@

          Key Capabilities

          imagery)
        • Configure data layers with basic or choropleth (color-by-value) rendering
        • -
        • Perform spatial queries (intersects, contains, within, -distance-based) via gis_locational_query()
        • +
        • Perform spatial queries (intersects, contains, within, distance-based) +via gis_locational_query()
        • Import area boundaries from GeoJSON/shapefiles via area import wizard
        • Manage color schemes for thematic mapping with sequential, diverging, or qualitative palettes
        • @@ -401,8 +401,8 @@

          Key Capabilities

          Key Models

          --++ @@ -457,8 +457,8 @@

          UI Location

          Security

          Model
          --++ @@ -469,8 +469,7 @@

          Security

          - + diff --git a/spp_gis_report/README.rst b/spp_gis_report/README.rst index 4a04d875..623c086b 100644 --- a/spp_gis_report/README.rst +++ b/spp_gis_report/README.rst @@ -33,46 +33,46 @@ for external tool integration. Key Capabilities ~~~~~~~~~~~~~~~~ -- Template-based wizard guides users through report creation with three - steps -- Aggregates registrant, program, or disaster data by administrative - area using configurable field paths -- Normalizes values per km², per capita, per household, or as - percentages -- Rolls up data through area hierarchy from base level to all parent - levels -- Auto-calculates thresholds using quartiles, equal intervals, Jenks - breaks, or standard deviation -- Scheduled or on-demand data refresh with background job processing -- GeoJSON API endpoints using report codes (not database IDs) for - external tools -- Supports multiple geometry types: polygon choropleth, point markers, - clusters, heatmaps +- Template-based wizard guides users through report creation with three + steps +- Aggregates registrant, program, or disaster data by administrative + area using configurable field paths +- Normalizes values per km², per capita, per household, or as + percentages +- Rolls up data through area hierarchy from base level to all parent + levels +- Auto-calculates thresholds using quartiles, equal intervals, Jenks + breaks, or standard deviation +- Scheduled or on-demand data refresh with background job processing +- GeoJSON API endpoints using report codes (not database IDs) for + external tools +- Supports multiple geometry types: polygon choropleth, point markers, + clusters, heatmaps Key Models ~~~~~~~~~~ -+------------------------------+--------------------------------------+ -| Model | Description | -+==============================+======================================+ -| ``spp.gis.report`` | Report configuration defining | -| | source, aggregation, and display | -+------------------------------+--------------------------------------+ -| ``spp.gis.report.data`` | Cached computed values for each | -| | area, updated on schedule | -+------------------------------+--------------------------------------+ -| ``spp.gis.report.template`` | Pre-built report definitions with | -| | JSON configuration | -+------------------------------+--------------------------------------+ -| ``spp.gis.report.category`` | Categories for organizing reports | -| | and templates | -+------------------------------+--------------------------------------+ -| ``spp.gis.report.threshold`` | Color threshold definitions for map | -| | visualization | -+------------------------------+--------------------------------------+ -| ``spp.gis.report.wizard`` | Three-step wizard for creating | -| | reports from templates | -+------------------------------+--------------------------------------+ ++------------------------------+---------------------------------------+ +| Model | Description | ++==============================+=======================================+ +| ``spp.gis.report`` | Report configuration defining source, | +| | aggregation, and display | ++------------------------------+---------------------------------------+ +| ``spp.gis.report.data`` | Cached computed values for each area, | +| | updated on schedule | ++------------------------------+---------------------------------------+ +| ``spp.gis.report.template`` | Pre-built report definitions with | +| | JSON configuration | ++------------------------------+---------------------------------------+ +| ``spp.gis.report.category`` | Categories for organizing reports and | +| | templates | ++------------------------------+---------------------------------------+ +| ``spp.gis.report.threshold`` | Color threshold definitions for map | +| | visualization | ++------------------------------+---------------------------------------+ +| ``spp.gis.report.wizard`` | Three-step wizard for creating | +| | reports from templates | ++------------------------------+---------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -83,61 +83,60 @@ loaded automatically and accessible via the wizard. UI Location ~~~~~~~~~~~ -- **Menu**: GIS Reports > Reports -- **Templates**: GIS Reports > Templates -- **Configuration**: GIS Reports > Configuration > Categories and Color - Schemes (admin only) -- **Wizard**: Create reports by opening a template and clicking "Create - Report" -- **Form Tabs**: General, Data Source, Aggregation, Normalization, - Visualization, Rollup, Schedule, Access, Map Layer +- **Menu**: GIS Reports > Reports +- **Templates**: GIS Reports > Templates +- **Configuration**: GIS Reports > Configuration > Categories and Color + Schemes (admin only) +- **Wizard**: Create reports by opening a template and clicking "Create + Report" +- **Form Tabs**: General, Data Source, Aggregation, Normalization, + Visualization, Rollup, Schedule, Access, Map Layer Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| ``base.group_user`` | Read reports and data | -+----------------------------------+----------------------------------+ -| ``group_gis_report_user`` | Read reports, write data for | -| | refresh | -+----------------------------------+----------------------------------+ -| ``group_gis_report_officer`` | Read/Write/Create (no delete) | -+----------------------------------+----------------------------------+ -| ``group_gis_report_manager`` | Full CRUD | -+----------------------------------+----------------------------------+ -| ``spp_r | Read reports and data | -| egistry.group_registry_officer`` | | -+----------------------------------+----------------------------------+ -| ``spp_security.group_spp_admin`` | Full CRUD and configuration | -+----------------------------------+----------------------------------+ ++-----------------------------------------+----------------------------------+ +| Group | Access | ++=========================================+==================================+ +| ``base.group_user`` | Read reports and data | ++-----------------------------------------+----------------------------------+ +| ``group_gis_report_user`` | Read reports, write data for | +| | refresh | ++-----------------------------------------+----------------------------------+ +| ``group_gis_report_officer`` | Read/Write/Create (no delete) | ++-----------------------------------------+----------------------------------+ +| ``group_gis_report_manager`` | Full CRUD | ++-----------------------------------------+----------------------------------+ +| ``spp_registry.group_registry_officer`` | Read reports and data | ++-----------------------------------------+----------------------------------+ +| ``spp_security.group_spp_admin`` | Full CRUD and configuration | ++-----------------------------------------+----------------------------------+ API Endpoints ~~~~~~~~~~~~~ All endpoints use report ``code`` as identifier, not database IDs: -- ``GET /api/v2/GISReport`` - List available reports -- ``GET /api/v2/GISReport//geojson`` - Get report data as GeoJSON - FeatureCollection -- ``GET /api/v2/GISReport//summary`` - Get aggregate statistics -- ``POST /api/v2/GISReport//refresh`` - Trigger manual data - refresh +- ``GET /api/v2/GISReport`` - List available reports +- ``GET /api/v2/GISReport//geojson`` - Get report data as GeoJSON + FeatureCollection +- ``GET /api/v2/GISReport//summary`` - Get aggregate statistics +- ``POST /api/v2/GISReport//refresh`` - Trigger manual data + refresh Extension Points ~~~~~~~~~~~~~~~~ -- Override ``_get_gis_report_source_models()`` on ``spp.gis.report`` to - add models as data sources -- Override ``_apply_context_filters()`` on ``spp.gis.report`` to add - module-specific filtering (e.g., program context) -- Inherit ``spp.gis.report.wizard`` and override - ``_validate_context_requirements()`` and - ``_get_context_filter_vals()`` to add wizard steps for program or - incident selection -- Add report templates via data XML files with JSON configuration -- Extend ``spp.area`` to add reference data fields for normalization +- Override ``_get_gis_report_source_models()`` on ``spp.gis.report`` to + add models as data sources +- Override ``_apply_context_filters()`` on ``spp.gis.report`` to add + module-specific filtering (e.g., program context) +- Inherit ``spp.gis.report.wizard`` and override + ``_validate_context_requirements()`` and + ``_get_context_filter_vals()`` to add wizard steps for program or + incident selection +- Add report templates via data XML files with JSON configuration +- Extend ``spp.area`` to add reference data fields for normalization Dependencies ~~~~~~~~~~~~ diff --git a/spp_gis_report/static/description/index.html b/spp_gis_report/static/description/index.html index c5a6ca68..cc60ad62 100644 --- a/spp_gis_report/static/description/index.html +++ b/spp_gis_report/static/description/index.html @@ -405,8 +405,8 @@

          Key Capabilities

          Key Models

          Group
          spp_security.group_spp_admin Full CRUD on all GIS models
          sp -p_registry.group_registry_read
          spp_registry.group_registry_read Read-only on color schemes and layers
          --++ @@ -415,20 +415,20 @@

          Key Models

          - + - + - +
          Model
          spp.gis.reportReport configuration defining -source, aggregation, and displayReport configuration defining source, +aggregation, and display
          spp.gis.report.dataCached computed values for each -area, updated on scheduleCached computed values for each area, +updated on schedule
          spp.gis.report.template Pre-built report definitions with JSON configuration
          spp.gis.report.categoryCategories for organizing reports -and templatesCategories for organizing reports and +templates
          spp.gis.report.threshold Color threshold definitions for map @@ -463,8 +463,8 @@

          UI Location

          Security

          --++ @@ -485,8 +485,7 @@

          Security

          - + diff --git a/spp_gis_report_programs/README.rst b/spp_gis_report_programs/README.rst index b0bcf8a2..b2c66542 100644 --- a/spp_gis_report_programs/README.rst +++ b/spp_gis_report_programs/README.rst @@ -34,25 +34,25 @@ visualization. Key Capabilities ~~~~~~~~~~~~~~~~ -- Filter GIS reports to show only registrants enrolled in a specific - program -- Add program selector to report forms and wizard interface -- Validate program selection requirements before generating reports -- Include program identifier in generated report codes -- Grant GIS report access to program officers and managers +- Filter GIS reports to show only registrants enrolled in a specific + program +- Add program selector to report forms and wizard interface +- Validate program selection requirements before generating reports +- Include program identifier in generated report codes +- Grant GIS report access to program officers and managers Key Models ~~~~~~~~~~ -+---------------------------+-----------------------------------------+ -| Model | Extension | -+===========================+=========================================+ -| ``spp.gis.report`` | Adds ``program_id`` field and filters | -| | domain by program members | -+---------------------------+-----------------------------------------+ -| ``spp.gis.report.wizard`` | Adds ``program_id`` selection with | -| | validation and code suffix | -+---------------------------+-----------------------------------------+ ++---------------------------+------------------------------------------+ +| Model | Extension | ++===========================+==========================================+ +| ``spp.gis.report`` | Adds ``program_id`` field and filters | +| | domain by program members | ++---------------------------+------------------------------------------+ +| ``spp.gis.report.wizard`` | Adds ``program_id`` selection with | +| | validation and code suffix | ++---------------------------+------------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -63,26 +63,26 @@ and ``spp_programs`` are present. UI Location ~~~~~~~~~~~ -- **Report Form**: Program field appears in the "context_group" on GIS - report forms (accessed via **GIS Reports > Reports**) -- **Wizard**: Program field appears in the "context_filters" group when - generating reports from templates +- **Report Form**: Program field appears in the "context_group" on GIS + report forms (accessed via **GIS Reports > Reports**) +- **Wizard**: Program field appears in the "context_filters" group when + generating reports from templates Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| ``spp_p | Read GIS reports, data, | -| rograms.group_programs_officer`` | templates, etc. | -+----------------------------------+----------------------------------+ -| ``spp_p | Read/Write (no create/unlink) | -| rograms.group_programs_manager`` | all models | -+----------------------------------+----------------------------------+ -| ``spp_gi | Implied for program managers via | -| s_report.group_gis_report_user`` | XML | -+----------------------------------+----------------------------------+ ++------------------------------------------+----------------------------------+ +| Group | Access | ++==========================================+==================================+ +| ``spp_programs.group_programs_officer`` | Read GIS reports, data, | +| | templates, etc. | ++------------------------------------------+----------------------------------+ +| ``spp_programs.group_programs_manager`` | Read/Write (no create/unlink) | +| | all models | ++------------------------------------------+----------------------------------+ +| ``spp_gis_report.group_gis_report_user`` | Implied for program managers via | +| | XML | ++------------------------------------------+----------------------------------+ Models with access: ``spp.gis.report``, ``spp.gis.report.data``, ``spp.gis.report.threshold``, ``spp.gis.report.template``, @@ -91,14 +91,14 @@ Models with access: ``spp.gis.report``, ``spp.gis.report.data``, Extension Points ~~~~~~~~~~~~~~~~ -- Override ``_apply_context_filters()`` on ``spp.gis.report`` to add - custom program-based filtering -- Override ``_validate_context_requirements()`` on - ``spp.gis.report.wizard`` for additional validation -- Override ``_get_context_code_suffix()`` to customize report code - generation with program identifiers -- Override ``_get_context_filter_vals()`` to modify report creation - values +- Override ``_apply_context_filters()`` on ``spp.gis.report`` to add + custom program-based filtering +- Override ``_validate_context_requirements()`` on + ``spp.gis.report.wizard`` for additional validation +- Override ``_get_context_code_suffix()`` to customize report code + generation with program identifiers +- Override ``_get_context_filter_vals()`` to modify report creation + values Dependencies ~~~~~~~~~~~~ diff --git a/spp_gis_report_programs/static/description/index.html b/spp_gis_report_programs/static/description/index.html index b21bad0b..e4f407a7 100644 --- a/spp_gis_report_programs/static/description/index.html +++ b/spp_gis_report_programs/static/description/index.html @@ -394,8 +394,8 @@

          Key Capabilities

          Key Models

          Group
          group_gis_report_manager Full CRUD
          spp_r -egistry.group_registry_officer
          spp_registry.group_registry_officer Read reports and data
          spp_security.group_spp_admin
          --++ @@ -432,8 +432,8 @@

          UI Location

          Security

          Model
          --++ @@ -441,18 +441,15 @@

          Security

          - + - + - + diff --git a/spp_grm/README.rst b/spp_grm/README.rst index 1e56a513..676d60b4 100644 --- a/spp_grm/README.rst +++ b/spp_grm/README.rst @@ -32,57 +32,57 @@ group registrants and supports anonymous submissions. Key Capabilities ~~~~~~~~~~~~~~~~ -- Multi-channel intake: Email alias integration creates tickets from - inbound messages, portal form for beneficiaries, manual entry by - officers -- Stage-based workflow: Define stages with access control restrictions, - approval requirements, and decision enforcement before closure -- SLA tracking: Automatically compute deadlines based on - category/subcategory configuration, monitor status (on track, at - risk, breached), post notifications on breach -- Team assignment: Organize handlers into teams with geographic area - responsibilities, auto-assign based on category defaults -- Appeals and escalation: Reference original tickets for appeals, track - escalation history and reasons, mark tickets as escalated -- Hierarchical categorization: Two-level category/subcategory system - with inherited defaults for severity, sensitivity, SLA hours, and - team assignment -- Decision tracking: Record final decisions (upheld, partially upheld, - rejected, withdrawn, redirected, referred to case) with resolution - summaries -- Anonymous complaints: Optional contact fields for complainants not in - the registry +- Multi-channel intake: Email alias integration creates tickets from + inbound messages, portal form for beneficiaries, manual entry by + officers +- Stage-based workflow: Define stages with access control restrictions, + approval requirements, and decision enforcement before closure +- SLA tracking: Automatically compute deadlines based on + category/subcategory configuration, monitor status (on track, at risk, + breached), post notifications on breach +- Team assignment: Organize handlers into teams with geographic area + responsibilities, auto-assign based on category defaults +- Appeals and escalation: Reference original tickets for appeals, track + escalation history and reasons, mark tickets as escalated +- Hierarchical categorization: Two-level category/subcategory system + with inherited defaults for severity, sensitivity, SLA hours, and team + assignment +- Decision tracking: Record final decisions (upheld, partially upheld, + rejected, withdrawn, redirected, referred to case) with resolution + summaries +- Anonymous complaints: Optional contact fields for complainants not in + the registry Key Models ~~~~~~~~~~ -+--------------------------------+------------------------------------+ -| Model | Description | -+================================+====================================+ -| ``spp.grm.ticket`` | Main complaint/grievance with SLA | -| | tracking and decision fields | -+--------------------------------+------------------------------------+ -| ``spp.grm.ticket.stage`` | Workflow stage with access control | -| | and closure configuration | -+--------------------------------+------------------------------------+ -| ``spp.grm.ticket.category`` | Primary classification with | -| | hierarchical structure | -+--------------------------------+------------------------------------+ -| ``spp.grm.ticket.subcategory`` | Second-level classification under | -| | category | -+--------------------------------+------------------------------------+ -| ``spp.grm.team`` | Team of handlers with manager and | -| | geographic areas | -+--------------------------------+------------------------------------+ -| ``spp.grm.sla.rule`` | Conditional SLA rules with | -| | escalation targets | -+--------------------------------+------------------------------------+ -| ``spp.grm.ticket.tag`` | Tags for flexible ticket | -| | classification | -+--------------------------------+------------------------------------+ -| ``spp.grm.ticket.channel`` | Communication channel (email, | -| | phone, walk-in, portal, etc.) | -+--------------------------------+------------------------------------+ ++--------------------------------+-------------------------------------+ +| Model | Description | ++================================+=====================================+ +| ``spp.grm.ticket`` | Main complaint/grievance with SLA | +| | tracking and decision fields | ++--------------------------------+-------------------------------------+ +| ``spp.grm.ticket.stage`` | Workflow stage with access control | +| | and closure configuration | ++--------------------------------+-------------------------------------+ +| ``spp.grm.ticket.category`` | Primary classification with | +| | hierarchical structure | ++--------------------------------+-------------------------------------+ +| ``spp.grm.ticket.subcategory`` | Second-level classification under | +| | category | ++--------------------------------+-------------------------------------+ +| ``spp.grm.team`` | Team of handlers with manager and | +| | geographic areas | ++--------------------------------+-------------------------------------+ +| ``spp.grm.sla.rule`` | Conditional SLA rules with | +| | escalation targets | ++--------------------------------+-------------------------------------+ +| ``spp.grm.ticket.tag`` | Tags for flexible ticket | +| | classification | ++--------------------------------+-------------------------------------+ +| ``spp.grm.ticket.channel`` | Communication channel (email, | +| | phone, walk-in, portal, etc.) | ++--------------------------------+-------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -103,13 +103,13 @@ After installing: UI Location ~~~~~~~~~~~ -- **Menu**: Helpdesk (top-level menu item) -- **Tickets**: Helpdesk > Tickets -- **Configuration**: Helpdesk > Configuration (manager access required) -- **Portal**: Beneficiaries can view and create tickets at - ``/my/tickets`` -- **Registrant Profile**: Stat button shows ticket count and opens - related tickets +- **Menu**: Helpdesk (top-level menu item) +- **Tickets**: Helpdesk > Tickets +- **Configuration**: Helpdesk > Configuration (manager access required) +- **Portal**: Beneficiaries can view and create tickets at + ``/my/tickets`` +- **Registrant Profile**: Stat button shows ticket count and opens + related tickets Security ~~~~~~~~ @@ -130,15 +130,15 @@ no direct model access entries. Extension Points ~~~~~~~~~~~~~~~~ -- Override ``_compute_sla_deadline()`` on ``spp.grm.ticket`` to - implement custom SLA calculation logic -- Install ``spp_grm_cel`` to provide ``spp.grm.escalation.rule`` model, - which is automatically invoked when SLA status changes to breached -- Inherit ``spp.grm.ticket`` to add domain-specific fields (extended by - ``spp_grm_registry``, ``spp_grm_programs``) -- Extend ``spp.grm.ticket.stage`` to add workflow state fields -- Override ``evaluate_ticket()`` on ``spp.grm.sla.rule`` to add custom - matching conditions +- Override ``_compute_sla_deadline()`` on ``spp.grm.ticket`` to + implement custom SLA calculation logic +- Install ``spp_grm_cel`` to provide ``spp.grm.escalation.rule`` model, + which is automatically invoked when SLA status changes to breached +- Inherit ``spp.grm.ticket`` to add domain-specific fields (extended by + ``spp_grm_registry``, ``spp_grm_programs``) +- Extend ``spp.grm.ticket.stage`` to add workflow state fields +- Override ``evaluate_ticket()`` on ``spp.grm.sla.rule`` to add custom + matching conditions Dependencies ~~~~~~~~~~~~ diff --git a/spp_grm/static/description/index.html b/spp_grm/static/description/index.html index 4af66cdb..3173ce19 100644 --- a/spp_grm/static/description/index.html +++ b/spp_grm/static/description/index.html @@ -389,15 +389,15 @@

          Key Capabilities

        • Stage-based workflow: Define stages with access control restrictions, approval requirements, and decision enforcement before closure
        • SLA tracking: Automatically compute deadlines based on -category/subcategory configuration, monitor status (on track, at -risk, breached), post notifications on breach
        • +category/subcategory configuration, monitor status (on track, at risk, +breached), post notifications on breach
        • Team assignment: Organize handlers into teams with geographic area responsibilities, auto-assign based on category defaults
        • Appeals and escalation: Reference original tickets for appeals, track escalation history and reasons, mark tickets as escalated
        • Hierarchical categorization: Two-level category/subcategory system -with inherited defaults for severity, sensitivity, SLA hours, and -team assignment
        • +with inherited defaults for severity, sensitivity, SLA hours, and team +assignment
        • Decision tracking: Record final decisions (upheld, partially upheld, rejected, withdrawn, redirected, referred to case) with resolution summaries
        • @@ -409,8 +409,8 @@

          Key Capabilities

          Key Models

          Group
          spp_p -rograms.group_programs_officer
          spp_programs.group_programs_officer Read GIS reports, data, templates, etc.
          spp_p -rograms.group_programs_manager
          spp_programs.group_programs_manager Read/Write (no create/unlink) all models
          spp_gi -s_report.group_gis_report_user
          spp_gis_report.group_gis_report_user Implied for program managers via XML
          --++ diff --git a/spp_grm_demo/README.rst b/spp_grm_demo/README.rst index 40d8e30c..2c74c1a0 100644 --- a/spp_grm_demo/README.rst +++ b/spp_grm_demo/README.rst @@ -35,31 +35,31 @@ escalations, and timeline distribution. Key Capabilities ~~~~~~~~~~~~~~~~ -- Generate story tickets for specific demo personas that align with - ``spp_mis_demo_v2`` and ``spp_case_demo`` -- Generate volume tickets using YAML scenario templates or built-in - fallback scenarios -- Simulate ticket workflows: resolution notes, stage transitions, - escalations, and assignments -- Link tickets to beneficiaries, programs, and teams with configurable - distribution -- Control resolved vs. unresolved ratios, severity distribution, and - timeline spread -- Backdate ticket creation and workflow events across a configurable - time range +- Generate story tickets for specific demo personas that align with + ``spp_mis_demo_v2`` and ``spp_case_demo`` +- Generate volume tickets using YAML scenario templates or built-in + fallback scenarios +- Simulate ticket workflows: resolution notes, stage transitions, + escalations, and assignments +- Link tickets to beneficiaries, programs, and teams with configurable + distribution +- Control resolved vs. unresolved ratios, severity distribution, and + timeline spread +- Backdate ticket creation and workflow events across a configurable + time range Key Models ~~~~~~~~~~ -+----------------------------+----------------------------------------+ -| Model | Description | -+============================+========================================+ -| ``spp.grm.demo.generator`` | Transient model containing generation | -| | logic and workflow simulation | -+----------------------------+----------------------------------------+ -| ``spp.grm.demo.wizard`` | Transient model inheriting from | -| | generator for wizard UI configuration | -+----------------------------+----------------------------------------+ ++----------------------------+-----------------------------------------+ +| Model | Description | ++============================+=========================================+ +| ``spp.grm.demo.generator`` | Transient model containing generation | +| | logic and workflow simulation | ++----------------------------+-----------------------------------------+ +| ``spp.grm.demo.wizard`` | Transient model inheriting from | +| | generator for wizard UI configuration | ++----------------------------+-----------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -74,9 +74,9 @@ After installing: UI Location ~~~~~~~~~~~ -- **Menu**: Helpdesk > Configuration > Generate Demo Data -- **Wizard**: Configure story vs. volume generation, ticket count, time - range, and resolution percentages +- **Menu**: Helpdesk > Configuration > Generate Demo Data +- **Wizard**: Configure story vs. volume generation, ticket count, time + range, and resolution percentages Security ~~~~~~~~ @@ -92,15 +92,15 @@ Data Generated The generator creates ``spp.grm.ticket`` records with: -- Story tickets: 8 predefined personas with specific scenarios (payment - issues, eligibility inquiries, service requests) -- Volume tickets: Scenario-based tickets distributed over time with - realistic progression -- Ticket categories: Payment Issues, Eligibility Questions, Service - Delivery, Information Requests, Data Update Requests, General, - Complaint, Feedback -- Workflow progression: Resolution notes, stage transitions, escalation - notes, and user assignments with backdated timestamps +- Story tickets: 8 predefined personas with specific scenarios (payment + issues, eligibility inquiries, service requests) +- Volume tickets: Scenario-based tickets distributed over time with + realistic progression +- Ticket categories: Payment Issues, Eligibility Questions, Service + Delivery, Information Requests, Data Update Requests, General, + Complaint, Feedback +- Workflow progression: Resolution notes, stage transitions, escalation + notes, and user assignments with backdated timestamps Integration ~~~~~~~~~~~ diff --git a/spp_hazard/README.rst b/spp_hazard/README.rst index 990402ce..5621da30 100644 --- a/spp_hazard/README.rst +++ b/spp_hazard/README.rst @@ -34,45 +34,44 @@ targeted emergency response and humanitarian assistance. Key Capabilities ~~~~~~~~~~~~~~~~ -- Define hazard categories in a tree structure (e.g., Natural > Storm > - Typhoon) -- Record incidents with start/end dates, severity levels, and lifecycle - status (alert, active, recovery, closed) -- Link incidents to geographic areas with area-specific severity - overrides -- Track registrant-level impacts by type (physical, economic, health, - social) and damage level -- Verify impact records with workflow states (reported, verified, - disputed, closed) -- Bulk-create impact records for all registrants in an affected area - via ``bulk_create_impacts()`` -- Identify potentially affected registrants based on geographic - location +- Define hazard categories in a tree structure (e.g., Natural > Storm > + Typhoon) +- Record incidents with start/end dates, severity levels, and lifecycle + status (alert, active, recovery, closed) +- Link incidents to geographic areas with area-specific severity + overrides +- Track registrant-level impacts by type (physical, economic, health, + social) and damage level +- Verify impact records with workflow states (reported, verified, + disputed, closed) +- Bulk-create impact records for all registrants in an affected area via + ``bulk_create_impacts()`` +- Identify potentially affected registrants based on geographic location Key Models ~~~~~~~~~~ -+------------------------------+--------------------------------------+ -| Model | Description | -+==============================+======================================+ -| ``spp.hazard.category`` | Hierarchical classification of | -| | hazard types | -+------------------------------+--------------------------------------+ -| ``spp.hazard.incident`` | Specific disaster event with dates, | -| | severity, and affected areas | -+------------------------------+--------------------------------------+ -| ``spp.hazard.incident.area`` | Links incident to area with | -| | area-specific details | -+------------------------------+--------------------------------------+ -| ``spp.hazard.impact`` | Records impact on a registrant | -| | (type, damage level, verification) | -+------------------------------+--------------------------------------+ -| ``spp.hazard.impact.type`` | Classification of impact types by | -| | category | -+------------------------------+--------------------------------------+ -| ``res.partner`` (extended) | Adds hazard impact tracking fields | -| | to registrants | -+------------------------------+--------------------------------------+ ++------------------------------+---------------------------------------+ +| Model | Description | ++==============================+=======================================+ +| ``spp.hazard.category`` | Hierarchical classification of hazard | +| | types | ++------------------------------+---------------------------------------+ +| ``spp.hazard.incident`` | Specific disaster event with dates, | +| | severity, and affected areas | ++------------------------------+---------------------------------------+ +| ``spp.hazard.incident.area`` | Links incident to area with | +| | area-specific details | ++------------------------------+---------------------------------------+ +| ``spp.hazard.impact`` | Records impact on a registrant (type, | +| | damage level, verification) | ++------------------------------+---------------------------------------+ +| ``spp.hazard.impact.type`` | Classification of impact types by | +| | category | ++------------------------------+---------------------------------------+ +| ``res.partner`` (extended) | Adds hazard impact tracking fields to | +| | registrants | ++------------------------------+---------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -90,42 +89,42 @@ After installing: UI Location ~~~~~~~~~~~ -- **Menu**: Hazard & Emergency (top-level application menu) -- **Incidents**: Hazard & Emergency > Incidents > All Incidents -- **Impacts**: Hazard & Emergency > Incidents > Impact Records -- **Configuration**: Hazard & Emergency > Configuration (accessible to - managers only) -- **Registrant Form**: Stat button shows impact count; "Emergency - Response" tab displays impact records list +- **Menu**: Hazard & Emergency (top-level application menu) +- **Incidents**: Hazard & Emergency > Incidents > All Incidents +- **Impacts**: Hazard & Emergency > Incidents > Impact Records +- **Configuration**: Hazard & Emergency > Configuration (accessible to + managers only) +- **Registrant Form**: Stat button shows impact count; "Emergency + Response" tab displays impact records list Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| ``group_hazard_viewer`` | Read-only access to all hazard | -| | records | -+----------------------------------+----------------------------------+ -| ``group_hazard_officer`` | Create and manage incidents and | -| | impacts (no delete) | -+----------------------------------+----------------------------------+ -| ``group_hazard_manager`` | Full CRUD access including | -| | configuration | -+----------------------------------+----------------------------------+ -| ``spp_security.group_spp_admin`` | Inherits manager access | -+----------------------------------+----------------------------------+ ++----------------------------------+-----------------------------------+ +| Group | Access | ++==================================+===================================+ +| ``group_hazard_viewer`` | Read-only access to all hazard | +| | records | ++----------------------------------+-----------------------------------+ +| ``group_hazard_officer`` | Create and manage incidents and | +| | impacts (no delete) | ++----------------------------------+-----------------------------------+ +| ``group_hazard_manager`` | Full CRUD access including | +| | configuration | ++----------------------------------+-----------------------------------+ +| ``spp_security.group_spp_admin`` | Inherits manager access | ++----------------------------------+-----------------------------------+ Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``spp.hazard.incident`` and override - ``identify_potentially_affected_registrants()`` to customize - targeting logic -- Inherit ``spp.hazard.impact`` to add domain-specific impact fields - (e.g., crop damage for farmer registries) -- Override ``bulk_create_impacts()`` to customize mass impact record - creation +- Inherit ``spp.hazard.incident`` and override + ``identify_potentially_affected_registrants()`` to customize targeting + logic +- Inherit ``spp.hazard.impact`` to add domain-specific impact fields + (e.g., crop damage for farmer registries) +- Override ``bulk_create_impacts()`` to customize mass impact record + creation Dependencies ~~~~~~~~~~~~ diff --git a/spp_hazard/static/description/index.html b/spp_hazard/static/description/index.html index dcc45418..fc511312 100644 --- a/spp_hazard/static/description/index.html +++ b/spp_hazard/static/description/index.html @@ -392,18 +392,17 @@

          Key Capabilities

          social) and damage level
        • Verify impact records with workflow states (reported, verified, disputed, closed)
        • -
        • Bulk-create impact records for all registrants in an affected area -via bulk_create_impacts()
        • -
        • Identify potentially affected registrants based on geographic -location
        • +
        • Bulk-create impact records for all registrants in an affected area via +bulk_create_impacts()
        • +
        • Identify potentially affected registrants based on geographic location
        • Key Models

          Model
          --++ @@ -412,8 +411,8 @@

          Key Models

          - + - + - +
          Model
          spp.hazard.categoryHierarchical classification of -hazard typesHierarchical classification of hazard +types
          spp.hazard.incident Specific disaster event with dates, @@ -424,16 +423,16 @@

          Key Models

          area-specific details
          spp.hazard.impactRecords impact on a registrant -(type, damage level, verification)Records impact on a registrant (type, +damage level, verification)
          spp.hazard.impact.type Classification of impact types by category
          res.partner (extended)Adds hazard impact tracking fields -to registrantsAdds hazard impact tracking fields to +registrants
          @@ -467,8 +466,8 @@

          UI Location

          Security

          --++ @@ -498,8 +497,8 @@

          Security

          Extension Points

          • Inherit spp.hazard.incident and override -identify_potentially_affected_registrants() to customize -targeting logic
          • +identify_potentially_affected_registrants() to customize targeting +logic
          • Inherit spp.hazard.impact to add domain-specific impact fields (e.g., crop damage for farmer registries)
          • Override bulk_create_impacts() to customize mass impact record diff --git a/spp_hide_menus_base/README.rst b/spp_hide_menus_base/README.rst index b7d5ae8f..3cf0375d 100644 --- a/spp_hide_menus_base/README.rst +++ b/spp_hide_menus_base/README.rst @@ -32,24 +32,24 @@ operations. Key Capabilities ~~~~~~~~~~~~~~~~ -- Track menu visibility state and preserve original group assignments - in configuration records -- Hide menus by replacing group_ids with ``group_hide_menus_user`` - (only users in this group see hidden menus) -- Restore menus by reverting to original group_ids -- Auto-hide 15 predefined menus during module installation via - ``ir.module.module.next()`` hook -- Manual toggle via list view with hide/show action buttons +- Track menu visibility state and preserve original group assignments in + configuration records +- Hide menus by replacing group_ids with ``group_hide_menus_user`` (only + users in this group see hidden menus) +- Restore menus by reverting to original group_ids +- Auto-hide 15 predefined menus during module installation via + ``ir.module.module.next()`` hook +- Manual toggle via list view with hide/show action buttons Key Models ~~~~~~~~~~ -+-------------------+-------------------------------------------------+ -| Model | Description | -+===================+=================================================+ -| ``spp.hide.menu`` | Stores menu reference, state (show/hide), and | -| | original group_ids | -+-------------------+-------------------------------------------------+ ++-------------------+--------------------------------------------------+ +| Model | Description | ++===================+==================================================+ +| ``spp.hide.menu`` | Stores menu reference, state (show/hide), and | +| | original group_ids | ++-------------------+--------------------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -68,28 +68,28 @@ To manually configure: UI Location ~~~~~~~~~~~ -- **Menu**: Settings > Users & Companies > Hidden Menus (requires - Technical Features group) +- **Menu**: Settings > Users & Companies > Hidden Menus (requires + Technical Features group) Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| ``base.group_system`` | Full CRUD | -+----------------------------------+----------------------------------+ -| ``spp_hide_me | See menus hidden from other | -| nus_base.group_hide_menus_user`` | users (assigned via privilege | -| | system) | -+----------------------------------+----------------------------------+ ++-----------------------------------------------+----------------------------------+ +| Group | Access | ++===============================================+==================================+ +| ``base.group_system`` | Full CRUD | ++-----------------------------------------------+----------------------------------+ +| ``spp_hide_menus_base.group_hide_menus_user`` | See menus hidden from other | +| | users (assigned via privilege | +| | system) | ++-----------------------------------------------+----------------------------------+ Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``ir.module.module`` and extend ``MENU_APP`` dictionary to - add custom menus to auto-hide list -- Inherit ``spp.hide.menu`` to add custom metadata or hide/show logic +- Inherit ``ir.module.module`` and extend ``MENU_APP`` dictionary to add + custom menus to auto-hide list +- Inherit ``spp.hide.menu`` to add custom metadata or hide/show logic Dependencies ~~~~~~~~~~~~ diff --git a/spp_hide_menus_base/static/description/index.html b/spp_hide_menus_base/static/description/index.html index c15988a4..8e64c031 100644 --- a/spp_hide_menus_base/static/description/index.html +++ b/spp_hide_menus_base/static/description/index.html @@ -383,10 +383,10 @@

            OpenSPP Hide Non-OpenSPP Menus: Base

            Key Capabilities

              -
            • Track menu visibility state and preserve original group assignments -in configuration records
            • -
            • Hide menus by replacing group_ids with group_hide_menus_user -(only users in this group see hidden menus)
            • +
            • Track menu visibility state and preserve original group assignments in +configuration records
            • +
            • Hide menus by replacing group_ids with group_hide_menus_user (only +users in this group see hidden menus)
            • Restore menus by reverting to original group_ids
            • Auto-hide 15 predefined menus during module installation via ir.module.module.next() hook
            • @@ -437,8 +437,8 @@

              UI Location

              Security

          Group
          --++ @@ -449,8 +449,7 @@

          Security

          - + @@ -461,8 +460,8 @@

          Security

          Extension Points

            -
          • Inherit ir.module.module and extend MENU_APP dictionary to -add custom menus to auto-hide list
          • +
          • Inherit ir.module.module and extend MENU_APP dictionary to add +custom menus to auto-hide list
          • Inherit spp.hide.menu to add custom metadata or hide/show logic
          diff --git a/spp_key_management/README.rst b/spp_key_management/README.rst index bec8900c..4b4df9a0 100644 --- a/spp_key_management/README.rst +++ b/spp_key_management/README.rst @@ -33,61 +33,60 @@ index computation, and audit logging of key operations. Key Capabilities ~~~~~~~~~~~~~~~~ -- Symmetric encryption/decryption using AES-256-GCM with envelope - encryption pattern -- Asymmetric key management for JWT signing and credential issuance - (RSA, EC, Ed25519) -- Blind index computation using HMAC-SHA256 for searchable encrypted - data -- Key rotation with versioning (old versions remain available for - decryption) -- Pluggable provider system: switch between local database storage and - enterprise KMS -- HSM/KMS signing operations where private keys never leave secure - hardware -- Audit logging of all key access operations (without logging sensitive - key material) +- Symmetric encryption/decryption using AES-256-GCM with envelope + encryption pattern +- Asymmetric key management for JWT signing and credential issuance + (RSA, EC, Ed25519) +- Blind index computation using HMAC-SHA256 for searchable encrypted + data +- Key rotation with versioning (old versions remain available for + decryption) +- Pluggable provider system: switch between local database storage and + enterprise KMS +- HSM/KMS signing operations where private keys never leave secure + hardware +- Audit logging of all key access operations (without logging sensitive + key material) Key Models ~~~~~~~~~~ -+----------------------------------+----------------------------------+ -| Model | Description | -+==================================+==================================+ -| ``spp.key.manager`` | Main service interface for all | -| | key operations | -+----------------------------------+----------------------------------+ -| ``spp.encryption.key`` | Encrypted key storage with | -| | versioning support | -+----------------------------------+----------------------------------+ -| ``spp.key.provider`` | Abstract base class for key | -| | provider implementations | -+----------------------------------+----------------------------------+ -| ``spp.key.provider.registry`` | Registry configuring which | -| | provider serves which purpose | -+----------------------------------+----------------------------------+ -| ``spp.key.purpose`` | Purpose definitions (PII, | -| | financial, credentials, etc) | -+----------------------------------+----------------------------------+ -| ``spp.asymmetric.key`` | RSA/EC/Ed25519 key pairs for | -| | signing operations | -+----------------------------------+----------------------------------+ -| ``spp.key.provider.config`` | Configuration file provider | -| | (development) | -+----------------------------------+----------------------------------+ -| ``spp.key.provider.database`` | Database provider using envelope | -| | encryption | -+----------------------------------+----------------------------------+ -| ``spp.key.provider.vault`` | HashiCorp Vault integration | -+----------------------------------+----------------------------------+ -| ``spp.key.provider.aws.kms`` | AWS Key Management Service | -| | integration | -+----------------------------------+----------------------------------+ -| ``spp.key.provider.gcp.kms`` | Google Cloud KMS integration | -+----------------------------------+----------------------------------+ -| ``s | Azure Key Vault integration | -| pp.key.provider.azure.keyvault`` | | -+----------------------------------+----------------------------------+ ++-------------------------------------+----------------------------------+ +| Model | Description | ++=====================================+==================================+ +| ``spp.key.manager`` | Main service interface for all | +| | key operations | ++-------------------------------------+----------------------------------+ +| ``spp.encryption.key`` | Encrypted key storage with | +| | versioning support | ++-------------------------------------+----------------------------------+ +| ``spp.key.provider`` | Abstract base class for key | +| | provider implementations | ++-------------------------------------+----------------------------------+ +| ``spp.key.provider.registry`` | Registry configuring which | +| | provider serves which purpose | ++-------------------------------------+----------------------------------+ +| ``spp.key.purpose`` | Purpose definitions (PII, | +| | financial, credentials, etc) | ++-------------------------------------+----------------------------------+ +| ``spp.asymmetric.key`` | RSA/EC/Ed25519 key pairs for | +| | signing operations | ++-------------------------------------+----------------------------------+ +| ``spp.key.provider.config`` | Configuration file provider | +| | (development) | ++-------------------------------------+----------------------------------+ +| ``spp.key.provider.database`` | Database provider using envelope | +| | encryption | ++-------------------------------------+----------------------------------+ +| ``spp.key.provider.vault`` | HashiCorp Vault integration | ++-------------------------------------+----------------------------------+ +| ``spp.key.provider.aws.kms`` | AWS Key Management Service | +| | integration | ++-------------------------------------+----------------------------------+ +| ``spp.key.provider.gcp.kms`` | Google Cloud KMS integration | ++-------------------------------------+----------------------------------+ +| ``spp.key.provider.azure.keyvault`` | Azure Key Vault integration | ++-------------------------------------+----------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -109,29 +108,29 @@ After installing: UI Location ~~~~~~~~~~~ -- **Menu**: Settings > Administration > Key Management -- **Submenus**: +- **Menu**: Settings > Administration > Key Management +- **Submenus**: - - Key Providers (configure which KMS backend to use) - - Encryption Keys (view stored keys and versions) - - Asymmetric Keys (manage signing keys for credentials) - - Key Purposes (define key segregation policies) + - Key Providers (configure which KMS backend to use) + - Encryption Keys (view stored keys and versions) + - Asymmetric Keys (manage signing keys for credentials) + - Key Purposes (define key segregation policies) Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| ``spp_ | Read/Write/Create on all models, | -| key_management.group_key_admin`` | key rotation | -+----------------------------------+----------------------------------+ -| ``spp_key_managem | Read encryption keys for use in | -| ent.group_key_operator_officer`` | operations | -+----------------------------------+----------------------------------+ -| ``base.group_system`` | Full access to all key | -| | management features | -+----------------------------------+----------------------------------+ ++---------------------------------------------------+----------------------------------+ +| Group | Access | ++===================================================+==================================+ +| ``spp_key_management.group_key_admin`` | Read/Write/Create on all models, | +| | key rotation | ++---------------------------------------------------+----------------------------------+ +| ``spp_key_management.group_key_operator_officer`` | Read encryption keys for use in | +| | operations | ++---------------------------------------------------+----------------------------------+ +| ``base.group_system`` | Full access to all key | +| | management features | ++---------------------------------------------------+----------------------------------+ Encryption keys and asymmetric keys cannot be deleted (enforced by Python ``unlink()`` override). All key access operations are logged with @@ -141,16 +140,16 @@ material). Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``spp.key.provider`` and implement ``get_data_key()`` and - ``get_index_salt()`` to add custom KMS backends -- Override ``spp.key.manager.encrypt()`` or ``decrypt()`` to customize - encryption behavior -- Call ``key_manager.get_key(purpose, key_id)`` from other modules to - retrieve keys for encryption -- Call ``key_manager.compute_blind_index(value, purpose, salt_id)`` to - create searchable indexes for encrypted fields -- Use ``spp.asymmetric.key.sign(data)`` for HSM-backed signing without - exposing private keys +- Inherit ``spp.key.provider`` and implement ``get_data_key()`` and + ``get_index_salt()`` to add custom KMS backends +- Override ``spp.key.manager.encrypt()`` or ``decrypt()`` to customize + encryption behavior +- Call ``key_manager.get_key(purpose, key_id)`` from other modules to + retrieve keys for encryption +- Call ``key_manager.compute_blind_index(value, purpose, salt_id)`` to + create searchable indexes for encrypted fields +- Use ``spp.asymmetric.key.sign(data)`` for HSM-backed signing without + exposing private keys Dependencies ~~~~~~~~~~~~ diff --git a/spp_key_management/static/description/index.html b/spp_key_management/static/description/index.html index 63a2f7aa..5a985b04 100644 --- a/spp_key_management/static/description/index.html +++ b/spp_key_management/static/description/index.html @@ -404,8 +404,8 @@

          Key Capabilities

          Key Models

          Group
          base.group_system Full CRUD
          spp_hide_me -nus_base.group_hide_menus_user
          spp_hide_menus_base.group_hide_menus_user See menus hidden from other users (assigned via privilege system)
          --++ @@ -455,8 +455,7 @@

          Key Models

          - + @@ -496,8 +495,8 @@

          UI Location

          Security

          Model
          spp.key.provider.gcp.kms Google Cloud KMS integration
          s -pp.key.provider.azure.keyvault
          spp.key.provider.azure.keyvault Azure Key Vault integration
          --++ @@ -505,13 +504,11 @@

          Security

          - + - + diff --git a/spp_mis_demo_v2/README.rst b/spp_mis_demo_v2/README.rst index f4553eaa..6aef2b05 100644 --- a/spp_mis_demo_v2/README.rst +++ b/spp_mis_demo_v2/README.rst @@ -32,22 +32,22 @@ Packs for eligibility rules. Key Capabilities ~~~~~~~~~~~~~~~~ -- Generate 6 programs (Child Grant, Elderly Pension, Emergency Relief, - Cash Transfer, Disability Support, Food Assistance) with CEL - expressions -- Enroll 8 demo personas with predefined stories and payment histories - covering all demo scenarios -- Install Logic Packs from ``spp_studio`` for eligibility rules - (child_benefit, social_pension, vulnerability_assessment, - cash_transfer_basic, disability_assistance) -- Activate registry variables (age, child_count, hh_total_income, - dependency_ratio, etc.) via post_init_hook -- Generate volume data with configurable random enrollments for - dashboard testing -- Create change requests at various workflow stages (draft, pending, - approved, rejected) -- Cross-module integration: automatically creates GRM tickets and case - records when those modules are installed +- Generate 6 programs (Child Grant, Elderly Pension, Emergency Relief, + Cash Transfer, Disability Support, Food Assistance) with CEL + expressions +- Enroll 8 demo personas with predefined stories and payment histories + covering all demo scenarios +- Install Logic Packs from ``spp_studio`` for eligibility rules + (child_benefit, social_pension, vulnerability_assessment, + cash_transfer_basic, disability_assistance) +- Activate registry variables (age, child_count, hh_total_income, + dependency_ratio, etc.) via post_init_hook +- Generate volume data with configurable random enrollments for + dashboard testing +- Create change requests at various workflow stages (draft, pending, + approved, rejected) +- Cross-module integration: automatically creates GRM tickets and case + records when those modules are installed Key Models ~~~~~~~~~~ @@ -87,28 +87,28 @@ Demo Programs All programs use CEL expressions with activated registry variables: -- **Universal Child Grant**: ``r.is_group == true and child_count > 0`` - (member aggregation) -- **Elderly Social Pension**: - ``r.is_group == false and age >= retirement_age`` (age computation) -- **Emergency Relief Fund**: - ``dependency_ratio >= 1.5 or (is_female_headed and elderly_count > 0)`` - (compound conditions) -- **Cash Transfer Program**: - ``hh_total_income < poverty_line and hh_size >= 2`` (income-based - targeting) -- **Disability Support Grant**: - ``r.is_group == true and has_disabled_member`` (member existence - check) -- **Food Assistance**: ``r.is_registrant == true and r.active == true`` - (simple field comparison) +- **Universal Child Grant**: ``r.is_group == true and child_count > 0`` + (member aggregation) +- **Elderly Social Pension**: + ``r.is_group == false and age >= retirement_age`` (age computation) +- **Emergency Relief Fund**: + ``dependency_ratio >= 1.5 or (is_female_headed and elderly_count > 0)`` + (compound conditions) +- **Cash Transfer Program**: + ``hh_total_income < poverty_line and hh_size >= 2`` (income-based + targeting) +- **Disability Support Grant**: + ``r.is_group == true and has_disabled_member`` (member existence + check) +- **Food Assistance**: ``r.is_registrant == true and r.active == true`` + (simple field comparison) UI Location ~~~~~~~~~~~ -- **Menu**: Settings > Demo Data > Load MIS Demo -- **Form**: Wizard with generation options (demo mode, Logic Pack - installation, volume data configuration) +- **Menu**: Settings > Demo Data > Load MIS Demo +- **Form**: Wizard with generation options (demo mode, Logic Pack + installation, volume data configuration) Security ~~~~~~~~ @@ -122,11 +122,10 @@ Group Access Extension Points ~~~~~~~~~~~~~~~~ -- Override ``_create_demo_programs()`` to customize program definitions -- Override ``_enroll_demo_stories()`` to modify enrollment logic -- Add custom demo modes by extending ``demo_mode`` selection field -- Inherit ``spp.mis.demo.generator`` to add fields or generation - methods +- Override ``_create_demo_programs()`` to customize program definitions +- Override ``_enroll_demo_stories()`` to modify enrollment logic +- Add custom demo modes by extending ``demo_mode`` selection field +- Inherit ``spp.mis.demo.generator`` to add fields or generation methods Dependencies ~~~~~~~~~~~~ diff --git a/spp_mis_demo_v2/static/description/index.html b/spp_mis_demo_v2/static/description/index.html index ccb11977..d971693b 100644 --- a/spp_mis_demo_v2/static/description/index.html +++ b/spp_mis_demo_v2/static/description/index.html @@ -496,8 +496,7 @@

          Extension Points

        • Override _create_demo_programs() to customize program definitions
        • Override _enroll_demo_stories() to modify enrollment logic
        • Add custom demo modes by extending demo_mode selection field
        • -
        • Inherit spp.mis.demo.generator to add fields or generation -methods
        • +
        • Inherit spp.mis.demo.generator to add fields or generation methods
        • diff --git a/spp_programs/README.rst b/spp_programs/README.rst index 97ec6521..e52a3532 100644 --- a/spp_programs/README.rst +++ b/spp_programs/README.rst @@ -31,121 +31,121 @@ eligibility, deduplication, notifications, and compliance workflows. Key Capabilities ~~~~~~~~~~~~~~~~ -- **Program Management**: Define programs with target type - (individual/group), states (active/ended), and configurable - manager-based logic -- **Cycle Management**: Create time-bound distribution cycles with - approval workflows, recurrence, and compliance filtering -- **Enrollment**: Import and enroll registrants as program members, - verify eligibility, track enrollment states -- **Deduplication**: Identify and manage duplicate beneficiaries using - ID documents or phone numbers -- **Entitlements**: Generate cash or in-kind entitlements with approval - workflows, fund balance validation, and CEL expression support -- **Payment Processing**: Create payment batches, track disbursements, - reconcile payments via accounting integration -- **Fund Tracking**: Monitor program budgets, available funds, and - journal entries through Odoo accounting -- **Stock Integration**: Link in-kind entitlements to inventory, - trigger procurements, track warehouse movements -- **Compliance**: Define ongoing beneficiary conditions and filter - cycle members by compliance status -- **Manager Architecture**: Extensible pattern for eligibility, - deduplication, notification, program, cycle, entitlement, payment, - and compliance logic +- **Program Management**: Define programs with target type + (individual/group), states (active/ended), and configurable + manager-based logic +- **Cycle Management**: Create time-bound distribution cycles with + approval workflows, recurrence, and compliance filtering +- **Enrollment**: Import and enroll registrants as program members, + verify eligibility, track enrollment states +- **Deduplication**: Identify and manage duplicate beneficiaries using + ID documents or phone numbers +- **Entitlements**: Generate cash or in-kind entitlements with approval + workflows, fund balance validation, and CEL expression support +- **Payment Processing**: Create payment batches, track disbursements, + reconcile payments via accounting integration +- **Fund Tracking**: Monitor program budgets, available funds, and + journal entries through Odoo accounting +- **Stock Integration**: Link in-kind entitlements to inventory, trigger + procurements, track warehouse movements +- **Compliance**: Define ongoing beneficiary conditions and filter cycle + members by compliance status +- **Manager Architecture**: Extensible pattern for eligibility, + deduplication, notification, program, cycle, entitlement, payment, and + compliance logic Key Models ~~~~~~~~~~ -+----------------------------------+----------------------------------+ -| Model | Description | -+==================================+==================================+ -| ``spp.program`` | Main program with managers, | -| | target type, and funding | -+----------------------------------+----------------------------------+ -| ``spp.cycle`` | Time-bound distribution cycle | -| | within a program | -+----------------------------------+----------------------------------+ -| ``spp.program.membership`` | Enrolls registrant in program | -| | with state tracking | -+----------------------------------+----------------------------------+ -| ``spp.cycle.membership`` | Links registrant to specific | -| | cycle for entitlement prep | -+----------------------------------+----------------------------------+ -| ``spp.entitlement`` | Cash entitlement with approval | -| | workflow | -+----------------------------------+----------------------------------+ -| ``spp.entitlement.inkind`` | In-kind entitlement with | -| | product, quantity, warehouse | -+----------------------------------+----------------------------------+ -| ``spp.payment`` | Individual payment linked to | -| | cash entitlement | -+----------------------------------+----------------------------------+ -| ``spp.payment.batch`` | Groups payments for batch | -| | processing and reconciliation | -+----------------------------------+----------------------------------+ -| ``spp.payment.batch.tag`` | Tags for categorizing payment | -| | batches | -+----------------------------------+----------------------------------+ -| ``spp.eligibility.manager`` | Wrapper for eligibility manager | -| | implementations | -+----------------------------------+----------------------------------+ -| `` | Base eligibility manager | -| spp.program.membership.manager`` | (abstract) | -+----------------------------------+----------------------------------+ -| ``spp.prog | Default eligibility | -| ram.membership.manager.default`` | implementation | -+----------------------------------+----------------------------------+ -| ``spp.deduplication.manager`` | Wrapper for deduplication | -| | manager implementations | -+----------------------------------+----------------------------------+ -| ``sp | Notification manager for | -| p.program.notification.manager`` | beneficiary communications | -+----------------------------------+----------------------------------+ -| ``spp.program.manager`` | Wrapper for program lifecycle | -| | manager implementations | -+----------------------------------+----------------------------------+ -| ``spp.program.manager.default`` | Default program manager | -| | implementation | -+----------------------------------+----------------------------------+ -| ``spp.cycle.manager`` | Wrapper for cycle manager | -| | implementations | -+----------------------------------+----------------------------------+ -| ``spp.cycle.manager.default`` | Default cycle manager | -| | implementation | -+----------------------------------+----------------------------------+ -| ``s | Wrapper for entitlement manager | -| pp.program.entitlement.manager`` | implementations | -+----------------------------------+----------------------------------+ -| ``spp.progr | Default entitlement manager | -| am.entitlement.manager.default`` | implementation | -+----------------------------------+----------------------------------+ -| ``spp.pr | Cash entitlement manager with | -| ogram.entitlement.manager.cash`` | amount calculation | -+----------------------------------+----------------------------------+ -| ``spp.prog | In-kind entitlement manager with | -| ram.entitlement.manager.inkind`` | product configuration | -+----------------------------------+----------------------------------+ -| ``spp.program.payment.manager`` | Wrapper for payment manager | -| | implementations | -+----------------------------------+----------------------------------+ -| ``spp.p | Default payment manager | -| rogram.payment.manager.default`` | implementation | -+----------------------------------+----------------------------------+ -| ``spp.compliance.manager`` | Wrapper for compliance manager | -| | implementations | -+----------------------------------+----------------------------------+ -| `` | Default compliance manager with | -| spp.compliance.manager.default`` | CEL support | -+----------------------------------+----------------------------------+ -| ``spp.program.fund`` | Tracks program budget and fund | -| | utilization | -+----------------------------------+----------------------------------+ -| ``spp.program.fund.report.view`` | Fund balance reporting view | -+----------------------------------+----------------------------------+ -| ``sp | Tracks duplicate membership | -| p.program.membership.duplicate`` | records | -+----------------------------------+----------------------------------+ ++---------------------------------------------+----------------------------------+ +| Model | Description | ++=============================================+==================================+ +| ``spp.program`` | Main program with managers, | +| | target type, and funding | ++---------------------------------------------+----------------------------------+ +| ``spp.cycle`` | Time-bound distribution cycle | +| | within a program | ++---------------------------------------------+----------------------------------+ +| ``spp.program.membership`` | Enrolls registrant in program | +| | with state tracking | ++---------------------------------------------+----------------------------------+ +| ``spp.cycle.membership`` | Links registrant to specific | +| | cycle for entitlement prep | ++---------------------------------------------+----------------------------------+ +| ``spp.entitlement`` | Cash entitlement with approval | +| | workflow | ++---------------------------------------------+----------------------------------+ +| ``spp.entitlement.inkind`` | In-kind entitlement with | +| | product, quantity, warehouse | ++---------------------------------------------+----------------------------------+ +| ``spp.payment`` | Individual payment linked to | +| | cash entitlement | ++---------------------------------------------+----------------------------------+ +| ``spp.payment.batch`` | Groups payments for batch | +| | processing and reconciliation | ++---------------------------------------------+----------------------------------+ +| ``spp.payment.batch.tag`` | Tags for categorizing payment | +| | batches | ++---------------------------------------------+----------------------------------+ +| ``spp.eligibility.manager`` | Wrapper for eligibility manager | +| | implementations | ++---------------------------------------------+----------------------------------+ +| ``spp.program.membership.manager`` | Base eligibility manager | +| | (abstract) | ++---------------------------------------------+----------------------------------+ +| ``spp.program.membership.manager.default`` | Default eligibility | +| | implementation | ++---------------------------------------------+----------------------------------+ +| ``spp.deduplication.manager`` | Wrapper for deduplication | +| | manager implementations | ++---------------------------------------------+----------------------------------+ +| ``spp.program.notification.manager`` | Notification manager for | +| | beneficiary communications | ++---------------------------------------------+----------------------------------+ +| ``spp.program.manager`` | Wrapper for program lifecycle | +| | manager implementations | ++---------------------------------------------+----------------------------------+ +| ``spp.program.manager.default`` | Default program manager | +| | implementation | ++---------------------------------------------+----------------------------------+ +| ``spp.cycle.manager`` | Wrapper for cycle manager | +| | implementations | ++---------------------------------------------+----------------------------------+ +| ``spp.cycle.manager.default`` | Default cycle manager | +| | implementation | ++---------------------------------------------+----------------------------------+ +| ``spp.program.entitlement.manager`` | Wrapper for entitlement manager | +| | implementations | ++---------------------------------------------+----------------------------------+ +| ``spp.program.entitlement.manager.default`` | Default entitlement manager | +| | implementation | ++---------------------------------------------+----------------------------------+ +| ``spp.program.entitlement.manager.cash`` | Cash entitlement manager with | +| | amount calculation | ++---------------------------------------------+----------------------------------+ +| ``spp.program.entitlement.manager.inkind`` | In-kind entitlement manager with | +| | product configuration | ++---------------------------------------------+----------------------------------+ +| ``spp.program.payment.manager`` | Wrapper for payment manager | +| | implementations | ++---------------------------------------------+----------------------------------+ +| ``spp.program.payment.manager.default`` | Default payment manager | +| | implementation | ++---------------------------------------------+----------------------------------+ +| ``spp.compliance.manager`` | Wrapper for compliance manager | +| | implementations | ++---------------------------------------------+----------------------------------+ +| ``spp.compliance.manager.default`` | Default compliance manager with | +| | CEL support | ++---------------------------------------------+----------------------------------+ +| ``spp.program.fund`` | Tracks program budget and fund | +| | utilization | ++---------------------------------------------+----------------------------------+ +| ``spp.program.fund.report.view`` | Fund balance reporting view | ++---------------------------------------------+----------------------------------+ +| ``spp.program.membership.duplicate`` | Tracks duplicate membership | +| | records | ++---------------------------------------------+----------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -156,19 +156,18 @@ After installing: 2. Create a program, selecting target type (individual/group) 3. In the **Configuration** tab, configure managers: - - **Eligibility Manager**: Define who can enroll (supports CEL - expressions) - - **Program Manager**: Handles enrollment and cycle creation logic - - **Cycle Manager**: Manages cycle lifecycle and beneficiary copying - - **Entitlement Manager**: Generates and approves entitlements (cash - or in-kind) - - **Payment Manager**: Prepares and sends payment batches - - **Deduplication Manager** (optional): Identify duplicate - beneficiaries - - **Notification Manager** (optional): Send beneficiary - notifications - - **Compliance Manager** (optional): Define ongoing compliance - conditions + - **Eligibility Manager**: Define who can enroll (supports CEL + expressions) + - **Program Manager**: Handles enrollment and cycle creation logic + - **Cycle Manager**: Manages cycle lifecycle and beneficiary copying + - **Entitlement Manager**: Generates and approves entitlements (cash + or in-kind) + - **Payment Manager**: Prepares and sends payment batches + - **Deduplication Manager** (optional): Identify duplicate + beneficiaries + - **Notification Manager** (optional): Send beneficiary notifications + - **Compliance Manager** (optional): Define ongoing compliance + conditions 4. Set up program journal under **Programs > Accounting > Configuration** or via Create Journal button @@ -178,67 +177,66 @@ After installing: UI Location ~~~~~~~~~~~ -- **Programs**: Programs > Programs -- **Cycles**: Accessed via "Cycles" stat button on program form (no - standalone menu) -- **Beneficiaries**: Accessed via "Beneficiaries" stat button on - program form (no standalone menu) -- **Cash Entitlements**: Accessed via entitlement buttons on cycle form - (no standalone menu) -- **In-Kind Entitlements**: Programs > In-Kind > Entitlements -- **Payment Batches**: Programs > Payments > Payment Batches -- **Individual Payments**: Accessed via payment buttons on cycle form - (no standalone menu) -- **Fund Management**: Programs > Accounting +- **Programs**: Programs > Programs +- **Cycles**: Accessed via "Cycles" stat button on program form (no + standalone menu) +- **Beneficiaries**: Accessed via "Beneficiaries" stat button on program + form (no standalone menu) +- **Cash Entitlements**: Accessed via entitlement buttons on cycle form + (no standalone menu) +- **In-Kind Entitlements**: Programs > In-Kind > Entitlements +- **Payment Batches**: Programs > Payments > Payment Batches +- **Individual Payments**: Accessed via payment buttons on cycle form + (no standalone menu) +- **Fund Management**: Programs > Accounting Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| ``spp_ | Read-only on all program data | -| programs.group_programs_viewer`` | | -+----------------------------------+----------------------------------+ -| ``spp_p | Read/write/create on all models | -| rograms.group_programs_officer`` | (no delete) | -+----------------------------------+----------------------------------+ -| ``spp_p | Full CRUD on cycles and | -| rograms.group_programs_manager`` | memberships, RWC on programs (no | -| | program delete) | -+----------------------------------+----------------------------------+ -| ``spp_pro | Read/write/create on | -| grams.group_programs_validator`` | entitlements and cycles (finance | -| | validation role) | -+----------------------------------+----------------------------------+ -| ``spp_programs | Read/write/create on | -| .group_programs_cycle_approver`` | entitlements and cycles | -| | (approval role) | -+----------------------------------+----------------------------------+ -| ``spp_pr | Read/write/create on | -| ograms.group_programs_rejector`` | entitlements (rejection role) | -+----------------------------------+----------------------------------+ ++------------------------------------------------+----------------------------------+ +| Group | Access | ++================================================+==================================+ +| ``spp_programs.group_programs_viewer`` | Read-only on all program data | ++------------------------------------------------+----------------------------------+ +| ``spp_programs.group_programs_officer`` | Read/write/create on all models | +| | (no delete) | ++------------------------------------------------+----------------------------------+ +| ``spp_programs.group_programs_manager`` | Full CRUD on cycles and | +| | memberships, RWC on programs (no | +| | program delete) | ++------------------------------------------------+----------------------------------+ +| ``spp_programs.group_programs_validator`` | Read/write/create on | +| | entitlements and cycles (finance | +| | validation role) | ++------------------------------------------------+----------------------------------+ +| ``spp_programs.group_programs_cycle_approver`` | Read/write/create on | +| | entitlements and cycles | +| | (approval role) | ++------------------------------------------------+----------------------------------+ +| ``spp_programs.group_programs_rejector`` | Read/write/create on | +| | entitlements (rejection role) | ++------------------------------------------------+----------------------------------+ Extension Points ~~~~~~~~~~~~~~~~ -- Override ``_pre_enrollment_hook(partner)`` and - ``_post_enrollment_hook(partner)`` on ``spp.program`` for custom - enrollment logic -- Inherit manager models and add to ``_selection_manager_ref_id()`` to - register custom manager types: - - - ``spp.program.membership.manager`` for custom eligibility - - ``spp.cycle.manager`` for custom cycle logic - - ``spp.program.entitlement.manager`` for custom entitlement - generation - - ``spp.compliance.manager`` for custom compliance rules - -- Extend ``spp.entitlement`` or ``spp.entitlement.inkind`` to add - domain-specific entitlement fields -- Override ``get_compliance_domain(membership)`` on compliance managers - to define custom compliance criteria -- Use ``spp.manager.mixin`` pattern to create new manager types +- Override ``_pre_enrollment_hook(partner)`` and + ``_post_enrollment_hook(partner)`` on ``spp.program`` for custom + enrollment logic +- Inherit manager models and add to ``_selection_manager_ref_id()`` to + register custom manager types: + + - ``spp.program.membership.manager`` for custom eligibility + - ``spp.cycle.manager`` for custom cycle logic + - ``spp.program.entitlement.manager`` for custom entitlement + generation + - ``spp.compliance.manager`` for custom compliance rules + +- Extend ``spp.entitlement`` or ``spp.entitlement.inkind`` to add + domain-specific entitlement fields +- Override ``get_compliance_domain(membership)`` on compliance managers + to define custom compliance criteria +- Use ``spp.manager.mixin`` pattern to create new manager types Dependencies ~~~~~~~~~~~~ diff --git a/spp_programs/static/description/index.html b/spp_programs/static/description/index.html index 56b515f0..82774f18 100644 --- a/spp_programs/static/description/index.html +++ b/spp_programs/static/description/index.html @@ -397,21 +397,21 @@

          Key Capabilities

          reconcile payments via accounting integration
        • Fund Tracking: Monitor program budgets, available funds, and journal entries through Odoo accounting
        • -
        • Stock Integration: Link in-kind entitlements to inventory, -trigger procurements, track warehouse movements
        • -
        • Compliance: Define ongoing beneficiary conditions and filter -cycle members by compliance status
        • +
        • Stock Integration: Link in-kind entitlements to inventory, trigger +procurements, track warehouse movements
        • +
        • Compliance: Define ongoing beneficiary conditions and filter cycle +members by compliance status
        • Manager Architecture: Extensible pattern for eligibility, -deduplication, notification, program, cycle, entitlement, payment, -and compliance logic
        • +deduplication, notification, program, cycle, entitlement, payment, and +compliance logic

          Key Models

          Group
          spp_ -key_management.group_key_admin
          spp_key_management.group_key_admin Read/Write/Create on all models, key rotation
          spp_key_managem -ent.group_key_operator_officer
          spp_key_management.group_key_operator_officer Read encryption keys for use in operations
          --++ @@ -459,13 +459,11 @@

          Key Models

          - + - + @@ -473,8 +471,7 @@

          Key Models

          - + @@ -494,23 +491,19 @@

          Key Models

          - + - + - + - + @@ -518,8 +511,7 @@

          Key Models

          - + @@ -527,8 +519,7 @@

          Key Models

          - + @@ -539,8 +530,7 @@

          Key Models

          - + @@ -563,8 +553,7 @@

          Configuration

        • Payment Manager: Prepares and sends payment batches
        • Deduplication Manager (optional): Identify duplicate beneficiaries
        • -
        • Notification Manager (optional): Send beneficiary -notifications
        • +
        • Notification Manager (optional): Send beneficiary notifications
        • Compliance Manager (optional): Define ongoing compliance conditions
        • @@ -581,8 +570,8 @@

          UI Location

        • Programs: Programs > Programs
        • Cycles: Accessed via “Cycles” stat button on program form (no standalone menu)
        • -
        • Beneficiaries: Accessed via “Beneficiaries” stat button on -program form (no standalone menu)
        • +
        • Beneficiaries: Accessed via “Beneficiaries” stat button on program +form (no standalone menu)
        • Cash Entitlements: Accessed via entitlement buttons on cycle form (no standalone menu)
        • In-Kind Entitlements: Programs > In-Kind > Entitlements
        • @@ -596,8 +585,8 @@

          UI Location

          Security

          Model Wrapper for eligibility manager implementations
          `` -spp.program.membership.manager``
          spp.program.membership.manager Base eligibility manager (abstract)
          spp.prog -ram.membership.manager.default
          spp.program.membership.manager.default Default eligibility implementation
          Wrapper for deduplication manager implementations
          sp -p.program.notification.manager
          spp.program.notification.manager Notification manager for beneficiary communications
          Default cycle manager implementation
          s -pp.program.entitlement.manager
          spp.program.entitlement.manager Wrapper for entitlement manager implementations
          spp.progr -am.entitlement.manager.default
          spp.program.entitlement.manager.default Default entitlement manager implementation
          spp.pr -ogram.entitlement.manager.cash
          spp.program.entitlement.manager.cash Cash entitlement manager with amount calculation
          spp.prog -ram.entitlement.manager.inkind
          spp.program.entitlement.manager.inkind In-kind entitlement manager with product configuration
          Wrapper for payment manager implementations
          spp.p -rogram.payment.manager.default
          spp.program.payment.manager.default Default payment manager implementation
          Wrapper for compliance manager implementations
          `` -spp.compliance.manager.default``
          spp.compliance.manager.default Default compliance manager with CEL support
          spp.program.fund.report.view Fund balance reporting view
          sp -p.program.membership.duplicate
          spp.program.membership.duplicate Tracks duplicate membership records
          --++ @@ -605,35 +594,29 @@

          Security

          - + - + - + - + - + - + diff --git a/spp_registry/README.rst b/spp_registry/README.rst index de767e46..de963b12 100644 --- a/spp_registry/README.rst +++ b/spp_registry/README.rst @@ -31,45 +31,44 @@ mapping. Extends ``res.partner`` to support social protection use cases. Key Capabilities ~~~~~~~~~~~~~~~~ -- Manage individual and group registrants with demographic fields - (gender, birthdate, civil status, occupation) -- Track group membership with configurable roles, start/end dates, and - automatic status computation -- Store and validate ID documents with regex-based validation and - expiry tracking -- Define relationships between registrants (individual-to-individual, - group-to-group, individual-to-group) -- Manage multiple phone numbers per registrant with validation and - sanitization -- Tag registrants using vocabulary-based classification -- Disable registrants and relationships with audit trail (disabled - date, disabled by, reason) +- Manage individual and group registrants with demographic fields + (gender, birthdate, civil status, occupation) +- Track group membership with configurable roles, start/end dates, and + automatic status computation +- Store and validate ID documents with regex-based validation and expiry + tracking +- Define relationships between registrants (individual-to-individual, + group-to-group, individual-to-group) +- Manage multiple phone numbers per registrant with validation and + sanitization +- Tag registrants using vocabulary-based classification +- Disable registrants and relationships with audit trail (disabled date, + disabled by, reason) Key Models ~~~~~~~~~~ -+-------------------------------+-------------------------------------+ -| Model | Description | -+===============================+=====================================+ -| ``res.partner`` | Extended for registrant management | -| | (individuals/groups) | -+-------------------------------+-------------------------------------+ -| ``spp.group.membership`` | Links individuals to groups with | -| | roles and dates | -+-------------------------------+-------------------------------------+ -| ``spp.registry.id`` | ID documents attached to | -| | registrants | -+-------------------------------+-------------------------------------+ -| ``spp.id.type`` | ID type definitions with validation | -| | rules | -+-------------------------------+-------------------------------------+ -| ``spp.registry.relationship`` | Relationships between registrants | -+-------------------------------+-------------------------------------+ -| ``spp.relationship`` | Relationship type definitions | -+-------------------------------+-------------------------------------+ -| ``spp.phone.number`` | Phone numbers with country-based | -| | validation | -+-------------------------------+-------------------------------------+ ++-------------------------------+--------------------------------------+ +| Model | Description | ++===============================+======================================+ +| ``res.partner`` | Extended for registrant management | +| | (individuals/groups) | ++-------------------------------+--------------------------------------+ +| ``spp.group.membership`` | Links individuals to groups with | +| | roles and dates | ++-------------------------------+--------------------------------------+ +| ``spp.registry.id`` | ID documents attached to registrants | ++-------------------------------+--------------------------------------+ +| ``spp.id.type`` | ID type definitions with validation | +| | rules | ++-------------------------------+--------------------------------------+ +| ``spp.registry.relationship`` | Relationships between registrants | ++-------------------------------+--------------------------------------+ +| ``spp.relationship`` | Relationship type definitions | ++-------------------------------+--------------------------------------+ +| ``spp.phone.number`` | Phone numbers with country-based | +| | validation | ++-------------------------------+--------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -85,16 +84,15 @@ After installing: UI Location ~~~~~~~~~~~ -- **Menu**: Registry (top-level menu) -- **Configuration**: Registry > Configuration -- **Form tabs** (Individuals): Profile, Identity, Participation, - History -- **Form tabs** (Groups): Profile, Identity, Participation, History -- **Relationships**: Accessible from registrant forms under the - "Identity" tab -- **Membership**: Accessible from individual forms under the - "Participation" tab (group memberships) or group forms under the - "Participation" tab (group members) +- **Menu**: Registry (top-level menu) +- **Configuration**: Registry > Configuration +- **Form tabs** (Individuals): Profile, Identity, Participation, History +- **Form tabs** (Groups): Profile, Identity, Participation, History +- **Relationships**: Accessible from registrant forms under the + "Identity" tab +- **Membership**: Accessible from individual forms under the + "Participation" tab (group memberships) or group forms under the + "Participation" tab (group members) Note: This module defines no top-level menu items for Individuals or Groups lists. These actions are typically exposed by domain-specific @@ -103,34 +101,29 @@ modules (e.g., ``spp_base_demo``). Security ~~~~~~~~ -+-------------------------------------+-------------------------------+ -| Group | Access | -+=====================================+===============================+ -| ``s | Read-only | -| pp_registry.group_registry_viewer`` | | -+-------------------------------------+-------------------------------+ -| ``sp | Read/Write/Create (no delete) | -| p_registry.group_registry_officer`` | | -+-------------------------------------+-------------------------------+ -| ``sp | Full CRUD | -| p_registry.group_registry_manager`` | | -+-------------------------------------+-------------------------------+ -| ``spp_reg | Configuration menu access | -| istry.group_registry_config_admin`` | | -+-------------------------------------+-------------------------------+ ++----------------------------------------------+-------------------------------+ +| Group | Access | ++==============================================+===============================+ +| ``spp_registry.group_registry_viewer`` | Read-only | ++----------------------------------------------+-------------------------------+ +| ``spp_registry.group_registry_officer`` | Read/Write/Create (no delete) | ++----------------------------------------------+-------------------------------+ +| ``spp_registry.group_registry_manager`` | Full CRUD | ++----------------------------------------------+-------------------------------+ +| ``spp_registry.group_registry_config_admin`` | Configuration menu access | ++----------------------------------------------+-------------------------------+ Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``res.partner`` to add custom fields for individuals or - groups -- Override ``_compute_calc_age()`` to customize age computation logic -- Inherit ``spp.group.membership`` to add domain-specific membership - fields -- Override ``count_individuals()`` on ``res.partner`` to customize - group member counting with complex filters -- Use ``invalidate_group_metrics()`` to trigger metric recalculation - when group composition changes +- Inherit ``res.partner`` to add custom fields for individuals or groups +- Override ``_compute_calc_age()`` to customize age computation logic +- Inherit ``spp.group.membership`` to add domain-specific membership + fields +- Override ``count_individuals()`` on ``res.partner`` to customize group + member counting with complex filters +- Use ``invalidate_group_metrics()`` to trigger metric recalculation + when group composition changes Dependencies ~~~~~~~~~~~~ diff --git a/spp_registry/static/description/index.html b/spp_registry/static/description/index.html index 21effa4f..1f4e452b 100644 --- a/spp_registry/static/description/index.html +++ b/spp_registry/static/description/index.html @@ -386,23 +386,23 @@

          Key Capabilities

          (gender, birthdate, civil status, occupation)
        • Track group membership with configurable roles, start/end dates, and automatic status computation
        • -
        • Store and validate ID documents with regex-based validation and -expiry tracking
        • +
        • Store and validate ID documents with regex-based validation and expiry +tracking
        • Define relationships between registrants (individual-to-individual, group-to-group, individual-to-group)
        • Manage multiple phone numbers per registrant with validation and sanitization
        • Tag registrants using vocabulary-based classification
        • -
        • Disable registrants and relationships with audit trail (disabled -date, disabled by, reason)
        • +
        • Disable registrants and relationships with audit trail (disabled date, +disabled by, reason)
        • Key Models

          Group
          spp_ -programs.group_programs_viewer
          spp_programs.group_programs_viewer Read-only on all program data
          spp_p -rograms.group_programs_officer
          spp_programs.group_programs_officer Read/write/create on all models (no delete)
          spp_p -rograms.group_programs_manager
          spp_programs.group_programs_manager Full CRUD on cycles and memberships, RWC on programs (no program delete)
          spp_pro -grams.group_programs_validator
          spp_programs.group_programs_validator Read/write/create on entitlements and cycles (finance validation role)
          spp_programs -.group_programs_cycle_approver
          spp_programs.group_programs_cycle_approver Read/write/create on entitlements and cycles (approval role)
          spp_pr -ograms.group_programs_rejector
          spp_programs.group_programs_rejector Read/write/create on entitlements (rejection role)
          --++ @@ -419,8 +419,7 @@

          Key Models

          roles and dates - +
          Model
          spp.registry.idID documents attached to -registrantsID documents attached to registrants
          spp.id.type ID type definitions with validation @@ -455,8 +454,7 @@

          UI Location

          • Menu: Registry (top-level menu)
          • Configuration: Registry > Configuration
          • -
          • Form tabs (Individuals): Profile, Identity, Participation, -History
          • +
          • Form tabs (Individuals): Profile, Identity, Participation, History
          • Form tabs (Groups): Profile, Identity, Participation, History
          • Relationships: Accessible from registrant forms under the “Identity” tab
          • @@ -472,8 +470,8 @@

            UI Location

            Security

            --++ @@ -481,20 +479,16 @@

            Security

            - + - + - + - + @@ -503,13 +497,12 @@

            Security

            Extension Points

              -
            • Inherit res.partner to add custom fields for individuals or -groups
            • +
            • Inherit res.partner to add custom fields for individuals or groups
            • Override _compute_calc_age() to customize age computation logic
            • Inherit spp.group.membership to add domain-specific membership fields
            • -
            • Override count_individuals() on res.partner to customize -group member counting with complex filters
            • +
            • Override count_individuals() on res.partner to customize group +member counting with complex filters
            • Use invalidate_group_metrics() to trigger metric recalculation when group composition changes
            diff --git a/spp_registry_search/README.rst b/spp_registry_search/README.rst index 6ff6758f..55931c52 100644 --- a/spp_registry_search/README.rst +++ b/spp_registry_search/README.rst @@ -32,30 +32,30 @@ bypass for compliance purposes. Key Capabilities ~~~~~~~~~~~~~~~~ -- Search-first landing page with no records loaded by default - (privacy-by-design) -- Quick search across name, ID numbers, phone, and email with - 3-character minimum -- Advanced filters for registrant type (individual/group) and - registration date range -- Recently viewed section showing user's last 10 accessed registrants - with avatars -- Automatic view tracking when registrant forms are opened -- Archive/unarchive permission enforcement (officers and managers only) -- Auditor bypass group for browse-all access to full registrant lists +- Search-first landing page with no records loaded by default + (privacy-by-design) +- Quick search across name, ID numbers, phone, and email with + 3-character minimum +- Advanced filters for registrant type (individual/group) and + registration date range +- Recently viewed section showing user's last 10 accessed registrants + with avatars +- Automatic view tracking when registrant forms are opened +- Archive/unarchive permission enforcement (officers and managers only) +- Auditor bypass group for browse-all access to full registrant lists Key Models ~~~~~~~~~~ -+-------------------------------+-------------------------------------+ -| Model | Description | -+===============================+=====================================+ -| ``spp.registry.view.history`` | Tracks user's recently viewed | -| | registrants with timestamps | -+-------------------------------+-------------------------------------+ -| ``res.partner`` (extended) | Adds view tracking on form open and | -| | archive restrictions | -+-------------------------------+-------------------------------------+ ++-------------------------------+--------------------------------------+ +| Model | Description | ++===============================+======================================+ +| ``spp.registry.view.history`` | Tracks user's recently viewed | +| | registrants with timestamps | ++-------------------------------+--------------------------------------+ +| ``res.partner`` (extended) | Adds view tracking on form open and | +| | archive restrictions | ++-------------------------------+--------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -73,44 +73,44 @@ After installing: UI Location ~~~~~~~~~~~ -- **Default landing**: Registry > Search (replaces individuals/groups - menus for non-auditors) -- **Auditor menus**: Registry > Browse All (Audit) > All Individuals / - All Groups -- **Recently viewed**: Displayed in search portal below the search form +- **Default landing**: Registry > Search (replaces individuals/groups + menus for non-auditors) +- **Auditor menus**: Registry > Browse All (Audit) > All Individuals / + All Groups +- **Recently viewed**: Displayed in search portal below the search form Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| ``sp | Full CRUD on view history | -| p_registry.group_registry_read`` | (restricted to own records via | -| | IR rule) | -+----------------------------------+----------------------------------+ -| ``spp_registry_search | Bypass search requirement, | -| .group_registry_search_auditor`` | access browse-all menus | -+----------------------------------+----------------------------------+ ++-------------------------------------------------------+----------------------------------+ +| Group | Access | ++=======================================================+==================================+ +| ``spp_registry.group_registry_read`` | Full CRUD on view history | +| | (restricted to own records via | +| | IR rule) | ++-------------------------------------------------------+----------------------------------+ +| ``spp_registry_search.group_registry_search_auditor`` | Bypass search requirement, | +| | access browse-all menus | ++-------------------------------------------------------+----------------------------------+ Archive/unarchive permission check enforces these groups: -- ``base.group_system`` -- ``spp_security.group_spp_admin`` -- ``spp_registry.group_registry_manager`` -- ``spp_registry.group_registry_officer`` +- ``base.group_system`` +- ``spp_security.group_spp_admin`` +- ``spp_registry.group_registry_manager`` +- ``spp_registry.group_registry_officer`` Extension Points ~~~~~~~~~~~~~~~~ -- Override ``res.partner.get_formview_action()`` to customize view - tracking behavior -- Inherit ``spp.registry.view.history.get_recent_registrants()`` to - modify area filtering or result format -- Override ``res.partner._check_archive_permission()`` to add custom - permission logic -- Extend OWL component ``spp_registry_search.search_portal`` to modify - search interface +- Override ``res.partner.get_formview_action()`` to customize view + tracking behavior +- Inherit ``spp.registry.view.history.get_recent_registrants()`` to + modify area filtering or result format +- Override ``res.partner._check_archive_permission()`` to add custom + permission logic +- Extend OWL component ``spp_registry_search.search_portal`` to modify + search interface Dependencies ~~~~~~~~~~~~ diff --git a/spp_registry_search/static/description/index.html b/spp_registry_search/static/description/index.html index e1c27df9..c8333985 100644 --- a/spp_registry_search/static/description/index.html +++ b/spp_registry_search/static/description/index.html @@ -400,8 +400,8 @@

            Key Capabilities

            Key Models

            Group
            s -pp_registry.group_registry_viewer
            spp_registry.group_registry_viewer Read-only
            sp -p_registry.group_registry_officer
            spp_registry.group_registry_officer Read/Write/Create (no delete)
            sp -p_registry.group_registry_manager
            spp_registry.group_registry_manager Full CRUD
            spp_reg -istry.group_registry_config_admin
            spp_registry.group_registry_config_admin Configuration menu access
            --++ @@ -447,8 +447,8 @@

            UI Location

            Security

            Model
            --++ @@ -456,14 +456,12 @@

            Security

            - + - + diff --git a/spp_security/README.rst b/spp_security/README.rst index b6e5e563..d54ff431 100644 --- a/spp_security/README.rst +++ b/spp_security/README.rst @@ -32,19 +32,18 @@ within these predefined categories. Key Capabilities ~~~~~~~~~~~~~~~~ -- Define 22 domain-specific security categories (Registry, Programs, - Entitlements, GRM, etc.) organizing security groups in user settings - UI -- Provide central Administrator group (``group_spp_admin``) that - automatically inherits all manager-level permissions from installed - domain modules -- Implement multi-company record rule for ``res.partner`` restricting - access to records from user's companies -- Implement self-only record rule for ``res.users`` restricting users - in ``group_access_restrict_self`` to viewing only their own user - record -- Link Odoo system administrators (``base.group_system``) to - automatically inherit OpenSPP Administrator privileges +- Define 22 domain-specific security categories (Registry, Programs, + Entitlements, GRM, etc.) organizing security groups in user settings + UI +- Provide central Administrator group (``group_spp_admin``) that + automatically inherits all manager-level permissions from installed + domain modules +- Implement multi-company record rule for ``res.partner`` restricting + access to records from user's companies +- Implement self-only record rule for ``res.users`` restricting users in + ``group_access_restrict_self`` to viewing only their own user record +- Link Odoo system administrators (``base.group_system``) to + automatically inherit OpenSPP Administrator privileges Configuration ~~~~~~~~~~~~~ @@ -61,24 +60,24 @@ This module defines no model access rights (empty ``ir.model.access.csv``). It provides only security groups and record rules. -+----------------------+----------------------+----------------------+ -| Group | XML ID | Purpose | -+======================+======================+======================+ -| Administrator | ``group_spp_admin`` | Inherits all manager | -| | | permissions from all | -| | | domains | -+----------------------+----------------------+----------------------+ -| Restricted: Self | ``group_ac | Restricts users to | -| Only | cess_restrict_self`` | viewing only their | -| | | own record | -+----------------------+----------------------+----------------------+ ++-----------------------+--------------------------------+----------------------+ +| Group | XML ID | Purpose | ++=======================+================================+======================+ +| Administrator | ``group_spp_admin`` | Inherits all manager | +| | | permissions from all | +| | | domains | ++-----------------------+--------------------------------+----------------------+ +| Restricted: Self Only | ``group_access_restrict_self`` | Restricts users to | +| | | viewing only their | +| | | own record | ++-----------------------+--------------------------------+----------------------+ Record rules: -- ``rule_partner_company``: Multi-company access for ``res.partner`` - (company_ids filter) -- ``rule_user_self_only``: Self-only access for ``res.users`` (applied - to ``group_access_restrict_self``) +- ``rule_partner_company``: Multi-company access for ``res.partner`` + (company_ids filter) +- ``rule_user_self_only``: Self-only access for ``res.users`` (applied + to ``group_access_restrict_self``) Extension Points ~~~~~~~~~~~~~~~~ diff --git a/spp_security/static/description/index.html b/spp_security/static/description/index.html index acd02fe1..58d48553 100644 --- a/spp_security/static/description/index.html +++ b/spp_security/static/description/index.html @@ -391,9 +391,8 @@

            Key Capabilities

            domain modules
          • Implement multi-company record rule for res.partner restricting access to records from user’s companies
          • -
          • Implement self-only record rule for res.users restricting users -in group_access_restrict_self to viewing only their own user -record
          • +
          • Implement self-only record rule for res.users restricting users in +group_access_restrict_self to viewing only their own user record
          • Link Odoo system administrators (base.group_system) to automatically inherit OpenSPP Administrator privileges
          • @@ -412,9 +411,9 @@

            Security

            rules.

            Group
            sp -p_registry.group_registry_read
            spp_registry.group_registry_read Full CRUD on view history (restricted to own records via IR rule)
            spp_registry_search -.group_registry_search_auditor
            spp_registry_search.group_registry_search_auditor Bypass search requirement, access browse-all menus
            ---+++ @@ -429,10 +428,8 @@

            Security

            permissions from all domains - - + + diff --git a/spp_service_points/README.rst b/spp_service_points/README.rst index fdcc5214..2e100a9d 100644 --- a/spp_service_points/README.rst +++ b/spp_service_points/README.rst @@ -32,40 +32,42 @@ disabled with reason tracking. Key Capabilities ~~~~~~~~~~~~~~~~ -- Create service points with contact information including phone - validation and address -- Link service points to companies and automatically track company - contacts as individuals -- Assign service points to hierarchical geographic areas via - ``spp.area`` -- Classify service points using vocabulary codes in the - ``urn:openspp:vocab:service-types`` namespace -- Enable and disable service points with date stamping and reason - tracking -- Create user accounts for service point contacts with security group - assignment -- Track contract status and operational state of each service point +- Create service points with contact information including phone + validation and address +- Link service points to companies and automatically track company + contacts as individuals +- Assign service points to hierarchical geographic areas via + ``spp.area`` +- Classify service points using vocabulary codes in the + ``urn:openspp:vocab:service-types`` namespace +- Enable and disable service points with date stamping and reason + tracking +- Create user accounts for service point contacts with security group + assignment +- Track contract status and operational state of each service point Key Models ~~~~~~~~~~ -+-----------------------+---------------------------------------------+ -| Model | Description | -+=======================+=============================================+ -| ``spp.service.point`` | Service delivery location with area | -| | assignment and type classification | -+-----------------------+---------------------------------------------+ ++-----------------------+----------------------------------------------+ +| Model | Description | ++=======================+==============================================+ +| ``spp.service.point`` | Service delivery location with area | +| | assignment and type classification | ++-----------------------+----------------------------------------------+ Extends ~~~~~~~ -+-----------------+-----------------------------------------------------------+ -| Model | Fields Added | -+=================+===========================================================+ -| ``res.partner`` | ``service_point_ids``, ``individual_service_points_ids`` | -+-----------------+-----------------------------------------------------------+ -| ``res.users`` | ``service_point_ids`` (related to partner service points) | -+-----------------+-----------------------------------------------------------+ ++-----------------+----------------------------------------------------+ +| Model | Fields Added | ++=================+====================================================+ +| ``res.partner`` | ``service_point_ids``, | +| | ``individual_service_points_ids`` | ++-----------------+----------------------------------------------------+ +| ``res.users`` | ``service_point_ids`` (related to partner service | +| | points) | ++-----------------+----------------------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -79,9 +81,9 @@ After installing: UI Location ~~~~~~~~~~~ -- **Menu**: Service Point > Service Points -- **Registrant Tab**: Accessible from registrant forms under the - "Service Points" tab +- **Menu**: Service Point > Service Points +- **Registrant Tab**: Accessible from registrant forms under the + "Service Points" tab Security ~~~~~~~~ @@ -101,12 +103,12 @@ Group Access Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``spp.service.point`` to add domain-specific fields or custom - validation -- Override ``_compute_phone_sanitized()`` to customize phone formatting - logic -- Extend service point forms via XPath to add tabs for country-specific - requirements +- Inherit ``spp.service.point`` to add domain-specific fields or custom + validation +- Override ``_compute_phone_sanitized()`` to customize phone formatting + logic +- Extend service point forms via XPath to add tabs for country-specific + requirements Dependencies ~~~~~~~~~~~~ diff --git a/spp_service_points/static/description/index.html b/spp_service_points/static/description/index.html index 62159229..d42f7527 100644 --- a/spp_service_points/static/description/index.html +++ b/spp_service_points/static/description/index.html @@ -402,8 +402,8 @@

            Key Capabilities

            Key Models

            Group
            Restricted: Self -Onlygroup_ac -cess_restrict_self
            Restricted: Self Onlygroup_access_restrict_self Restricts users to viewing only their own record
            --++ @@ -422,8 +422,8 @@

            Key Models

            Extends

            Model
            --++ @@ -432,10 +432,12 @@

            Extends

            - + - +
            Model
            res.partnerservice_point_ids, individual_service_points_idsservice_point_ids, +individual_service_points_ids
            res.usersservice_point_ids (related to partner service points)service_point_ids (related to partner service +points)
            diff --git a/spp_source_tracking/README.rst b/spp_source_tracking/README.rst index 12ec63fd..4378d88b 100644 --- a/spp_source_tracking/README.rst +++ b/spp_source_tracking/README.rst @@ -31,51 +31,50 @@ audit trails and relationship transfer. Key Capabilities ~~~~~~~~~~~~~~~~ -- Source detection: Distinguishes between Odoo UI, API, bulk import, - mobile app, migration, and merge operations via context and HTTP - headers -- Immutable creation tracking: Records source system, source reference, - collection method, and collection date at creation -- Update tracking: Maintains last update system and reference for all - modifications -- Registrant merge: Transfers identifiers, relationships, and program - memberships from merged record to survivor -- Merge provenance: Preserves audit trail with JSON data snapshots and - merge chain pointers -- Merge chain resolution: Follows ``merged_into_id`` pointers to find - current active partner +- Source detection: Distinguishes between Odoo UI, API, bulk import, + mobile app, migration, and merge operations via context and HTTP + headers +- Immutable creation tracking: Records source system, source reference, + collection method, and collection date at creation +- Update tracking: Maintains last update system and reference for all + modifications +- Registrant merge: Transfers identifiers, relationships, and program + memberships from merged record to survivor +- Merge provenance: Preserves audit trail with JSON data snapshots and + merge chain pointers +- Merge chain resolution: Follows ``merged_into_id`` pointers to find + current active partner Key Models ~~~~~~~~~~ -+-------------------------------+-------------------------------------+ -| Model | Description | -+===============================+=====================================+ -| ``spp.mixin.source.tracking`` | Abstract mixin providing source | -| | tracking fields | -+-------------------------------+-------------------------------------+ -| ``spp.merge.provenance`` | Audit record of merge operations | -| | with data snapshots | -+-------------------------------+-------------------------------------+ -| ``res.partner`` | Extended with source tracking and | -| | merge capabilities | -+-------------------------------+-------------------------------------+ -| ``spp.registry.id`` | Extended with source tracking for | -| | identifier provenance | -+-------------------------------+-------------------------------------+ -| ``spp.program.membership`` | Extended with source tracking for | -| | enrollment provenance | -+-------------------------------+-------------------------------------+ ++-------------------------------+--------------------------------------+ +| Model | Description | ++===============================+======================================+ +| ``spp.mixin.source.tracking`` | Abstract mixin providing source | +| | tracking fields | ++-------------------------------+--------------------------------------+ +| ``spp.merge.provenance`` | Audit record of merge operations | +| | with data snapshots | ++-------------------------------+--------------------------------------+ +| ``res.partner`` | Extended with source tracking and | +| | merge capabilities | ++-------------------------------+--------------------------------------+ +| ``spp.registry.id`` | Extended with source tracking for | +| | identifier provenance | ++-------------------------------+--------------------------------------+ +| ``spp.program.membership`` | Extended with source tracking for | +| | enrollment provenance | ++-------------------------------+--------------------------------------+ UI Location ~~~~~~~~~~~ -- **Source Tracking Tab**: Individual and group registrant forms under - "Source Tracking" -- **Merge History Menu**: Registry > Configuration > Merge History -- **Search Filters**: Partner search includes filters for source - system, collection method, merged records, and records with merge - history +- **Source Tracking Tab**: Individual and group registrant forms under + "Source Tracking" +- **Merge History Menu**: Registry > Configuration > Merge History +- **Search Filters**: Partner search includes filters for source system, + collection method, merged records, and records with merge history Security ~~~~~~~~ @@ -91,14 +90,14 @@ Group Access Extension Points ~~~~~~~~~~~~~~~~ -- Override ``_selection_collection_method()`` to add custom collection - methods -- Inherit ``spp.mixin.source.tracking`` in any model to enable source - tracking -- Override ``_get_merge_snapshot()`` to customize which fields are - preserved in merge audit trail -- Override ``_transfer_relationships()`` or ``_transfer_memberships()`` - to customize merge behavior +- Override ``_selection_collection_method()`` to add custom collection + methods +- Inherit ``spp.mixin.source.tracking`` in any model to enable source + tracking +- Override ``_get_merge_snapshot()`` to customize which fields are + preserved in merge audit trail +- Override ``_transfer_relationships()`` or ``_transfer_memberships()`` + to customize merge behavior Configuration ~~~~~~~~~~~~~ diff --git a/spp_source_tracking/static/description/index.html b/spp_source_tracking/static/description/index.html index a3527b0b..af13af48 100644 --- a/spp_source_tracking/static/description/index.html +++ b/spp_source_tracking/static/description/index.html @@ -401,8 +401,8 @@

            Key Capabilities

            Key Models

            --++ @@ -439,9 +439,8 @@

            UI Location

          • Source Tracking Tab: Individual and group registrant forms under “Source Tracking”
          • Merge History Menu: Registry > Configuration > Merge History
          • -
          • Search Filters: Partner search includes filters for source -system, collection method, merged records, and records with merge -history
          • +
          • Search Filters: Partner search includes filters for source system, +collection method, merged records, and records with merge history
          • diff --git a/spp_starter_social_registry/README.rst b/spp_starter_social_registry/README.rst index 281972f9..06f6aa1d 100644 --- a/spp_starter_social_registry/README.rst +++ b/spp_starter_social_registry/README.rst @@ -33,12 +33,12 @@ enrollment or entitlement management. Key Capabilities ~~~~~~~~~~~~~~~~ -- One-click installation of all Social Registry dependencies -- Automatically configures ``spp_starter.registry_type`` parameter to - ``social_registry`` -- Bundles core registry, API, DCI clients, change requests, and no-code - tools -- Installs async job processing infrastructure via ``queue_job`` +- One-click installation of all Social Registry dependencies +- Automatically configures ``spp_starter.registry_type`` parameter to + ``social_registry`` +- Bundles core registry, API, DCI clients, change requests, and no-code + tools +- Installs async job processing infrastructure via ``queue_job`` Configuration ~~~~~~~~~~~~~ @@ -54,10 +54,10 @@ After installing: Use Cases ~~~~~~~~~ -- National Social Registries tracking population demographics -- Humanitarian registration systems without program management -- Civil registration databases requiring external data synchronization -- ID management systems as standalone deployments +- National Social Registries tracking population demographics +- Humanitarian registration systems without program management +- Civil registration databases requiring external data synchronization +- ID management systems as standalone deployments For SP-MIS deployments with program enrollment and entitlements, use ``spp_starter_sp_mis`` instead. diff --git a/spp_starter_sp_mis/README.rst b/spp_starter_sp_mis/README.rst index 7754e050..a9fb6720 100644 --- a/spp_starter_sp_mis/README.rst +++ b/spp_starter_sp_mis/README.rst @@ -32,27 +32,27 @@ restrict registrant editing to administrators. Key Capabilities ~~~~~~~~~~~~~~~~ -- **Bundle Management**: Installs social registry foundation plus - program management modules in a single deployment -- **Starter Type Configuration**: Sets system identifier to "sp_mis" - for deployment classification -- **Registry Access Control**: Optional JavaScript-based restriction - that makes registrant forms read-only for non-admin users -- **Client-Side Enforcement**: Patches ``FormController`` and - ``ListController`` to hide Create/Edit/Delete buttons and force - readonly mode +- **Bundle Management**: Installs social registry foundation plus + program management modules in a single deployment +- **Starter Type Configuration**: Sets system identifier to "sp_mis" for + deployment classification +- **Registry Access Control**: Optional JavaScript-based restriction + that makes registrant forms read-only for non-admin users +- **Client-Side Enforcement**: Patches ``FormController`` and + ``ListController`` to hide Create/Edit/Delete buttons and force + readonly mode Key Models ~~~~~~~~~~ This module defines no models. It extends: -+-------------------------+-------------------------------------------+ -| Model | Extension | -+=========================+===========================================+ -| ``res.config.settings`` | Adds ``is_registry_admin_only_crud`` | -| | boolean field | -+-------------------------+-------------------------------------------+ ++-------------------------+--------------------------------------------+ +| Model | Extension | ++=========================+============================================+ +| ``res.config.settings`` | Adds ``is_registry_admin_only_crud`` | +| | boolean field | ++-------------------------+--------------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -70,28 +70,28 @@ After installing: UI Location ~~~~~~~~~~~ -- **Settings**: Settings > SP-MIS Settings (registry access control - toggle) -- **Programs**: Inherited from ``spp_programs`` (Social Protection > - Programs) -- **Service Points**: Inherited from ``spp_service_points`` via - transitive dependency +- **Settings**: Settings > SP-MIS Settings (registry access control + toggle) +- **Programs**: Inherited from ``spp_programs`` (Social Protection > + Programs) +- **Service Points**: Inherited from ``spp_service_points`` via + transitive dependency Implementation Details ~~~~~~~~~~~~~~~~~~~~~~ The registry restriction uses: -- **Config Parameter**: ``spp_starter.registry_admin_only_crud`` - (default: True) -- **JSON-RPC Endpoint**: ``/spp_starter_sp_mis/registry_restriction`` - checks restriction status -- **JavaScript Patches**: Modifies ``FormController`` and - ``ListController`` for ``res.partner`` model -- **Admin Check**: Users in ``spp_security.group_spp_admin`` bypass all - restrictions -- **MutationObserver**: Monitors DOM changes to re-apply restrictions - dynamically +- **Config Parameter**: ``spp_starter.registry_admin_only_crud`` + (default: True) +- **JSON-RPC Endpoint**: ``/spp_starter_sp_mis/registry_restriction`` + checks restriction status +- **JavaScript Patches**: Modifies ``FormController`` and + ``ListController`` for ``res.partner`` model +- **Admin Check**: Users in ``spp_security.group_spp_admin`` bypass all + restrictions +- **MutationObserver**: Monitors DOM changes to re-apply restrictions + dynamically Included Modules ~~~~~~~~~~~~~~~~ @@ -99,12 +99,12 @@ Included Modules Everything from ``spp_starter_social_registry`` (registry, API, DCI, change requests) plus: -- ``spp_programs`` (includes ``spp_service_points`` as transitive - dependency) -- ``spp_approval`` -- ``spp_event_data`` -- ``spp_api_v2_cycles`` (auto-installed when ``spp_api_v2`` + - ``spp_programs`` are present) +- ``spp_programs`` (includes ``spp_service_points`` as transitive + dependency) +- ``spp_approval`` +- ``spp_event_data`` +- ``spp_api_v2_cycles`` (auto-installed when ``spp_api_v2`` + + ``spp_programs`` are present) Dependencies ~~~~~~~~~~~~ diff --git a/spp_starter_sp_mis/static/description/index.html b/spp_starter_sp_mis/static/description/index.html index 931a27ef..9baf84ff 100644 --- a/spp_starter_sp_mis/static/description/index.html +++ b/spp_starter_sp_mis/static/description/index.html @@ -385,8 +385,8 @@

            Key Capabilities

            • Bundle Management: Installs social registry foundation plus program management modules in a single deployment
            • -
            • Starter Type Configuration: Sets system identifier to “sp_mis” -for deployment classification
            • +
            • Starter Type Configuration: Sets system identifier to “sp_mis” for +deployment classification
            • Registry Access Control: Optional JavaScript-based restriction that makes registrant forms read-only for non-admin users
            • Client-Side Enforcement: Patches FormController and @@ -399,8 +399,8 @@

              Key Models

              This module defines no models. It extends:

            Model
            --++ diff --git a/spp_studio/README.rst b/spp_studio/README.rst index 5ab7c951..83a62e9c 100644 --- a/spp_studio/README.rst +++ b/spp_studio/README.rst @@ -34,56 +34,56 @@ scheduled activation. Key Capabilities ~~~~~~~~~~~~~~~~ -- Create and test CEL expressions with real-time variable discovery and - validation -- Add custom fields to Individual and Group registries through a guided - builder -- Install pre-built logic packs for cash transfers, PMT targeting, - child benefits, social pensions, and other programs -- Test expressions using personas with example data before deployment -- Manage lifecycle through governance workflow: draft, pending - approval, published, archived -- Track version history with scheduled activation for future changes -- Monitor where logic and fields are used across programs +- Create and test CEL expressions with real-time variable discovery and + validation +- Add custom fields to Individual and Group registries through a guided + builder +- Install pre-built logic packs for cash transfers, PMT targeting, child + benefits, social pensions, and other programs +- Test expressions using personas with example data before deployment +- Manage lifecycle through governance workflow: draft, pending approval, + published, archived +- Track version history with scheduled activation for future changes +- Monitor where logic and fields are used across programs Key Models ~~~~~~~~~~ -+-------------------------------+-------------------------------------+ -| Model | Description | -+===============================+=====================================+ -| ``spp.cel.expression`` | Business logic definitions with CEL | -| | expressions | -+-------------------------------+-------------------------------------+ -| ``spp.cel.variable`` | Variable definitions for use in | -| | expressions | -+-------------------------------+-------------------------------------+ -| ``spp.cel.variable.category`` | Categories for organizing variables | -+-------------------------------+-------------------------------------+ -| ``spp.studio.field`` | Custom field definitions for | -| | registry extension | -+-------------------------------+-------------------------------------+ -| ``spp.studio.pack`` | Pre-built logic bundles for common | -| | use cases | -+-------------------------------+-------------------------------------+ -| ``spp.studio.pack.item`` | Individual logic definitions within | -| | a pack | -+-------------------------------+-------------------------------------+ -| ``spp.studio.test`` | Test cases for validating logic | -| | expressions | -+-------------------------------+-------------------------------------+ -| ``spp.studio.test.persona`` | Test personas with example data for | -| | logic validation | -+-------------------------------+-------------------------------------+ -| ``spp.studio.placement.zone`` | Form zones where custom fields can | -| | be placed | -+-------------------------------+-------------------------------------+ -| ``spp.studio.version`` | Version history tracking for logic | -| | changes | -+-------------------------------+-------------------------------------+ -| ``spp.studio.usage`` | Usage tracking for logic and field | -| | references | -+-------------------------------+-------------------------------------+ ++-------------------------------+--------------------------------------+ +| Model | Description | ++===============================+======================================+ +| ``spp.cel.expression`` | Business logic definitions with CEL | +| | expressions | ++-------------------------------+--------------------------------------+ +| ``spp.cel.variable`` | Variable definitions for use in | +| | expressions | ++-------------------------------+--------------------------------------+ +| ``spp.cel.variable.category`` | Categories for organizing variables | ++-------------------------------+--------------------------------------+ +| ``spp.studio.field`` | Custom field definitions for | +| | registry extension | ++-------------------------------+--------------------------------------+ +| ``spp.studio.pack`` | Pre-built logic bundles for common | +| | use cases | ++-------------------------------+--------------------------------------+ +| ``spp.studio.pack.item`` | Individual logic definitions within | +| | a pack | ++-------------------------------+--------------------------------------+ +| ``spp.studio.test`` | Test cases for validating logic | +| | expressions | ++-------------------------------+--------------------------------------+ +| ``spp.studio.test.persona`` | Test personas with example data for | +| | logic validation | ++-------------------------------+--------------------------------------+ +| ``spp.studio.placement.zone`` | Form zones where custom fields can | +| | be placed | ++-------------------------------+--------------------------------------+ +| ``spp.studio.version`` | Version history tracking for logic | +| | changes | ++-------------------------------+--------------------------------------+ +| ``spp.studio.usage`` | Usage tracking for logic and field | +| | references | ++-------------------------------+--------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -101,40 +101,38 @@ After installing: UI Location ~~~~~~~~~~~ -- **Menu**: Studio (top-level menu) -- **Home**: Studio > Home -- **Rules**: Studio > Rules > Expressions, Variables, Packages, Test - Personas -- **Custom Fields**: Studio > Forms & Fields > Custom Fields -- **Settings**: Studio > Settings (managers only) +- **Menu**: Studio (top-level menu) +- **Home**: Studio > Home +- **Rules**: Studio > Rules > Expressions, Variables, Packages, Test + Personas +- **Custom Fields**: Studio > Forms & Fields > Custom Fields +- **Settings**: Studio > Settings (managers only) Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| `` | Read | -| spp_studio.group_studio_viewer`` | | -+----------------------------------+----------------------------------+ -| ``spp_stud | Read/Write/Create on logic and | -| io.group_studio_editor_officer`` | fields (no delete on fields) | -+----------------------------------+----------------------------------+ -| ``s | Full CRUD | -| pp_studio.group_studio_manager`` | | -+----------------------------------+----------------------------------+ ++--------------------------------------------+----------------------------------+ +| Group | Access | ++============================================+==================================+ +| ``spp_studio.group_studio_viewer`` | Read | ++--------------------------------------------+----------------------------------+ +| ``spp_studio.group_studio_editor_officer`` | Read/Write/Create on logic and | +| | fields (no delete on fields) | ++--------------------------------------------+----------------------------------+ +| ``spp_studio.group_studio_manager`` | Full CRUD | ++--------------------------------------------+----------------------------------+ Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``spp.cel.expression`` to add domain-specific validation or - compilation steps -- Override ``_pre_activate()`` on ``spp.studio.field`` to customize - field creation behavior -- Add new logic pack categories by extending the ``category`` selection - field -- Implement custom variable sources by inheriting ``spp.cel.variable`` - and overriding discovery methods +- Inherit ``spp.cel.expression`` to add domain-specific validation or + compilation steps +- Override ``_pre_activate()`` on ``spp.studio.field`` to customize + field creation behavior +- Add new logic pack categories by extending the ``category`` selection + field +- Implement custom variable sources by inheriting ``spp.cel.variable`` + and overriding discovery methods Dependencies ~~~~~~~~~~~~ diff --git a/spp_studio/static/description/index.html b/spp_studio/static/description/index.html index 4411eb48..834ee68e 100644 --- a/spp_studio/static/description/index.html +++ b/spp_studio/static/description/index.html @@ -389,11 +389,11 @@

            Key Capabilities

            validation
          • Add custom fields to Individual and Group registries through a guided builder
          • -
          • Install pre-built logic packs for cash transfers, PMT targeting, -child benefits, social pensions, and other programs
          • +
          • Install pre-built logic packs for cash transfers, PMT targeting, child +benefits, social pensions, and other programs
          • Test expressions using personas with example data before deployment
          • -
          • Manage lifecycle through governance workflow: draft, pending -approval, published, archived
          • +
          • Manage lifecycle through governance workflow: draft, pending approval, +published, archived
          • Track version history with scheduled activation for future changes
          • Monitor where logic and fields are used across programs
          • @@ -402,8 +402,8 @@

            Key Capabilities

            Key Models

            Model
            --++ @@ -485,8 +485,8 @@

            UI Location

            Security

            Model
            --++ @@ -494,17 +494,14 @@

            Security

            - + - + - + diff --git a/spp_studio_api_v2/README.rst b/spp_studio_api_v2/README.rst index b541a483..a7d210f5 100644 --- a/spp_studio_api_v2/README.rst +++ b/spp_studio_api_v2/README.rst @@ -35,48 +35,48 @@ field schemas and variable metadata for external integrations. Key Capabilities ~~~~~~~~~~~~~~~~ -- Automatically register Studio custom fields to API extensions - (``studio-individual`` and ``studio-group``) when activated -- Expose field definitions with JSON Schema validation rules, selection - options, and visibility conditions -- List available CEL variables with metadata including value type, - source type, and period granularity -- Retrieve cached variable values for Individual/Group resources with - support for historical periods -- Parse incoming API extension data (CodeableConcept, ISO dates) into - Odoo field values for create/update operations -- Monkey-patch IndividualService and GroupService to handle extension - writes and include variable values in responses +- Automatically register Studio custom fields to API extensions + (``studio-individual`` and ``studio-group``) when activated +- Expose field definitions with JSON Schema validation rules, selection + options, and visibility conditions +- List available CEL variables with metadata including value type, + source type, and period granularity +- Retrieve cached variable values for Individual/Group resources with + support for historical periods +- Parse incoming API extension data (CodeableConcept, ISO dates) into + Odoo field values for create/update operations +- Monkey-patch IndividualService and GroupService to handle extension + writes and include variable values in responses Key Models ~~~~~~~~~~ -+----------------------------------+----------------------------------+ -| Model | Description | -+==================================+==================================+ -| ``s | Service methods for Individual | -| pp.studio.api.individual.mixin`` | API extension and variable data | -+----------------------------------+----------------------------------+ -| ``spp.studio.api.group.mixin`` | Service methods for Group API | -| | extension and variable data | -+----------------------------------+----------------------------------+ -| ``spp.studio.field`` (extended) | Adds ``api_exposed`` flag and | -| | auto-registration hooks | -+----------------------------------+----------------------------------+ -| ``fastapi.endpoint`` (extended) | Mounts Studio router on API v2 | -| | endpoint | -+----------------------------------+----------------------------------+ ++-------------------------------------+----------------------------------+ +| Model | Description | ++=====================================+==================================+ +| ``spp.studio.api.individual.mixin`` | Service methods for Individual | +| | API extension and variable data | ++-------------------------------------+----------------------------------+ +| ``spp.studio.api.group.mixin`` | Service methods for Group API | +| | extension and variable data | ++-------------------------------------+----------------------------------+ +| ``spp.studio.field`` (extended) | Adds ``api_exposed`` flag and | +| | auto-registration hooks | ++-------------------------------------+----------------------------------+ +| ``fastapi.endpoint`` (extended) | Mounts Studio router on API v2 | +| | endpoint | ++-------------------------------------+----------------------------------+ API Endpoints ~~~~~~~~~~~~~ -- **GET /Studio/fields**: List active Studio custom fields with - configuration -- **GET /Studio/fields/{technical_name}/schema**: Get JSON Schema - validation rules for a specific field -- **GET /Studio/variables**: List available CEL variables with metadata -- **GET /Studio/variables/{resource_type}/{identifier}**: Get cached - variable values for an Individual or Group +- **GET /Studio/fields**: List active Studio custom fields with + configuration +- **GET /Studio/fields/{technical_name}/schema**: Get JSON Schema + validation rules for a specific field +- **GET /Studio/variables**: List available CEL variables with metadata +- **GET /Studio/variables/{resource_type}/{identifier}**: Get cached + variable values for an Individual or Group All endpoints require ``studio:read`` scope. @@ -101,17 +101,16 @@ fields are activated. Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| ``spp_api_v2.group_api_v2_read`` | Read on service mixins | -+----------------------------------+----------------------------------+ -| ` | Read/Write on service mixins | -| `spp_api_v2.group_api_v2_write`` | | -+----------------------------------+----------------------------------+ -| `` | Read/Write/Create on service | -| spp_api_v2.group_api_v2_create`` | mixins (no delete) | -+----------------------------------+----------------------------------+ ++------------------------------------+----------------------------------+ +| Group | Access | ++====================================+==================================+ +| ``spp_api_v2.group_api_v2_read`` | Read on service mixins | ++------------------------------------+----------------------------------+ +| ``spp_api_v2.group_api_v2_write`` | Read/Write on service mixins | ++------------------------------------+----------------------------------+ +| ``spp_api_v2.group_api_v2_create`` | Read/Write/Create on service | +| | mixins (no delete) | ++------------------------------------+----------------------------------+ API authorization uses scope-based authentication (``studio:read`` scope), not Odoo group checks. @@ -119,13 +118,13 @@ scope), not Odoo group checks. Extension Points ~~~~~~~~~~~~~~~~ -- Override ``_convert_to_odoo()`` in ExtensionWriteService to add - custom field type conversions -- Override ``compute_variable_value()`` in VariableValueService to add - custom computation logic -- Add models to ``SAFE_LOOKUP_MODELS`` (ExtensionWriteService) or - ``SAFE_SOURCE_MODELS`` (VariableValueService) to enable - lookups/computation +- Override ``_convert_to_odoo()`` in ExtensionWriteService to add custom + field type conversions +- Override ``compute_variable_value()`` in VariableValueService to add + custom computation logic +- Add models to ``SAFE_LOOKUP_MODELS`` (ExtensionWriteService) or + ``SAFE_SOURCE_MODELS`` (VariableValueService) to enable + lookups/computation Dependencies ~~~~~~~~~~~~ diff --git a/spp_studio_api_v2/static/description/index.html b/spp_studio_api_v2/static/description/index.html index 79f97fcc..17ea7bce 100644 --- a/spp_studio_api_v2/static/description/index.html +++ b/spp_studio_api_v2/static/description/index.html @@ -401,8 +401,8 @@

            Key Capabilities

            Key Models

            Group
            `` -spp_studio.group_studio_viewer``
            spp_studio.group_studio_viewer Read
            spp_stud -io.group_studio_editor_officer
            spp_studio.group_studio_editor_officer Read/Write/Create on logic and fields (no delete on fields)
            s -pp_studio.group_studio_manager
            spp_studio.group_studio_manager Full CRUD
            --++ @@ -410,8 +410,7 @@

            Key Models

            - + @@ -464,8 +463,8 @@

            UI Location

            Security

            Model
            s -pp.studio.api.individual.mixin
            spp.studio.api.individual.mixin Service methods for Individual API extension and variable data
            --++ @@ -476,12 +475,10 @@

            Security

            - + - + @@ -493,8 +490,8 @@

            Security

            Extension Points

              -
            • Override _convert_to_odoo() in ExtensionWriteService to add -custom field type conversions
            • +
            • Override _convert_to_odoo() in ExtensionWriteService to add custom +field type conversions
            • Override compute_variable_value() in VariableValueService to add custom computation logic
            • Add models to SAFE_LOOKUP_MODELS (ExtensionWriteService) or diff --git a/spp_studio_change_requests/README.rst b/spp_studio_change_requests/README.rst index bb4886ca..a43cf7ad 100644 --- a/spp_studio_change_requests/README.rst +++ b/spp_studio_change_requests/README.rst @@ -32,38 +32,38 @@ access rights for each CR type. Key Capabilities ~~~~~~~~~~~~~~~~ -- Create custom change request types through a three-step wizard - (naming, field selection, approval configuration) -- Dynamically generate ``x_spp_cr_detail_*`` models and - ``ir.model.fields`` records at runtime when activating a CR type -- Map fields from ``res.partner`` to detail model fields, supporting - char, text, date, selection, many2one, and other types -- Manage lifecycle through draft/active/inactive states with validation - checks and deactivation impact warnings -- Configure approval groups and auto-apply settings per CR type -- Add or modify field mappings on active types; changes sync to detail - models and form views automatically +- Create custom change request types through a three-step wizard + (naming, field selection, approval configuration) +- Dynamically generate ``x_spp_cr_detail_*`` models and + ``ir.model.fields`` records at runtime when activating a CR type +- Map fields from ``res.partner`` to detail model fields, supporting + char, text, date, selection, many2one, and other types +- Manage lifecycle through draft/active/inactive states with validation + checks and deactivation impact warnings +- Configure approval groups and auto-apply settings per CR type +- Add or modify field mappings on active types; changes sync to detail + models and form views automatically Key Models ~~~~~~~~~~ -+----------------------------------+----------------------------------+ -| Model | Description | -+==================================+==================================+ -| `` | Studio-created CR type | -| spp.studio.change.request.type`` | definition with lifecycle | -| | tracking | -+----------------------------------+----------------------------------+ -| ``spp.studio.cr.field.mapping`` | Field mapping from | -| | ``res.partner`` to CR detail | -| | model | -+----------------------------------+----------------------------------+ -| ``spp.cr.detail.generic`` | Generic detail template model | -| | (unused; types generate x\_\*) | -+----------------------------------+----------------------------------+ -| ``x_spp_cr_detail_*`` | Auto-generated detail models for | -| (dynamically) | each activated CR type | -+----------------------------------+----------------------------------+ ++------------------------------------+----------------------------------+ +| Model | Description | ++====================================+==================================+ +| ``spp.studio.change.request.type`` | Studio-created CR type | +| | definition with lifecycle | +| | tracking | ++------------------------------------+----------------------------------+ +| ``spp.studio.cr.field.mapping`` | Field mapping from | +| | ``res.partner`` to CR detail | +| | model | ++------------------------------------+----------------------------------+ +| ``spp.cr.detail.generic`` | Generic detail template model | +| | (unused; types generate x\_\*) | ++------------------------------------+----------------------------------+ +| ``x_spp_cr_detail_*`` | Auto-generated detail models for | +| (dynamically) | each activated CR type | ++------------------------------------+----------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -81,27 +81,25 @@ After installing: UI Location ~~~~~~~~~~~ -- **Menu**: Studio > Forms & Fields > Change Requests -- **Wizard**: Three-step builder for guided CR type creation -- **Detail Forms**: Generated dynamically at - ``/web#model=x_spp_cr_detail_*`` +- **Menu**: Studio > Forms & Fields > Change Requests +- **Wizard**: Three-step builder for guided CR type creation +- **Detail Forms**: Generated dynamically at + ``/web#model=x_spp_cr_detail_*`` Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| `` | Read CR types and mappings | -| spp_studio.group_studio_viewer`` | | -+----------------------------------+----------------------------------+ -| ``spp_stud | Read/Write/Create on CR types | -| io.group_studio_editor_officer`` | and mappings (no delete on CR | -| | types) | -+----------------------------------+----------------------------------+ -| ``s | Full CRUD | -| pp_studio.group_studio_manager`` | | -+----------------------------------+----------------------------------+ ++--------------------------------------------+----------------------------------+ +| Group | Access | ++============================================+==================================+ +| ``spp_studio.group_studio_viewer`` | Read CR types and mappings | ++--------------------------------------------+----------------------------------+ +| ``spp_studio.group_studio_editor_officer`` | Read/Write/Create on CR types | +| | and mappings (no delete on CR | +| | types) | ++--------------------------------------------+----------------------------------+ +| ``spp_studio.group_studio_manager`` | Full CRUD | ++--------------------------------------------+----------------------------------+ Detail models use ``spp_change_request_v2`` groups (user, validator, manager) with create disabled to prevent manual record creation. @@ -109,13 +107,13 @@ manager) with create disabled to prevent manual record creation. Extension Points ~~~~~~~~~~~~~~~~ -- Inherit ``spp.studio.change.request.type`` and override - ``_prepare_cr_type_vals()`` to customize generated CR type - configuration -- Override ``_build_detail_form_arch()`` to customize the generated - form view XML structure -- Extend ``spp.studio.cr.field.mapping._prepare_detail_field_vals()`` - to add custom field properties or domain filters +- Inherit ``spp.studio.change.request.type`` and override + ``_prepare_cr_type_vals()`` to customize generated CR type + configuration +- Override ``_build_detail_form_arch()`` to customize the generated form + view XML structure +- Extend ``spp.studio.cr.field.mapping._prepare_detail_field_vals()`` to + add custom field properties or domain filters Dependencies ~~~~~~~~~~~~ diff --git a/spp_studio_change_requests/static/description/index.html b/spp_studio_change_requests/static/description/index.html index 39eccfd8..0f7a29b1 100644 --- a/spp_studio_change_requests/static/description/index.html +++ b/spp_studio_change_requests/static/description/index.html @@ -400,8 +400,8 @@

              Key Capabilities

              Key Models

            Group
            spp_api_v2.group_api_v2_read Read on service mixins
            ` -spp_api_v2.group_api_v2_write`
            spp_api_v2.group_api_v2_write Read/Write on service mixins
            `` -spp_api_v2.group_api_v2_create``
            spp_api_v2.group_api_v2_create Read/Write/Create on service mixins (no delete)
            --++ @@ -409,8 +409,7 @@

            Key Models

            - + @@ -458,8 +457,8 @@

            UI Location

            Security

            Model
            `` -spp.studio.change.request.type``
            spp.studio.change.request.type Studio-created CR type definition with lifecycle tracking
            --++ @@ -467,18 +466,15 @@

            Security

            - + - + - + @@ -492,10 +488,10 @@

            Extension Points

          • Inherit spp.studio.change.request.type and override _prepare_cr_type_vals() to customize generated CR type configuration
          • -
          • Override _build_detail_form_arch() to customize the generated -form view XML structure
          • -
          • Extend spp.studio.cr.field.mapping._prepare_detail_field_vals() -to add custom field properties or domain filters
          • +
          • Override _build_detail_form_arch() to customize the generated form +view XML structure
          • +
          • Extend spp.studio.cr.field.mapping._prepare_detail_field_vals() to +add custom field properties or domain filters
          • diff --git a/spp_studio_events/README.rst b/spp_studio_events/README.rst index 80c0dd3c..15ef97f3 100644 --- a/spp_studio_events/README.rst +++ b/spp_studio_events/README.rst @@ -32,49 +32,49 @@ registrants. Key Capabilities ~~~~~~~~~~~~~~~~ -- Create event types through a 3-step wizard (basic info, fields, - review) -- Define custom fields with 10 field types: text, long text, integer, - decimal, date, datetime, boolean, selection, multi-select, link -- Apply field validation rules: range constraints for numbers, regex - patterns for text -- Configure conditional field visibility based on other field values -- Group fields into tabs for organized data entry forms -- Apply reusable field templates to accelerate event type creation -- Generate dynamic data entry wizards with proper widgets for each - field type -- Target events to individuals, groups, or both -- Draft/Active lifecycle prevents editing active event types -- Optional Kobo form integration for external data collection -- Optional approval workflow configuration +- Create event types through a 3-step wizard (basic info, fields, + review) +- Define custom fields with 10 field types: text, long text, integer, + decimal, date, datetime, boolean, selection, multi-select, link +- Apply field validation rules: range constraints for numbers, regex + patterns for text +- Configure conditional field visibility based on other field values +- Group fields into tabs for organized data entry forms +- Apply reusable field templates to accelerate event type creation +- Generate dynamic data entry wizards with proper widgets for each field + type +- Target events to individuals, groups, or both +- Draft/Active lifecycle prevents editing active event types +- Optional Kobo form integration for external data collection +- Optional approval workflow configuration Key Models ~~~~~~~~~~ -+----------------------------------+----------------------------------+ -| Model | Description | -+==================================+==================================+ -| ``spp.studio.event.type`` | Custom event type definition | -| | with draft/active lifecycle | -+----------------------------------+----------------------------------+ -| ``spp.studio.event.field`` | Field definition with type, | -| | validation, and visibility | -+----------------------------------+----------------------------------+ -| ``spp.studio.event.field.group`` | Groups fields into tabs in the | -| | data entry wizard | -+----------------------------------+----------------------------------+ -| ``s | Reusable template containing | -| pp.studio.event.field.template`` | field definitions | -+----------------------------------+----------------------------------+ -| ``spp.st | Field definition within a | -| udio.event.field.template.line`` | template | -+----------------------------------+----------------------------------+ -| ``spp.studio.event.type.wizard`` | 3-step wizard for creating event | -| | types | -+----------------------------------+----------------------------------+ -| ``spp.event.data.entry.wizard`` | Generated wizard for entering | -| | event data | -+----------------------------------+----------------------------------+ ++------------------------------------------+----------------------------------+ +| Model | Description | ++==========================================+==================================+ +| ``spp.studio.event.type`` | Custom event type definition | +| | with draft/active lifecycle | ++------------------------------------------+----------------------------------+ +| ``spp.studio.event.field`` | Field definition with type, | +| | validation, and visibility | ++------------------------------------------+----------------------------------+ +| ``spp.studio.event.field.group`` | Groups fields into tabs in the | +| | data entry wizard | ++------------------------------------------+----------------------------------+ +| ``spp.studio.event.field.template`` | Reusable template containing | +| | field definitions | ++------------------------------------------+----------------------------------+ +| ``spp.studio.event.field.template.line`` | Field definition within a | +| | template | ++------------------------------------------+----------------------------------+ +| ``spp.studio.event.type.wizard`` | 3-step wizard for creating event | +| | types | ++------------------------------------------+----------------------------------+ +| ``spp.event.data.entry.wizard`` | Generated wizard for entering | +| | event data | ++------------------------------------------+----------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -92,40 +92,38 @@ After installing: UI Location ~~~~~~~~~~~ -- **Menu**: Studio > Forms & Fields > Event Types -- **Wizard**: 3-step builder accessed via Create button -- **Data Entry**: Generated wizard form specific to each event type, - launched from event type form or registrant profile +- **Menu**: Studio > Forms & Fields > Event Types +- **Wizard**: 3-step builder accessed via Create button +- **Data Entry**: Generated wizard form specific to each event type, + launched from event type form or registrant profile Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| `` | Read event types and templates | -| spp_studio.group_studio_viewer`` | | -+----------------------------------+----------------------------------+ -| ``spp_stud | Read/Write/Create on event | -| io.group_studio_editor_officer`` | types, fields, and templates (no | -| | delete on event | -| | types/fields/templates) | -+----------------------------------+----------------------------------+ -| ``s | Full CRUD | -| pp_studio.group_studio_manager`` | | -+----------------------------------+----------------------------------+ ++--------------------------------------------+----------------------------------+ +| Group | Access | ++============================================+==================================+ +| ``spp_studio.group_studio_viewer`` | Read event types and templates | ++--------------------------------------------+----------------------------------+ +| ``spp_studio.group_studio_editor_officer`` | Read/Write/Create on event | +| | types, fields, and templates (no | +| | delete on event | +| | types/fields/templates) | ++--------------------------------------------+----------------------------------+ +| ``spp_studio.group_studio_manager`` | Full CRUD | ++--------------------------------------------+----------------------------------+ Extension Points ~~~~~~~~~~~~~~~~ -- Override ``_generate_wizard_view()`` on ``spp.studio.event.type`` to - customize generated wizard form layout -- Inherit ``spp.studio.event.field`` and override ``validate_value()`` - to add custom validation logic -- Extend ``spp.event.data.entry.wizard`` to add pre-save hooks for - event data processing -- Create predefined field templates via data files in - ``data/event_field_templates.xml`` +- Override ``_generate_wizard_view()`` on ``spp.studio.event.type`` to + customize generated wizard form layout +- Inherit ``spp.studio.event.field`` and override ``validate_value()`` + to add custom validation logic +- Extend ``spp.event.data.entry.wizard`` to add pre-save hooks for event + data processing +- Create predefined field templates via data files in + ``data/event_field_templates.xml`` Dependencies ~~~~~~~~~~~~ diff --git a/spp_studio_events/static/description/index.html b/spp_studio_events/static/description/index.html index e198a634..782fd0c1 100644 --- a/spp_studio_events/static/description/index.html +++ b/spp_studio_events/static/description/index.html @@ -392,8 +392,8 @@

            Key Capabilities

          • Configure conditional field visibility based on other field values
          • Group fields into tabs for organized data entry forms
          • Apply reusable field templates to accelerate event type creation
          • -
          • Generate dynamic data entry wizards with proper widgets for each -field type
          • +
          • Generate dynamic data entry wizards with proper widgets for each field +type
          • Target events to individuals, groups, or both
          • Draft/Active lifecycle prevents editing active event types
          • Optional Kobo form integration for external data collection
          • @@ -404,8 +404,8 @@

            Key Capabilities

            Key Models

            Group
            `` -spp_studio.group_studio_viewer``
            spp_studio.group_studio_viewer Read CR types and mappings
            spp_stud -io.group_studio_editor_officer
            spp_studio.group_studio_editor_officer Read/Write/Create on CR types and mappings (no delete on CR types)
            s -pp_studio.group_studio_manager
            spp_studio.group_studio_manager Full CRUD
            --++ @@ -425,13 +425,11 @@

            Key Models

            - + - + @@ -472,8 +470,8 @@

            UI Location

            Security

            Model Groups fields into tabs in the data entry wizard
            s -pp.studio.event.field.template
            spp.studio.event.field.template Reusable template containing field definitions
            spp.st -udio.event.field.template.line
            spp.studio.event.field.template.line Field definition within a template
            --++ @@ -481,19 +479,16 @@

            Security

            - + - + - + @@ -506,8 +501,8 @@

            Extension Points

            customize generated wizard form layout
          • Inherit spp.studio.event.field and override validate_value() to add custom validation logic
          • -
          • Extend spp.event.data.entry.wizard to add pre-save hooks for -event data processing
          • +
          • Extend spp.event.data.entry.wizard to add pre-save hooks for event +data processing
          • Create predefined field templates via data files in data/event_field_templates.xml
          • diff --git a/spp_user_roles/README.rst b/spp_user_roles/README.rst index fc71c30d..31cdf5eb 100644 --- a/spp_user_roles/README.rst +++ b/spp_user_roles/README.rst @@ -32,31 +32,31 @@ favor of manual UI-triggered updates. Key Capabilities ~~~~~~~~~~~~~~~~ -- Categorize roles as global (system-wide) or local (area-specific) via - ``role_type`` selection field -- Automatically sync security groups when roles are assigned or updated - via overridden ``set_groups_from_roles()`` -- Protect base system groups (user, portal, public, technical features) - from accidental removal during sync -- Display assigned roles in user list view via computed stored - Many2many field -- Manually trigger role synchronization via "Update User Roles" button - on role form +- Categorize roles as global (system-wide) or local (area-specific) via + ``role_type`` selection field +- Automatically sync security groups when roles are assigned or updated + via overridden ``set_groups_from_roles()`` +- Protect base system groups (user, portal, public, technical features) + from accidental removal during sync +- Display assigned roles in user list view via computed stored Many2many + field +- Manually trigger role synchronization via "Update User Roles" button + on role form Key Models ~~~~~~~~~~ -+-------------------------+-------------------------------------------+ -| Model | Description | -+=========================+===========================================+ -| ``res.users.role`` | Extended with ``role_type`` field and | -| | manual update action | -+-------------------------+-------------------------------------------+ -| ``res.users.role.line`` | Extended with related ``role_type`` field | -+-------------------------+-------------------------------------------+ -| ``res.users`` | Extended with stored roles field and | -| | custom group sync | -+-------------------------+-------------------------------------------+ ++-------------------------+--------------------------------------------+ +| Model | Description | ++=========================+============================================+ +| ``res.users.role`` | Extended with ``role_type`` field and | +| | manual update action | ++-------------------------+--------------------------------------------+ +| ``res.users.role.line`` | Extended with related ``role_type`` field | ++-------------------------+--------------------------------------------+ +| ``res.users`` | Extended with stored roles field and | +| | custom group sync | ++-------------------------+--------------------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -72,49 +72,49 @@ After installing: UI Location ~~~~~~~~~~~ -- **User Management**: Settings > Users & Companies > Users (Roles & - Access Rights tab) -- **Role Form**: Accessed from user's role lines with "Update User - Roles" button -- **No standalone menu**: Extends existing Settings views, does not add - new menu items +- **User Management**: Settings > Users & Companies > Users (Roles & + Access Rights tab) +- **Role Form**: Accessed from user's role lines with "Update User + Roles" button +- **No standalone menu**: Extends existing Settings views, does not add + new menu items Security ~~~~~~~~ -+----------------------------------+----------------------------------+ -| Group | Access | -+==================================+==================================+ -| ``spp_us | Read users, roles, and role | -| er_roles.group_local_registrar`` | lines | -+----------------------------------+----------------------------------+ -| ``spp_security.group_spp_admin`` | Full CRUD on roles and role | -| | lines | -+----------------------------------+----------------------------------+ ++------------------------------------------+----------------------------------+ +| Group | Access | ++==========================================+==================================+ +| ``spp_user_roles.group_local_registrar`` | Read users, roles, and role | +| | lines | ++------------------------------------------+----------------------------------+ +| ``spp_security.group_spp_admin`` | Full CRUD on roles and role | +| | lines | ++------------------------------------------+----------------------------------+ Predefined Roles ~~~~~~~~~~~~~~~~ **Global Roles** (system-wide access): -- System Admin, Registry Viewer, Global Finance, Global Program - Manager, Global Registrar, Global Support, Global Support Manager +- System Admin, Registry Viewer, Global Finance, Global Program Manager, + Global Registrar, Global Support, Global Support Manager **Local Roles** (area-specific access): -- Local Registrar, Local Support +- Local Registrar, Local Support Extension Points ~~~~~~~~~~~~~~~~ -- Override ``set_groups_from_roles()`` to customize which groups are - protected from removal (currently protects ``base.group_user``, - ``base.group_no_one``, ``mail.group_mail_template_editor``, - ``base.group_portal``, ``base.group_public``) -- Inherit ``res.users.role`` to add custom fields or selection values - for ``role_type`` -- Extend ``action_update_users()`` to add custom logic during manual - role synchronization +- Override ``set_groups_from_roles()`` to customize which groups are + protected from removal (currently protects ``base.group_user``, + ``base.group_no_one``, ``mail.group_mail_template_editor``, + ``base.group_portal``, ``base.group_public``) +- Inherit ``res.users.role`` to add custom fields or selection values + for ``role_type`` +- Extend ``action_update_users()`` to add custom logic during manual + role synchronization Dependencies ~~~~~~~~~~~~ diff --git a/spp_user_roles/static/description/index.html b/spp_user_roles/static/description/index.html index 1dcb0c0f..7a07926c 100644 --- a/spp_user_roles/static/description/index.html +++ b/spp_user_roles/static/description/index.html @@ -389,8 +389,8 @@

            Key Capabilities

            via overridden set_groups_from_roles()
          • Protect base system groups (user, portal, public, technical features) from accidental removal during sync
          • -
          • Display assigned roles in user list view via computed stored -Many2many field
          • +
          • Display assigned roles in user list view via computed stored Many2many +field
          • Manually trigger role synchronization via “Update User Roles” button on role form
          • @@ -399,8 +399,8 @@

            Key Capabilities

            Key Models

            Group
            `` -spp_studio.group_studio_viewer``
            spp_studio.group_studio_viewer Read event types and templates
            spp_stud -io.group_studio_editor_officer
            spp_studio.group_studio_editor_officer Read/Write/Create on event types, fields, and templates (no delete on event types/fields/templates)
            s -pp_studio.group_studio_manager
            spp_studio.group_studio_manager Full CRUD
            --++ @@ -448,8 +448,8 @@

            UI Location

            Security

            Model
            --++ @@ -457,8 +457,7 @@

            Security

            - + @@ -473,8 +472,8 @@

            Security

            Predefined Roles

            Global Roles (system-wide access):

              -
            • System Admin, Registry Viewer, Global Finance, Global Program -Manager, Global Registrar, Global Support, Global Support Manager
            • +
            • System Admin, Registry Viewer, Global Finance, Global Program Manager, +Global Registrar, Global Support, Global Support Manager

            Local Roles (area-specific access):

              diff --git a/spp_versioning/README.rst b/spp_versioning/README.rst index 6fc7891a..6ee274ac 100644 --- a/spp_versioning/README.rst +++ b/spp_versioning/README.rst @@ -31,35 +31,35 @@ tracking to prevent archiving in-use artifacts. Key Capabilities ~~~~~~~~~~~~~~~~ -- Store version snapshots in JSON with three relation strategies: - shallow (IDs), embed (snapshot data), follow (cascade versions) -- Schedule versions for future activation via daily cron job with - supersession chain tracking -- Optional approval workflow (draft → pending → approved → - scheduled/current) and test gate enforcement -- Usage tracking prevents archiving artifacts referenced by programs or - consumers +- Store version snapshots in JSON with three relation strategies: + shallow (IDs), embed (snapshot data), follow (cascade versions) +- Schedule versions for future activation via daily cron job with + supersession chain tracking +- Optional approval workflow (draft → pending → approved → + scheduled/current) and test gate enforcement +- Usage tracking prevents archiving artifacts referenced by programs or + consumers Key Models ~~~~~~~~~~ -+----------------------------------+----------------------------------+ -| Model | Description | -+==================================+==================================+ -| ``spp.versioned.mixin`` | Abstract mixin to add versioning | -| | capabilities to any model | -+----------------------------------+----------------------------------+ -| ``spp.artifact.version`` | Stores version snapshots with | -| | state machine | -| | (draft/scheduled/current) | -+----------------------------------+----------------------------------+ -| ``spp.artifact.usage`` | Tracks where artifacts are used | -| | (prevents orphan archiving) | -+----------------------------------+----------------------------------+ -| ``spp.ar | Wizard for scheduling version | -| tifact.version.schedule.wizard`` | activation with conflict | -| | detection | -+----------------------------------+----------------------------------+ ++------------------------------------------+----------------------------------+ +| Model | Description | ++==========================================+==================================+ +| ``spp.versioned.mixin`` | Abstract mixin to add versioning | +| | capabilities to any model | ++------------------------------------------+----------------------------------+ +| ``spp.artifact.version`` | Stores version snapshots with | +| | state machine | +| | (draft/scheduled/current) | ++------------------------------------------+----------------------------------+ +| ``spp.artifact.usage`` | Tracks where artifacts are used | +| | (prevents orphan archiving) | ++------------------------------------------+----------------------------------+ +| ``spp.artifact.version.schedule.wizard`` | Wizard for scheduling version | +| | activation with conflict | +| | detection | ++------------------------------------------+----------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -75,14 +75,14 @@ After installing: UI Location ~~~~~~~~~~~ -- Versioned artifacts call ``action_view_versions()`` to open version - history or ``action_open_schedule_wizard()`` for scheduling -- When used with ``spp_studio``, menus appear under **Studio > Settings - > Versioning**: +- Versioned artifacts call ``action_view_versions()`` to open version + history or ``action_open_schedule_wizard()`` for scheduling +- When used with ``spp_studio``, menus appear under **Studio > Settings + > Versioning**: - - **Scheduled Changes** (shows upcoming activations) - - **Version History** (all versions across models) - - **Artifact Usages** (dependency tracking) + - **Scheduled Changes** (shows upcoming activations) + - **Version History** (all versions across models) + - **Artifact Usages** (dependency tracking) Security ~~~~~~~~ diff --git a/spp_versioning/static/description/index.html b/spp_versioning/static/description/index.html index f6fc45f8..c0b07f3b 100644 --- a/spp_versioning/static/description/index.html +++ b/spp_versioning/static/description/index.html @@ -396,8 +396,8 @@

              Key Capabilities

              Key Models

            Group
            spp_us -er_roles.group_local_registrar
            spp_user_roles.group_local_registrar Read users, roles, and role lines
            --++ @@ -418,8 +418,7 @@

            Key Models

            - + diff --git a/spp_vocabulary/README.rst b/spp_vocabulary/README.rst index 8beb60ec..23091219 100644 --- a/spp_vocabulary/README.rst +++ b/spp_vocabulary/README.rst @@ -32,45 +32,43 @@ education levels) that are reused across OpenSPP modules. Key Capabilities ~~~~~~~~~~~~~~~~ -- Define vocabularies with globally unique namespace URIs for - interoperability -- Manage hierarchical codes with lifecycle tracking (active, - deprecated, replaced) -- Create local code extensions that map to standard codes with - equivalence tracking -- Map codes between different vocabularies for translation and - interoperability -- Filter active codes per deployment using deployment profiles -- Group codes semantically via concept groups for business logic - abstraction +- Define vocabularies with globally unique namespace URIs for + interoperability +- Manage hierarchical codes with lifecycle tracking (active, deprecated, + replaced) +- Create local code extensions that map to standard codes with + equivalence tracking +- Map codes between different vocabularies for translation and + interoperability +- Filter active codes per deployment using deployment profiles +- Group codes semantically via concept groups for business logic + abstraction Key Models ~~~~~~~~~~ -+----------------------------------+----------------------------------+ -| Model | Description | -+==================================+==================================+ -| ``spp.vocabulary`` | Collection of codes with a | -| | namespace (e.g., Gender, ID | -| | Type) | -+----------------------------------+----------------------------------+ -| ``spp.vocabulary.code`` | Individual code within a | -| | vocabulary (e.g., 'M', 'female') | -+----------------------------------+----------------------------------+ -| ``spp.vocabulary.mapping`` | Maps codes between different | -| | vocabularies | -+----------------------------------+----------------------------------+ -| ``spp.vocabulary.concept.group`` | Semantic grouping of codes for | -| | business logic abstraction | -+----------------------------------+----------------------------------+ -| ``spp.deployment.profile`` | Deployment-specific | -| | configuration for active code | -| | subsets | -+----------------------------------+----------------------------------+ -| ``spp.vocabulary.selection`` | Code selection within a | -| | deployment profile with | -| | inheritance | -+----------------------------------+----------------------------------+ ++----------------------------------+-----------------------------------+ +| Model | Description | ++==================================+===================================+ +| ``spp.vocabulary`` | Collection of codes with a | +| | namespace (e.g., Gender, ID Type) | ++----------------------------------+-----------------------------------+ +| ``spp.vocabulary.code`` | Individual code within a | +| | vocabulary (e.g., 'M', 'female') | ++----------------------------------+-----------------------------------+ +| ``spp.vocabulary.mapping`` | Maps codes between different | +| | vocabularies | ++----------------------------------+-----------------------------------+ +| ``spp.vocabulary.concept.group`` | Semantic grouping of codes for | +| | business logic abstraction | ++----------------------------------+-----------------------------------+ +| ``spp.deployment.profile`` | Deployment-specific configuration | +| | for active code subsets | ++----------------------------------+-----------------------------------+ +| ``spp.vocabulary.selection`` | Code selection within a | +| | deployment profile with | +| | inheritance | ++----------------------------------+-----------------------------------+ Configuration ~~~~~~~~~~~~~ @@ -88,10 +86,10 @@ After installing: UI Location ~~~~~~~~~~~ -- **Menu**: Settings > Vocabularies -- **Submenus**: Manage Vocabularies, All Codes, Code Mappings, Concept - Groups, Deployment Profiles, Vocabulary Selections -- **Vocabulary Form Tabs**: Details, Codes, Technical +- **Menu**: Settings > Vocabularies +- **Submenus**: Manage Vocabularies, All Codes, Code Mappings, Concept + Groups, Deployment Profiles, Vocabulary Selections +- **Vocabulary Form Tabs**: Details, Codes, Technical Security ~~~~~~~~ @@ -114,14 +112,14 @@ vocabularies. Extension Points ~~~~~~~~~~~~~~~~ -- Override ``spp.vocabulary.code.get_or_create_local()`` to customize - local code creation -- Inherit ``spp.vocabulary.concept.group`` and override ``contains()`` - for custom membership logic -- Use ``spp.vocabulary.code.resolve_by_uri()`` for URI-based code - resolution in interoperability scenarios -- Use ``spp.deployment.profile.get_active_domain()`` to filter code - fields by active deployment profile +- Override ``spp.vocabulary.code.get_or_create_local()`` to customize + local code creation +- Inherit ``spp.vocabulary.concept.group`` and override ``contains()`` + for custom membership logic +- Use ``spp.vocabulary.code.resolve_by_uri()`` for URI-based code + resolution in interoperability scenarios +- Use ``spp.deployment.profile.get_active_domain()`` to filter code + fields by active deployment profile Dependencies ~~~~~~~~~~~~ diff --git a/spp_vocabulary/static/description/index.html b/spp_vocabulary/static/description/index.html index 73b7e77a..dfcdfc0e 100644 --- a/spp_vocabulary/static/description/index.html +++ b/spp_vocabulary/static/description/index.html @@ -385,8 +385,8 @@

            Key Capabilities

            • Define vocabularies with globally unique namespace URIs for interoperability
            • -
            • Manage hierarchical codes with lifecycle tracking (active, -deprecated, replaced)
            • +
            • Manage hierarchical codes with lifecycle tracking (active, deprecated, +replaced)
            • Create local code extensions that map to standard codes with equivalence tracking
            • Map codes between different vocabularies for translation and @@ -400,8 +400,8 @@

              Key Capabilities

              Key Models

            Model Tracks where artifacts are used (prevents orphan archiving)
            spp.ar -tifact.version.schedule.wizard
            spp.artifact.version.schedule.wizard Wizard for scheduling version activation with conflict detection
            --++ @@ -411,8 +411,7 @@

            Key Models

            +namespace (e.g., Gender, ID Type) - +
            Model
            spp.vocabulary Collection of codes with a -namespace (e.g., Gender, ID -Type)
            spp.vocabulary.code Individual code within a @@ -427,9 +426,8 @@

            Key Models

            business logic abstraction
            spp.deployment.profileDeployment-specific -configuration for active code -subsetsDeployment-specific configuration +for active code subsets
            spp.vocabulary.selection Code selection within a