|
@@ -110,7 +110,7 @@ async def get_data_list(table_id: int,page: int = Query(1, gt=0, description='
|
|
schema_name = table_structure["schema_name"]
|
|
schema_name = table_structure["schema_name"]
|
|
columns = [col["column_name"] for col in table_structure["columns"]]
|
|
columns = [col["column_name"] for col in table_structure["columns"]]
|
|
|
|
|
|
- sql = f"SELECT {', '.join(columns)} FROM `{schema_name}`.`{table_name}` where del_flag='0'"
|
|
|
|
|
|
+ sql = f"SELECT {', '.join(columns)} FROM `{schema_name}`.`{table_name}` where del_flag='0' order by update_time desc"
|
|
totalsql = f'select count(*) from ({sql})t'
|
|
totalsql = f'select count(*) from ({sql})t'
|
|
|
|
|
|
total = db.execute(text(totalsql)).fetchone()[0]
|
|
total = db.execute(text(totalsql)).fetchone()[0]
|