[Buildroot] [PATCH buildroot-test 2/2] web/index.php: allow filtering by date

Victor Huesca victor.huesca at bootlin.com
Tue Aug 13 07:08:22 UTC 2019


This patch provide a way to pass a date as part of the filter. This date
can be either a single date or a couple 'start and end' dates as an
associative array to cover every case:

Example: "date[from]=2019-03-03&date[to]=2019-07-21"

Signed-off-by: Victor Huesca <victor.huesca at bootlin.com>
---
 web/index.php | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/web/index.php b/web/index.php
index 939cac5..0c79aa6 100644
--- a/web/index.php
+++ b/web/index.php
@@ -59,6 +59,9 @@ if (isset($_GET['subarch']) && preg_match("/^[A-Za-z0-9_\+\.\-]*$/", $_GET['suba
 if (isset ($_GET['submitter']))
   $filters["submitter"] = urldecode($_GET['submitter']);
 
+if (isset($_GET['date']))
+  $filters["date"] = $_GET['date'];
+
 bab_header("Buildroot tests");
 
 echo "<table>\n";
-- 
2.21.0




More information about the buildroot mailing list