1
This commit is contained in:
@@ -347,6 +347,7 @@ async def export_team_credit_records(
|
||||
# 生成 CSV(兼容 Excel 打开)
|
||||
import csv
|
||||
import io
|
||||
from datetime import datetime
|
||||
|
||||
output = io.StringIO()
|
||||
writer = csv.writer(output)
|
||||
@@ -359,7 +360,7 @@ async def export_team_credit_records(
|
||||
item.get("amount", 0),
|
||||
item.get("balance_after", 0),
|
||||
item.get("description") or "-",
|
||||
item.get("created_at") or "-",
|
||||
datetime.fromisoformat(item.get("created_at") or "-").strftime("%Y-%m-%d %H:%M:%S"),
|
||||
])
|
||||
|
||||
from starlette.responses import StreamingResponse
|
||||
|
||||
Reference in New Issue
Block a user