Dashboard Button link to get filter values and auto-apply in Look

Could you help me with one tricky functionality I am trying to implement in Looker.

Let me provide the background to be able to recommend me options.

I have a dashboard with a button, that is linked to Look. I have a filter "shipping_address_country_code" on the dashboard and in the Look. 

My task: get filter value from Dashboard and auto apply to the Look. The tricky moment is that I want to do it NOT in the dimension but in Button URL.

So the use case is

1. User opens the dashboard

2. User selects a filter "shipping_address_country_code" = NL

3. User clicks on the button

4. User sees Look

5. User sees filter "shipping_address_country_code" on the Look with auto-applied filter value "shipping_address_country_code" = NL

So the code example from LookML model of the dashboard. 

#Button Send the selection
  - type: button
    name: button_243
    rich_content_json: '{"text":"Send selection","description":"Send your selection
      to Google Ads after the final check of your customers","newTab":true,"alignment":"center","size":"large","style":"FILLED","color":"#80868B",
      "href":"https://crystalloids.eu.looker.com/looks/56?Orders={{_filters[orders.shipping_address_country_code]| url_encode}}&f[orders.shipping_address_country_code]"}'
 

One more option I tried

#"href":"https://crystalloids.eu.looker.com/looks/56?fields=orders.shipping_address_country_code&f[orders.shi..."}'

These code examples work for the dimension but not for the button. Could you consult me if my scenario is can be implemented and if yes, what should I correct in the code to reach the result.

Thank you in advance! 

0 6 2,596
6 REPLIES 6
Top Labels in this Space
Top Solution Authors