From f648c7b80674b2f59b0c14d42b92d9bb86542435 Mon Sep 17 00:00:00 2001 From: Francesco Nazzaro Date: Tue, 15 Oct 2024 14:41:57 +0200 Subject: [PATCH 1/2] fix link --- haunts/spreadsheet.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/haunts/spreadsheet.py b/haunts/spreadsheet.py index e170f5c..3ec2ced 100644 --- a/haunts/spreadsheet.py +++ b/haunts/spreadsheet.py @@ -178,6 +178,7 @@ def sync_events(config_dir, sheet, data, calendars, days, month, projects=[], al from_time=default_start_time or last_to_time, ) last_to_time = event["next_slot"] + print(event) request = sheet.values().batchUpdate( spreadsheetId=get("CONTROLLER_SHEET_DOCUMENT_ID"), @@ -197,9 +198,7 @@ def sync_events(config_dir, sheet, data, calendars, days, month, projects=[], al # Quick link to the event on the calendar { "range": f"{month}!{headers[get('LINK_COLUMN_NAME', 'Link')]}{y + 2}", - "values": [ - [f"=HYPERLINK(\"{event[get('LINK_COLUMN_NAME', 'Link')]}\";\"open\")"] - ], + "values": [[f"=HYPERLINK(\"{event['link']}\";\"open\")"]], }, ], }, From 033c0bad0121cab94894dba12ba9acf8f033a152 Mon Sep 17 00:00:00 2001 From: Francesco Nazzaro Date: Tue, 15 Oct 2024 14:42:31 +0200 Subject: [PATCH 2/2] drop print --- haunts/spreadsheet.py | 1 - 1 file changed, 1 deletion(-) diff --git a/haunts/spreadsheet.py b/haunts/spreadsheet.py index 65452cb..94eb8cc 100644 --- a/haunts/spreadsheet.py +++ b/haunts/spreadsheet.py @@ -173,7 +173,6 @@ def sync_events(config_dir, sheet, data, calendars, days, month, projects=[], al from_time=default_start_time or last_to_time, ) last_to_time = event["next_slot"] - print(event) request = sheet.values().batchUpdate( spreadsheetId=get("CONTROLLER_SHEET_DOCUMENT_ID"),