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

fixes #26052 - add missing IDs to Layout #6551

Merged
merged 1 commit into from May 16, 2019

Conversation

glekner
Copy link
Contributor

@glekner glekner commented Mar 7, 2019

No description provided.

@theforeman-bot
Copy link
Member

Issues: #26052

ohadlevy
ohadlevy previously approved these changes Mar 7, 2019
@glekner
Copy link
Contributor Author

glekner commented Mar 7, 2019

I'm using the url (e.g. Hardware Models is menu_item_models for the new attributes.
I assumed dividers don't need the additional attributes.

@glekner
Copy link
Contributor Author

glekner commented Mar 7, 2019

Dashboard url is / so the attributes are wrong

<a id="menu_item_" data-id="aid_" href="/"><span class="list-group-item-value">Dashboard</span></a>

maybe we should hardcode the attributes in the server @ohadlevy ?

@waldenraines
Copy link

@lhellebr you may want to have a look at this as I'm not sure what the IDs were prior to the react navigation.

Copy link
Member

@tbrisker tbrisker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A couple of comments -

  1. This does not restore the same ids for the menu items as before. The original id was generated by the item name - https://github.com/theforeman/foreman/blob/1.19-stable/app/helpers/home_helper.rb#L41. This means that changing it to be based on the url will still cause multiple failures for QE automation.
  2. The data aid attribute should no longer be used by automation - see Fixes #23168 - undefined method `split' for nil:NilClass #5712 (comment) and SatelliteQE/airgun@8438e72 which dropped it completely, so we don't need to continue using this attribute which was only used for QE automation.

@glekner
Copy link
Contributor Author

glekner commented Mar 14, 2019

removed data-id and changed id to item.name
Also opened a quick fix PR because right now theres an empty data-id attribute
Screenshot 2019-03-14 12 06 48

@glekner
Copy link
Contributor Author

glekner commented Mar 21, 2019

  • rebased and updated PF version, so data-id isn't shown anymore

Copy link
Member

@tbrisker tbrisker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See inline comment; this also needs updating the react-patternfly rpm version

@coveralls
Copy link

Coverage Status

Coverage remained the same at 67.373% when pulling 276eb19 on glekner:verticalnav-ids into ef73d68 on theforeman:develop.

@glekner
Copy link
Contributor Author

glekner commented May 16, 2019

@tbrisker can we merge? aid is no longer used

@tbrisker
Copy link
Member

Thanks @glekner! I didn't notice that you pushed the update a couple of weeks ago.

@tbrisker tbrisker merged commit 68bda9e into theforeman:develop May 16, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
6 participants