Compare commits

..

No commits in common. "d10f32519eb931dea18a0da864db2d379d9a9d9f" and "ce795b02e613091fa8d05a69c2d59319b046ac6b" have entirely different histories.

9 changed files with 5 additions and 12 deletions

2
.gitignore vendored
View File

@ -4,4 +4,4 @@
__pycache__ __pycache__
**/__pycache__ **/__pycache__
static/temp/ static

View File

@ -22,12 +22,7 @@ async def insert_group_chat(supervisor: str, members: list[str]) -> GroupChat:
try: try:
group_chat_res = await session.scalars( group_chat_res = await session.scalars(
insert(GroupChat) insert(GroupChat)
.values( .values(id=id, name=name, supervisor=supervisor, members=members)
id=id,
name=name,
supervisor=supervisor,
members=members,
)
.returning(GroupChat) .returning(GroupChat)
) )
contact_res: ScalarResult[Contact] = await session.scalars( contact_res: ScalarResult[Contact] = await session.scalars(

View File

@ -54,9 +54,7 @@ class UserProfile(Base):
location: Mapped[str] = mapped_column(String, nullable=True) location: Mapped[str] = mapped_column(String, nullable=True)
status: Mapped[str] = mapped_column(String, nullable=True) status: Mapped[str] = mapped_column(String, nullable=True)
sign: Mapped[str] = mapped_column(String, nullable=True) sign: Mapped[str] = mapped_column(String, nullable=True)
avatar: Mapped[str] = mapped_column( avatar: Mapped[str] = mapped_column(String, nullable=True, default="user.png")
String, nullable=True, default="default_user_avatar.png"
)
user_id: Mapped[str] = mapped_column( user_id: Mapped[str] = mapped_column(
ForeignKey("user_account.id", ondelete="CASCADE") ForeignKey("user_account.id", ondelete="CASCADE")
) )
@ -148,7 +146,7 @@ class GroupChat(Base):
introduction: Mapped[str] = mapped_column(String(100), default="") introduction: Mapped[str] = mapped_column(String(100), default="")
tags: Mapped[list[str]] = mapped_column(ARRAY(String), default=[]) tags: Mapped[list[str]] = mapped_column(ARRAY(String), default=[])
noticeboard: Mapped[list[dict]] = mapped_column(JSONB, default=[]) noticeboard: Mapped[list[dict]] = mapped_column(JSONB, default=[])
avatar: Mapped[str] = mapped_column(String, default="default_group_avatar.png") avatar: Mapped[str] = mapped_column(String, default="Logo_light.png")
created_at: Mapped[datetime] = mapped_column( created_at: Mapped[datetime] = mapped_column(
default=datetime.now, onupdate=datetime.now default=datetime.now, onupdate=datetime.now
) )

View File

@ -6,7 +6,7 @@ from src.database.redis_api import redis_server
host = "smtp.163.com" host = "smtp.163.com"
username = "together_app@163.com" username = "together_app@163.com"
password = "ZHHLUQSTDTQSBEQZ" password = "AGBEYAOHPTAHHMKK"
smtp = SMTP(host=host) smtp = SMTP(host=host)
smtp.ehlo() smtp.ehlo()

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 70 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 107 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.6 MiB