fix: Do not require start and end date time for execution filters

This commit is contained in:
Faruk AYDIN
2025-03-28 16:16:01 +01:00
parent f7e81ec687
commit 9b5f33058c

View File

@@ -591,13 +591,15 @@ class User extends Base {
builder.where('executions.status', 'failure');
}
if (startDateTime && endDateTime) {
if (startDateTime) {
const startDate = DateTime.fromMillis(Number(startDateTime));
if (startDate.isValid) {
builder.where('executions.created_at', '>=', startDate.toISO());
}
}
if (endDateTime) {
const endDate = DateTime.fromMillis(Number(endDateTime));
if (endDate.isValid) {