From 4fd3ac94acc5cbb66e0383063c78e7a725cb037d Mon Sep 17 00:00:00 2001 From: emjay0921 Date: Thu, 7 May 2026 12:19:09 +0800 Subject: [PATCH] fix(spp_graduation): expose Graduation Criteria via menu + standalone views MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The model `spp.graduation.criteria` shipped with the module along with ACL entries and the `criteria_ids` One2many on `spp.graduation.pathway`, but had no menu, no action_window, and no standalone list/form views. Users could only edit criteria indirectly through the embedded list on the pathway form — the documented `Graduation > Graduation Criteria` nav path resolved to nothing. - Add `views/graduation_criteria_views.xml` with list, form, and search views plus an `action_graduation_criteria` action_window. The search view groups by pathway and assessment_method, filters required vs optional, and surfaces the archived flag. - Wire a `Graduation Criteria` menuitem as a direct child of `menu_graduation_root` (sequence 20, between Assessments and Configuration), gated on `group_spp_graduation_user` per the OP suggested fix. - Bump 19.0.2.0.0 → 19.0.2.0.1 + HISTORY entry. Refs OP#990. --- spp_graduation/__manifest__.py | 3 +- spp_graduation/readme/HISTORY.md | 4 + .../views/graduation_criteria_views.xml | 125 ++++++++++++++++++ spp_graduation/views/graduation_menus.xml | 10 ++ 4 files changed, 141 insertions(+), 1 deletion(-) create mode 100644 spp_graduation/views/graduation_criteria_views.xml diff --git a/spp_graduation/__manifest__.py b/spp_graduation/__manifest__.py index 3d680af7..c0b3fb07 100644 --- a/spp_graduation/__manifest__.py +++ b/spp_graduation/__manifest__.py @@ -2,7 +2,7 @@ { "name": "OpenSPP Graduation Management", "summary": "Manage graduation and exit from time-bound social protection programs", - "version": "19.0.2.0.0", + "version": "19.0.2.0.1", "category": "OpenSPP", "author": "OpenSPP.org", "website": "https://github.com/OpenSPP/OpenSPP2", @@ -23,6 +23,7 @@ "security/ir.model.access.csv", "views/graduation_pathway_views.xml", "views/graduation_assessment_views.xml", + "views/graduation_criteria_views.xml", "views/graduation_menus.xml", "data/graduation_data.xml", ], diff --git a/spp_graduation/readme/HISTORY.md b/spp_graduation/readme/HISTORY.md index 4aaf9afe..1f50cd43 100644 --- a/spp_graduation/readme/HISTORY.md +++ b/spp_graduation/readme/HISTORY.md @@ -1,3 +1,7 @@ +### 19.0.2.0.1 + +- fix(views): add a "Graduation Criteria" menu item directly under the Graduation root, plus a list/form/search view and action for `spp.graduation.criteria`. The model and ACL were already shipped, but no UI surface existed — criteria could only be edited indirectly through the pathway form. Visible to `group_spp_graduation_user` and above. + ### 19.0.2.0.0 - Initial migration to OpenSPP2 diff --git a/spp_graduation/views/graduation_criteria_views.xml b/spp_graduation/views/graduation_criteria_views.xml new file mode 100644 index 00000000..3a0c4c50 --- /dev/null +++ b/spp_graduation/views/graduation_criteria_views.xml @@ -0,0 +1,125 @@ + + + + + spp.graduation.criteria.search + spp.graduation.criteria + + + + + + + + + + + + + + + + + + + + + spp.graduation.criteria.list + spp.graduation.criteria + + + + + + + + + + + + + + + + + + spp.graduation.criteria.form + spp.graduation.criteria + +
+ + +
+

+ +

+
+ + + + + + + + + + + + + + + + +
+
+
+
+ + + + Graduation Criteria + spp.graduation.criteria + list,form + + +

+ Create a new Graduation Criterion +

+

+ Define weighted criteria within a pathway, each with its own + assessment method (self-report, verification, computed, or + field observation) and a flag for whether it is required. +

+
+
+
diff --git a/spp_graduation/views/graduation_menus.xml b/spp_graduation/views/graduation_menus.xml index f17e7fc1..12aaf536 100644 --- a/spp_graduation/views/graduation_menus.xml +++ b/spp_graduation/views/graduation_menus.xml @@ -33,6 +33,16 @@ sequence="20" /> + + +