This is probably an old issue but I have not seen a resolution in the Groups documentation.
I was hoping that, if I put everything in groups, then they would be displayed in the order given in the entities list.
default_view: view: True icon: mdi:home entities: - group.alarms - group.lights - group.back_door_lock - group.temperature_control
Instead, the order displayed in Chrome and IOS is
I am at v0.46.0
Seems like a reasonable expectation. What am I missing?
I believe they appear in the order that they are defined.
So in your groups code you probably have:
view : no
- entity list
Thanks for the suggestion and timely response.
Who ever owns https://home-assistant.io/components/group/ should add this ordering characteristic.
See treno above. Edit groups.yaml that determines order.
My GUI order does not follow the order the groups are defined in. I am defining the groups within the .yaml file directly instead of in groups.yaml. Would that make a difference?
the order from top to bottom that groups are defined is the order in which they will appear on the frontend. if you add these groups to a view (defined in the same section as other groups) the groups will appear on the front end in which the groups were defined, NOT the order you list them in the view definition.
name: Group 1
name: Group 3
name: Group 2
name: View 1
this will display the groups on the frontend in a new view called “
View 1” and the groups will display in the order of:
This is also true for the order in which other components such as switches, lights, automations, etc are defined. It doesn’t matter the order you list them in the group or view definition, it only matters the order in which the component/entity was defined.
This has definitely changed in a recent release, as now this example seems to display:
Agree this has also changed in a recent release when i went to 0.57 all my views changed. I normally order group/ front end order by changing the group order in customize.
As an example changing “group.front_door” [group id 57] and “group.upstairs_door” [group id 56] i would expect the position to swap on the front end but this does not happen.
Groups will be ordered based in the order they are defined in your groups.
order is only used now when you don’t explicitly define the groups.
I agree that the ordering seems a bit strange. I’ve split the groups into several yaml-files and it seems impossible to tell which order the views will appear in. I suggest a new index-property in the group definition and that the groups/views will be ordered by that value.
view : yes
view : yes
what you are describing exists. You can manually assign the order property to the group in customize.
This will make the groups appear in order of group 2, group 3, group 1.
However, if people read what I posted, the group and entity display order depends on the order in which they are defined not in the order they are listed in the view. Sure the documentation may be lacking but once you play around with the ordering you’ll understand what it does and how to work with it.
Groups will be displayed in the order they are listed.
Well I’ll be… I just checked my configuration and yes, 0.57+ changes this behavior. group entities appear in the order in which they are listed and not in the order they are defined. However, in the case of listing groups and components in a view, it depends on the order they were loaded/defined. I have a camera for local radar and two groups for weather information in a view. the are listed as camera, group1, and group2, but they appear on the frontend as group1, group2, camera.
I am also having issues i agree with the statement "Groups will be displayed in the order they are listed."
As an example this is a list of my “groups” that i was shown on a separate tab
When i view the tab via my mobile phone, the order is listed as above which is fine.
What i want to be able to do is change the the order of the groupings on my front end when at my PC. Before the update i was doing this using.
so device specific group ordering? Not sure you can do that. HA doesn’t know what device is looking at it, it only knows that someone is looking at it. You could possibly incorporate an
input_boolean that would toggle views/ordering but you would have to remember to flip the switch on the frontend each time you change devices
hmmm it use to function fine before i am sure.
As an example the below is my downstairs tab with has its own view.
When visiting on my mobile the order is correct
But the view in the tab is misordered when on Windows
I used to use customize as below but changing order “11” to “12” for example the entities do not change place, i am sure in previous versions this was not an issue
“the group and entity display order depends on the order in which they are defined”
For me this is problem because I’ve divided the groups.yaml into several files making order a bit difficult to grasp. Renaming the files in alphabetical order didn’t work…
Thank you for the update using customize to order the groups - this solved my problem!