Эх сурвалжийг харах

[core] Rowselector jQuery plugin exclude element parameter

Added possibility to avoid firing of the row click with a
data-row-selector-exclude="true" param
Enrico Berti 13 жил өмнө
parent
commit
6c9657b

+ 3 - 0
desktop/core/static/js/Source/jHue/jquery.rowselector.js

@@ -23,6 +23,9 @@
 	Plugin.prototype.init = function () {
 		var _this = this;		
         $(_this.element).closest("tr").click(function(e){
+            if ($(e.target).data("row-selector-exclude")){
+                return;
+            }
             if (!$(e.target).is("a")){
                 if ($.trim($(_this.element).attr("href")) != ""){
                     location.href = $(_this.element).attr("href");