From c3ebdb00570d59faf859e67c968adb7b75c6e68f Mon Sep 17 00:00:00 2001 From: Colin Maudry Date: Fri, 30 Jan 2026 20:13:59 +0100 Subject: [PATCH] =?UTF-8?q?Am=C3=A9liorations=20styles=20tableaux,=20heade?= =?UTF-8?q?rs?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/assets/css/style.css | 4 ++-- src/figures.py | 14 ++++---------- src/pages/acheteur.py | 6 +++--- src/pages/titulaire.py | 6 +++--- 4 files changed, 12 insertions(+), 18 deletions(-) diff --git a/src/assets/css/style.css b/src/assets/css/style.css index 6a1d71e..0084638 100644 --- a/src/assets/css/style.css +++ b/src/assets/css/style.css @@ -238,11 +238,11 @@ table.cell-table th { font-family: "Inter", sans-serif; text-align: left; font-weight: 600; - padding-right: 12px; + padding: 2px 12px 4px 2px; border: 1px solid rgb(179, 56, 33) !important; background-color: rgb(179, 56, 33); border-bottom: none !important; - height: 34px; + height: 32px; } .dash-table-container diff --git a/src/figures.py b/src/figures.py index 8f13d8a..ed85db4 100644 --- a/src/figures.py +++ b/src/figures.py @@ -91,11 +91,8 @@ def get_yearly_statistics(statistics, today_str) -> html.Div: page_size=10, sort_action="none", filter_action="none", - style_header={ - "border": "solid 1px rgb(179, 56, 33)", - "backgroundColor": "rgb(179, 56, 33)", - "color": "white", - }, + style_header={"fontFamily": "Inter", "fontSize": "16px"}, + style_cell={"fontFamily": "Inter", "fontSize": "16px"}, ) return html.Div(children=table, className="marches_table") @@ -210,11 +207,8 @@ def get_sources_tables(source_path) -> html.Div: ], sort_action="native", markdown_options={"html": True}, - style_header={ - "border": "solid 1px rgb(179, 56, 33)", - "backgroundColor": "rgb(179, 56, 33)", - "color": "white", - }, + style_header={"fontFamily": "Inter", "fontSize": "16px"}, + style_cell={"fontFamily": "Inter", "fontSize": "16px"}, ) return html.Div(children=datatable) diff --git a/src/pages/acheteur.py b/src/pages/acheteur.py index 161d972..6f5e5e2 100644 --- a/src/pages/acheteur.py +++ b/src/pages/acheteur.py @@ -71,7 +71,7 @@ layout = [ className="org_year", children=dcc.Dropdown( id="acheteur_year", - options=["Toutes"] + options=["Toutes les années"] + [ str(year) for year in range( @@ -231,7 +231,7 @@ def get_acheteur_marches_data(url, acheteur_year: str) -> tuple: acheteur_siret = url.split("/")[-1] lff = df.lazy() lff = lff.filter(pl.col("acheteur_id") == acheteur_siret) - if acheteur_year and acheteur_year != "Toutes": + if acheteur_year and acheteur_year != "Toutes les années": acheteur_year = int(acheteur_year) lff = lff.filter(pl.col("dateNotification").dt.year() == acheteur_year) lff = lff.sort(["dateNotification", "uid"], descending=True, nulls_last=True) @@ -292,7 +292,7 @@ def download_acheteur_data( def to_bytes(buffer): df_to_download.write_excel( - buffer, worksheet="DECP" if annee in ["Toutes", None] else annee + buffer, worksheet="DECP" if annee in ["Toutes les années", None] else annee ) date = datetime.datetime.now().strftime("%Y-%m-%d_%H:%M:%S") diff --git a/src/pages/titulaire.py b/src/pages/titulaire.py index 834ce68..84ec606 100644 --- a/src/pages/titulaire.py +++ b/src/pages/titulaire.py @@ -71,7 +71,7 @@ layout = [ className="org_year", children=dcc.Dropdown( id="titulaire_year", - options=["Toutes"] + options=["Toutes les années"] + [ str(year) for year in range( @@ -235,7 +235,7 @@ def get_titulaire_marches_data(url, titulaire_year: str) -> tuple: (pl.col("titulaire_id") == titulaire_siret) & (pl.col("titulaire_typeIdentifiant") == "SIRET") ) - if titulaire_year and titulaire_year != "Toutes": + if titulaire_year and titulaire_year != "Toutes les années": lff = lff.filter( pl.col("dateNotification").cast(pl.String).str.starts_with(titulaire_year) ) @@ -305,7 +305,7 @@ def download_titulaire_data( def to_bytes(buffer): df_to_download.write_excel( - buffer, worksheet="DECP" if annee in ["Toutes", None] else annee + buffer, worksheet="DECP" if annee in ["Toutes les années", None] else annee ) date = datetime.datetime.now().strftime("%Y-%m-%d_%H:%M:%S")