Skip to content

Commit 18ae0d8

Browse files
committed
trust_level
1 parent 9bfdcf3 commit 18ae0d8

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

userdata_api/utils/admin.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ async def get_user_info(user_id: int, user: dict[str, int | list[dict[str, str |
6464
is_union_member = (
6565
db.session.query(Info)
6666
.join(Info.param)
67+
.join(Info.source)
6768
.filter(Info.owner_id == user_id, Param.name == "Членство в профсоюзе")
6869
.order_by(Source.trust_level.desc())
6970
.order_by(Info.create_ts.desc())
@@ -72,6 +73,7 @@ async def get_user_info(user_id: int, user: dict[str, int | list[dict[str, str |
7273
student_card_number = (
7374
db.session.query(Info)
7475
.join(Info.param)
76+
.join(Info.source)
7577
.filter(Info.owner_id == user_id, Param.name == "Номер студенческого билета")
7678
.order_by(Source.trust_level.desc())
7779
.order_by(Info.create_ts.desc())
@@ -80,6 +82,7 @@ async def get_user_info(user_id: int, user: dict[str, int | list[dict[str, str |
8082
union_card_number = (
8183
db.session.query(Info)
8284
.join(Info.param)
85+
.join(Info.source)
8386
.filter(Info.owner_id == user_id, Param.name == "Номер профсоюзного билета")
8487
.order_by(Source.trust_level.desc())
8588
.order_by(Info.create_ts.desc())

0 commit comments

Comments
 (0)