Python-Menu/main.py
2025-12-07 18:19:21 +07:00

28 lines
693 B
Python

import tkinter as tk
from database import setup
from screens.login_screen import LoginScreen
# Setup database saat awal run
setup()
class CafeApp(tk.Tk):
def __init__(self):
super().__init__()
self.title("Cafe Application - Tkinter")
self.geometry("900x600")
self.resizable(False, False)
# Frame container
self.container = tk.Frame(self)
self.container.pack(fill="both", expand=True)
self.show_login()
def show_login(self):
for widget in self.container.winfo_children():
widget.destroy()
LoginScreen(self.container, self)
if __name__ == "__main__":
app = CafeApp()
app.mainloop()