ezKit 1.12.43__py3-none-any.whl → 1.12.44__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- ezKit/database.py +4 -2
- {ezkit-1.12.43.dist-info → ezkit-1.12.44.dist-info}/METADATA +1 -1
- {ezkit-1.12.43.dist-info → ezkit-1.12.44.dist-info}/RECORD +6 -6
- {ezkit-1.12.43.dist-info → ezkit-1.12.44.dist-info}/WHEEL +0 -0
- {ezkit-1.12.43.dist-info → ezkit-1.12.44.dist-info}/licenses/LICENSE +0 -0
- {ezkit-1.12.43.dist-info → ezkit-1.12.44.dist-info}/top_level.txt +0 -0
ezKit/database.py
CHANGED
@@ -790,7 +790,7 @@ async def async_create_and_count(db: DatabaseAsyncSession, schema: Type[Declarat
|
|
790
790
|
# --------------------------------------------------------------------------------------------------
|
791
791
|
|
792
792
|
|
793
|
-
async def async_read_and_count(db: DatabaseAsyncSession,
|
793
|
+
async def async_read_and_count(db: DatabaseAsyncSession, data: dict, statement_prefix: str, statement_end: str = "") -> dict:
|
794
794
|
|
795
795
|
# 初始返回结果 (适用于 count 等于 0)
|
796
796
|
result = {"count": 0, "list": [], "pageIndex": data["pageIndex"], "pageSize": 0}
|
@@ -810,7 +810,9 @@ async def async_read_and_count(db: DatabaseAsyncSession, table_name: str, data:
|
|
810
810
|
|
811
811
|
# 统计 WHERE
|
812
812
|
|
813
|
-
|
813
|
+
# table_name: str
|
814
|
+
# count_statement = text(f"SELECT COUNT(*) FROM {table_name} {where_clause}").bindparams(*bind_params)
|
815
|
+
count_statement = text(f"SELECT COUNT(*) FROM ({statement_prefix} {where_clause})").bindparams(*bind_params)
|
814
816
|
|
815
817
|
count_result = await db.operate_return_scalar_one(count_statement, statement_params)
|
816
818
|
|
@@ -4,7 +4,7 @@ ezKit/auth.py,sha256=HO19O4qOz68e0YwOP04habxMCAk42B3D7LW7yKgm9ZA,398
|
|
4
4
|
ezKit/bottle.py,sha256=43h4v1kzz6qrLvCt5IMN0H-gFtaT0koG9wETqteXsps,181666
|
5
5
|
ezKit/bottle_extensions.py,sha256=27rogmfK7mL2qUSjXH79IMGZbCVULtYEikql_N9O6Zs,1165
|
6
6
|
ezKit/cipher.py,sha256=7jBarRH7ukSYzkz-Anl8B8JzluhnRz4CLHidPRRj_cg,2939
|
7
|
-
ezKit/database.py,sha256=
|
7
|
+
ezKit/database.py,sha256=nYvh0mv1nPgJbFb3k5sheN7QS5IBTpCnqjYxINnX1As,32666
|
8
8
|
ezKit/dockerhub.py,sha256=j-wQO-71BsOgExHZhYynuy2k_hCX3on-vg0TH7QCit4,1996
|
9
9
|
ezKit/errors.py,sha256=92PggwPQfTS3Vg4og7GHYnO9CTSM7zmuh2w3kx_tSBE,1425
|
10
10
|
ezKit/fastapix.py,sha256=-nz565ASKvp3nGs9J4wORTHxlhMozqCwv8zREWpmYtI,3382
|
@@ -18,8 +18,8 @@ ezKit/token.py,sha256=Ac-i9xfq4TqpGyfCzakjrh4NYzxHiN2sCQrMk1tzVi8,1716
|
|
18
18
|
ezKit/utils.py,sha256=U457ahFkxIXuB-qWvS3995xJs-LlkFIX5_ZWVgmL5cY,43130
|
19
19
|
ezKit/xftp.py,sha256=-XQXyhMqeigT63P6sXkSS7r4GROXyqqlkzKxITLWG-g,8278
|
20
20
|
ezKit/zabbix.py,sha256=PkMnfu7mcuotwwIIsHaC9FsNg-gap6hD1xvm0AwSL1Y,33777
|
21
|
-
ezkit-1.12.
|
22
|
-
ezkit-1.12.
|
23
|
-
ezkit-1.12.
|
24
|
-
ezkit-1.12.
|
25
|
-
ezkit-1.12.
|
21
|
+
ezkit-1.12.44.dist-info/licenses/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
|
22
|
+
ezkit-1.12.44.dist-info/METADATA,sha256=jw1B3wvM_rwcY8ae71N-MM2QY2I3XEmhKn5eStoVWwA,317
|
23
|
+
ezkit-1.12.44.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
24
|
+
ezkit-1.12.44.dist-info/top_level.txt,sha256=aYLB_1WODsqNTsTFWcKP-BN0KCTKcV-HZJ4zlHkCFw8,6
|
25
|
+
ezkit-1.12.44.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|