From eaf9f4a082013ffa6f3b897b53168e05bced739e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tam=C3=A1s=20Gul=C3=A1csi?= Date: Sun, 26 Sep 2021 09:54:11 +0200 Subject: [PATCH] Filter showed statuses with status_board_order --- Taskodrome/pages/main.php | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Taskodrome/pages/main.php b/Taskodrome/pages/main.php index b18f0b3..665953f 100644 --- a/Taskodrome/pages/main.php +++ b/Taskodrome/pages/main.php @@ -64,6 +64,8 @@ function write_bug_rows( $p_rows ) print $users; + $t_status_board_order = plugin_config_get("status_board_order", null, false, null, $current_project_id); + $t_allowed_statuses = array_flip( $t_status_board_order ); $t_all_statuses = array(); $t_status_colors = array(); $t_rows = count( $p_rows ); @@ -71,7 +73,8 @@ function write_bug_rows( $p_rows ) $t_row = $p_rows[$i]; $handler_id = $t_row->handler_id; - if (!array_key_exists($t_row->handler_id, $alive_user_ids)) + if (!array_key_exists($t_row->handler_id, $alive_user_ids) || + !array_key_exists($t_row->status, $t_allowed_statuses)) { continue; } @@ -159,7 +162,7 @@ function write_bug_rows( $p_rows ) print '

'; $status_order = null; - foreach( convertStatusEnumToString( plugin_config_get("status_board_order", null, false, null, $current_project_id)) as $t_value ) { + foreach( convertStatusEnumToString( $t_status_board_order ) as $t_value ) { $status_order .= $t_value.';'; }