2022-10-01 16:44:23 +02:00
|
|
|
$("#userAddId").on("change keydown keyup",(function(event){var userId=$(this).val();if(8!==event.keyCode&&37!==event.keyCode&&39!==event.keyCode&&46!==event.keyCode&&window.getSelection().toString()!==userId){var searchReplace={"á":"a","à":"a","â":"a","ä":"a","ã":"a","å":"a","ç":"c","é":"e","è":"e","ê":"e","ë":"e","í":"i","ì":"i","î":"i","ï":"i","ñ":"n","ó":"o","ò":"o","ô":"o","ö":"o","õ":"o","ú":"u","ù":"u","û":"u","ü":"u","ý":"y","ÿ":"y","Á":"A","À":"A","Â":"A","Ä":"A","Ã":"A","Å":"A","Ç":"C","É":"E","È":"E","Ê":"E","Ë":"E","Í":"I","Ì":"I","Î":"I","Ï":"I","Ñ":"N","Ó":"O","Ò":"O","Ô":"O","Ö":"O","Õ":"O","Ú":"U","Ù":"U","Û":"U","Ü":"U","Ý":"Y","Ÿ":"Y","'":"-",'"':"-"," ":"-"};userId=(userId=userId.replace(/[áàâäãåçéèêëíìîïñóòôöõúùûüýÿ'" ]/gi,(function(match){return searchReplace[match]}))).replace(/[^a-z0-9-]/gi,""),$(this).val(userId)}})),$("#userAddGroup").on("change",(function(){$(".userAddGroupDescription").hide(),$("#userAddGroupDescription"+$(this).val()).show()})).trigger("change"),$(document).ready((function(){"1"===$("#userAddGroup").val()?$("#userAddMemberFiles").slideDown():$("#userAddMemberFiles").slideUp((function(){$("#userAddtFiles").prop("checked",!1).trigger("change")}))})),$("#userAddGroup").on("change",(function(){"1"===$("#userAddGroup").val()?$("#userAddMemberFiles").slideDown():$("#userAddMemberFiles").slideUp((function(){$("#userAddFiles").prop("checked",!1).trigger("change")}))})).trigger("change");
|