From dcfe6bf86535bcf38592e8125fe551316834c38e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nguy=E1=BB=85n=20Minh?= <w11220031@st.phenikaa-uni.edu.vn> Date: Wed, 2 Apr 2025 13:22:07 +0700 Subject: [PATCH] adjust image path in login.py --- app/frontend/components/auth/login.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/frontend/components/auth/login.py b/app/frontend/components/auth/login.py index ac8cbb3..bc8da11 100644 --- a/app/frontend/components/auth/login.py +++ b/app/frontend/components/auth/login.py @@ -1,4 +1,5 @@ import customtkinter as ctk +import os from tkinter import messagebox from PIL import Image from utils.api_requests import login_api @@ -15,7 +16,7 @@ def login_frame(parent, switch_func, API_URL): left_frame = ctk.CTkFrame(container, fg_color="transparent") left_frame.grid(row=0, column=0, sticky="nsew") - image_path = "../../app/static/front_end_img/login.jpg" + image_path = os.path.abspath("app/static/front_end_img/login.jpg") img = ctk.CTkImage(light_image=Image.open(image_path), size=(800, 800)) image_label = ctk.CTkLabel(left_frame, image=img, text="") image_label.place(relwidth=1, relheight=1) -- GitLab