[#6217] allow choosing document summaries for ZGW registrations#6299
[#6217] allow choosing document summaries for ZGW registrations#6299SonnyBA wants to merge 1 commit into
Conversation
b895ff3 to
d024608
Compare
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #6299 +/- ##
=======================================
Coverage 97.07% 97.07%
=======================================
Files 866 868 +2
Lines 32755 32798 +43
Branches 2981 2983 +2
=======================================
+ Hits 31797 31839 +42
- Misses 646 647 +1
Partials 312 312 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
6b7f278 to
3f1eb28
Compare
| all_values = state.get_data(include_static_variables=True) | ||
| variables = [key for key in all_values] | ||
| values = {key: all_values[key] for key in variables} |
There was a problem hiding this comment.
A few questions/remarks about this:
- What exactly are you trying to achieve here? Won't
all_valuesjust equalvaluesat the end? - Iterating over a
FormioDatainstance is not allowed, because you will not get the full variable keys if there is nested data. For example, component with key "foo.bar" will be present in the data as{"foo": {"bar": "baz"}}, so iterating over it will just give you "foo". - Does it make sense to include static variables here? I don't think they are in the PDF summary right?
Also, I think we need some processing of the values and schema here. Looking at the generic json plugin, partners and children data need to be cleaned up. Also, I'm not sure if it makes sense to include the submission data from file components as is, because it just contains metadata about the upload to the server. Would it be possible to relate it to the created attachment documents, like in the Objects API?
Given that it's the third plugin that requires this data cleanup, perhaps this is the part that can be refactored/generalized? Specifically processing partners and children will be the same for all plugins I think. (still a bit unclear to me whether this is worth it tbh, because there is also plugin-specific things happening)
3f1eb28 to
6204449
Compare
6204449 to
ee2d74e
Compare
Closes #6217
Changes
Allows form builders to specify which registration summary documents they want to include for requests to the configured ZGW API:
Checklist
Check off the items that are completed or not relevant.
Impact on features
Dockerfile/scripts
./binfolderCommit hygiene
Documentation
[skip: e2e]