195 // Click on a link into the popup "link to" or other dropdown that ask to close drop down on element click, so close dropdown
196 $(".dropdowncloseonclick").on(\'click\', function () {
197 console.log("Link has class dropdowncloseonclick, so we close/hide the popup ul");
198 //$(this).parent().parent().hide(); // $(this).parent().parent() is ul
199 $(this).parent().parent().removeClass("open"); // $(this).parent().parent() is ul
200 });
201
202 // Click outside of any dropdown
203 $(document).bind(\'click\', function (e) {
204 var $clicked = $(e.target); // This is element we click on
205 if (!$clicked.parents().hasClass("dropdown")) {
206 //console.log("close dropdown dd ul - we click outside");
207 //$(".dropdown dd ul").hide();
208 $(".dropdown dd ul").removeClass("open");
209
210 if ($("input:hidden[name=formfilteraction]").val() == "listafterchangingselectedfields") {
211 console.log("resubmit form saved into lastopendropdown after clicking outside of dropdown and having change selectlist from selectlist field of hamburger dropdown");
259 console.log("We click on tag with .reposition class. this.ref is now "+this.href);
260 }
261 else
262 {
263 console.log("We click on tag with .reposition class but element is not an <a> html tag, so we try to update input form field with name=page_y with value "+page_y);