银行管理系统python+tkinter
时间: 2023-12-16 14:27:29 浏览: 261
基于Tkinter+Python的可视化银行管理系统可以实现开户、查询、取款、存款、转账、销户、改密等功能。以下是一个简单的实现示例:
```python
import tkinter as tk
class BankSystem:
def __init__(self, master):
self.master = master
self.master.title("银行管理系统")
self.master.geometry("400x300")
self.label = tk.Label(self.master, text="欢迎使用银行管理系统", font=("Arial", 16))
self.label.pack(pady=20)
self.button1 = tk.Button(self.master, text="开户", width=10, command=self.open_account)
self.button1.pack(pady=10)
self.button2 = tk.Button(self.master, text="查询", width=10, command=self.check_account)
self.button2.pack(pady=10)
self.button3 = tk.Button(self.master, text="取款", width=10, command=self.withdraw)
self.button3.pack(pady=10)
self.button4 = tk.Button(self.master, text="存款", width=10, command=self.deposit)
self.button4.pack(pady=10)
self.button5 = tk.Button(self.master, text="转账", width=10, command=self.transfer)
self.button5.pack(pady=10)
self.button6 = tk.Button(self.master, text="销户", width=10, command=self.close_account)
self.button6.pack(pady=10)
self.button7 = tk.Button(self.master, text="改密", width=10, command=self.change_password)
self.button7.pack(pady=10)
def open_account(self):
# 实现开户功能
pass
def check_account(self):
# 实现查询功能
pass
def withdraw(self):
# 实现取款功能
pass
def deposit(self):
# 实现存款功能
pass
def transfer(self):
# 实现转账功能
pass
def close_account(self):
# 实现销户功能
pass
def change_password(self):
# 实现改密功能
pass
root = tk.Tk()
bank_system = BankSystem(root)
root.mainloop()
```
阅读全文