Fix:尝试修复筛选最近10天数据的bug #12

Merged
longbot merged 1 commits from longbot/API:Fix-sql-date-error into main 2025-08-29 10:02:50 +00:00
1 changed files with 1 additions and 1 deletions
Showing only changes of commit 6c65f5be85 - Show all commits

View File

@ -638,7 +638,7 @@ export class OrderService {
totalQuery += ` AND o.date_created >= ?`; totalQuery += ` AND o.date_created >= ?`;
const tenDaysAgo = new Date(); const tenDaysAgo = new Date();
tenDaysAgo.setDate(tenDaysAgo.getDate() - 10); tenDaysAgo.setDate(tenDaysAgo.getDate() - 10);
parameters.push(new Date(tenDaysAgo).toISOString().substring(0, 10)); parameters.push(tenDaysAgo.toISOString());
} }
// 处理 status 参数 // 处理 status 参数