Two Drop-Downs (external) and Dash Table (Python)

Good day,

I’m trying to build a dashboard with a dash datable and two dropdowns. The dropdowns are generated by the unique values of two fields (location and side). The first field is location which than determines the second dropdown which represent the site. For example a location can have three sites (e.g. A, B and C). Each site can have 2 or more. measurements (see image below). The link to the dataset: link to dataset

I would like to generate a dashboard that is able to select the location(s) first, which than filter the dash table meeting the selected location(s). Secondly I would like to select the side(s) which than filter the rest of the dash table meeting the selected side(s) and previous selected location(s).

This is my python script that I have so far:
import dash
import dash_html_components as html
import dash_core_components as dcc
import dash_table as dt
from dash.dependencies import Input, Output
import pandas as pd

df = pd.read_csv(‘C:\Users\jsi201\Documents\test\test.csv’)

app = dash.Dash(name)

fnameDict = {}
for i in df[‘location’].unique():
fnameDict[i] = [df[‘site’][j] for j in df[df[‘location’]==i].index]

names = list(fnameDict.keys())
nestedOptions = fnameDict[names[0]]

app.layout = html.Div(
options=[{‘label’:name, ‘value’:name} for name in names],
value = list(fnameDict.keys())[0]
style={‘width’: ‘20%’, ‘display’: ‘inline-block’}

                options=[{'label': i, 'value': i} for i in df.location.unique()]
            style={'width': '20%', 'display': 'inline-block'}
        dt.DataTable(id='table-container', columns=[{'id': c, 'name': c} for c in df.columns.values])


dash.dependencies.Output(‘optdropdown’, ‘options’),
[dash.dependencies.Input(‘namedropdown’, ‘value’)]
def update_date_dropdown(name):
return [{‘label’: i, ‘value’: i} for i in fnameDict[name]]

dash.dependencies.Output(‘table-container’, ‘data’),
[dash.dependencies.Input(‘namedropdown’, ‘value’),
dash.dependencies.Input(‘optdropdown’, ‘value’)])

def display_table(location,mm):
dff = df[df.location==location]
dff1 = dff[]
#dff = df[df.location==location]
return dff1.to_dict(‘records’)

if name == ‘main’:

This is the output that generates:

Any help would be very much appreciated. Kind regards Jorn Sijbertsma