Skip to content

Attributes without a value set are not rendered in the account console #22961

Closed

Description

@pedroigor

Before reporting an issue

Area

account/ui

Describe the bug

The personal info page in Account v2 does not show attributes like E-mail, First Name, and Last Name if their values are undefined.

We should always show these attributes regardless of their value not being set

The exception is Email which should also respect the conditions around the update-email feature and realm settings like Register email as username and/or Edit Username Allowed. For these conditions, the UI is behaving correctly.

The check for undefined values for those attributes was introduced by #12109. Although I did not find many issues around that, I think having those attributes always available from UI is the correct behavior.

Version

22.0.1

Expected behavior

The personal info page in the account console must show attributes like E-mail, First Name, and Last Name if their values are undefined.

Actual behavior

The personal info page in the account console does not show attributes like E-mail, First Name, and Last Name if their values are undefined.

How to Reproduce?

  • Create a user and do not provide an e-mail
  • The email field is not shown if you access the account console/personal info for the user

The same happens if you force the first and last name fields to null when creating the user (the admin console is passing an empty string).

Anything else?

No response

Activity

  1. added
    kind/bug
    on Sep 4, 2023
  2. ghost added
    area/account/ui
    on Sep 4, 2023
  3. self-assigned this
    on Sep 4, 2023
  4. added this to the 22.0.3 milestone on Sep 4, 2023
  5. added
    area/account/ui
    and removed
    area/account/ui
    on Sep 5, 2023
  6. pedroigor commented on Sep 5, 2023

    @pedroigor
    ContributorAuthor

    @edewit The intriguing part is that we have been working like that since v18. I'm also not sure about the reason for not showing fields with undefined values.

    But as you know, you might even end up with an empty form depending on how you configured the realm settings for email as username and edit username allowed.

  7. pedroigor commented on Sep 5, 2023

    @pedroigor
    ContributorAuthor

    @ioemat Looks like it will break the UI for #12109. Perhaps we should just accept that Account v2 is not integrated with the user profile and wait for it on Account v3?

  8. edewit commented on Sep 5, 2023

    @edewit
    Contributor

    Yes, I think that will be best, we only need to increase the tests for account v3 to become the main account

  9. pedroigor commented on Sep 5, 2023

    @pedroigor
    ContributorAuthor

    @sschu What do you think about this one?

  10. sschu commented on Sep 5, 2023

    @sschu
    Contributor

    I think that in general all attributes that can be read or set according to the user profile and/or the realm settings should be shown - editable when they can be set and as read only if they cannot be set. I think the same should also be true for the admin console, so an admin always sees the whole profile and can fill out missing values without having to add keys.

  11. pedroigor commented on Sep 5, 2023

    @pedroigor
    ContributorAuthor

    The problem is that account v2 does not support user profile and the change to not show undefined attributes came from @ioemat. That is why I'm asking if reverting one of the changes from #12109 will break something there.

  12. sschu commented on Sep 5, 2023

    @sschu
    Contributor

    We mostly use our own fork of the account console, so changing this back should not break anything for us.

  13. added a commit that references this issue on Sep 8, 2023
    4d71138
  14. jonkoops commented on Sep 8, 2023

    @jonkoops
    Contributor

    @pedroigor perhaps this one could still be backported before 22.0.2 is released?

  15. modified the milestones: 22.0.3, 22.0.2 on Sep 8, 2023
  16. added a commit that references this issue on Sep 11, 2023
    38522e4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

area/account/uikind/bug

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions