From 618e7b2f14059e8e81dec4a3dd37478598575401 Mon Sep 17 00:00:00 2001 From: edouardbruelhart Date: Fri, 12 Apr 2024 15:08:34 +0200 Subject: [PATCH] save before test --- ms_sample_list_creator/csv_batch.py | 2 +- ms_sample_list_creator/ms_sample_list_creator.py | 13 ++++++------- 2 files changed, 7 insertions(+), 8 deletions(-) diff --git a/ms_sample_list_creator/csv_batch.py b/ms_sample_list_creator/csv_batch.py index bde4597..d59113c 100644 --- a/ms_sample_list_creator/csv_batch.py +++ b/ms_sample_list_creator/csv_batch.py @@ -45,7 +45,7 @@ def __init__(self, csv_batch_window: tk.Toplevel, root: tk.Tk): self.file = str(os.environ.get("FILE")) self.current_position = 1 self.current_row = 1 - self.timestamp = "202404101527"#datetime.now().strftime("%Y%m%d%H%M") + self.timestamp = "202404101527" # datetime.now().strftime("%Y%m%d%H%M") self.csv_path = f"{self.output_folder}/{datetime.now().strftime('%Y%m%d')}_{self.operator}_dbgi_{self.file}.csv" self.warning_label = tk.Label( diff --git a/ms_sample_list_creator/ms_sample_list_creator.py b/ms_sample_list_creator/ms_sample_list_creator.py index 2aa6a8b..17adede 100644 --- a/ms_sample_list_creator/ms_sample_list_creator.py +++ b/ms_sample_list_creator/ms_sample_list_creator.py @@ -6,9 +6,9 @@ import tkinter as tk -from csv_batch import csvBatch # type: ignore[import-not-found] -from home_page import HomeWindow # type: ignore[import-not-found] -from new_batch import newBatch # type: ignore[import-not-found] +import home_page # type: ignore[import-not-found] +import csv_batch # type: ignore[import-not-found] +import new_batch # type: ignore[import-not-found] def submit_results(clicked_button: str) -> None: @@ -29,7 +29,6 @@ def submit_results(clicked_button: str) -> None: def handle_user_choice() -> None: """ Collect user choice and transmits it to de function that shows the correct window. - ;C:\users\edouard\Local Settings\Application Data\Programs\Python\Python38\Scripts Args: None @@ -49,14 +48,14 @@ def show_selected_window(choice: str) -> None: new_batch_window = tk.Toplevel(root) new_batch_window.title("Create new batch") # Show the window for a new batch - newBatch(new_batch_window, root) + new_batch.newBatch(new_batch_window, root) elif choice == "csv": # Create a new Toplevel window for the new batch csv_batch_window = tk.Toplevel(root) csv_batch_window.minsize(300, 200) csv_batch_window.title("Import csv batch") # Show the window for a new batch - csvBatch(csv_batch_window, root) + csv_batch.csvBatch(csv_batch_window, root) else: # Handle the case of an unknown choice print("Unknown error, please try again with other parameters.") @@ -68,7 +67,7 @@ def show_selected_window(choice: str) -> None: root.minsize(600, 600) # Create an instance of the HomeWindow class -home_page = HomeWindow(root) +home_page = home_page.HomeWindow(root) # Display the HomeWindow home_page.pack()