Metadata
- Source
- FLUID-6414
- Type
- Bug
- Priority
- Major
- Status
- Closed
- Resolution
- Fixed
- Assignee
- Antranig Basman
- Reporter
- Antranig Basman
- Created
2019-10-19T03:44:33.793-0400 - Updated
2024-07-22T10:35:22.511-0400 - Versions
- N/A
- Fixed Versions
-
- 4.0
- Component
-
- Framework
Description
For a while our only means of contributing so-called "raw" dynamic grades has been either i) via a direct IL reference to the grade(s), or ii) to a nullary function which returns such a grade(s).
Docs at https://docs.fluidproject.org/infusion/development/ComponentGrades.html#raw-dynamic-grades
Route ii) is a bit odd-looking and baroque, and cuts off the possibility for easily supplying arguments which is fairly common in newer cases with lensed components whose grade should depend on material in the source. We should at least allow expressions like this:
dynamicComponents: {
element: {
type: "gpii.psp.repeater.element",
sources: "{repeater}.model.items",
options: {
gradeNames: "@expand:{gpii.psp.repeater}.getElementGrade({that}.options.source)",
Note that for full support we need to implement some form of Queen of Sheba adaptation for components whose grade CHANGES as a result of change in model material. This requires a wholly new mechanism to destroy and reinstantiate the component without attempting to blast its source model material in the "unobservable gap".