Question

Pass date filter using liquid variables in html


Hello… hoping you can advise. I’m trying to pass multiple dashboard filters including a “date range” filter to navigate to another dashboard while maintaining all filter values. The invoice code and customer code portions are working but the date filter is not being recognized. I’m wondering if it is due to the date parameter being defined as a dimension group. I also tried defining it as a date type dimension but that didn’t work as well. Here’s the two versions of the date range dimension and html below. Appreciate any guidance you can provide. Thank you.

 

dimension_group: date_range {
    type: time
    timeframes: [
      raw,
      time,
      date,
      week,
      month,
      quarter,
      year
    ]
    sql: CAST(${TABLE}.created_date AS TIMESTAMP) ;;

}

  dimension: date_range {
    type: date
    sql: ${TABLE}.created_date ;;
    }
 

html:
 <a href="https://recurlystaging.cloud.looker.com/dashboards-next/53?Date+Range={{ _filters['invoices.date_range']| url_encode }}&Invoice+code={{ _filters['invoices.invoice_code']| url_encode }}&Customer+code={{ _filters['invoices.customer_code']| url_encode }}">{{ value }} </a>


This topic has been closed for comments