jimbob1001
(Jimbob100101)
February 8, 2017, 10:40pm
1
Started using packages to keep my config a bit more organised, but have noticed that the order of my groups are not being respected in the gui views.
Is there some way to force a particular group order?
At present I have groups set up like…
group:
view: yes
- entity_id: group 1
- entity_id: group 2
- entity_id: group 3
But in the GUI those entities are showing up as…
group 2
group 1
group 3
I would prefer them to show in the order they appear listed in the group
rpitera
(Robert Pitera)
February 8, 2017, 11:35pm
2
Try using group order in customize:
#
# Group Order
#
group.aeotec_smart_switch_1:
order: "1"
group.aeotec_smart_switch_2:
order: "2"
group.aeotec_smart_energy_switch:
order: "3"
group.outside:
order: "11"
group.livingroom:
friendly_name: living room
order: "12"
group.hallway:
order: "13"
group.office:
order: "14"
group.bedroom:
friendly_name: bedroom
order: "15"
group.diningroom:
friendly_name: dining room
order: "16"
group.tearoom:
friendly_name: tea room
order: "17"
group.upstairs:
friendly_name: second floor
order: "18"
group.ecobee:
order: "19"
group.nest_protect_downstairs:
friendly_name: Nest Protect Main Floor
order: "20"
group.nest_protect_upstairs:
friendly_name: Nest Protect Second Floor
order: "21"
1 Like
jimbob1001
(Jimbob100101)
February 9, 2017, 7:29am
3
Thanks,
I tried that, but I have also started using the new customize format so have to use…
homeassistant:
customize:
entity_id: group.1
order: "1"
Received an error…
17-02-08 22:18:05 ERROR (Thread-3) [homeassistant.util.yaml] mapping values are not allowed here
in "/config/includes/packages/plex.yaml"
Edit: removing the quotes has now fixed this!..
homeassistant:
customize:
entity_id: group.1
order: 1
Many thanks for the help!
2 Likes
norien
(Norien)
April 13, 2017, 5:48pm
4
I’m not sure what I am doing wrong but I cannot get it to work at all. No matter where I put that it messes everything up.
jimbob1001
(Jimbob100101)
April 13, 2017, 6:05pm
5
Maybe try post up the code you are using to see if we help can troubleshoot it?
norien
(Norien)
April 13, 2017, 6:08pm
6
jimbob1001
(Jimbob100101)
April 13, 2017, 8:10pm
7
Had a quick scan but cannot find anywhere in those files where you reference group orders maybe give a specific example?
Also my experience of using packages i have found that having customisations in different files caused problems, so ended up with just one customize.yaml file for all my various customisations
norien
(Norien)
April 13, 2017, 10:01pm
8
Ok here is my view:
default_view:
name: DEFAULT
view: yes
icon: mdi:home
entities:
- group.livingroom
- group.bedroom
- group.findlays_room
- group.office
- group.backyard
- group.laundry_room:
And inside this package is my laundry room which I have placed last in the group.
https://github.com/Norien/Home-Assistant-Config/blob/master/packages/laundry_room.yaml
However it shows up first on the views page. The order doesn’t even remotely match.
jimbob1001
(Jimbob100101)
April 14, 2017, 6:18am
9
Unless i am missing something, you have not used group orders in those snippets of code as rpitera suggested…
homeassistant:
customise:
group.hallway:
order: 13
group.office:
order: 14
group.bedroom:
friendly_name: bedroom
order: 15
Have i misunderstood what you are asking?
Edit: So here’s my full working code…
Pages.yaml…
group:
default_view:
view: true
entities:
- group.today
- group.tomorrow
- group.home
- group.web
- group.living_room_lights
- group.outside
- group.media_centre
Customise.yaml…
homeassistant:
customize:
group.today:
order: 1
group.tomorrow:
order: 2
group.home:
order: 3
group.living_room_lights:
order: 4
group.outside:
order: 5
group.media_centre:
order: 6
group.web:
order: 7
1 Like
norien
(Norien)
April 14, 2017, 4:13pm
10
I had to take it out as it would keep breaking my groups completely. I’m not sure what I’m doing wrong no matter where I put that it breaks. I can’t find any documentation regarding group ordering …
jimbob1001
(Jimbob100101)
April 14, 2017, 4:39pm
11
You may need to put all customisations into one yaml file, rather than having them scattered around the different packages.
I found i had issues until I created the single customise.yaml. i now don’t have customisations in any other file & it works fine for me
rpitera
(Robert Pitera)
April 15, 2017, 12:41pm
12
I don’t think it’s documented - I found out about it in the forums.
That’s how I have mine; I don’t use packages. I would think that at the least you’d have to have all the group orders in customize.yaml in it’s entirety.
jimbob1001
(Jimbob100101)
April 18, 2017, 9:13pm
13
Yes, i think packages are good for combining certain bits, but having customisations across lots of packages means you are more likely to create potentially conflicting customisations - e.g. if you added group order: 2
to two separate packages then that would be conflicting, but because you have customisations spread around you’d never know where the conflict was happening!
1 Like