初次提交

This commit is contained in:
2025-10-14 20:05:29 +08:00
commit 6e4e48fdd2
673 changed files with 437006 additions and 0 deletions

View File

@@ -0,0 +1,20 @@
from app.core.database import SessionLocal
from app.models.user import User
def cleanup_test_user():
"""清理测试用户"""
db = SessionLocal()
try:
# 删除测试用户
test_user = db.query(User).filter(User.username == "peng").first()
if test_user:
db.delete(test_user)
db.commit()
print("已删除测试用户 'peng'")
else:
print("未找到测试用户 'peng'")
finally:
db.close()
if __name__ == "__main__":
cleanup_test_user()