Altinn / Altinn/app-frontend-react
Støtte for å binde "minCount" og "maxCount" i RepeatingGroup til datamodell
- Dominant language
- TypeScript
- Stars
- 21
- Forks
- 33
- Avg merge
- 6d 23h
- Merged PRs (30d)
- 3
Description
### Description
Jeg ønsker støtte for å kunne binde feltene "minCount" og "maxCount" til en RepeatingGroup til et felt i datamodellen, i stedet for bare en hardkodet integer.
I mitt tilfelle har jeg en repeterende gruppe hvor det er et krav at brukeren må legge inn et gitt antall items, men `minCount` varierer fra instans til instans.
Forlsag:
```json
{
"id": "my-repeating-group",
"type": "RepeatingGroup",
"dataModelBindings": {
"group": "some.list.in.datamodel"
},
"children": [
"child-component1",
"child-component2",
"child-component3"
]
"minCount": ["dataModel", "some.field.in.datamodel"],
"maxCount": ["dataModel", "some.other.field.in.datamodel"],
}
```
### Additional Information
- #2069
Contributor guide
Research direction
Start by tracing the RepeatingGroup implementation and its existing dataModelBindings behavior, then review the related discussion in #2069. Done means minCount and maxCount can use data-model values while preserving the current integer behavior and enforcing the requested item-count limits.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100