src/pyams_skin/resources/js/myams-require.min.js
changeset 536 d1742b03d5a7
parent 514 824f546d4a67
child 553 644d0f6f6503
--- a/src/pyams_skin/resources/js/myams-require.min.js	Fri Jul 26 12:42:05 2019 +0200
+++ b/src/pyams_skin/resources/js/myams-require.min.js	Fri Jul 26 12:42:35 2019 +0200
@@ -1,1 +1,1 @@
-"use strict";!function(e,t){var r=t.console;String.prototype.startsWith=function(e){var t=this.length,r=e.length;return!(t<r)&&this.substr(0,r)===e},String.prototype.endsWith=function(e){var t=this.length,r=e.length;return!(t<r)&&this.substr(t-r)===e},String.prototype.unserialize=function(e){for(var t=decodeURIComponent(this).split("&"),r={},n=0;n<t.length;n++){var o=t[n].split("=",2);r[o[0]]=o[1]}return r},Array.prototype.indexOf||(Array.prototype.indexOf=function(e,t){var r=this.length;for((t=(t=Number(t)||0)<0?Math.ceil(t):Math.floor(t))<0&&(t+=r);t<r;t++)if(t in this&&this[t]===e)return t;return-1}),e.expr[":"].hasvalue=function(t,r,n){return""!==e(t).val()},e.expr[":"].econtains=function(t,r,n){return(t.textContent||t.innerText||e(t).text()||"").toLowerCase()===n[3].toLowerCase()},e.expr[":"].withtext=function(t,r,n){return(t.textContent||t.innerText||e(t).text()||"")===n[3]},e.expr[":"].parents=function(t,r,n){return e(t).parents(n[3]).length>0},void 0===e.scrollbarWidth&&(e.scrollbarWidth=function(){var t=e('<div style="width: 50px; height: 50px; overflow: auto"><div/></div>').appendTo("body"),r=t.children(),n=r.innerWidth()-r.height(99).innerWidth();return t.remove(),n}),e.fn.extend({exists:function(){return e(this).length>0},objectOrParentWithClass:function(e){return this.hasClass(e)?this:this.parents("."+e)},listattr:function(t){var r=[];return this.each(function(){r.push(e(this).attr(t))}),r},style:function(e,t,r){if(void 0!==this.get(0)){var n=this.get(0).style;return void 0!==e?void 0!==t?(r=void 0!==r?r:"",n.setProperty(e,t,r),this):n.getPropertyValue(e):n}},removeClassPrefix:function(t){return this.each(function(r,n){var o=n.className.split(" ").map(function(e){return e.startsWith(t)?"":e});n.className=e.trim(o.join(" "))}),this}}),void 0===t.MyAMS&&(t.MyAMS={devmode:!0,devext:"",lang:"en",throttleDelay:350,menuSpeed:235,navbarHeight:49,ajaxNav:!0,safeMethods:["GET","HEAD","OPTIONS","TRACE"],csrfCookieName:"csrf_token",csrfHeaderName:"X-CSRF-Token",enableWidgets:!0,enableMobile:!1,enableFastclick:!1,warnOnFormChange:!1,ismobile:/iphone|ipad|ipod|android|blackberry|mini|windows\sce|palm/i.test(navigator.userAgent.toLowerCase())});var n=t.MyAMS,o=n;n.baseURL=function(){var t=e('script[src*="/myams.js"], script[src*="/myams.min.js"], script[src*="/myams-core.js"], script[src*="/myams-core.min.js"], script[src*="/myams-require.js"], script[src*="/myams-require.min.js"]').attr("src");return o.devmode=t.indexOf(".min.js")<0,o.devext=o.devmode?"":".min",t.substring(0,t.lastIndexOf("/")+1)}(),n.log=function(){r&&r.debug&&r.debug(this,arguments)},n.getQueryVar=function(e,t){if(e.indexOf("?")<0)return!1;e.endsWith("&")||(e+="&");var r=new RegExp(".*?[&\\?]"+t+"=(.*?)&.*"),n=e.replace(r,"$1");return n!==e&&n},n.rgb2hex=function(t){return"#"+e.map(t.match(/\b(\d+)\b/g),function(e){return("0"+parseInt(e).toString(16)).slice(-2)}).join("")},n.generateId=function(){function e(){return Math.floor(65536*(1+Math.random())).toString(16).substring(1)}return e()+e()+e()+e()},n.generateUUID=function(){var e=(new Date).getTime();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(t){var r=(e+16*Math.random())%16|0;return e=Math.floor(e/16),("x"===t?r:3&r|8).toString(16)})},n.getObject=function(e,t){if(e){if("string"!=typeof e)return e;var r=e.split(".");t=void 0===t||null===t?window:t;for(var n=0;n<r.length;n++)try{t=t[r[n]]}catch(e){return}return t}},n.getFunctionByName=function(e,t){if(void 0!==e){if("function"==typeof e)return e;var r=e.split("."),n=r.pop();t=void 0===t||null===t?window:t;for(var o=0;o<r.length;o++)try{t=t[r[o]]}catch(e){return}try{return t[n]}catch(e){return}}},n.executeFunctionByName=function(e,t){var r=o.getFunctionByName(e,window);if("function"==typeof r){var n=Array.prototype.slice.call(arguments,2);return r.apply(t,n)}},n.isInDOM=function(r){return!!(r=e(r)).exists()&&t.document.body.contains(r[0])},n.getSource=function(e){return e.replace(/{[^{}]*}/g,function(e){return o.getFunctionByName(e.substr(1,e.length-2))})},n.getScript=function(t,r,n,i){"object"==typeof r&&(i=n,n=r,r=null),void 0===n&&(n={});var a={dataType:"script",url:o.getSource(t),success:r,error:i||o.error.show,cache:!o.devmode,async:void 0===n.async?"function"==typeof r:n.async},s=e.extend({},a,n);return e.ajax(s)},n.getCSS=function(t,r,n,i){n&&(n=o.getFunctionByName(n));var a=e("HEAD"),s=e('style[data-ams-id="'+r+'"]',a);if(0===s.length){if(s=e("<style>").attr("data-ams-id",r).text('@import "'+o.getSource(t)+'";'),n)var c=setInterval(function(){try{s[0].sheet.cssRules;n.call(window,!0,i),clearInterval(c)}catch(e){}},10);s.appendTo(a)}else n&&n.call(window,!1,i)}}(jQuery,this),function(e,t){t.MyAMS.i18n={INFO:"Information",WARNING:"!! WARNING !!",ERROR:"ERROR: ",LOADING:"Loading...",PROGRESS:"Processing",WAIT:"Please wait!",FORM_SUBMITTED:"This form was already submitted...",NO_SERVER_RESPONSE:"No response from server!",ERROR_OCCURED:"An error occured!",ERRORS_OCCURED:"Some errors occured!",BAD_LOGIN_TITLE:"Bad login!",BAD_LOGIN_MESSAGE:"Your anthentication credentials didn't allow you to open a session; please check your credentials or contact administrator.",CONFIRM:"Confirm",CONFIRM_REMOVE:"Removing this content can't be undone. Do you confirm?",CLEAR_STORAGE_TITLE:"Clear Local Storage",CLEAR_STORAGE_CONTENT:"Would you like to RESET all your saved widgets and clear LocalStorage?",BTN_OK:"OK",BTN_CANCEL:"Cancel",BTN_OK_CANCEL:"[OK][Cancel]",BTN_YES:"Yes",BTN_NO:"No",BTN_YES_NO:"[Yes][No]",CLIPBOARD_COPY:"Copy to clipboard with Ctrl+C, and Enter",CLIPBOARD_CHARACTER_COPY_OK:"Character copied to clipboard",CLIPBOARD_TEXT_COPY_OK:"Text copied to clipboard",FORM_CHANGED_WARNING:"Some changes were not saved. These updates will be lost if you leave this page.",DELETE_WARNING:"This change can't be undone. Are you sure that you want to delete this element?",NO_UPDATE:"No changes were applied.",DATA_UPDATED:"Data successfully updated.",HOME:"Home",LOGOUT:"Logout?",LOGOUT_COMMENT:"You can improve your security further after logging out by closing this opened browser",SELECT2_PLURAL:"s",SELECT2_MATCH:"One result is available, press enter to select it.",SELECT2_MATCHES:" results are available, use up and down arrow keys to navigate.",SELECT2_NOMATCHES:"No matches found",SELECT2_SEARCHING:"Searching...",SELECT2_LOADMORE:"Loading more results...",SELECT2_INPUT_TOOSHORT:"Please enter {0} more character{1}",SELECT2_INPUT_TOOLONG:"Please delete {0} character{1}",SELECT2_SELECTION_TOOBIG:"You can only select {0} item{1}",SELECT2_FREETAG_PREFIX:"Free text: ",DT_COLUMNS:"Columns"}}(jQuery,this),function(e,t){var r=t.MyAMS,n=[];r.require=function(t,o){for(var i=[],a=0;a<t.length;a++){var s=t[a];if(n.indexOf(s)<0){var c=r.baseURL+"myams-"+s+r.devext+".js";i.push(r.getScript(c,{async:!0},console.error)),n.push(s)}}i.length>0?e.when.apply(e,i).then(function(){o()}):o()}}(jQuery,this);
+"use strict";!function(e,t){var n=t.console;String.prototype.startsWith=function(e){var t=this.length,n=e.length;return!(t<n)&&this.substr(0,n)===e},String.prototype.endsWith=function(e){var t=this.length,n=e.length;return!(t<n)&&this.substr(t-n)===e},String.prototype.unserialize=function(e){for(var t=decodeURIComponent(this).split("&"),n={},r=0;r<t.length;r++){var a=t[r].split("=",2);n[a[0]]=a[1]}return n},Array.prototype.indexOf||(Array.prototype.indexOf=function(e,t){var n=this.length;for((t=(t=Number(t)||0)<0?Math.ceil(t):Math.floor(t))<0&&(t+=n);t<n;t++)if(t in this&&this[t]===e)return t;return-1}),e.expr[":"].hasvalue=function(t,n,r){return""!==e(t).val()},e.expr[":"].econtains=function(t,n,r){return(t.textContent||t.innerText||e(t).text()||"").toLowerCase()===r[3].toLowerCase()},e.expr[":"].withtext=function(t,n,r){return(t.textContent||t.innerText||e(t).text()||"")===r[3]},e.expr[":"].parents=function(t,n,r){return e(t).parents(r[3]).length>0},void 0===e.scrollbarWidth&&(e.scrollbarWidth=function(){var t=e('<div style="width: 50px; height: 50px; overflow: auto"><div/></div>').appendTo("body"),n=t.children(),r=n.innerWidth()-n.height(99).innerWidth();return t.remove(),r}),e.fn.extend({exists:function(){return e(this).length>0},objectOrParentWithClass:function(e){return this.hasClass(e)?this:this.parents("."+e)},listattr:function(t){var n=[];return this.each(function(){n.push(e(this).attr(t))}),n},style:function(e,t,n){if(void 0!==this.get(0)){var r=this.get(0).style;return void 0!==e?void 0!==t?(n=void 0!==n?n:"",r.setProperty(e,t,n),this):r.getPropertyValue(e):r}},removeClassPrefix:function(t){return this.each(function(n,r){var a=r.className.split(" ").map(function(e){return e.startsWith(t)?"":e});r.className=e.trim(a.join(" "))}),this}}),void 0===t.MyAMS&&(t.MyAMS={devmode:!0,devext:"",lang:"en",throttleDelay:350,menuSpeed:235,navbarHeight:49,ajaxNav:!0,safeMethods:["GET","HEAD","OPTIONS","TRACE"],csrfCookieName:"csrf_token",csrfHeaderName:"X-CSRF-Token",enableWidgets:!0,enableMobile:!1,enableFastclick:!1,warnOnFormChange:!1,ismobile:/iphone|ipad|ipod|android|blackberry|mini|windows\sce|palm/i.test(navigator.userAgent.toLowerCase())});var r=t.MyAMS,a=r;r.baseURL=function(){var t=e('script[src*="/myams.js"], script[src*="/myams.min.js"], script[src*="/myams-core.js"], script[src*="/myams-core.min.js"], script[src*="/myams-require.js"], script[src*="/myams-require.min.js"]').attr("src");return a.devmode=t.indexOf(".min.js")<0,a.devext=a.devmode?"":".min",t.substring(0,t.lastIndexOf("/")+1)}(),r.log=function(){n&&n.debug&&n.debug(this,arguments)},r.getQueryVar=function(e,t){if(e.indexOf("?")<0)return!1;e.endsWith("&")||(e+="&");var n=new RegExp(".*?[&\\?]"+t+"=(.*?)&.*"),r=e.replace(n,"$1");return r!==e&&r},r.rgb2hex=function(t){return"#"+e.map(t.match(/\b(\d+)\b/g),function(e){return("0"+parseInt(e).toString(16)).slice(-2)}).join("")},r.generateId=function(){function e(){return Math.floor(65536*(1+Math.random())).toString(16).substring(1)}return e()+e()+e()+e()},r.generateUUID=function(){var e=(new Date).getTime();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(t){var n=(e+16*Math.random())%16|0;return e=Math.floor(e/16),("x"===t?n:3&n|8).toString(16)})},r.getObject=function(e,t){if(e){if("string"!=typeof e)return e;var n=e.split(".");t=void 0===t||null===t?window:t;for(var r=0;r<n.length;r++)try{t=t[n[r]]}catch(e){return}return t}},r.getFunctionByName=function(e,t){if(void 0!==e){if("function"==typeof e)return e;var n=e.split("."),r=n.pop();t=void 0===t||null===t?window:t;for(var a=0;a<n.length;a++)try{t=t[n[a]]}catch(e){return}try{return t[r]}catch(e){return}}},r.executeFunctionByName=function(e,t){var n=a.getFunctionByName(e,window);if("function"==typeof n){var r=Array.prototype.slice.call(arguments,2);return n.apply(t,r)}},r.isInDOM=function(n){return!!(n=e(n)).exists()&&t.document.body.contains(n[0])},r.getSource=function(e){return e.replace(/{[^{}]*}/g,function(e){return a.getFunctionByName(e.substr(1,e.length-2))})},r.getScript=function(t,n,r,i){"object"==typeof n&&(i=r,r=n,n=null),void 0===r&&(r={});var o={dataType:"script",url:a.getSource(t),success:n,error:i||a.error.show,cache:!a.devmode,async:void 0===r.async?"function"==typeof n:r.async},s=e.extend({},o,r);return e.ajax(s)},r.getCSS=function(t,n,r,i){r&&(r=a.getFunctionByName(r));var o=e("HEAD"),s=e('style[data-ams-id="'+n+'"]',o);if(0===s.length){if(s=e("<style>").attr("data-ams-id",n).text('@import "'+a.getSource(t)+'";'),r)var c=setInterval(function(){try{s[0].sheet.cssRules;r.call(window,!0,i),clearInterval(c)}catch(e){}},10);s.appendTo(o)}else r&&r.call(window,!1,i)},r.initHandlers=function(t){e(t).on("click","[data-ams-click-handler]",function(t){var n=e(this),r=n.data("ams-disabled-handlers");if(!0!==r&&"click"!==r&&"all"!==r){var i=n.data();if(i.amsClickHandler){!0!==i.amsStopPropagation&&!0!==i.amsClickStopPropagation||t.stopPropagation(),!0!==i.amsClickKeepDefault&&t.preventDefault();for(var o=i.amsClickHandler.split(/\s+/),s=0;s<o.length;s++){var c=a.getFunctionByName(o[s]);void 0!==c&&c.call(n,t,i.amsClickHandlerOptions)}}}}),e(t).on("change","[data-ams-change-handler]",function(t){var n=e(this);if(!n.prop("readonly")){var r=n.data("ams-disabled-handlers");if(!0!==r&&"change"!==r&&"all"!==r){var i=n.data();if(i.amsChangeHandler){!0!==i.amsStopPropagation&&!0!==i.amsChangeStopPropagation||t.stopPropagation(),!0!==i.amsChangeKeepDefault&&t.preventDefault();for(var o=i.amsChangeHandler.split(/\s+/),s=0;s<o.length;s++){var c=a.getFunctionByName(o[s]);void 0!==c&&c.call(n,t,i.amsChangeHandlerOptions)}}}}}),e(t).on("reset","form",function(t){var n=e(this);setTimeout(function(){e(".alert-danger, SPAN.state-error",n).not(".persistent").remove(),e("LABEL.state-error",n).removeClass("state-error"),e('INPUT.select2[type="hidden"]',n).each(function(){var t=e(this),n=t.data("select2"),r=t.data("ams-select2-input-value");r&&t.select2("val",r.split(n.opts.separator))}),n.find(".select2").trigger("change"),e("[data-ams-reset-callback]",n).each(function(){var t=e(this),r=t.data(),i=a.getFunctionByName(r.amsResetCallback);void 0!==i&&i.call(n,t,r.amsResetCallbackOptions)})},10),a.form&&a.form.setFocus(n)}),e(t).on("reset","[data-ams-reset-handler]",function(t){var n=e(this),r=n.data();if(r.amsResetHandler){!0!==r.amsResetKeepDefault&&t.preventDefault();var i=a.getFunctionByName(r.amsResetHandler);void 0!==i&&i.call(n,r.amsResetHandlerOptions)}}),e(t).on("click","[data-ams-click-event]",function(t){var n=e(this);e(t.target).trigger(n.data("ams-click-event"),n.data("ams-click-event-options"))}),e(t).on("click",'input[type="checkbox"][readonly]',function(){return!1})}}(jQuery,this),function(e,t){t.MyAMS.i18n={INFO:"Information",WARNING:"!! WARNING !!",ERROR:"ERROR: ",LOADING:"Loading...",PROGRESS:"Processing",WAIT:"Please wait!",FORM_SUBMITTED:"This form was already submitted...",NO_SERVER_RESPONSE:"No response from server!",ERROR_OCCURED:"An error occured!",ERRORS_OCCURED:"Some errors occured!",BAD_LOGIN_TITLE:"Bad login!",BAD_LOGIN_MESSAGE:"Your anthentication credentials didn't allow you to open a session; please check your credentials or contact administrator.",CONFIRM:"Confirm",CONFIRM_REMOVE:"Removing this content can't be undone. Do you confirm?",CLEAR_STORAGE_TITLE:"Clear Local Storage",CLEAR_STORAGE_CONTENT:"Would you like to RESET all your saved widgets and clear LocalStorage?",BTN_OK:"OK",BTN_CANCEL:"Cancel",BTN_OK_CANCEL:"[OK][Cancel]",BTN_YES:"Yes",BTN_NO:"No",BTN_YES_NO:"[Yes][No]",CLIPBOARD_COPY:"Copy to clipboard with Ctrl+C, and Enter",CLIPBOARD_CHARACTER_COPY_OK:"Character copied to clipboard",CLIPBOARD_TEXT_COPY_OK:"Text copied to clipboard",FORM_CHANGED_WARNING:"Some changes were not saved. These updates will be lost if you leave this page.",DELETE_WARNING:"This change can't be undone. Are you sure that you want to delete this element?",NO_UPDATE:"No changes were applied.",DATA_UPDATED:"Data successfully updated.",HOME:"Home",LOGOUT:"Logout?",LOGOUT_COMMENT:"You can improve your security further after logging out by closing this opened browser",SELECT2_PLURAL:"s",SELECT2_MATCH:"One result is available, press enter to select it.",SELECT2_MATCHES:" results are available, use up and down arrow keys to navigate.",SELECT2_NOMATCHES:"No matches found",SELECT2_SEARCHING:"Searching...",SELECT2_LOADMORE:"Loading more results...",SELECT2_INPUT_TOOSHORT:"Please enter {0} more character{1}",SELECT2_INPUT_TOOLONG:"Please delete {0} character{1}",SELECT2_SELECTION_TOOBIG:"You can only select {0} item{1}",SELECT2_FREETAG_PREFIX:"Free text: ",DT_COLUMNS:"Columns"}}(jQuery,this),function(e,t){var n=t.MyAMS,r=[];n.require=function(t,a){for(var i=[],o=0;o<t.length;o++){var s=t[o];if(r.indexOf(s)<0){if(s.startsWith("http://")||s.startsWith("https://"))var c=s;else c=n.baseURL+"myams-"+s+n.devext+".js";i.push(n.getScript(c,{async:!0},console.error)),r.push(s)}}i.length>0?e.when.apply(e,i).then(function(){a()}):a()}}(jQuery,this);