GitHub user agussimonte added a comment to the discussion: Trying to export 
excel file on a embedded chart but RLS filters not working

Hi, I did something like this. When you pass the urlParams, it filters both the 
view and the exported Excel file.
embedDashboard({
  // The ID of the dashboard you want to embed
  id: "YOUR_DASHBOARD_ID", 
  
  // Your Superset instance base URL
  supersetDomain: "https://superset.example.com";, 
  
  // The HTML element where the dashboard will be mounted
  mountPoint: document.getElementById("superset-container"), 
  
  // Function to fetch the guest token from your backend
  fetchGuestToken: () => fetchGuestTokenFromBackend(), 
  
  dashboardUiConfig: {
    filters: {
      visible: false,
      expanded: false,
    },
    // Example: Passing URL parameters to filter data
    urlParams: {
      companyId: "12345",
      // startDate: "2023-01-01",
      // endDate: "2023-12-31"
    },
  },
});

GitHub link: 
https://github.com/apache/superset/discussions/30283#discussioncomment-15305940

----
This is an automatically sent email for [email protected].
To unsubscribe, please send an email to: 
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to