Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Required advanced AddressComponent should allow empty c/o #5644

Closed
torbjokv opened this issue Feb 11, 2021 · 2 comments
Closed

Required advanced AddressComponent should allow empty c/o #5644

torbjokv opened this issue Feb 11, 2021 · 2 comments
Assignees
Labels
area/ui-editor Area: Related to the designer tool for assembling app UI in Altinn Studio. kind/bug Used when there is a defect / something is not working as it should. solution/studio/designer Issues related to the Altinn Studio Designer solution. status/duplicate Status: An issue that is closed as a duplicate of another issue.
Milestone

Comments

@torbjokv
Copy link
Contributor

Describe the bug

An address is could still be valid and complete without c/o filled.

{
    "id": "haraldhjemmeadresse",
    "type": "AddressComponent",
    "textResourceBindings": {
        "title": "HaraldAdresseLedetekst"
    },
    "dataModelBindings": {
        "address": "Harald.Gateadresse",
        "zipCode": "Harald.Postnr",
        "postPlace": "Harald.Poststed",
        "careOf": "Harald.Co",
        "houseNumber": "Harald.Bolignummer"
    },
    "simplified": false,
    "readOnly": false,
    "required": true
}

To Reproduce

Steps to reproduce the behavior:

  1. Add AddressComponent
  2. Disable simplified
  3. bind it to something
  4. Set AddressComponent as required in FormLayout.json
  5. Fill all fields except c/o filed
  6. observe that validation fails

Expected behavior

I expect form to be valid without c/o

Screenshots

image

@torbjokv torbjokv added the kind/bug Used when there is a defect / something is not working as it should. label Feb 11, 2021
@altinnadmin
Copy link
Member

If we created an address widget to replace the current AddressComponent, this would become trivial.

All we need is to get the horizontal layout support in #1515 shipped first 😃

@altinnadmin altinnadmin added area/ui-editor Area: Related to the designer tool for assembling app UI in Altinn Studio. solution/studio/designer Issues related to the Altinn Studio Designer solution. labels Feb 11, 2021
@lvbachmann lvbachmann self-assigned this Feb 12, 2021
@lvbachmann lvbachmann modified the milestones: 2021 - W7/8, 2021 - W9/10 Feb 12, 2021
@lvbachmann lvbachmann added bug/C2 status/duplicate Status: An issue that is closed as a duplicate of another issue. labels Feb 16, 2021
@lvbachmann
Copy link
Contributor

To be solved by Altinn/app-frontend-react#289 (as per suggestion by @altinnadmin).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/ui-editor Area: Related to the designer tool for assembling app UI in Altinn Studio. kind/bug Used when there is a defect / something is not working as it should. solution/studio/designer Issues related to the Altinn Studio Designer solution. status/duplicate Status: An issue that is closed as a duplicate of another issue.
Projects
None yet
Development

No branches or pull requests

3 participants