]> git.wh0rd.org Git - tt-rss.git/commitdiff
tweak filter list display
authorAndrew Dolgov <fox@madoka.spb.ru>
Tue, 16 Dec 2008 07:21:35 +0000 (08:21 +0100)
committerAndrew Dolgov <fox@madoka.spb.ru>
Tue, 16 Dec 2008 07:21:35 +0000 (08:21 +0100)
modules/pref-filters.php

index d0e12f31fac78af5d4214685576f00934e304d6b..f30d772bcbbf4a12eacc1f9bb6102c9a85b2cd22 100644 (file)
                                enabled,
                                inverse,
                                feed_id,
+                               filter_param,
                                filter_type,
                                ttrss_filter_actions.description AS action_description,
                                ttrss_feeds.title AS feed_title,
                                print "<td align='center'><input onclick='toggleSelectPrefRow(this, \"filter\");' 
                                        type=\"checkbox\" id=\"FICHK-".$line["id"]."\"></td>";
 
+                               $filter_params = array(
+                                       "before" => __("before"),
+                                       "after" => __("after"));
+       
+                               if ($line["filter_type"] == 5) {
+
+                                       if (!strtotime($line["reg_exp"])) {
+                                               $line["reg_exp"] = "<span class=\"filterDateError\">" . 
+                                                       $line["reg_exp"] . "</span>";
+                                       }
+
+                                       $line["reg_exp"] = __("Date") . " " . 
+                                               $filter_params[$line['filter_param']] . " " .
+                                               $line["reg_exp"];
+                               }
+
                                if (!$enabled) {
                                        $line["reg_exp"] = "<span class=\"insensitive\">" . 
                                                $line["reg_exp"] . " " .  __("(Disabled)")."</span>";
 
                                $onclick = "onclick='editFilter($filter_id)' title='".__('Click to edit')."'";
 
-                               if ($line["filter_type"] == 5 && !strtotime($line["reg_exp"])) {
-                                       $line["reg_exp"] = "<span class=\"filterDateError\">" . 
-                                               $line["reg_exp"] . "</span>";
-                               }
-
                                $inverse_label = "";
 
                                if ($inverse) {