Top Menu Bard Link to another Dashboard

Hi, I need a little help or pointing in the right direction please?

I have a dashboard called mobile which contains other views. These being called downstairs and upstairs (plans of the house with devices on)

I have another dashboard called “Dashboard” and I would like to place a link in the top menu bar that can open the downstairs and upstairs views.

When I create a new view in this dashboard and set the url it doesnt work.

I think I am not understanding what the correct url needs to look like , so can anyone suggest what that might be.

Many thanks

Andy

Try

tap_action:
  action: navigate
  navigation_url: /mobile/<view_name>

Thank you , but that didnt work this is what I added

title: Downstairs
path: downstairs
cards: []
tap_action:
  action: navigate
  navigation_url: /dashboard-mobile/house-layout

Just to add, i created the new view and then scrolled down to the bottom of the dashboard code and added it there. Im baffled why I cant just add the url in the view options. Am I not understanding something?

OK, that just means your dashboard is called dashboard-mobile not mobile.

Ok but why doesnt it work, either by entering the url into the view screen or adding code into the view section

OK, so I am not sure about your specific situation, but here is mine and maybe that will help.

my homeassistant is at: http://homeassistant.home:8123/lovelace/home

In the example above, lovelace is my dashboard and home is the first view in it.

The link to get there is:

tap_action:
  action: navigate
  navigation_path: /lovelace/home

I have another view called temp in a dashboard called home-devices. The url I would have to type into to the browser to go directly there is http://homeassistant.home:8123/home-devices/temp

I hope this helps you work it out for your case.

[edit: typos]

Thank you , tried all sorts of combinations and nothing works . If you put in a path within the same dashboard it then locks you out of the ability to edit that view so I then have to remove the code and loose that view.

To be honest I have given up as what should be a simple config as wasted so much time… but thank you for trying to help

regards

Andy

Can you share your yaml?
To be clear, tap_action must be inside a card that allows it eg:

- type: button
  name: Home page
  show_state: false
  tap_action:
    action: navigate
    navigation_url: /lovelace/home

Thanks , I think we might be at cross purposes. I am trying to add a Top Menu bar view so I cant add it in a card

 - title: 'Downstairs '
    path: /dashboard-mobile/house-layout
    cards: []

As soon as I add this , the view link becomes un-editable then and I have to remove that code from the whole dashboard code

I tried your code as well but because there is no card I don’t understand how that can work… When I create new view there is an option for a url but that doesnt work… I’m confused now which is why I gave up

Can you please share the yaml for the whole view?

Hi , to make it easy I created a new dashboard called test with a couple of cards for date & time and weather. I then created a new view with the url to the other view in the mobile dashboard. Didnt work and in fact caused the problem when now I cannot edit the downstairs view unless I edit via yaml.

views:
  - title: Test
    cards:
      - type: custom:mushroom-entity-card
        entity: sensor.date_time
        layout_options:
          grid_columns: 4
          grid_rows: 1
      - show_current: true
        show_forecast: true
        type: weather-forecast
        entity: weather.forecast_home
        forecast_type: daily
        theme: Catppuccin Frappe
  - title: Downstairs
    path: /dashboard-mobile/house-layout
    cards: []

OK, that doesn’t make any sense to me (sorry).

  • Aren’t you trying to navigate to Downstairs from view Test
  • Are both the views in dashboard dashboard-mobile?
  • By ‘Top Menu’, do you mean badges or do you want to create your own menu (in which case we can talk about how to do that).

If you do mean badges and are trying to link within the same dashboard, you don’t need to specify the dashboard so, for example, to link from Test to Downstairs, try this:

views:
  - title: Test
    path: test
    badges:
      - type: entity
        entity: <some-entity>
        name: "Downstairs"
        tap_action:
          action: navigate
          navigation_url: downstairs
    cards:
      - type: custom:mushroom-entity-card
        entity: sensor.date_time
        layout_options:
          grid_columns: 4
          grid_rows: 1
      - show_current: true
        show_forecast: true
        type: weather-forecast
        entity: weather.forecast_home
        forecast_type: daily
        theme: Catppuccin Frappe
  - title: Downstairs
    path: downstairs
    cards: []

The badge in view Test should now navigate to Downstairs. Some points:

  • the views: path only shows the path within the dashboard (it does contain the dashboard name).
  • you only need to put the dashboard name in the navigation_url if you are navigating to a different dashboard.

[edited for typos]

Yeh basically , I have a default dashboard called mobile.

This as 4 views called
Home - Main dashboard designed for mobile use via app
Car - View of tesla and various parameters via the Tessie integration
Downstairs - a plan of the downstairs of the house with all the devices on
Upstairs - same as downstairs but the upstairs level

Then i have another dashboard called …wait for it Dashboards ( i know took me ages to think of that one) which is designed more for a tablet layout and as 3 views, which are

Main - Random sensors , date/time , button to switch helpers etc
Hallway - Again designed for Hallway tablet with links to show London Underground tube status etc
Home Engery - shows energy usage from Hildebrand Glow integration with house smart meters

What I was trying to do was have another view on the Dashboard (Dashboard) that displayed the Downstairs view from the mobile dashboard. This way I only have the one downstairs dashboard and don’t have to maintain two give it uses the picture-elements card with round 50 sensors, lights, smart plugs etc shown on it.

I thought because the downstairs dashboard gave me a url in a browser of
/dashboard-mobile/house-layout I just just input that in the view url of the other dashboard to link to it… But sadly not .

looking on the community I think this as been asked for as a feature so the only way I can do it for now is a button on one of the existing views like I do now for the mobile view to display devices/batteries etc

Shame it cannot be done but a button instead is not a great shake really i guess

Many thanks for trying to help thou

Regards

Andy

:rofl:

Got it.

I do this by creating effectively a bunch of layouts that can be called from anywhere using custom:decluttering-card

Here are some examples of the same thing but in different dashboards (the yaml only exists once):

Screenshot 2024-08-21 at 16.07.52

The boxes in red are the same single decluttering-card but called from 2 different dashboards/views. The card itself is a mix of custom:vertical-stack-in-card, custom:button-card, and conditional-card.

You can pass variables such that every button (outside of the red square) that you see in the first screen is in fact only one of 2 decluttering-card (the menu on the left is one, everything on the right is the other) using different variables (for entity, colour, visibility, etc etc - it’s a great way to create a consistent theme for your dashboard.

Is this what you are looking for?

Hi

That will certainly do the job, I have similar

But using mushroom buttons

What I was hoping to do was a link in the menu bar instead … but as that doesn’t work I’ll add a few buttons

Thank you for taking the time to help

Regards

Andy

The menu bar (now I realise what you mean) can only show the icon or title of a view in that dashboard.

Yeh sorry it was difficult to explain, but the buttons work well :+1:t2: so happy days !!

1 Like