[bitbake-devel] [PATCH 7/7] toaster: filtersnippet remove redefinition of filter type key

Alex DAMIAN alexandru.damian at intel.com
Fri May 1 16:40:46 UTC 2015


From: Michael Wood <michael.g.wood at intel.com>

This redefinition is not needed and also used Mozilla specific API to
access the data thus breaking the date filter in all other browsers.

[YOCTO #7577]

Signed-off-by: Michael Wood <michael.g.wood at intel.com>
---
 lib/toaster/toastergui/static/js/filtersnippet.js | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/lib/toaster/toastergui/static/js/filtersnippet.js b/lib/toaster/toastergui/static/js/filtersnippet.js
index 27b057e..2b84c54 100755
--- a/lib/toaster/toastergui/static/js/filtersnippet.js
+++ b/lib/toaster/toastergui/static/js/filtersnippet.js
@@ -80,8 +80,7 @@ function date_init (key, from_date, to_date, min_date, max_date, initial_enable)
     $("form").unbind('submit');
     $("form").submit(function(e) {
         // format a composite daterange filter value so that it can be parsed and post-processed in the view
-        var key=e.originalEvent.explicitOriginalTarget.getAttribute("data-key")
-        if (typeof key != "undefined") {
+        if (key !== undefined) {
             if ($("#date_from_"+key).length) {
                 var filter=key+"__gte!"+key+"__lt:"+$("#date_from_"+key).val()+"!"+$("#date_to_"+key).val()+"_daterange";
                 $("#last_date_from_"+key).val($("#date_from_"+key).val());
-- 
1.9.1




More information about the bitbake-devel mailing list