console-api |
log |
URL: https://lausd.atenterprise.powerschool.com/resources/js/library.bundle.js?v=202105210854(Line 2)
Message:
JQMIGRATE: Migrate is installed with logging active, version 1.4.1
|
console-api |
debug |
URL: https://lausd.atenterprise.powerschool.com/resources/js/library.bundle.js?v=202105210854(Line 2)
Message:
Assigning value to moduleName SelectPlusField [object Object]
|
console-api |
debug |
URL: https://lausd.atenterprise.powerschool.com/resources/js/library.bundle.js?v=202105210854(Line 2)
Message:
Assigning value to moduleName Lib function Lib(init){if(init&&init.getGlobalInstance&&window.top._lib)return window.top._lib;window.top._lib||(window.top._lib=this);var isActiveDirectory=init.isActiveDirectory,companyId=init.companyId,sessionId=init.sessionId,onLoadCallback=init.onLoad||function(){};this.isDevMode=configuration.developmentMode,this.loaded=!1;var _this=this,parents=[],kids=[],hiddenDivs={},checkboxElements=[],jqueryUniversalChangeSupportedTags=":input[type!=hidden]",jqueryUniversalChangeSupportedEvents=["change","select","click","blur"],cookie_test=!1,dependentFieldCtx=null,_log=function(t,e){return logger.log(t)};function setGlobalData(t,e){_log("Setting '".concat(t,"' attribute to value '").concat(e,"'"));try{window&&window.top?$(window.top).data(t,e):_log("Can not set '".concat(t,"' attribute with value '").concat(e,"', top window is not available."))}catch(i){_log(new Error("Can not set '".concat(t,"' attribute with value '").concat(e,"': ").concat(i.message)))}}function getGlobalData(t){_log("Getting '".concat(t,"' attribute value."));try{if(window&&window.top){var e=$(window.top).data(t);return _log("Attribute '".concat(t,"' has value '").concat(e,"'")),e}return _log("Can not get '".concat(t,"' attribute value, top window is not available.")),null}catch(i){return _log(new Error("Can not get '".concat(t,"' attribute value: ").concat(i.message))),null}}function checkJQuery(t,e){return e||t.$||$}function getModal(t){return t.document.thismodal}function createModal(t,e,i){function n(e){_log("Doing resize!!!"),triggerResize(t,!1)}(e=e||{}).paddingTop=80,e.onOpen=mergeFunctions(e.onOpen,(function(e){$(t).on("resize",n),function(e){doModalContentFix(t,e)}(e)})),e.onClose=mergeFunctions(e.onClose,(function(){return $(t).off("resize",n)})),e.openOnCreate=!1,e.context=t;var s=Modal.createModal(e);return s&&(i&&(t.document.thismodal=s),s.open()),s}function doModalContentFix(t,e){var i=$(e.getContent(!0)),n=$(i);n.closest(".vex").css("padding-top","40px"),n.closest(".vex").find(".vex-dialog-input").css("overflow","auto"),n.find("#PageParagraphContainer").removeAttr("id"),n.find("#PageMainContainer").removeAttr("id"),n.find('input[type="submit"], input[type="reset"], input[type="file"]').addClass("vex-dialog-button vex-dialog-button-primary ss-modal-ok").css({"margin-top":"5px",float:"none"}),n.find('input[type="submit"]').click((function(){var e=$(document.getElementsByTagName("form")[1]),i=n.find("#footContainer"),s=i.find(".pagebuttons"),o=$('<img id=\'bulkActionInProgressSpinner\' src="https://cdn.atenterprise.powerschool.com/images/loading.gif" class="preventMultipleSubmitButtonClickSpinner" />');if("undefined"!=typeof e.attr("action")&&-1!=e.attr("action").indexOf("mass_transition_documents")){var r=$("<h4 id='bulkActionCompletedP'>Your requested action is complete.</h4>"),a=$("<h4 id='bulkActionFailedP' style='color:red' class='red ajaxerror'>One or more records have failed. Please check your pending items queue</h4>"),l=$("<h4 id='bulkActionInProgressP'>Bulk action requested is in progress</h4>"),c=$("<h4 id='emptySignature' style='color:red'class='red ajaxerror'>Signature field cannot be empty</h4>");try{i.length>1&&null!=i[1]&&void 0!=i[1]&&$($(".vex #footContainer")[0]).hide(),event.preventDefault();var u=$(".passwordfield").attr("value");e.find('input[id="authenticatedoc"]').length>0||void 0!==u&&null!==u&&""!==u.trim()?(s.hide(),i.append(o),i.append(l),$.ajax({data:e.serialize(),type:e.attr("method"),url:e.attr("action"),success:function(e){-1==e.indexOf("ajaxerror")?(o.hide(),l.hide(),i.append(r),t.location.reload()):(o.hide(),l.hide(),alert(e),event.stopPropagation())},error:function(t){o.hide(),l.hide(),i.append(a),event.stopPropagation()}})):(i.append(c),$(".passwordfield").focus((function(){c.hide()})))}catch(h){o.hide(),l.hide(),i.append(a)}}else s.hide(),i.append(o)})),n.find('input[type="button"]').addClass("vex-dialog-button vex-dialog-button-secondary ss-modal-cancel").css({"margin-top":"5px",float:"none"}),$(".linkbutton, .wizardlink").click((function(){return t.setTimeout((function(){doModalContentFix(t,e),triggerResize(t,!1)}),15)}))}function doModalOp(t,e,i){var n=getModal(t);if(n&&(n.isOpen()||!e))try{i(n,n.getContent(!0))}catch(s){_log(s)}}function triggerResize(t,e,i){(e=!1!==e)&&$(t).triggerHandler("resize"),i=!0===i,doModalOp(t,!0,(function(e,n){var s=t._triggerResizeQueue||{timeoutId:null};t._triggerResizeQueue=s,null!==s.timeoutId&&window.clearTimeout(s.timeoutId),s.timeoutId=window.setTimeout((function(){try{e.resizeContent(i)}catch(t){_log(t)}}),15)}))}function isChecked(t,e){return getCheckboxElement(t,e).checked}function getCheckboxElement(t,e){return checkboxElements[e]}function checkCheckBox(t,e,i,n){var s=getCheckboxElement(t,e);return s&&(s.checked=i,n&&lib.assureParentSelected(t,e)),!0}function emailCheck(t,e,i){var n="[^\\s".concat('\\(\\)><@,;:\\\\\\"\\.\\[\\]',"]"),s="".concat(n,"+"),o="(".concat(s,"|").concat('("[^"]*")',")"),r=new RegExp("^".concat(o,"(\\.").concat(o,")*$")),a="[a-zA-Z0-9](?:[a-zA-Z0-9-]*[a-zA-Z0-9]+)*",l=new RegExp("^".concat(a,"(\\.").concat(a,")+\\s*$")),c=t.match(/^\s*(.+)@(.+)$/);if(null==c)return invalidField(e,i,"The email address seems incorrect (check @ and .'s)"),!1;for(var u=c[1],h=c[2],d=0;d<u.length;d++)if(u.charCodeAt(d)>127)return invalidField(e,i,"The email username contains invalid characters."),!1;if(null==u.match(r))return invalidField(e,i,"The email username doesn't seem to be valid."),!1;var p=h.match(/^\[(\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})\]$/);if(null!=p){for(var f=1;f<=4;f++)if(p[f]>255)return invalidField(e,i,"Email destination IP address is invalid!"),!1;return!0}var m=h.match(l);if(null==m)return invalidField(e,i,"The email domain name does not seem to be valid."),!1;if(!(m[1].length>2))return invalidField(e,i,"The email address has an invalid tld domain. Are you missing .com?"),!1;if(h.length>255)return invalidField(e,i,"The email address has to long a domain name."),!1;for(var g=0;g<m.length-1;g++)if(m[g].length>63)return invalidField(e,i,"The email address domain name is to long."),!1;return!0}function getFieldValue(t,e){var i=t.$,n="",s=e.type||i(e).attr("type");if(s)if(s.indexOf("select-")>=0)e.selectedIndex>=0&&(n=e.options[e.selectedIndex].value);else if(s.indexOf("check")>=0||s.indexOf("radio")>=0){if(e.checked&&(n=e.value),e.length)for(var o=0;o<e.length;o++)e[o].checked&&(n=e[o].value)}else n=e.value;else if(e.length)for(var r=0;r<e.length;r++)e[r].checked&&(n=e[r].value);return null==n&&(n=""),n}function reassignFieldListeners(t,e){var i;if(i=t.length?t[0].form:t.form){for(var n=0;n<i.validatorFields.length;n++)i.validatorFields[n]==t&&(i.validatorFields[n]=e);for(var s=0;s<i.maskValidatorFields.length;s++)i.maskValidatorFields[s]==t&&(i.maskValidatorFields[s]=e)}}function validNewField(t,e,i){var n;if(void 0===i[0]&&(i[0]=e[0]),!(n=e.length?e[0].form:e.form))return!0;for(var s=0;s<n.validatorFields.length;s++)if(n.validatorFields[s]==e&&!n.validatorFunctions[s](t,i))return!1;for(var o=0;o<n.maskValidatorFields.length;o++)if(n.maskValidatorFields[o]==e&&!n.maskValidatorFunctions[o](t,i,n.maskValidatorMasks[o]))return!1;return!0}function validFields(t,e){t.runningValidFields=!0;for(var i=0;i<e.validatorFunctions.length;i+=1)if(fieldInForm(e,e.validatorFields[i])&&!e.validatorFunctions[i](t,e.validatorFields[i]))return t.runningValidFields=!1,!1;for(var n=0;n<e.maskValidatorFunctions.length;n+=1)if(fieldInForm(e,e.maskValidatorFields[n])&&!e.maskValidatorFunctions[n](t,e.maskValidatorFields[n],e.maskValidatorMasks[n]))return invalidField(t,e.maskValidatorFields[n],"".concat(e.maskValidatorFields[n].value," is not in the correct format.")),t.runningValidFields=!1,!1;return t.runningValidFields=!1,!0}function fieldInForm(t,e){function i(e){for(var i=0;i<t.elements.length;i++)if(t.elements[i]==e)return!0;return!1}if(!e)return!0;if(e.length&&!e.type){if(e.length<500){for(var n=0;n<e.length;n++)if(!i(e[n]))return!1}else if(!i(e[0]))return!1;return!0}return i(e)}function getMultiNumberChecked(t,e){var i=0;if(e.length)for(var n=0;n<e.length;n++)e[n].checked||e[n].selected?i++:e[n].options&&(i+=getMultiNumberChecked(t,e[n].options));else e.options&&e.options.length>0?i=getMultiNumberChecked(t,e.options):(e.checked||e.selected)&&(i=1);return i}function getFormObjects(t,e){var i=[],n=t.document.forms,s=0;for(s=0;s<n.length;s+=1){var o=n[s];o.elements[e]&&i.push(o)}return i}function stripSymbols(t){var e=t.value;void 0!==e&&(t.value=e.replace(/(\$|\,|\(|\)|\&)/g,""))}function getFormattedDate(t,e){var i=t.value.replace("-","/"),n=i.lastIndexOf("/");if(i.length-n==3){var s="20",o=i.substring(n+1,n+3);o>"30"&&(s="19"),i=i.substring(0,n+1)+s+o}return i}function isValidDate(t,e){var i,n,s,o,r;for(r=1;r<t.length;r++){var a=t.substring(r,r+1);if(isNaN(a)&&"/"!=a&&"-"!=a&&" "==a)return!1}if(""!=(o=t)){if((r=o.indexOf("/"))<1)return!1;if((i=o.substring(0,r)).length<1||i.length>2||i.charAt(0)>"9"||0==i&&1==r)return!1;if("0"==i.substring(0,1)&&(i=i.substring(1,2)),i=parseInt(i),!e){if((r=(o=o.substring(r+1)).indexOf("/"))<1)return!1;if((n=o.substring(0,r)).length<1||n.length>2||n.charAt(0)>"9")return!1;"0"==n.substring(0,1)&&(n=n.substring(1,2)),n=parseInt(n)}if(4!=(s=o.substring(r+1)).length||s.charAt(0)<"0"||s.charAt(0)>"9")return!1;if(s=parseInt(s),i<1||i>12||n<1||n>31||s<1900||s>2299||2==i&&n>29||2==i&&29==n&&s%4!=0||4==i&&n>30||6==i&&n>30||9==i&&n>30||11==i&&n>30)return!1}return!0}function isValidBirthDate(t,e,i,n){var s=!0,o=t.value;if(o.length>0){e&&(o=o.replace(/\//,"/01/"));var r=new Date(o),a=new Date,l=new Date;a.setFullYear(a.getFullYear()-n),l.setFullYear(l.getFullYear()-i),s=r>=a&&r<=l}return s}function isValidDateTime(t){var e=t.value.split(" ");return 3==e.length&&(isValidDate(e[0]),!!isValidStandardTime(e))}function isValidStandardTime(t){if(3!=t.length)return!1;if(5!=t[1].length)return!1;if(2!=t[2].length)return!1;var e=t[1].substring(0,2);if(isNaN(e))return!1;if(":"!=t[1].charAt(2))return!1;e=t[1].substring(3,5);return!isNaN(e)&&("am"==t[2].toLowerCase()||"pm"==t[2].toLowerCase())}function isValidNumber(t){var e,i;if(""!=t.value){if(e=0,"-"==t.charAt(0)&&(e=1,1==t.length))return!1;for(i=0;e<t.length;e++)if("."==t.charAt(e)){if(i>0||e==t.length-1)return!1;i++}else if(t.charAt(e)<"0"||t.charAt(e)>"9")return!1}return!0}function jqueryUniversalChange(t,e,i){(0,t.$)(e).bind(jqueryUniversalTriggerType(t,e),i)}function jqueryUniversalTriggerType(t,e){var i,n=t.$;switch(e.tagName.toUpperCase()){case"INPUT":switch(n(e).attr("type").toUpperCase()){case"RADIO":case"CHECKBOX":case"BUTTON":i="click change";break;case"PASSWORD":case"TEXT":i="blur change";break;case"FILE":i="change";break;default:i="change select click blur"}break;case"TEXTAREA":case"SELECT":i="blur change";break;default:i="change select click blur"}return i}function checkFormatting(t,e,i){var n=i,s=e,o=!0;return"00008698"!=companyId&&!isActiveDirectory&&t.document.location.href.indexOf("employee_form")<0&&(null!=n&&""!=n.value||null==s||""==s.value||(s=s.value).length<6&&(invalidField(t,e,"The username is invalid. Usernames must be at least ".concat(6," characters in length, should not include spaces, and must not be identical to the password.")),o=!1)),o}function makeTestCookie(){document.cookie="cookietest=yes;path=/"}function findTestCookie(){if(document.cookie.length>0&&window.navigator.cookieEnabled&&-1!==document.cookie.indexOf("cookietest="))return!0;return!1}function toolboxRegisterSelection(t,e){var i=t.$,n=i("#".concat(e,"_action_select")),s=n.closest("form");s.find("#inlineContent").length||s.append('<div id="inlineContent" style="height: 30ex"></div>');var o=function(){i("#inlineContent").html("").css("height","30ex"),t.toolbox[e]._parent.append(t.toolbox[e])};i('form input:reset[name="undo"]').click((function(){return o()})),n.change((function(){var n=i("#".concat(e,"_action_select option:selected")).attr("value"),s=!1;if("default"==n)return o(),!1;if(t.toolbox=t.toolbox||{},t.toolbox[e]=t.toolbox[e]||i("#toolbox_".concat(e)),t.toolbox[e]._parent=t.toolbox[e]._parent||t.toolbox[e].parent(),i("#toolbox_".concat(e)).remove(),i("#".concat(n)).length){var r=i("#".concat(n)).clone();r.attr("class",r.attr("id")),r.attr("id",""),i("#inlineContent").html(" ").append(r),r.show()}else s=!0;toolboxRunFunction(t,n),s&&t.document.forms[0].submit()}))}function toolboxRegisterActionGo(t,e){(0,t.$)("#".concat(e,"_go")).click((function(){var i=t.$,n=i("#".concat(e,"_action_select option:selected")).attr("value"),s=!1;if("default"===n)return t.alert("Please select an action to perform."),!1;if("all"===i('select[name="ACTION_TYPE"]').val()){if("RA00000002"===n)return t.alert("At most 100 recipients can be assigned eForms at a time. Please select no more than 100 recipients and try again."),!1}else if(0===i("div.rs tbody :checkbox:checked").length)return t.alert("Please select the records on which to perform the action."),!1;i("#".concat(n)).length?lib.showPopup(t,n):(s=!0,toolboxRunFunction(t,n)||lib.addHiddenField(t,n,n)),s&&t.document.forms[0].submit()}))}function closePopupFirst(t,e){Modal.closeAll(t,(function(){return e(t)}))}function toolboxRunFunction(t,e){if(!t.toolboxFunctions||!t.toolboxFunctions[e])return!1;try{t.toolboxFunctions[e](),triggerResize(t)}catch(i){return!1}return!0}function toolboxAddCancel(t,e){doModalOp(t,!0,(function(t,e){t.enableCancel(!0),$(e).find("input[name='cancel']").attr("onclick","").click((function(e){return e.preventDefault(),t.close(),!1}))}))}function canMakeAjaxCall(t,e){return"#"!=t||(_log("NOT making Ajax call, no valid URL provided (url is '#')."),!1)}function ajaxFillinPopup(t,e,i,n,s,o,r){if(canMakeAjaxCall(i,n)){var a=t.$;null==n?n="ajax=y":-1==n.indexOf("ajax=")&&(n+="&ajax=y");var l="get";n.length+i.length>2e3&&(n+="&fake_post=Y",l="post"),a(t.document).ajaxError((function(t,e,i){return _log("Server error: ".concat(e.status," url: ").concat(i.url))}));var c=getModal(t);c&&c.isOpen()?(dependentFieldCtx=".searchsoft-modal",a[l](i,n,(function(i,l){if("success"!=l)throw"AJAX error getting content";var u=a(c.getContent(!0)),h="div#inlineContent",d=a(u).find("div#inlineContent");d.length||(h=(d=a(u).find("div#".concat(e))).length?"div#".concat(e):null),c.setContent(i,h),d=a(c.getContent(!0)),afterAjaxPopProcess(t,e,d,n,s,o,r)}),"text").always((function(){dependentFieldCtx=null}))):a.get(i,n,(function(i,l){if("success"!=l)throw"AJAX error getting content";var c=a("#inlineContent div.".concat(e)).html(i);a("#inlineContent").css("height","auto"),afterAjaxPopProcess(t,e,c,n,s,o,r),lib.initForms(t)}),"text")}}function afterAjaxPopProcess(t,e,i,n,s,o,r){var a=t.$;lib.initForms(t),lib.addCheckboxApplicants(t,e),toolboxAddCancel(t,e),addMissingPopupRedirect(t,e),alwaysIsChanged(t,e),_this.isDevMode&&(i.find(".devmenulink, .wizardpopup").addClass("wizardlink").removeClass("wizardpopup"),i.find("div.rs a[href!='#ConfirmDelete'], div.rsrange a[href!='#ConfirmDelete']").addClass("wizardlink"),r=!0),s?hijackPopupSubmit(t,e,n,s,o,r):popUpFormSpinner(t);var l=getModal(t);(l&&doModalContentFix(t,l),i.find(".wizardlink").click((function(i){var n=a(this).attr("href");if(canMakeAjaxCall(n,null)){if(i.preventDefault(),l){var c=l.getContent(!0);a(c).find("form").hide().after("<h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p>")}return ajaxFillinPopup(t,e,n,null,s,o,r),!1}})),o)&&i.find(".linkbutton").each((function(){this.onclick=function(){return!0},a(this).click((function(i){var c=a(this).attr("href");if(canMakeAjaxCall(c,n)){if(i.preventDefault(),l){var u=l.getContent(!0);a(u).find("form").hide().after("<h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p>")}return ajaxFillinPopup(t,e,c,n,s,o,r),!1}}))}));l&&lib.addStyleClasses(t,l.getContent(!0)),lib.addStyleClasses(t,"#inlineContent .".concat(e)),triggerResize(t)}function addMissingPopupRedirect(t,e){var i=t.$;if(!i("input[name='searchpage']").length){var n=t.location;doModalOp(t,!0,(function(t,e){return i(e).find("form").append('<input type="hidden" name="searchpage" value="'.concat(n.pathname).concat(n.search,'" />'))}))}}function alwaysIsChanged(t,e){var i=t.$;doModalOp(t,!0,(function(t,e){return i(e).find("input[name='is_changed']").val("true")}))}function popUpFormSpinner(t){var e=t.$;doModalOp(t,!1,(function(t,i){return e(i).closest("form").submit((function(t){var i=e(this),n=i.get(0),s=n.onsubmit,o=!s||s.apply(n);return!1!==o?i.attr("target")&&0===i.attr("action").lastIndexOf("/servlet/jasper",0)?(i.hide().after("<div id='reportmessage'><p>Your report will be downloaded shortly. This could take up to several minutes. Feel free to close this window.</p><p>If your report does not download shortly, please go back and try again.</p><p><a href='#' id='submitshowformagain'> Go Back to Form </a></p></div>"),e("#submitshowformagain").click((function(t){return t.preventDefault(),i.next("#reportmessage").remove(),i.show(),!1}))):i.hide().after("<h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p>"):t.preventDefault(),o}))}))}function hijackPopupSubmit(t,e,i,n,s,o){var r=t.$;doModalOp(t,!1,(function(a,l){return r(l).find("form:not([target])").submit((function(l){l.preventDefault();var c=r(this).prop("onsubmit");if(!c||c.apply(this)){var u=r(this).serialize();u+="&ajax=y";var h=r(this).attr("action"),d=r(this).attr("method");d=null==d||"GET"==d.toUpperCase()?"get":"post";var p=r("<div><h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p></div>").attr("id",e);return a.setContent(p),r[d](h,u,(function(l,c){if("success"!=c)throw new Error("AJAX error");if(s){var d=p.html(l);afterAjaxPopProcess(t,e,d,i,n,s,o)}else/error has occured/.test(l)&&o?(p.html("<h1> Failure </h1>"),p.append("<p>CAUTION: Developer <a id='hijackretry' href='#'>Retry</a>. Will not provide success or failure message! Check your console</p>"),p.append("<xmp> ".concat(l,"</xmp>")),r("#hijackretry").click((function(){return r.post(h,u)}))):/ajaxerror/.test(l)&&-1==h.indexOf("/ats/application/detail/college_attended_form")?p.html(l):(p.html("<h1> Success </h1>"),a.close())})),!1}}))}))}function invalidField(t,e,i){var n=$(e).closest(".vex-dialog-input");n.find(".pagebuttons").show(),n.find(".preventMultipleSubmitButtonClickSpinner").remove(),t.fieldPrompt?t.fieldPrompt(e,i):t.alert(i)}function trimArray(t){for(var e=[],i=0,n=0;n<t.length;n++)e[i++]=t[n];return e}function getNextUrlFromNavigationPulldown(t,e){var i=e?"prev":"next",n=(0,t.parent.frames[0].$)("select[name=navchoice] option:selected")[i]();if(0!=n.length){var s=n.val(),o=s.substring(s.indexOf(",")+1,s.lastIndexOf(",")),r=s.substring(s.lastIndexOf(",")+1);o+="?".concat(r);t.location;return o}}function displayFn(t){return t?"".concat(t.toString().replace(/[\s]+/gim," ").substr(0,50),"..."):"null function"}function loadJsSource(t){return $.ajax({url:t,dataType:"text",async:!1}).responseText}setGlobalData("Lib.accessNextPage",!0),setGlobalData("Lib.loading",!1);var lib={pageListeners:[],log:function(t,e){_log("Call to deprecated Lib.log() function (should call Utils.log() directly)",!0),_log(t,e)},getCookie:function(t){var e=document.cookie.split(/\s*;\s*/),i=null;return $.each(e,(function(e,n){var s=n.split("=");if(s[0]==t)return i=s[1],!1})),i},getParam:function(t){var e=location.href,i=e.indexOf("?");if(i<0)return null;var n=(e=e.substr(i+1)).split("&"),s=null;return $.each(n,(function(e,i){var n=i.split("=");if(2==n.length){var o=n[0];return t==o?(s=n[1],!1):void 0}})),s},getModal:function(){return Modal},doSlowPageLoad:function(t,e){function i(t){var i=t.onReadyFunctions,n=i?i.length:0;_log("In doSlowPageLoad(".concat(e,"), win.onReadyFunctions.length=").concat(n))}var n=t.$;t.spinnerOn=!0,n(t.document).ready((function(){i(t),n("#slowpageloading").fadeIn(400),_log("Doing doSlowPageLoad(".concat(e,")")),window.setTimeout((function(){i(t),n("body").load(e,(function(){t.spinnerOn=!1;var e=t.onReadyFunctions||[];i(t);for(var n=0;n<e.length;n++)try{var s=e[n],o=displayFn(s);_log("Running onReadyFunction:\n".concat(o)),s(t)}catch(r){_log(r)}}))}),1e3)}))},renderHierCheckboxModel:function(t,e,i){new HierCheckboxModel(t,e,i).render()},openNode:function(t,e){return!0},toggleNode:function(t,e,i){var n;(i=void 0==i||!0===i)&&(n=t.document.getElementById("".concat(e,"_img")));var s=t.document.getElementById(e);"none"==s.style.display?(s.style.display="",i&&(n.src="/ats/images/minus.gif")):(s.style.display="none",i&&(n.src="/ats/images/plus.gif"))},assureChildrenMatch:function(t,e){var i=parents[e];if(i)for(var n=isChecked(t,e),s=i.length,o=0;o<s;o++){var r=i[o];checkCheckBox(t,r,n,!1),lib.assureChildrenMatch(t,r)}return!0},assureParentSelected:function(t,e){var i=kids[e];return i&&checkCheckBox(t,i,!0,!0),!0},setCheckboxElements:function(t){checkboxElements=[];for(var e=0;e<t.document.forms[0].elements.length;e++){var i=t.document.forms[0].elements[e];if(i&&"checkbox"==i.type){var n=i.value;checkboxElements[n]=i}}},rmimg:function(t,e){t.document.getElementById(e)||(t.document.getElementById("".concat(e,"_img")).style.display="none")},setParent:function(t,e,i){kids[e]=i;var n=parents[i];n||(n=[]),n=n.concat(e),parents[i]=n},initPageCollapse:function(t){for(var e in hiddenDivs)lib.pageCollapse(t,e)},pageCollapse:function(t,e){var i=t.getElementById("".concat(e,"-collapse-button")),n=t.getElementById(e);n&&i&&("none"==n.style.display?(n.style.display="",delete hiddenDivs[e],i.src="/ats/images/minus.gif"):(n.style.display="none",hiddenDivs[e]||(hiddenDivs[e]=!0),i.src="/ats/images/plus.gif"))},pageCollapseAtsSearchMultiPage:function(t,e){var i=t.$,n="#".concat(e,"-nonWrapper");i(".subPageContent").not(n).addClass("subPageContentHidden"),i(n).toggleClass("subPageContentHidden"),setTimeout((function(){i("html, body").animate({scrollTop:i("#".concat(e,"-wrapper")).offset().top},350)}),351)},checkSessionId:function(t){if(null==sessionId||null==t||""==sessionId||""==t||"null"==sessionId||"null"==t)return!0;if(t==sessionId)return!0;var e=_this.getCookie("SSS_SESSION_ID");return t==e&&(sessionId=e,!0)},helpLink:function(t,e){return t.alert(e),!1},importStatusPopup:function(t,e){var i;switch(e){case"success_annual":i="<b>Annual/Yearly import of all the Florida Certifications and Courses is successful!!</b>";break;case"success_quarterly":i="<b>Quarterly import of the Florida Certifications and Courses is successful!!</b>";break;case"sftp_yearly":i="<b>Exception occurred during import : </b> <br> <b>YearlyImports</b> folder is missing in the SFTP location!";break;case"sftp_quarterly":i="<b>Exception occurred during import : </b> <br> <b>QuarterlyImports</b> folder is missing in the SFTP location!";break;case"ccd_missing":i="<b>Exception occurred during import : </b> <br> <b>CCD</b> folder is missing in the SFTP location!";break;case"not_xlsx_format":i="<b>Exception occurred during import : </b> <br> File(s) should be of .xlsx formats only, other formats are not allowed.";break;case"failure_missing_del":i="<b>Exception occurred during import : </b> <br> <b>Delete</b> column is missing or not in the right column on one of the sheets.<br> When performing Quarterly Imports, Delete columns must be present on all sheets, here's the places to check : <br> 1. <b>Delete</b> column should be in the 11th column for the All Certifications sheet<br> 2. <b>Delete</b> column should be in the 3rd column for all of the Special Certifications sheet<br> 3. <b>Delete</b> column should be in the 11th column for the Dual Certifications sheet<br> 4. <b>Delete</b> column should be in the 7th column for the All Courses sheet";break;case"yearly_missing_file":case"quarterly_missing_file":i="<b>Exception occurred during import :</b> <br> Files are missing or names mismatch in the SFTP location for "+e.split("_")[0]+" import :<br> NOTE : .xlsx files should be available with names in below formats : <b>Certifications_(school_year) or Certifications_(school_year)_(quarter)</b> and <br> <b>Courses_(school_year) or Courses_(school_year)_(quarter)</b>";break;case"errors":i="<b>Exception occurred during import.</b> <br> It might be because of following reasons :<br> 1. invalid certification or course data<br> 2. missing or incomplete data<br> Note : Please refer to logs in SFTP site and check latest log file for more details.";break;default:i="Unknown exception occurred during import of CCD Certifications and Courses!!"}if(i.length>0)return i},removeFileUpload:function(t,e){var i=t.$,n="#".concat(e),s="".concat(n,"_remove"),o="".concat(n,"_view"),r="".concat(n,"_hidden_remove");i(s).click((function(){var t=i(this),e=i(n);t.css("display","none"),i(o).css("display","none"),i(r).val(e.val()),e.val(null),t.closest("td").find('input[type="button"]').val("Upload a File")}))},checkEmail:function(t,e){var i=!0,n=e.value;return n.length>0&&(i=emailCheck(n,t,e)),i},selectLocation:function(t){var e=t.$,i=e("select[name='COMPANY_ID']"),n=function(){return document.cookie="COMPANY_ID=".concat(i.val(),"; path=/")};n(),i.change((function(){e("select[name='action']").val("default"),n(),e("#inlineContent").html(" ")}))},checkConfirmEmail:function(t,e){var i,n=(0,t.$)("#EMAIL").val().trim().toLowerCase();return n!=(i=e.value.trim().toLowerCase())?(invalidField(t,e,"Confirm Email should match Email."),!1):n==i||void 0},checkRequiredRadio:function(t,e){var i=!1,n=t.$;if("none"==n("#".concat(n(e).attr("name"),"_ROW")).css("display"))return!0;if(e.length)for(var s=0;s<e.length;s++)e[s].checked&&(i=!0);else e.checked&&(i=!0);return!!i||(invalidField(t,e,"You have not filled out all required answers on this page."),!1)},initForms:function(t){function e(t){t.initialized||(t.validatorFunctions=new Array(0),t.validatorFields=new Array(0),t.maskValidatorFields=new Array(0),t.maskValidatorFunctions=new Array(0),t.maskValidatorMasks=new Array(0),t.initialized=!0)}var i=t.document.forms;if(i)for(var n=0;n<i.length;n+=1){e(i[n])}else $("form").whenExists((function(){e(this)}))},checkRequired:function(t,e){var i=t.$,n=i(e),s=n.attr("name"),o=i("#".concat(s,"_ROW"));if((o.length>0?o:n.parents("tr").eq(0)).is(":visible")&&""==getFieldValue(t,e)){var r=s||n.attr("id");logger.log("## checkRequired - INVALID (".concat(r,")")),logger.log(e);var a=i('input[name="customValidationMessage"]');return invalidField(t,e,a.length>0&&""!=a.val()?a.val():"You have not filled out all required fields on this page."),!1}return!0},validForm:function(t,e,i){return!!lib.checkAccess()&&(t.runningValidFields=!0,"applicant.view"!=i&&"dbuser.pwd_no_libraryjsp"!=i&&(i.match("dbuser")||i.match("applicant")&&!i.match("applicant_type"))&&!checkFormatting(t,e.elements.NAME,e.elements.PWD)?(t.runningValidFields=!1,!1):(t.runningValidFields=!1,validFields(t,e)))},compressFormQuery:function(t,e,i){if(!lib.checkAccess())return!1;var n=t.$,s=n(e).find(":input").filter((function(){return""!=n(this).val()})).serialize(),o="".concat(n(e).attr("action"),"?").concat(s);return["/ats/application/applicants","/ats/employer/admin/employee_search_results","/ats/employer/admin/employee"].includes(n(e).attr("action"))?n.post("/servlet/support/login/encryptQueryString",{queryString:s,actionUrl:n(e).attr("action")},(function(e){t.location.href=e.encryptedString}),"json"):t.location.href=o,!1},encryptQueryString:function(t,e,i,n){i.preventDefault();var s=t.$,o=s(e).find(":input").serialize();return s.post("/servlet/support/login/encryptQueryString",{queryString:o,actionUrl:n},(function(e){t.location.href=e.encryptedString}),"json"),!1},appendMulti:function(t,e,i){lib.initForms(t);var n=getFormObjects(t,e),s=0;for(s=0;s<n.length;s+=1){var o=n[s],r=new Array(i),a=o.elements[e];o.validatorFunctions=o.validatorFunctions.concat(r),o.validatorFields=o.validatorFields.concat(a)}},multiCheck:function(t,e){var i=getMultiNumberChecked(t,e),n=t.$,s="".concat(n(e).attr("name"),"_ROW");return!(n("[id='".concat(s,"']")).last().is(":visible")&&i<1)||(invalidField(t,e,"You have not filled out all required answers on this page."),!1)},reqAllMultiCheck:function(t,e){var i=getMultiNumberChecked(t,e),n=Array.from(e).filter((function(t){return"checkbox"===t.type})).length,s=t.$,o="".concat(s(e).attr("name"),"_ROW");return!(s("[id='".concat(o,"']")).last().is(":visible")&&i<n)||(invalidField(t,e,"You have not filled out all required answers on this page."),!1)},appendMask:function(t,e,i){lib.initForms(t);var n,s=e;-1!=e.indexOf(":::")&&(s=e.substring(0,e.indexOf(":::")),-1!=(e=e.substring(e.indexOf(":::")+3)).indexOf(":::")&&(n=e.substring(0,e.indexOf(":::"))));var o=getFormObjects(t,s),r=0;for(r=0;r<o.length;r+=1){var a=o[r],l=a.elements[s],c=new Array(i),u=new Array(l),h=new Array(n);a.maskValidatorFunctions=a.maskValidatorFunctions.concat(c),a.maskValidatorFields=a.maskValidatorFields.concat(u),a.maskValidatorMasks=a.maskValidatorMasks.concat(h)}},append:function(t,e,i){lib.initForms(t);var n=getFormObjects(t,e),s=0;for(s=0;s<n.length;s+=1){var o=n[s],r=o.elements[e],a=new Array(i),l=new Array(r);o.validatorFunctions=o.validatorFunctions.concat(a),o.validatorFields=o.validatorFields.concat(l)}},checkSize:function(t,e){e>0&&t.value.length>e&&(t.value=t.value.substring(0,e),alert("You have reached the maximum size for this field"))},checkSearchNumber:function(t,e){stripSymbols(e);var i=e.value;if(void 0===i)return!0;if(i.indexOf(">")>0||i.indexOf("<")>0)return invalidField(t,e,"An invalid number was entered in this field. If you are using > or <, please make sure it is the first symbol in the field."),!1;var n=i;return 0!=n.indexOf(">")&&0!=n.indexOf("<")||(n=i.substr(1)),!!isValidNumber(n)||(invalidField(t,e,"An invalid number was entered in this field."),!1)},checkNumber:function(t,e){return stripSymbols(e),!!isValidNumber(e.value)||(invalidField(t,e,"An invalid number was entered in this field. This field cannot contain any symbols ($, %, #, etc)."),!1)},checkZeroInterval:function(t,e){return stripSymbols(e),0!==e.value||(invalidField(t,e,"Interval cannot be zero"),!1)},confirmDelete:function(t,e){if(confirm("Are you sure you want to delete this record?")){if(e.indexOf("redirect=")<0)e="".concat(e,"&redirect=").concat(escape(t.location.href));else{var i=e.indexOf("&redirect="),n=e.indexOf("%");if(i>=0&&n<0){var s="&redirect=".length;e=e.substring(0,i+s)+escape(e.substring(i+s))}}t.location.href=e}},handleImpersonation:function(t,e,i){var n=e.split("?")[1].substr("USER_ID=".length);return $.get("/servlet/support/login/impersonation",{companyId:companyId,userId:n,impersonationMode:i},(function(e){e.success?"EMPLOYER"==e.accountType&&top.document.location.replace("/ats/employer/v51_employer_frame"):t.alert(e.errorMessage)}),"json"),!1},checkTime:function(t,e){var i=!0,n=e.value;if(0==n.length)return!0;if(5!=n.length)i=!1;else if(":"!=n.substring(2,3))i=!1;else{var s=n.substring(0,2),o=n.substring(3,5);if(s.charAt(0)>2||s.charAt(1)>9||o.charAt(0)>5||o.charAt(1)>9||2==s.charAt(0)&&s.charAt(1)>3)i=!1;else{var r=parseInt(s),a=parseInt(o),l=parseInt(s.substring(0,1)),c=parseInt(s.substring(1,2)),u=parseInt(o.substring(0,1)),h=parseInt(o.substring(1,2));(r>23||r<0||a>59||a<0||isNaN(r)||isNaN(a)||isNaN(l)||isNaN(c)||isNaN(u)||isNaN(h))&&(i=!1)}}return i||invalidField(t,e,"An invalid time was entered. Use Military Time Format: 00:00 to 23:59"),i},checkDate:function(t,e){var i=getFormattedDate(e);return isValidDate(i,!1)?(e.value=i,!0):(invalidField(t,e,"An invalid date was entered. Use Month Date Year Format MM/DD/YYYY."),!1)},checkBirthDate:function(t,e){return!!isValidBirthDate(e,!1,10,110)||(invalidField(t,e,"An invalid birth date was entered."),!1)},checkShortDate:function(t,e){var i=getFormattedDate(e);return isValidDate(i,!0)?(e.value=i,!0):(invalidField(t,e,"An invalid date was entered. Use Month Date Year Format MM/YYYY."),!1)},storeShortDateToFullDate:function(t,e){var i=e.val(),n=$(e).attr("id"),s=$("#".concat(n,"_ROW"));if(!isValidDate(i,!0)||""==i&&"none"!=s.css("display"))return e.next().val(""),!1;var o=function(t){var e=t.lastIndexOf("/"),i=t.substring(0,e),n=t.substring(e);return"".concat(i,"/01").concat(n)}(i);return e.next().val(o),!0},checkDateTime:function(t,e){if(isValidDateTime(e))return!0;invalidField(t,e,"An invalid date was entered. Use Format MM/DD/YYYY HH:MM am/pm.")},toggleSelectAllCheckboxes:function(t,e){!!$(t).attr("checked")?lib.selectAllCheckboxes(e,!1):lib.deselectAllCheckboxes(e,!1)},selectAllCheckboxes:function(t,e){e&&lib.setAccess(t,!1);var i=0;for(i=0;i<t.document.forms[0].elements.length;i++)"checkbox"==t.document.forms[0].elements[i].type&&(t.document.forms[0].elements[i].checked=!0)},documentSubmit:function(t,e,i,n){return setTimeout((function(){var s=t.$;lib.setAccessNextPage(!0);var o=!!s("input[name='save_as_draft']").length,r="Y"===s("input[name='IGNORE_REQUIRED_FIELDS']").val(),a=r;if(o||r||(a=lib.validForm.call(e[0],t,e[0],i)),o||a){var l=!1;createModal(t,{content:"#".concat(n),attributes:{useCloseX:!0},onOpen:function(t){var i=t.getContent(!0);s(i).css("height","auto"),s(i).css("width","auto"),t.enableOk({enable:!1}),t.setContent("<h3>Submitting...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p>");var n="".concat(e.serialize(),"&ajax=Y");o&&(n+="&save_as_draft=Save+as+Draft"),s.post(e.attr("action"),n,(function(e){l=!0,t.setContent(e),o&&setTimeout((function(){return t.close()}),500)}))},onClose:function(t){l&&t.enableOk({enable:!0})}})}}),500),!1},importCcdSubmit:function(t,e,i,n){return setTimeout((function(){var e=t.$,s=e("#"+n).find("form");lib.setAccessNextPage(!0);lib.disableMouseActions(t);createModal(t,{content:"#".concat(n),onOpen:function(n){n.enableOk({enable:!1}),n.setContent("<div class ='importpopup' style=''><h3>Importing Data...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p></div>");var o=e(n.getContent(!0));o.closest(".vex").find(".vex-content").css({width:"700px",height:"200px"}),o.closest(".vex-content").find(".vex-dialog-input").css({overflow:"unset",width:"unset",height:"unset"});var r="".concat(s.serialize(),"&ajax=Y");e.post(i,r,(function(i){!0;var s=lib.importStatusPopup(t,i.trim());n.setContent("<p>"+s+"</p>");var o=e(n.getContent(!0));o.closest(".vex").find(".vex-content").css({"max-height":"300px",width:"700px"}),o.closest(".vex-content").find(".vex-dialog-input").css({width:"unset"}),lib.enableMouseActions(t)}))}})}),500),!1},disableMouseActions:function(t){var e=t.parent.frames[0],i=e?e.$("#WA00000124"):$("#WA00000124");$("*").css({cursor:"wait","pointer-events":"none"}),i.find("div, li").css({cursor:"wait"}),i.find("a, div .ui-control-help, span").css({"pointer-events":"none"})},enableMouseActions:function(t){var e=t.parent.frames[0],i=e?e.$("#WA00000124"):$("#WA00000124");$("*").css({cursor:"","pointer-events":"all"}),i.find("div, li").css({cursor:""}),i.find("a, div .ui-control-help, span").css({"pointer-events":"all"})},unfollow:function(t,e){var i=t.$,n=i(e);return i.post(n.attr("href"),(function(t){if("Success!"==t){var e=n.closest("tr").nextAll("tr.even");n.closest("tr").nextAll("tr.odd").removeClass("odd").addClass("even"),e.removeClass("even").addClass("odd"),n.closest("tr").remove()}})),!1},deselectAllCheckboxes:function(t,e){e&&lib.setAccess(t,!1);var i=0;for(i=0;i<t.document.forms[0].elements.length;i++)"checkbox"==t.document.forms[0].elements[i].type&&(t.document.forms[0].elements[i].checked=!1)},daysSince:function(t,e){var i,n=e.value,s=new Date((new Date).getTime()),o=new Date(s-24*n*60*60*1e3),r="".concat(o.getMonth()+1,"/").concat(o.getDate(),"/").concat(o.getFullYear()),a=e.name.lastIndexOf("_DAYSSINCE");if(a>0&&(i=e.name.substring(0,a)),n>0&&null!=n)for(var l=0;l<t.document.forms[0].elements.length;l++)t.document.forms[0].elements[l].name==i&&(t.document.forms[0].elements[l].value=r);else for(var c=0;c<t.document.forms[0].elements.length;c++)t.document.forms[0].elements[c].name==i&&(t.document.forms[0].elements[c].value="")},setAvgField:function(t,e){return t.avgField=e},setTotalField:function(t,e){t.totalField=e,t.document.forms[0].elements[e].enabled=!1},appendScore:function(t,e){t.scores=t.scores.concat(e)},calculateScore:function(t){for(var e=0,i=0,n=0;n<t.scores.length;n++){var s=t.document.forms[0].elements[t.scores[n]],o=parseInt(getFieldValue(t,s));!o>0&&(o=0,i++),e+=o}var r=e/(t.scores.length-i);return r=parseInt(r+.5),t.totalField&&e==parseInt(e)&&(t.document.forms[0].elements[t.totalField][0].value=e,t.document.forms[0].elements[t.totalField][1].value=e),t.avgField&&r==parseFloat(r)&&(t.document.forms[0].elements[t.avgField][0].value=r,t.document.forms[0].elements[t.avgField][1].value=r),!0},clearListeners:function(){return lib.pageListeners=[]},updatePage:function(t,e){var i=e.options[e.selectedIndex].value,n=null,s=null;if(i.indexOf(",")>=0&&(n=i.substring(0,i.indexOf(",")),(s=i.substring(i.indexOf(",")+1)).indexOf(",")>=0)){var o=s.substring(0,s.indexOf(",")),r=s.substring(s.indexOf(",")+1),a=o;if(null!=r){var l="?";a.indexOf("?")>=0&&(l="&"),a=a+l+r}}if(lib.checkAccess())lib.loadingPage(!0),s.indexOf(",")>=0&&(t.parent.frames[n].location.href=a,t.parent.frames[n].focus());else{t.alert('You must first click the "Save and Next" or "Undo" buttons before exiting this page.');for(var c=e.options.length,u=t.parent.frames[n].location.pathname,h=0;h<c;h++){if(e.options[h].value.indexOf(u)>=0){e.selectedIndex=h;break}}}},loadingPage:function(t){return setGlobalData("Lib.loading",t),1==t&&lib.setAccessNextPage(!0),!0},isLoadingPage:function(){return getGlobalData("Lib.loading")},pageUpdated:function(t){for(var e=0;e<_this.pageListeners.length;e++){var i=_this.pageListeners[e],n=void 0;try{(n=i.pageUpdated)&&n(t)}catch(s){}}},setAccessNextPage:function(t){var e=lib.checkAccess();return _log("accessNextPage: ".concat(e)),setGlobalData("Lib.accessNextPage",t),!0},authenticateUser:function(t){var e=t.$;e.ajax({contentType:"application/json; charset=utf-8",data:JSON.stringify({value:!0}),method:"POST",url:"/api/eformsdocumentapprove/eformsSignedDocument",success:function(t){var i=JSON.parse(t),n=i.success;if(n){var s,o,r;i.hasOwnProperty("firstName")&&(s=i.firstName),i.hasOwnProperty("lastName")&&(o=i.lastName),i.hasOwnProperty("email")&&(r=i.email),e("#form-data").append("<div></div>").append('<img src="/ats/css-base/images/click-ok.png"/>').append(" ").append(s).append(" ").append(o).append(" ").append("("+r+")").append("<div></div>").css("display","block"),e(".eformsubmit").css("display","block")}e("#authenticatedoc").attr("disabled","disabled")},error:function(t){this.setState({_messageToUser:"Authentication fails"})}})},setAccess:function(t,e){return _this.setAccessNextPage(e),t&&t.document&&t.document.forms&&t.document.forms[0]&&t.document.forms[0].elements&&t.document.forms[0].elements.is_changed&&!t.document.forms[0].elements.force_is_changed&&(t.document.forms[0].elements.is_changed.value=!e),!0},checkAccess:function(){return getGlobalData("Lib.accessNextPage")},checkLinkAccess:function(){return!!_this.checkAccess()||(alert('You must first click the "Save and Next" or "Undo" buttons before exiting this page.'),!1)},addDependentField:function(t,e,i,n){var s=t.$;s(t.document).ready((function(){for(var o,r,a=[],l=e.split("|"),c=n?n.split("|"):[],u=0;u<c.length;u++)c[u]=c?c[u].split("&"):[];for(var h=0;h<l.length;h++){for(var d=[],p=l[h].split("&"),f=0;f<p.length;f++){var m=p[f],g="_NOT"===m.substr(-4);g&&(m=m.substr(0,m.length-4));var v=void 0;(v=dependentFieldCtx?s(dependentFieldCtx).find("[name='".concat(m,"']")).not(":disabled"):s("[name='".concat(m,"']")).not(":disabled")).data("negative",g),d[f]={fields:v,values:c[h]&&c[h][f]?c[h][f]:""}}a[h]=d}if(s.each(a,(function(t,e){return s.each(e,(function(t,e){return o=o?o.add(e.fields):e.fields}))})),r=dependentFieldCtx?s(dependentFieldCtx).find("#".concat(i,"_ROW")):s("#".concat(i,"_ROW")),o&&o.length){var _=function(e){for(var i=!1,n=0;n<a.length&&!i;n++){for(var o=a[n],l=!0,c=function(t){for(var e=o[t],i=e.values.split(","),n=""===e.values,r=!1,a=0;a<e.fields.length&&!r;a++){var c=e.fields.eq(a),u=c.val(),h=c.data("negative");c.is(":radio,:checkbox")&&!c.is(":checked")&&(u=null);var d=!1;null!==u&&(u=s.makeArray(u),s.each(u,(function(t,e){""!=e&&s.inArray(e,i)>=0&&(d=!0)}))),r=d||u&&""!=u&&n,h&&(r=!r)}l=r},u=0;u<o.length&&l;u++)c(u);i=l}i?e?(r.show(),triggerResize(t,!0,!1)):"none"==r.css("display")&&(r.css("display",""),r.css("opacity","0"),r.animate({opacity:"1"},500,"swing",(function(){return triggerResize(t,!0,!1)}))):e?(r.hide(),triggerResize(t,!0,!1)):r.fadeOut({complete:function(){return triggerResize(t,!0,!1)}})};s(":reset").click((function(){s(this).get(0).form.reset(),_(!0)})),o.each((function(e,i){var n=s(i);n.hasClass("select-plus")&&!n.hasClass("select-plus-initialized")?SelectPlus.registerChangeListener(n,_):jqueryUniversalChange(t,i,(function(){return _()}))})),_(!0)}}))},setLocation:function(t,e){_this.checkAccess()?t.document.location.href=e:t.alert('You must first click the "Save and Next" or "Undo" buttons before exiting this page.')},setLocationToDashboard:function(t,e){t.document.location.href=e},historyGo:function(t,e){if(_this.checkAccess())t.$("body").trigger("ss-event-page-cancel"),t.history.go(-1);else{var i=(e=t.event||e).target||e.srcElement,n=$(i).parents("ul").find("input[type=submit]");t.alert('You must first click the "'.concat(n.val(),'" or "Undo" buttons before exiting this page.'))}},maskFormat:function(t,e,i){var n=e.value;return""==n||!!new RegExp(i).exec(n)},autoFormat:function(t,e,i){var n=t.value;if(""!=n){var s=new RegExp(e);s.exec(n)?t.value=n.replace(s,i):alert("".concat(n," is not in the correct format."))}},AppLoginStepFillIn:function(t){var e=t.$,i=e(".pagebuttons ul :has([value='Create New Account'])");i.css("display","block"),e("div.create_account")&&(e("div.create_account").html(i.html()),i.css("display","none")),e("#step2_links")?(e("#preview").hide(),e("#step2_links").html(e("#preview").html())):e("#preview").show()},addStyleClasses:function(t,e){var i=t.$;if(i){_log("addStyleClasses for ".concat(e=e||"body"));var n=i(e);n.find(":text").addClass("textfield"),n.find(":password").addClass("passwordfield"),n.find(":text, :password").focus((function(){i(this).addClass("textfieldfocus")})),n.find(":text, :password").blur((function(){i(this).removeClass("textfieldfocus")})),n.find("td:empty").html(" "),function(){var t=n.find('select[name="ACTION_TYPE"]');t.change((function(){var e=n.find(".rs :checkbox");"all"===t.val()?e.prop("disabled","disabled").hide():e.prop("disabled","").show()}))}(),n.find(":reset").click((function(t){i(".file_upload_field[type='hidden']").each((function(t){var e=i(this).attr("original");i(this).val(e);var n=i("#".concat(i(this).attr("name"),"_link"));n.attr("href",e),""==e&&n.fadeOut()}))}));var s={".embedded_field":function(t){t.closest("label").find(":radio, :checkbox").click((function(){return i(t).children(":text").focus()})),t.closest("label").find(":text").click((function(){i(this).closest("label").find(":radio, :checkbox").attr("checked","checked")}))},"a.wizardpopup":function(t){r(t,!0)},"a.wizardpopupNoReload":r,"a.modalpopuplink":function(e){return e.click((function(n){n.preventDefault();var s="modalpopuplink";return i("#".concat(s)).length||i("body").append("<div id='".concat(s,"' style='display:none;'><h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p></div>")),_this.addToolboxFunction(t,s,(function(){return ajaxFillinPopup(t,s,e.attr("href"))})),_this.showPopup(t,s),!1}))},"input.suggestsearch":function(e){var n="".concat(e.attr("id")||e.attr("name"),"_sug"),s=e.attr("href");s.indexOf("?")<0?s+="?":s+="&";s+="jscallback=?";var o=-1;function r(t){for(var s in c(),i("#".concat(n,"_con")).length||e.after("<div id='".concat(n,"_con'><div id='").concat(n,"' class='search_suggest'></div></div>")),t){var o=n+t[s];i("#".concat(n)).append("<div id='".concat(o,"' class='suggest_link'>").concat(s,"</div>"));var r=i("#".concat(o));r.hover(a,l),r.click((function(){e.val(i(this).html()),c()}))}}function a(){i(this).addClass("suggest_link_over"),e.unbind("blur")}function l(){i(this).removeClass("suggest_link_over"),e.blur(c)}function c(){i("#".concat(n,"_con")).remove()}e.keyup((function(n){-1!=o&&t.clearTimeout(o),o=t.setTimeout((function(){var t=e.val();if(""!=t){t={suggest:t,ajax:"y"};var n=i.param(t);i.getJSON(s,n,r)}}),500)})),e.blur(c)},"input.file_upload_field[type='button']":function(e){i(e).click((function(e){_log("Doing input.file_upload_field[type='button'].click()...");var n=this;i(n).parents().last().find("[id=upload_field]:hidden").remove(),closePopupFirst(t,(function(){_log("Doing fileUploadPopup - popups have been closed."),function(t,e){var i=e.$,n=getModal(e);if(n&&n.isOpen())return void alert("ERROR: cannot have a fileupload field within another pop-up");var s=i(t).attr("hiddenname"),o="FIELD_NAME=".concat(s,"&COMPANY_ID=").concat(companyId);if(!i("#".concat("upload_field")).length){var r='<div id="'.concat("upload_field",'" style="display: none"><h3>Loading...</h3> <p><img src=\'https://cdn.atenterprise.powerschool.com/images/loading.gif\' />Please Wait </p></div>');i("body").append(r)}var a="";i(t).is(".noextcheck")&&(a="?noextcheck=Y");_this.addToolboxFunction(e,"upload_field",(function(){ajaxFillinPopup(e,"upload_field","/ats/upload_field.jsp".concat(a),o)})),_this.addToolboxFunction(e,"".concat("upload_field","_close"),(function(){if(e.fileuploads&&e.fileuploads[s]){var t=e.fileuploads[s];t.id&&t.url&&(i("#".concat(s)).val(t.id),i(".".concat(s,"_link")).attr("href",t.url).fadeIn(),i(".".concat(s,"_remove")).attr("href","#").fadeIn(),i("#".concat(s,"_button")).attr("value","Replace File"),_this.setAccess(e,!1))}})),_this.showPopup(e,"upload_field")}(n,t)}))}))},".nctq_hoverable":function(e){e.mouseenter((function(e){o(t,i(this).next("div"),e,20,20),i(this).next("div").removeClass("nctq_scores_hidden"),i(this).next("div").addClass("nctq_scores_visible")})),e.mouseleave((function(t){i(this).next("div").removeClass("nctq_scores_visible"),i(this).next("div").addClass("nctq_scores_hidden")})),e.mousemove((function(e){o(t,i(this).next("div"),e,20,20)})),e.click((function(t){return t.preventDefault()}))}};!function(){var t="",e=!0;for(var o in s)e||(t+=","),t+=o,e=!1;n.find(t).each((function(){var t=i(this);for(var e in s)t.is(e)&&s[e].call(this,t)}))}()}else _log(new Error("Can not call addStyleClasses; jQuery is not available."));function o(t,e,i,n,s){var o=t.$,r=e.width(),a=e.height();e.css({top:Math.min(i.pageY+n,o(t).height()-a+o(t).scrollTop()),left:i.pageX-r-s})}function r(e,n){e.click((function(s){s.preventDefault();var o=e.attr("name")?e.attr("name"):"awizardpopup";return i("#".concat(o)).length||i("body").append("<div id='".concat(o,"' style='display:none;'><h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p></div>")),closePopupFirst(t,(function(){_this.addToolboxFunction(t,o,(function(){ajaxFillinPopup(t,o,e.attr("href"),null,!0,!0)})),n&&_this.addToolboxFunction(t,"".concat(o,"_close"),(function(){i("body").html("<h3 class='pageTitleCaption'>Please Wait... Loading</h3>");var e=t.location.href,n=top.frames[0]&&"sss_script"===top.frames[0].name;if(-1==e.indexOf("refresh")){var s=e;s.indexOf("?")>-1?s+="&refresh=Y":s+="?refresh=Y",n?t.location.replace(s):t.$("body").trigger("ss-event-page-reload")}else n?t.location.reload():t.$("body").trigger("ss-event-page-reload")})),_this.showPopup(t,o)})),!1}))}},fileUploadComplete:function(t,e,i){var n=t.$;n(".inlineHelp").remove(),n(".searchsoft-modal #file_upload_content").html(i),n(".searchsoft-modal #file_upload_waiting").stop().hide(),n(".searchsoft-modal #file_upload_content").fadeIn(),afterAjaxPopProcess(t,e,n(".file-upload-complete-wrapper-".concat(e)),null,!0,!0),triggerResize(t)},fileUploadStart:function(t){var e=t.$;return e(".inlineHelp").remove(),e(".searchsoft-modal #file_upload_waiting").fadeIn(),e(".searchsoft-modal #file_upload_content").hide(),!0},onReady:function(t,e){if(t.$=checkJQuery(t,t.$),t.$){var i=function i(){if(_log("win.document.readyState: ".concat(t.document.readyState)),"complete"!=t.document.readyState){var n=$.browser&&$.browser.mozilla?1e3:350;return _log("Deferring call to onReady for ".concat(n," ms...")),void t.setTimeout(i,n)}if(_log("Calling onReady() for:".concat(displayFn(e))),t.spinnerOn)t.onReadyFunctions=t.onReadyFunctions||[],t.onReadyFunctions.push(e),_log("Adding function to win.onReadyFunctions (length=".concat(t.onReadyFunctions.length,"), NOT calling function."));else try{_log("Executing onReady() function..."),e.call(_this,t)}catch(s){_log("Error occurred executing onReady function..."),_log(s)}};t.$(t.document).ready(i)}else _log(new Error("Can not call onReady; jQuery is not available."))},perform_cookie_test:function(){return makeTestCookie(),cookie_test=findTestCookie()},ready_modal_popup:function(t,e,i){(0,t.$)(t.document).ready((function(){e?toolboxRegisterSelection(t,i):toolboxRegisterActionGo(t,i),t.toolboxFunctions||(t.toolboxFunctions=new Array(0))}))},addToolboxFunction:function(t,e,i){t.toolboxFunctions||(t.toolboxFunctions=new Array(0)),t.toolboxFunctions[e]=i},ajaxPopupOp:function(t,e,i,n,s){var o=t.$,r=null;null==n&&""!=n||(r="op=".concat(n)),s&&(r="".concat(null==r?"":r+"&").concat(o("form").serialize()));var a=o("[name=table_name]").val();null==a||""==a||null!=r&&-1!=r.indexOf("table_name")||(r="".concat(r?r+"&":"","table_name=").concat(a)),ajaxFillinPopup(t,e,i,r)},ajaxPopup:function(t,e,i){return _this.ajaxPopupOp(t,e,i,null)},showPopup:function(t,e,i){var n=t.$,s=n("#".concat(e)).find("input[name=".concat(e,"]")).val();if(!s&&e.indexOf("_results")>0){var o=e.replace("_results","");s=n("#".concat(e)).find("input[name="+o+"]").val()}var r=n("#".concat(e)).parent(),a=n("#".concat(e)).find(".pagebuttons").hide().end();n(a).css("display","");var l={useCloseX:!0};i=i?n.extend({},l,i):l;var c=!s,u={id:e,attributes:i,content:a,onOpen:function(){n('[id="'.concat(e,'"]')).toArray().slice(0,-1).forEach((function(t){return n(t).remove()})),c&&(toolboxAddCancel(t,e),toolboxRunFunction(t,e))},onClose:function(i){var s=n(i.getContent(!0));s=n(s).children(),n(r).append(s.hide()),toolboxRunFunction(t,"".concat(e,"_close")),n(".inlineHelp").remove(),t.document.thismodal=null}};c?(u.showOk=!1,u.showCancel=!1):u.buttons=[{text:s,type:"ok",callback:function(i){return toolboxRunFunction(t,e)}},{text:"Cancel",type:"cancel"}],createModal(t,u,!0)},addHiddenField:function(t,e,i){(0,t.$)("form").append('<input type="hidden" name="'.concat(e,'" value="').concat(i,'" />'))},addCheckboxApplicants:function(t,e){var i=t.$;doModalOp(t,!1,(function(t,e){var n=i(e).find("form"),s=i("div.rs :checkbox:checked").clone();s.attr("checked","checked"),s.attr("remove","yes"),s.hide(),n.append(s);var o=i("select[name='ACTION_TYPE']");o.length&&n.append('<input type="hidden" name="ACTION_TYPE" value="'.concat(o.val(),'" />')),0==i(n).find(":checkbox:checked").length&&i(n).find(":hidden:checkbox").attr("checked","checked")}))},removeCheckboxApplicants:function(t,e){(0,t.$)("div#".concat(e," :checkbox[remove='yes']")).remove()},addSuperConfirm:function(t){var e=t.$;t.superConfirm=function(i,n){return createModal(t,{content:i,attributes:{useCloseX:!1},buttons:[{text:"Yes",type:"ok",callback:function(i){e.isFunction(n)&&n.apply(),triggerResize(t)}},{text:"Cancel",type:"cancel",callback:function(t){return e(".inlineHelp").remove()}}]})}},replaceAlert:function(t){var e=t.$;t.alert=function(i){if(i=i.replace(/\r\n|\n/g,"<br />"),Modal.anyShowing(t)){var n,s=e("<div class='red inlineHelp' />").html(i);e(".inlineHelp").length?(n=e(".inlineHelp").html(i),t.clearTimeout(t.helpTimeout)):(Modal.getCurrent(t).addContent(s),n=e(".inlineHelp").css("opacity","0").animate({opacity:"1"},500,"linear",(function(){triggerResize(t)}))),t.helpTimeout=t.setTimeout((function(){return n.animate({opacity:"0"},500,"linear",(function(){n.remove(),triggerResize(t)}))}),15e3),triggerResize(t)}else i=e("<p class='help_popup' />").html(i),createModal(t,{content:i,attributes:{useCloseX:!1},buttons:[{text:"Close",type:"ok",callback:function(t){return e(".inlineHelp").remove()}}]})}},addFieldPrompt:function(t){var e=t.$;function i(t,e,i){t.alert(i)}t.fieldPrompt=function n(s,o,r,a){var l=s,c=!(s.name||s.id||s.type)&&s.length;if(c||((s=[])[0]=l),r=!!r,t.runningValidFields&&(r=!0),Modal.anyShowing(t))return a?i(t,0,o):r?t.setTimeout((function(){return n(l,o,r,!0)}),550):i(t,0,o);try{if(e(".gridfield").length>0)for(var u=e(".gridfield"),h=0;h<u.length;h++)if(e.contains(u[h],s[0]))return i(t,0,o)}catch(x){}for(var d=t.fieldDelimiter||"tr",p=null,f=0;f<s.length;f++)p=p?p.add(e(s[f]).closest(d).eq(0)):e(s[f]).closest(d);if(!p.length)return i(t,0,o);var m=0!=e(p).find(".hasDatepicker").length,g=e(p).clone(!m);e(g).find("*").addBack().each((function(){var t=e(this).attr("id");t&&e(this).attr("id","".concat(t,"_COPY"))})),e(g).find(".do-not-copy").remove();var v=[],_=!1;if(g.find("*").each((function(t){for(var i=0;i<s.length;i++){var n=!0,o=s[i],r=e(o).attr("id"),a=e(this).attr("id");"".concat(r,"_COPY")!=a&&(n=!1),e(o).attr("name")!=e(this).attr("name")&&(n=!1),e(o).attr("value")!=e(this).attr("value")&&"select-one"!=e(o).attr("type")&&(n=!1),e(o).attr("type")!=e(this).attr("type")&&(n=!1),n&&(v[i]&&(_=!0),v[i]=e(this).get(0))}})),_)return i(t,0,o);if(s.length!=v.length)return i(t,0,o);s=trimArray(s),v=trimArray(v);var b=!1,y=e("<div class='invalid'>".concat(o,"</div>"));switch(e(y).append(g),d){case"tr":g.wrap('<table class="frmpfields"></table>');break;case"td":g.wrap('<table class="frmpfields"><tr></tr></table>');break;case"li":g.wrap("<ul></ul>");break;default:g.wrap('<div class="fieldprompt"></div>')}createModal(t,{content:y,attributes:{useCloseX:!0},showOk:!0,showCancel:!0,callback:function(i){var n;return v.filter((function(t){return void 0!==t})).forEach((function(t){var i=e("#".concat(t.id))[0];t.checked=i.checked,t.value=i.value})),n=c?v:v[0],!(0==e(p).find(".file_upload_field").length)||!!validNewField(t,l,n)&&void(b=!0)},onOpen:function(){if(m){var i=e(g).find(".hasDatepicker");e(i).removeClass("hasDatepicker"),e(i).datepicker({showOtherMonths:!0,selectOtherMonths:!0,showAnim:"slideDown",changeYear:!0})}triggerResize(t),e("#".concat(v[0].id)).focus()},onClose:function(){if(e(".inlineHelp").remove(),b){var i;i=c?v:v[0],reassignFieldListeners(l,i);for(var n=0;n<s.length;n++){var o=!1;v[n].checked&&(o=!0),e(s[n]).replaceWith(v[n]);var a=e(v[n]).attr("id")||"";(a=a.replace("_COPY",""))&&e(v[n]).attr("id",a),m&&(e(v[n]).removeClass("hasDatepicker"),e(v[n]).datepicker({showOtherMonths:!0,selectOtherMonths:!0,showAnim:"slideDown",changeYear:!0})),o&&e(v[n]).attr("checked","checked")}_this.setAccess(t,!1),r&&e("[name='submit_button']").trigger("click")}}})}},initFormPage:function(t){t.scores=new Array(0),t.avgField=null,t.totalField=null},multiRecordField:function(t,e,i,n){var s=t.$;function o(){var t=s("#".concat(e));t.html('<h3>Loading...</h3> <p><img src="https://cdn.atenterprise.powerschool.com/images/loading.gif" />Please Wait</p>'),s.get(i,"ajax=Y&refresh=Y",(function(e,i){if("success"!==i)throw"AJAX error getting content";t.html(e),r()}),"text")}function r(){if(s("#".concat(e," .resultpageajaxlinks")).length){var i="".concat(e,"_popup");s("#".concat(e,' a:not([class~="resultlink"])')).click((function(e){var n=s(this),r=n.attr("href");return n.hasClass("delete")?t.superConfirm("Are you sure you want to delete this record?",(function(){return s.post(r,null,(function(t,e){if("success"!==e)throw"AJAX error";o()}))})):(_this.addToolboxFunction(t,i,(function(){return ajaxFillinPopup(t,i,r,null,!0)})),_this.addToolboxFunction(t,"".concat(i,"_close"),(function(){return o()})),_this.showPopup(t,i)),e.preventDefault(),!1}))}}this.refreshResultPage=o,n?o():r()},jsExpression:function jsExpression(win,target,expression,defaults){for(var $=win.$,varRegExp=new RegExp("\\b[A-Za-z][A-Za-z0-9_]+\\b","g"),variable;null!=(variable=varRegExp.exec(expression));){var elem=$("[name='".concat(variable,"']"));elem.length&&(elem.unbind(jqueryUniversalChangeSupportedEvents.join(","),runExpression),jqueryUniversalChange(win,elem.get(0),runExpression))}function runExpression(){var expr=buildRawExpression();try{var value=eval(expr),targetField=$("#".concat(target,"_display")),targetHidden=$("#".concat(target));value!=targetHidden.val()&&(targetField.val(value),targetField.trigger("change"),targetHidden.val(value),targetHidden.trigger("change"))}catch(ex){lib.replaceAlert(win);var msg="<span style='font-size: 1em; font-style: normal; font-weight: normal'>It appears that there is an unresolved variable in the JS Expression string provided:</span><br /><br /><span style='font-size: .8em; font-style: italic; font-weight: bold'>".concat(expr,"</span><br /><br /><span style='font-size: 1em; font-style: normal; font-weight: normal'>Check the unresolved field name and ensure that it corresponds with an input on the page.</span>");win.alert(msg),$("#".concat(target,"_display")).val("###")}}function buildRawExpression(){var t=expression;try{for(var e;null!=(e=varRegExp.exec(expression));){var i=null,n=$("[name='".concat(e,"']"));if(0!=n.length&&"###"!=n.val())i=Number(n.val());else{if(null==defaults[e])continue;i=Number(defaults[e])}isFinite(i)||(i=Number(0)),t=t.replace(new RegExp("\\b".concat(e,"\\b"),"g"),i)}t="( ".concat(t," )")}catch(s){_log(s)}return t}runExpression()},reloadNewMcrelYear:function(t,e){var i=t.$;i((function(){var n=i('select[name="'.concat(e,'"]'));n.change((function(){var e=n.val();if(""!==e){var s=i("form").prop("action"),o=URI(s).setQuery("MCREL_YEAR_ID",e).toString();t.location.href=o}}))}))},addReloadOnSelectChange:function(t,e){var i=t.$;_this.onReady(t,(function(){return i("select[name='".concat(e,"']")).change((function(n){var s,o=t.location.href,r=new RegExp("".concat(e,"=[^&]*"));s=r.test(o)?o.replace(r,"".concat(e,"=").concat(i(this).val())):"".concat(o,"&").concat(e,"=").concat(i(this).val());var a=new RegExp("".concat(e,"=([^&]*)"),"g").exec(o);null!=a&&a[1]==i(this).val()||(t.location.href=s)}))}))},activatePreview:function(t,e,i,n,s){var o=t.$;o("#".concat(n)).click((function(){var r=o("[name=".concat(i,"]"));if(!r.length)return t.alert("No input field to preview");var a=r.val();if(""==a||null==a)return t.alert("No input currently selected");var l=s[a];if(""==l||null==l)return t.alert("No preview page for that selection");if(e)t.open(l);else{var c="".concat(n,"_div");_this.addToolboxFunction(t,c,(function(){return ajaxFillinPopup(t,c,l,null)})),_this.showPopup(t,c)}}))},registerStageSelect:function(t,e,i,n,s,o,r){_this.onReady(t,(function(){var a=t.$,l=a("[name='".concat(e,"']")),c="singleValue_".concat(e);if(l.length){var u=a("[name='".concat(n,"']"));if(u.length){var h="text"==u.attr("type"),d=!0;u.bind("change",p),p.apply(u.get(0))}else _log("StagedSelectField parent field is not present: ".concat(n))}else _log("StagedSelectField is not present!");function p(t){var e=a(this),n=e.val();h&&(n+="*"),encodeURIComponent?n=encodeURIComponent(n):escape&&(n=escape(n));var s=e.attr("type"),r="radio"==s||"checkbox"==s,u=e.attr("checked");if(!r||u)if(""!=n&&null!=n){var d="/ats/stage_field_lookup?GUI_FIELD_ID=".concat(i,"&parentvalue=").concat(n,"&ajax=Y&jscallback=?");a.getJSON(d,f)}else!function(){l.html("").show(),a("#".concat(c)).remove(),o||l.append("<option value='' selected='selected'></option>");l.triggerHandler("change")}()}function f(e){if(e){var i=1==e.length&&r,n="";l.html(""),a("#".concat(c)).remove(),i||l.show();var u="",h=!1;if(a.each(e,(function(t,e){var o=e.value;if(""!=o){var r=e.caption,l="";(-1!=a.inArray(o,s)||i)&&(n+=r,l=" selected='selected' ",h=!0),u+="<option value='".concat(o,"'").concat(l,">").concat(r,"</option>")}})),o||i||(u="<option value=''".concat(h?"":" selected='selected' ","></option>").concat(u)),l.append(u),i){l.hide();var p="<div id='".concat(c,"'>").concat(n,"</div>");l.after(p)}l.triggerHandler("change"),d&&(d=!1,l.change((function(){return _this.setAccess(t,!1)})))}else _log("lookups null")}}))},registerStageText:function(t,e,i,n,s,o){_this.onReady(t,(function(){var s=t.$,o=s("[name='".concat(e,"']"));if(o.length){var r=s("[name='".concat(n,"']"));if(r.length){var a=!0;r.bind("change",l),l.apply(r.get(0))}else alert("StageTextField parent field is not present: ".concat(n))}else alert("StageTextField is not present!");function l(t){var e=s(this),n=e.val();encodeURIComponent?n=encodeURIComponent(n):escape&&(n=escape(n));var o=e.attr("type"),r="radio"==o||"checkbox"==o,a=e.attr("checked");if((!r||a)&&""!=n&&null!=n){var l="/ats/stage_field_lookup?GUI_FIELD_ID=".concat(i,"&parentvalue=").concat(n,"&ajax=Y&jscallback=?");s.getJSON(l,c)}}function c(e){if(e)if(1==e.length){var i=e[0].value;if(o.val(i),null!==t&&null!==t.tinymce){var n=t.tinymce.get(o.attr("id"));null!==n&&n.setContent(i)}o.triggerHandler("change"),a&&(a=!1,o.change((function(){return _this.setAccess(t,!1)})))}else alert("lookup must have one value");else alert("lookups null")}}))},registerMoveToSelect:function(t,e){function i(t,e){var i=t.innerHTML,n=e.innerHTML,s=null===i?"":"".concat(i),o=null===n?"":"".concat(n);return s>o?1:s===o?0:-1}function n(t,e){var n=t.find(":selected");n.detach(),e.append(n);var s=e.children();s.detach(),e.append(s.get().sort(i))}var s=t.$,o=s("#".concat(e)),r=s("#".concat(e,"_src"));s("#".concat(e,"_addbtn")).click((function(){_this.setAccess(t,!1),o.children().prop("selected",!1),n(r,o)})),s("#".concat(e,"_rmvbtn")).click((function(){_this.setAccess(t,!1),r.children().prop("selected",!1),n(o,r)})),s("form").on("click","input:submit",(function(){r.children().prop("selected",!1),o.children().prop("selected",!0)}))},browseToNextUrlFromNavigationPulldown:function(t,e){var i=getNextUrlFromNavigationPulldown(t,e);i?t.location.href=i:alert("Already at the end or beginning of the list.")},writeRedirectFromNav:function(t){return t.$("form").append('<input type="hidden" name="redirect" value="'.concat(getNextUrlFromNavigationPulldown(t,!1),'">'))},handlePreviousNavButton:function(t){getNextUrlFromNavigationPulldown(t,!0)||t.$(":button[value=Previous]").remove()},registerQuickSelectGoButton:function(t,e){return _this.onReady(t,(function(){var i=t.$;i("#".concat(e,"_go")).click((function(){var n="[name='".concat(e,"']"),s=i(n).val();""!=s&&(t.location.href=s)}))}))},registerExpandingMultiValue:function(t,e,i,n){var s=t.$;_this.onReady(t,(function(){var o,r,a,l,c,u;function h(){(o=s("#".concat(e,"_ROW"))).find("script").remove(),r=o.html(),a=s("#".concat(e,"_TABLE_CONTAINER tbody")),l=o.find("#".concat(e,"_SIZE")),c=parseFloat(l.val()),u=o.find("#".concat(e,"_TEMPLATE")),n&&f(a.find(".".concat(e,"_subrecord_container"))),n&&p(a.find(".".concat(e,"_subrecord_container"))),i&&function(){var t=a.find(".".concat(e,"_subrecord_container"));g(t),v(t)}();var h="".concat(e,"_addmore");if(!a.parent().find("#".concat(h)).length){var m=s('<a class="addMoreA"></a>').attr({id:h,href:"#"}).html('<img src="/ats/css-base/add.png" class="addMoreImg"/>Add More').click((function(e){return e.preventDefault(),_this.setAccess(t,!1),d(),!1}));a.closest("table").after(m)}parseFloat(l.val())<1&&d()}function d(){var o=parseFloat(l.val());l.val(o+1),c+=1;var r='<tr class="subrecord_container '.concat(e,'_subrecord_container" id="').concat(e,"_").concat(c-1,'">').concat(u.html().replace(/_TEMPLATE/g,"_SUBRECORD_"+(c-1)),"</tr>");a.append(r);var h=s("#".concat(e,"_").concat(c-1));i&&g(h),n&&f(h),n&&p(h),v(h),triggerResize(t)}function p(e){e.each((function(){var e=s(this),i=e.find(".subrecord_min"),n=e.find(jqueryUniversalChangeSupportedTags).get(0);jqueryUniversalChange(t,n,(function(){return function(t,e){var i=s(t),n=parseFloat(e.html()),o=parseFloat(i.val());(isNaN(o)||n>=o)&&i.val(n+1)}(n,i),!0}))}))}function f(t){t.find(".remove_container").append(' greater than <span class="subrecord_min"></span>'),m(t)}function m(i){function n(t,e,i){var n=parseFloat(s(t).val()),o=parseFloat(e.val());i.html(n),!isNaN(o)&&n>=o&&(e.val(n+1),e.trigger("change"))}i.each((function(){var i=s(this),o=i.prev(".".concat(e,"_subrecord_container")),r=i.find(".subrecord_min");if(o.length){var a=i.find(jqueryUniversalChangeSupportedTags).filter(":first"),l=o.find(jqueryUniversalChangeSupportedTags).filter(":first").get(0);jqueryUniversalChange(t,l,(function(){return n(l,a,r),!0})),n(l,a,r)}else r.html("0")}))}function g(t){t.find(".remove_container").prepend('<a class="subrecord_remove"><img title="Remove" alt="remove" src="/ats/css-base/remove.png" /></a>')}function v(e){e.find(".subrecord_remove").click((function(e){_this.setAccess(t,!1),l.val(parseFloat(l.val())-1);var i=s(this).closest(".subrecord_container"),o=i.next(".subrecord_container");i.remove(),n&&m(o)}))}h(),s(":reset").click((function(t){o.html(r),h()}))}))},disableSubmitButtons:function(t){return t.$("input[type='submit']").attr("disabled","disabled"),!0},eformOptionalEventHideFields:function(t,e){function i(t,e){var i=$(t).find("input,select,textarea");$(i).each((function(t,i){e?$(i).prop("disabled",!1):$(i).prop("disabled",!0)})),e?$(t).show():$(t).hide()}_this.onReady(t,(function(){var n=(0,t.$)("#".concat(e)),s=n.closest("tr").nextUntil("tr.endEformEvent");n.change((function(){var t=n.is(":checked");i(s,t)})),n.trigger("change")}))}};function HierCheckboxModel(t,e,i){var n=t.$;this._rootNode={children:[]},this._allNodes=[],this._counter=0;var s=this;function o(e,i,r){var a=r.node,l=r.children;if(i=function(e,i,o,r,a){var l=e.name,c=e.value,u=e.isChecked,h=e.caption,d=e.url;r=void 0===r||"null"==r?null:r,a=void 0===a||"null"==a?null:a;var p,f=n("<li></li>");if(null!=r&&null!=a){p=n("<a></a>").attr("href","#".concat(c)),n(p).click((function(e){try{return lib[a](t,c,i)}catch(n){_log(n)}}));var m=n("<img />").attr("border","0").attr("src",r);n(p).append(m)}else null!=r&&(p=n("<img />").attr("src",r).attr("border","0"));p&&n(f).append(p);var g=n("<input />").attr("type","checkbox").attr("name",l).attr("value",c);u&&n(g).attr("checked","checked");if(n(g).click((function(e){!function(e,i){lib.setAccess(t,!1);var n=s._allNodes[i];if(function t(e){for(var i=e.children,n=0;n<i.length;n++)i[n].field.checked=e.field.checked,t(i[n])}(n),n.field.checked)for(var o=n.parent;null!=o&&null!=o.field;)o.field.checked=n.field.checked,o=o.parent}(0,i)})),n(f).append(g),d){d=0==d.indexOf("http://")?d:"http://"+d;var v=n("<a></a>").attr("target","_blank").attr("href",d).text(h);n(f).append(v)}else n(f).append(t.document.createTextNode(h));var _={html:f,field:g[0],children:[],parent:o};return _.parent.children.push(_),s._allNodes.push(_),_}(a,s._counter++,i),n(e).append(i.html),l.length>0){var c=n("<ul></ul>");n(i.html).append(c),n.each(l,(function(t,e){return o(c,i,e)}))}}this.render=function(){var t=n("script#".concat(e));i=n.parseJSON(i);var r=n("<ul></ul>");o(r,s._rootNode,i),n(r).insertAfter(t)}}function handleError(t,e,i){_log(new Error(t),!0)}function displayError(t,e,i){_log(t)}_this.isDevMode&&(_this.initDevLinks=function(){function t(t){this._useBase;var e=this;this.setToolAltOption=function(n){function s(){e._useBase=!1,i("div.devmenu a").css({background:"#eee"}),i("div.devmenu a.alttool").each((function(){var t=i(this),e=t.attr("href");e=e.replace("&usealt=N",""),t.attr("href",e)}))}function o(){e._useBase=!0,i("div.devmenu a").css({background:"orange"}),i("div.devmenu a.alttool").each((function(){var t=i(this),e=t.attr("href");e=e.replace("&usealt=N",""),e+="&usealt=N",t.attr("href",e)}))}(void 0===e._useBase||void 0!==n)&&(e._useBase=!0===n),i("a.dragalt").unbind("click.devtools").bind("click.devtools",(function(){s(),t.alert("Tools will modify the alt record (default behavior).")})),i("a.dragbase").unbind("click.devtools").bind("click.devtools",(function(){o(),t.alert("Tools will now modify the base records (for all companies)! \nDanger, this will effect all pages until you log-out or set it back to alt!")})),e._useBase?o():s()};var i=checkJQuery(t,t.$),n="devdivid",s=0;function o(){i("a.hidedev").click((function(t){t.preventDefault(),i(".debug,.devmenu").fadeOut()}))}i.extend(i.fn.disableTextSelect=function(){return this.each((function(){}))}),s&&s!=t.yOffset&&_this.onReady(t,(function(){t.scrollTo(0,s),s=0})),this.activateDevLink=function(){var e=i(this),s=e.attr("href");if(s&&!e.hasClass("newwindow")){var o=e.hasClass("wizarddevlink"),r=e.hasClass("search");return _this.addToolboxFunction(t,n,(function(){o?ajaxFillinPopup(t,n,s,null,!0,!0,!0):ajaxFillinPopup(t,n,s,null,!r,!1,!0)})),_this.showPopup(t,n),!1}return!0},_this.onReady(t,(function(){t.devDone||(i("body").children(":last").after("<div id=\"devdivid\" style='display: none;'><h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p></div>"),_this.addToolboxFunction(t,n+"_close",(function(){t.yOffset="number"==typeof t.pageYOffset?t.pageYOffset:t.document.documentElement?t.document.documentElement.scrollTop:t.document.body.scrollTop,s=t.yOffset,i("body").html("<h1>Reloading...</h1>"),t.location.reload()})),e.setToolAltOption(),i("a.showFieldNames").click((function(){return i("span.fieldName").show()})),function(){var s=null;t.document.body.onmouseup=function(){return s=null},"td"==t.fieldDelimiter?i("div.devfieldmenu").each((function(){var o=i(this).closest("td"),r=i(this).find("a[href*='GUI_FIELD_ID']:first").eq(0).attr("href").match(/GUI_FIELD_ID=\w*\d*/)[0].replace(/GUI_FIELD_ID=/,""),a=o.width(),l=o.height()-5,c="width: 10px; height: "+l+"px;",u="width: "+a+"px; height: 10px;",h='style="position: absolute;'+u+'text-align: center;float: left;clear: both;"',d='style="position: absolute;'+c+'"',p='style="display: block;'+u+'"',f='style="display: block;'+c+'overflow: hidden;"',m='style="border: 0; padding-top: '+(l/2-30)+'px;"',g=".uparrow,.rightcon,.leftarrow,.downcon",v='<div class="uparrow" '+h+"><a "+p+' href=""><img style="border: 0;" src="/ats/css-base/up.png"/></a></div><div class="leftarrow" '+d+"><a "+f+' href=""><img '+m+' src="/ats/css-base/left.png"/></a></div><div class="rightcon" style="left: '+(a-5)+'px; position: relative;"> <div class="rightarrow" '+d+"><a "+f+' href=""><img '+m+' src="/ats/css-base/right.png"/></a></div></div>',_='<div class="downcon"><div class="downarrow" '+h+"><a "+p+' href=""><img style="border: 0;" src="/ats/css-base/down.png"/></a></div></div>',b=i(this);b.disableTextSelect(),b.get(0).onmousedown=function(){return s=r};var y="/ats/admin/drag_move_field.jsp?end_field_id="+r;o.get(0).onmouseover=function(a){o.get(0).onmouseover=null,o.hover((function(a){null!=s&&s!=r&&(o.prepend(v),o.append(_),o.children(g).mouseup((function(){if(null!=s&&s!=r){var o=y+"&start_field_id="+s+"&dir="+i(this).attr("class").replace(/arrow/,"")+"&usealt="+(e._useBase?"N":"Y");_this.addToolboxFunction(t,n,(function(){return ajaxFillinPopup(t,n,o)})),_this.showPopup(t,n)}})))}),(function(){o.find(g).remove()})),o.trigger("mouseover")}})):i("div.devfieldmenu").each((function(){var o=i(this).closest("tr"),r=o.find("th"),a=i(this).find("a[href*='GUI_FIELD_ID']:first");if(a.length){a=a.eq(0).attr("href").match(/GUI_FIELD_ID=\w*\d*/)[0].replace(/GUI_FIELD_ID=/,"");var l="width: "+r.width()+"px; height: 1.5em; left: 0;",c='style="position: absolute;text-align: center;'+l+'"',u='style="'+l+'display: block;"',h='<div class="uparrow" '+c+"><a "+u+' href=""><img style="border: 0;" src="/ats/css-base/up.png"/></a></div>',d='<div class="downcon"><div class="downarrow" '+c+"><a "+u+' href=""><img style="border: 0;" src="/ats/css-base/down.png"/></a></div></div>',p=o.find("div.devmenu");p.disableTextSelect(),p.get(0).onmousedown=function(){return s=a};var f="/ats/admin/drag_move_field.jsp?end_field_id="+a;o.get(0).onmouseover=function(l){o.get(0).onmouseover=null,o.hover((function(){null!=s&&s!=a&&(r.prepend(h),r.append(d),o.find(".uparrow,.downcon").mouseup((function(){if(null!=s&&s!=a){var o=f+"&start_field_id="+s+"&dir="+i(this).attr("class").replace(/arrow/,"")+"&usealt="+(e._useBase?"N":"Y");_this.addToolboxFunction(t,n,(function(){return ajaxFillinPopup(t,n,o)})),_this.showPopup(t,n)}})))}),(function(){return o.find(".uparrow,.downcon").remove()})),o.trigger("mouseover")}}}))}(),i("a.dependtool").unbind().click((function(){var n=i(this).closest("div.devfieldmenu"),s=i(this).closest("div.devmenu").find("a[href*='GUI_FIELD_ID']:first").eq(0).attr("href").match(/GUI_FIELD_ID=\w*\d*/)[0].replace(/GUI_FIELD_ID=/,""),o=t.prompt("For what value?");n.replaceWith("<a onclick='window.location.reload()'>Stop</a>"),i("div.devfieldmenu").replaceWith((function(){var t=i(this).find("a[href*='GUI_FIELD_ID']:first").eq(0).attr("href").match(/GUI_FIELD_ID=\w*\d*/)[0].replace(/GUI_FIELD_ID=/,"");return"<a class='makedependlink' href='/ats/admin/field_make_depend.jsp?PARENT_GUI_FIELD_ID="+s+"&GUI_FIELD_ID="+t+"&value="+encodeURIComponent(o)+"&ajax=Y&usealt="+(e._useBase?"N":"Y")+"' > Make Dependant</a>"})),i("a.makedependlink").unbind().click((function(e){var n=i(this);e.preventDefault();var s=i(this).attr("href");return i.get(s,null,(function(e,i){"success"==i?n.remove():t.alert("failed to make dependant, check your console and get a developer")})),!1}))})),i("a.devmenulink").each((function(){this.onclick=e.activateDevLink})),o(),function(t){i(".showhidden").click((function(e){e.preventDefault(),""==t.location.search?t.location.search="?showhidden=Y":t.location.search.match(/showhidden=Y/)?t.location.search=t.location.search.replace(/[\?\&]showhidden=Y/,""):t.location.search+="&showhidden=Y"}))}(t),function(){var t=i("select[name='ALT_COMPANY_ID']");t.length&&!t.val()&&t.val("<%=companyId%>")}()),t.devDone=!0}))}return function(e){return e._ss_devLinks||(e._ss_devLinks=new t(e)),e._ss_devLinks}}()),window.onerror=!1===init.addGlobalErrorHandler?null:this.isDevMode?displayError:handleError,$.each(lib,(function(t,e){return _this[t]=e})),_this.perform_cookie_test(),onLoadCallback.call(this,this),this.loaded=!0}
|
console-api |
debug |
URL: https://lausd.atenterprise.powerschool.com/resources/js/library.bundle.js?v=202105210854(Line 2)
Message:
Assigning value to moduleName Lib function Lib(init){if(init&&init.getGlobalInstance&&window.top._lib)return window.top._lib;window.top._lib||(window.top._lib=this);var isActiveDirectory=init.isActiveDirectory,companyId=init.companyId,sessionId=init.sessionId,onLoadCallback=init.onLoad||function(){};this.isDevMode=configuration.developmentMode,this.loaded=!1;var _this=this,parents=[],kids=[],hiddenDivs={},checkboxElements=[],jqueryUniversalChangeSupportedTags=":input[type!=hidden]",jqueryUniversalChangeSupportedEvents=["change","select","click","blur"],cookie_test=!1,dependentFieldCtx=null,_log=function(t,e){return logger.log(t)};function setGlobalData(t,e){_log("Setting '".concat(t,"' attribute to value '").concat(e,"'"));try{window&&window.top?$(window.top).data(t,e):_log("Can not set '".concat(t,"' attribute with value '").concat(e,"', top window is not available."))}catch(i){_log(new Error("Can not set '".concat(t,"' attribute with value '").concat(e,"': ").concat(i.message)))}}function getGlobalData(t){_log("Getting '".concat(t,"' attribute value."));try{if(window&&window.top){var e=$(window.top).data(t);return _log("Attribute '".concat(t,"' has value '").concat(e,"'")),e}return _log("Can not get '".concat(t,"' attribute value, top window is not available.")),null}catch(i){return _log(new Error("Can not get '".concat(t,"' attribute value: ").concat(i.message))),null}}function checkJQuery(t,e){return e||t.$||$}function getModal(t){return t.document.thismodal}function createModal(t,e,i){function n(e){_log("Doing resize!!!"),triggerResize(t,!1)}(e=e||{}).paddingTop=80,e.onOpen=mergeFunctions(e.onOpen,(function(e){$(t).on("resize",n),function(e){doModalContentFix(t,e)}(e)})),e.onClose=mergeFunctions(e.onClose,(function(){return $(t).off("resize",n)})),e.openOnCreate=!1,e.context=t;var s=Modal.createModal(e);return s&&(i&&(t.document.thismodal=s),s.open()),s}function doModalContentFix(t,e){var i=$(e.getContent(!0)),n=$(i);n.closest(".vex").css("padding-top","40px"),n.closest(".vex").find(".vex-dialog-input").css("overflow","auto"),n.find("#PageParagraphContainer").removeAttr("id"),n.find("#PageMainContainer").removeAttr("id"),n.find('input[type="submit"], input[type="reset"], input[type="file"]').addClass("vex-dialog-button vex-dialog-button-primary ss-modal-ok").css({"margin-top":"5px",float:"none"}),n.find('input[type="submit"]').click((function(){var e=$(document.getElementsByTagName("form")[1]),i=n.find("#footContainer"),s=i.find(".pagebuttons"),o=$('<img id=\'bulkActionInProgressSpinner\' src="https://cdn.atenterprise.powerschool.com/images/loading.gif" class="preventMultipleSubmitButtonClickSpinner" />');if("undefined"!=typeof e.attr("action")&&-1!=e.attr("action").indexOf("mass_transition_documents")){var r=$("<h4 id='bulkActionCompletedP'>Your requested action is complete.</h4>"),a=$("<h4 id='bulkActionFailedP' style='color:red' class='red ajaxerror'>One or more records have failed. Please check your pending items queue</h4>"),l=$("<h4 id='bulkActionInProgressP'>Bulk action requested is in progress</h4>"),c=$("<h4 id='emptySignature' style='color:red'class='red ajaxerror'>Signature field cannot be empty</h4>");try{i.length>1&&null!=i[1]&&void 0!=i[1]&&$($(".vex #footContainer")[0]).hide(),event.preventDefault();var u=$(".passwordfield").attr("value");e.find('input[id="authenticatedoc"]').length>0||void 0!==u&&null!==u&&""!==u.trim()?(s.hide(),i.append(o),i.append(l),$.ajax({data:e.serialize(),type:e.attr("method"),url:e.attr("action"),success:function(e){-1==e.indexOf("ajaxerror")?(o.hide(),l.hide(),i.append(r),t.location.reload()):(o.hide(),l.hide(),alert(e),event.stopPropagation())},error:function(t){o.hide(),l.hide(),i.append(a),event.stopPropagation()}})):(i.append(c),$(".passwordfield").focus((function(){c.hide()})))}catch(h){o.hide(),l.hide(),i.append(a)}}else s.hide(),i.append(o)})),n.find('input[type="button"]').addClass("vex-dialog-button vex-dialog-button-secondary ss-modal-cancel").css({"margin-top":"5px",float:"none"}),$(".linkbutton, .wizardlink").click((function(){return t.setTimeout((function(){doModalContentFix(t,e),triggerResize(t,!1)}),15)}))}function doModalOp(t,e,i){var n=getModal(t);if(n&&(n.isOpen()||!e))try{i(n,n.getContent(!0))}catch(s){_log(s)}}function triggerResize(t,e,i){(e=!1!==e)&&$(t).triggerHandler("resize"),i=!0===i,doModalOp(t,!0,(function(e,n){var s=t._triggerResizeQueue||{timeoutId:null};t._triggerResizeQueue=s,null!==s.timeoutId&&window.clearTimeout(s.timeoutId),s.timeoutId=window.setTimeout((function(){try{e.resizeContent(i)}catch(t){_log(t)}}),15)}))}function isChecked(t,e){return getCheckboxElement(t,e).checked}function getCheckboxElement(t,e){return checkboxElements[e]}function checkCheckBox(t,e,i,n){var s=getCheckboxElement(t,e);return s&&(s.checked=i,n&&lib.assureParentSelected(t,e)),!0}function emailCheck(t,e,i){var n="[^\\s".concat('\\(\\)><@,;:\\\\\\"\\.\\[\\]',"]"),s="".concat(n,"+"),o="(".concat(s,"|").concat('("[^"]*")',")"),r=new RegExp("^".concat(o,"(\\.").concat(o,")*$")),a="[a-zA-Z0-9](?:[a-zA-Z0-9-]*[a-zA-Z0-9]+)*",l=new RegExp("^".concat(a,"(\\.").concat(a,")+\\s*$")),c=t.match(/^\s*(.+)@(.+)$/);if(null==c)return invalidField(e,i,"The email address seems incorrect (check @ and .'s)"),!1;for(var u=c[1],h=c[2],d=0;d<u.length;d++)if(u.charCodeAt(d)>127)return invalidField(e,i,"The email username contains invalid characters."),!1;if(null==u.match(r))return invalidField(e,i,"The email username doesn't seem to be valid."),!1;var p=h.match(/^\[(\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})\]$/);if(null!=p){for(var f=1;f<=4;f++)if(p[f]>255)return invalidField(e,i,"Email destination IP address is invalid!"),!1;return!0}var m=h.match(l);if(null==m)return invalidField(e,i,"The email domain name does not seem to be valid."),!1;if(!(m[1].length>2))return invalidField(e,i,"The email address has an invalid tld domain. Are you missing .com?"),!1;if(h.length>255)return invalidField(e,i,"The email address has to long a domain name."),!1;for(var g=0;g<m.length-1;g++)if(m[g].length>63)return invalidField(e,i,"The email address domain name is to long."),!1;return!0}function getFieldValue(t,e){var i=t.$,n="",s=e.type||i(e).attr("type");if(s)if(s.indexOf("select-")>=0)e.selectedIndex>=0&&(n=e.options[e.selectedIndex].value);else if(s.indexOf("check")>=0||s.indexOf("radio")>=0){if(e.checked&&(n=e.value),e.length)for(var o=0;o<e.length;o++)e[o].checked&&(n=e[o].value)}else n=e.value;else if(e.length)for(var r=0;r<e.length;r++)e[r].checked&&(n=e[r].value);return null==n&&(n=""),n}function reassignFieldListeners(t,e){var i;if(i=t.length?t[0].form:t.form){for(var n=0;n<i.validatorFields.length;n++)i.validatorFields[n]==t&&(i.validatorFields[n]=e);for(var s=0;s<i.maskValidatorFields.length;s++)i.maskValidatorFields[s]==t&&(i.maskValidatorFields[s]=e)}}function validNewField(t,e,i){var n;if(void 0===i[0]&&(i[0]=e[0]),!(n=e.length?e[0].form:e.form))return!0;for(var s=0;s<n.validatorFields.length;s++)if(n.validatorFields[s]==e&&!n.validatorFunctions[s](t,i))return!1;for(var o=0;o<n.maskValidatorFields.length;o++)if(n.maskValidatorFields[o]==e&&!n.maskValidatorFunctions[o](t,i,n.maskValidatorMasks[o]))return!1;return!0}function validFields(t,e){t.runningValidFields=!0;for(var i=0;i<e.validatorFunctions.length;i+=1)if(fieldInForm(e,e.validatorFields[i])&&!e.validatorFunctions[i](t,e.validatorFields[i]))return t.runningValidFields=!1,!1;for(var n=0;n<e.maskValidatorFunctions.length;n+=1)if(fieldInForm(e,e.maskValidatorFields[n])&&!e.maskValidatorFunctions[n](t,e.maskValidatorFields[n],e.maskValidatorMasks[n]))return invalidField(t,e.maskValidatorFields[n],"".concat(e.maskValidatorFields[n].value," is not in the correct format.")),t.runningValidFields=!1,!1;return t.runningValidFields=!1,!0}function fieldInForm(t,e){function i(e){for(var i=0;i<t.elements.length;i++)if(t.elements[i]==e)return!0;return!1}if(!e)return!0;if(e.length&&!e.type){if(e.length<500){for(var n=0;n<e.length;n++)if(!i(e[n]))return!1}else if(!i(e[0]))return!1;return!0}return i(e)}function getMultiNumberChecked(t,e){var i=0;if(e.length)for(var n=0;n<e.length;n++)e[n].checked||e[n].selected?i++:e[n].options&&(i+=getMultiNumberChecked(t,e[n].options));else e.options&&e.options.length>0?i=getMultiNumberChecked(t,e.options):(e.checked||e.selected)&&(i=1);return i}function getFormObjects(t,e){var i=[],n=t.document.forms,s=0;for(s=0;s<n.length;s+=1){var o=n[s];o.elements[e]&&i.push(o)}return i}function stripSymbols(t){var e=t.value;void 0!==e&&(t.value=e.replace(/(\$|\,|\(|\)|\&)/g,""))}function getFormattedDate(t,e){var i=t.value.replace("-","/"),n=i.lastIndexOf("/");if(i.length-n==3){var s="20",o=i.substring(n+1,n+3);o>"30"&&(s="19"),i=i.substring(0,n+1)+s+o}return i}function isValidDate(t,e){var i,n,s,o,r;for(r=1;r<t.length;r++){var a=t.substring(r,r+1);if(isNaN(a)&&"/"!=a&&"-"!=a&&" "==a)return!1}if(""!=(o=t)){if((r=o.indexOf("/"))<1)return!1;if((i=o.substring(0,r)).length<1||i.length>2||i.charAt(0)>"9"||0==i&&1==r)return!1;if("0"==i.substring(0,1)&&(i=i.substring(1,2)),i=parseInt(i),!e){if((r=(o=o.substring(r+1)).indexOf("/"))<1)return!1;if((n=o.substring(0,r)).length<1||n.length>2||n.charAt(0)>"9")return!1;"0"==n.substring(0,1)&&(n=n.substring(1,2)),n=parseInt(n)}if(4!=(s=o.substring(r+1)).length||s.charAt(0)<"0"||s.charAt(0)>"9")return!1;if(s=parseInt(s),i<1||i>12||n<1||n>31||s<1900||s>2299||2==i&&n>29||2==i&&29==n&&s%4!=0||4==i&&n>30||6==i&&n>30||9==i&&n>30||11==i&&n>30)return!1}return!0}function isValidBirthDate(t,e,i,n){var s=!0,o=t.value;if(o.length>0){e&&(o=o.replace(/\//,"/01/"));var r=new Date(o),a=new Date,l=new Date;a.setFullYear(a.getFullYear()-n),l.setFullYear(l.getFullYear()-i),s=r>=a&&r<=l}return s}function isValidDateTime(t){var e=t.value.split(" ");return 3==e.length&&(isValidDate(e[0]),!!isValidStandardTime(e))}function isValidStandardTime(t){if(3!=t.length)return!1;if(5!=t[1].length)return!1;if(2!=t[2].length)return!1;var e=t[1].substring(0,2);if(isNaN(e))return!1;if(":"!=t[1].charAt(2))return!1;e=t[1].substring(3,5);return!isNaN(e)&&("am"==t[2].toLowerCase()||"pm"==t[2].toLowerCase())}function isValidNumber(t){var e,i;if(""!=t.value){if(e=0,"-"==t.charAt(0)&&(e=1,1==t.length))return!1;for(i=0;e<t.length;e++)if("."==t.charAt(e)){if(i>0||e==t.length-1)return!1;i++}else if(t.charAt(e)<"0"||t.charAt(e)>"9")return!1}return!0}function jqueryUniversalChange(t,e,i){(0,t.$)(e).bind(jqueryUniversalTriggerType(t,e),i)}function jqueryUniversalTriggerType(t,e){var i,n=t.$;switch(e.tagName.toUpperCase()){case"INPUT":switch(n(e).attr("type").toUpperCase()){case"RADIO":case"CHECKBOX":case"BUTTON":i="click change";break;case"PASSWORD":case"TEXT":i="blur change";break;case"FILE":i="change";break;default:i="change select click blur"}break;case"TEXTAREA":case"SELECT":i="blur change";break;default:i="change select click blur"}return i}function checkFormatting(t,e,i){var n=i,s=e,o=!0;return"00008698"!=companyId&&!isActiveDirectory&&t.document.location.href.indexOf("employee_form")<0&&(null!=n&&""!=n.value||null==s||""==s.value||(s=s.value).length<6&&(invalidField(t,e,"The username is invalid. Usernames must be at least ".concat(6," characters in length, should not include spaces, and must not be identical to the password.")),o=!1)),o}function makeTestCookie(){document.cookie="cookietest=yes;path=/"}function findTestCookie(){if(document.cookie.length>0&&window.navigator.cookieEnabled&&-1!==document.cookie.indexOf("cookietest="))return!0;return!1}function toolboxRegisterSelection(t,e){var i=t.$,n=i("#".concat(e,"_action_select")),s=n.closest("form");s.find("#inlineContent").length||s.append('<div id="inlineContent" style="height: 30ex"></div>');var o=function(){i("#inlineContent").html("").css("height","30ex"),t.toolbox[e]._parent.append(t.toolbox[e])};i('form input:reset[name="undo"]').click((function(){return o()})),n.change((function(){var n=i("#".concat(e,"_action_select option:selected")).attr("value"),s=!1;if("default"==n)return o(),!1;if(t.toolbox=t.toolbox||{},t.toolbox[e]=t.toolbox[e]||i("#toolbox_".concat(e)),t.toolbox[e]._parent=t.toolbox[e]._parent||t.toolbox[e].parent(),i("#toolbox_".concat(e)).remove(),i("#".concat(n)).length){var r=i("#".concat(n)).clone();r.attr("class",r.attr("id")),r.attr("id",""),i("#inlineContent").html(" ").append(r),r.show()}else s=!0;toolboxRunFunction(t,n),s&&t.document.forms[0].submit()}))}function toolboxRegisterActionGo(t,e){(0,t.$)("#".concat(e,"_go")).click((function(){var i=t.$,n=i("#".concat(e,"_action_select option:selected")).attr("value"),s=!1;if("default"===n)return t.alert("Please select an action to perform."),!1;if("all"===i('select[name="ACTION_TYPE"]').val()){if("RA00000002"===n)return t.alert("At most 100 recipients can be assigned eForms at a time. Please select no more than 100 recipients and try again."),!1}else if(0===i("div.rs tbody :checkbox:checked").length)return t.alert("Please select the records on which to perform the action."),!1;i("#".concat(n)).length?lib.showPopup(t,n):(s=!0,toolboxRunFunction(t,n)||lib.addHiddenField(t,n,n)),s&&t.document.forms[0].submit()}))}function closePopupFirst(t,e){Modal.closeAll(t,(function(){return e(t)}))}function toolboxRunFunction(t,e){if(!t.toolboxFunctions||!t.toolboxFunctions[e])return!1;try{t.toolboxFunctions[e](),triggerResize(t)}catch(i){return!1}return!0}function toolboxAddCancel(t,e){doModalOp(t,!0,(function(t,e){t.enableCancel(!0),$(e).find("input[name='cancel']").attr("onclick","").click((function(e){return e.preventDefault(),t.close(),!1}))}))}function canMakeAjaxCall(t,e){return"#"!=t||(_log("NOT making Ajax call, no valid URL provided (url is '#')."),!1)}function ajaxFillinPopup(t,e,i,n,s,o,r){if(canMakeAjaxCall(i,n)){var a=t.$;null==n?n="ajax=y":-1==n.indexOf("ajax=")&&(n+="&ajax=y");var l="get";n.length+i.length>2e3&&(n+="&fake_post=Y",l="post"),a(t.document).ajaxError((function(t,e,i){return _log("Server error: ".concat(e.status," url: ").concat(i.url))}));var c=getModal(t);c&&c.isOpen()?(dependentFieldCtx=".searchsoft-modal",a[l](i,n,(function(i,l){if("success"!=l)throw"AJAX error getting content";var u=a(c.getContent(!0)),h="div#inlineContent",d=a(u).find("div#inlineContent");d.length||(h=(d=a(u).find("div#".concat(e))).length?"div#".concat(e):null),c.setContent(i,h),d=a(c.getContent(!0)),afterAjaxPopProcess(t,e,d,n,s,o,r)}),"text").always((function(){dependentFieldCtx=null}))):a.get(i,n,(function(i,l){if("success"!=l)throw"AJAX error getting content";var c=a("#inlineContent div.".concat(e)).html(i);a("#inlineContent").css("height","auto"),afterAjaxPopProcess(t,e,c,n,s,o,r),lib.initForms(t)}),"text")}}function afterAjaxPopProcess(t,e,i,n,s,o,r){var a=t.$;lib.initForms(t),lib.addCheckboxApplicants(t,e),toolboxAddCancel(t,e),addMissingPopupRedirect(t,e),alwaysIsChanged(t,e),_this.isDevMode&&(i.find(".devmenulink, .wizardpopup").addClass("wizardlink").removeClass("wizardpopup"),i.find("div.rs a[href!='#ConfirmDelete'], div.rsrange a[href!='#ConfirmDelete']").addClass("wizardlink"),r=!0),s?hijackPopupSubmit(t,e,n,s,o,r):popUpFormSpinner(t);var l=getModal(t);(l&&doModalContentFix(t,l),i.find(".wizardlink").click((function(i){var n=a(this).attr("href");if(canMakeAjaxCall(n,null)){if(i.preventDefault(),l){var c=l.getContent(!0);a(c).find("form").hide().after("<h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p>")}return ajaxFillinPopup(t,e,n,null,s,o,r),!1}})),o)&&i.find(".linkbutton").each((function(){this.onclick=function(){return!0},a(this).click((function(i){var c=a(this).attr("href");if(canMakeAjaxCall(c,n)){if(i.preventDefault(),l){var u=l.getContent(!0);a(u).find("form").hide().after("<h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p>")}return ajaxFillinPopup(t,e,c,n,s,o,r),!1}}))}));l&&lib.addStyleClasses(t,l.getContent(!0)),lib.addStyleClasses(t,"#inlineContent .".concat(e)),triggerResize(t)}function addMissingPopupRedirect(t,e){var i=t.$;if(!i("input[name='searchpage']").length){var n=t.location;doModalOp(t,!0,(function(t,e){return i(e).find("form").append('<input type="hidden" name="searchpage" value="'.concat(n.pathname).concat(n.search,'" />'))}))}}function alwaysIsChanged(t,e){var i=t.$;doModalOp(t,!0,(function(t,e){return i(e).find("input[name='is_changed']").val("true")}))}function popUpFormSpinner(t){var e=t.$;doModalOp(t,!1,(function(t,i){return e(i).closest("form").submit((function(t){var i=e(this),n=i.get(0),s=n.onsubmit,o=!s||s.apply(n);return!1!==o?i.attr("target")&&0===i.attr("action").lastIndexOf("/servlet/jasper",0)?(i.hide().after("<div id='reportmessage'><p>Your report will be downloaded shortly. This could take up to several minutes. Feel free to close this window.</p><p>If your report does not download shortly, please go back and try again.</p><p><a href='#' id='submitshowformagain'> Go Back to Form </a></p></div>"),e("#submitshowformagain").click((function(t){return t.preventDefault(),i.next("#reportmessage").remove(),i.show(),!1}))):i.hide().after("<h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p>"):t.preventDefault(),o}))}))}function hijackPopupSubmit(t,e,i,n,s,o){var r=t.$;doModalOp(t,!1,(function(a,l){return r(l).find("form:not([target])").submit((function(l){l.preventDefault();var c=r(this).prop("onsubmit");if(!c||c.apply(this)){var u=r(this).serialize();u+="&ajax=y";var h=r(this).attr("action"),d=r(this).attr("method");d=null==d||"GET"==d.toUpperCase()?"get":"post";var p=r("<div><h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p></div>").attr("id",e);return a.setContent(p),r[d](h,u,(function(l,c){if("success"!=c)throw new Error("AJAX error");if(s){var d=p.html(l);afterAjaxPopProcess(t,e,d,i,n,s,o)}else/error has occured/.test(l)&&o?(p.html("<h1> Failure </h1>"),p.append("<p>CAUTION: Developer <a id='hijackretry' href='#'>Retry</a>. Will not provide success or failure message! Check your console</p>"),p.append("<xmp> ".concat(l,"</xmp>")),r("#hijackretry").click((function(){return r.post(h,u)}))):/ajaxerror/.test(l)&&-1==h.indexOf("/ats/application/detail/college_attended_form")?p.html(l):(p.html("<h1> Success </h1>"),a.close())})),!1}}))}))}function invalidField(t,e,i){var n=$(e).closest(".vex-dialog-input");n.find(".pagebuttons").show(),n.find(".preventMultipleSubmitButtonClickSpinner").remove(),t.fieldPrompt?t.fieldPrompt(e,i):t.alert(i)}function trimArray(t){for(var e=[],i=0,n=0;n<t.length;n++)e[i++]=t[n];return e}function getNextUrlFromNavigationPulldown(t,e){var i=e?"prev":"next",n=(0,t.parent.frames[0].$)("select[name=navchoice] option:selected")[i]();if(0!=n.length){var s=n.val(),o=s.substring(s.indexOf(",")+1,s.lastIndexOf(",")),r=s.substring(s.lastIndexOf(",")+1);o+="?".concat(r);t.location;return o}}function displayFn(t){return t?"".concat(t.toString().replace(/[\s]+/gim," ").substr(0,50),"..."):"null function"}function loadJsSource(t){return $.ajax({url:t,dataType:"text",async:!1}).responseText}setGlobalData("Lib.accessNextPage",!0),setGlobalData("Lib.loading",!1);var lib={pageListeners:[],log:function(t,e){_log("Call to deprecated Lib.log() function (should call Utils.log() directly)",!0),_log(t,e)},getCookie:function(t){var e=document.cookie.split(/\s*;\s*/),i=null;return $.each(e,(function(e,n){var s=n.split("=");if(s[0]==t)return i=s[1],!1})),i},getParam:function(t){var e=location.href,i=e.indexOf("?");if(i<0)return null;var n=(e=e.substr(i+1)).split("&"),s=null;return $.each(n,(function(e,i){var n=i.split("=");if(2==n.length){var o=n[0];return t==o?(s=n[1],!1):void 0}})),s},getModal:function(){return Modal},doSlowPageLoad:function(t,e){function i(t){var i=t.onReadyFunctions,n=i?i.length:0;_log("In doSlowPageLoad(".concat(e,"), win.onReadyFunctions.length=").concat(n))}var n=t.$;t.spinnerOn=!0,n(t.document).ready((function(){i(t),n("#slowpageloading").fadeIn(400),_log("Doing doSlowPageLoad(".concat(e,")")),window.setTimeout((function(){i(t),n("body").load(e,(function(){t.spinnerOn=!1;var e=t.onReadyFunctions||[];i(t);for(var n=0;n<e.length;n++)try{var s=e[n],o=displayFn(s);_log("Running onReadyFunction:\n".concat(o)),s(t)}catch(r){_log(r)}}))}),1e3)}))},renderHierCheckboxModel:function(t,e,i){new HierCheckboxModel(t,e,i).render()},openNode:function(t,e){return!0},toggleNode:function(t,e,i){var n;(i=void 0==i||!0===i)&&(n=t.document.getElementById("".concat(e,"_img")));var s=t.document.getElementById(e);"none"==s.style.display?(s.style.display="",i&&(n.src="/ats/images/minus.gif")):(s.style.display="none",i&&(n.src="/ats/images/plus.gif"))},assureChildrenMatch:function(t,e){var i=parents[e];if(i)for(var n=isChecked(t,e),s=i.length,o=0;o<s;o++){var r=i[o];checkCheckBox(t,r,n,!1),lib.assureChildrenMatch(t,r)}return!0},assureParentSelected:function(t,e){var i=kids[e];return i&&checkCheckBox(t,i,!0,!0),!0},setCheckboxElements:function(t){checkboxElements=[];for(var e=0;e<t.document.forms[0].elements.length;e++){var i=t.document.forms[0].elements[e];if(i&&"checkbox"==i.type){var n=i.value;checkboxElements[n]=i}}},rmimg:function(t,e){t.document.getElementById(e)||(t.document.getElementById("".concat(e,"_img")).style.display="none")},setParent:function(t,e,i){kids[e]=i;var n=parents[i];n||(n=[]),n=n.concat(e),parents[i]=n},initPageCollapse:function(t){for(var e in hiddenDivs)lib.pageCollapse(t,e)},pageCollapse:function(t,e){var i=t.getElementById("".concat(e,"-collapse-button")),n=t.getElementById(e);n&&i&&("none"==n.style.display?(n.style.display="",delete hiddenDivs[e],i.src="/ats/images/minus.gif"):(n.style.display="none",hiddenDivs[e]||(hiddenDivs[e]=!0),i.src="/ats/images/plus.gif"))},pageCollapseAtsSearchMultiPage:function(t,e){var i=t.$,n="#".concat(e,"-nonWrapper");i(".subPageContent").not(n).addClass("subPageContentHidden"),i(n).toggleClass("subPageContentHidden"),setTimeout((function(){i("html, body").animate({scrollTop:i("#".concat(e,"-wrapper")).offset().top},350)}),351)},checkSessionId:function(t){if(null==sessionId||null==t||""==sessionId||""==t||"null"==sessionId||"null"==t)return!0;if(t==sessionId)return!0;var e=_this.getCookie("SSS_SESSION_ID");return t==e&&(sessionId=e,!0)},helpLink:function(t,e){return t.alert(e),!1},importStatusPopup:function(t,e){var i;switch(e){case"success_annual":i="<b>Annual/Yearly import of all the Florida Certifications and Courses is successful!!</b>";break;case"success_quarterly":i="<b>Quarterly import of the Florida Certifications and Courses is successful!!</b>";break;case"sftp_yearly":i="<b>Exception occurred during import : </b> <br> <b>YearlyImports</b> folder is missing in the SFTP location!";break;case"sftp_quarterly":i="<b>Exception occurred during import : </b> <br> <b>QuarterlyImports</b> folder is missing in the SFTP location!";break;case"ccd_missing":i="<b>Exception occurred during import : </b> <br> <b>CCD</b> folder is missing in the SFTP location!";break;case"not_xlsx_format":i="<b>Exception occurred during import : </b> <br> File(s) should be of .xlsx formats only, other formats are not allowed.";break;case"failure_missing_del":i="<b>Exception occurred during import : </b> <br> <b>Delete</b> column is missing or not in the right column on one of the sheets.<br> When performing Quarterly Imports, Delete columns must be present on all sheets, here's the places to check : <br> 1. <b>Delete</b> column should be in the 11th column for the All Certifications sheet<br> 2. <b>Delete</b> column should be in the 3rd column for all of the Special Certifications sheet<br> 3. <b>Delete</b> column should be in the 11th column for the Dual Certifications sheet<br> 4. <b>Delete</b> column should be in the 7th column for the All Courses sheet";break;case"yearly_missing_file":case"quarterly_missing_file":i="<b>Exception occurred during import :</b> <br> Files are missing or names mismatch in the SFTP location for "+e.split("_")[0]+" import :<br> NOTE : .xlsx files should be available with names in below formats : <b>Certifications_(school_year) or Certifications_(school_year)_(quarter)</b> and <br> <b>Courses_(school_year) or Courses_(school_year)_(quarter)</b>";break;case"errors":i="<b>Exception occurred during import.</b> <br> It might be because of following reasons :<br> 1. invalid certification or course data<br> 2. missing or incomplete data<br> Note : Please refer to logs in SFTP site and check latest log file for more details.";break;default:i="Unknown exception occurred during import of CCD Certifications and Courses!!"}if(i.length>0)return i},removeFileUpload:function(t,e){var i=t.$,n="#".concat(e),s="".concat(n,"_remove"),o="".concat(n,"_view"),r="".concat(n,"_hidden_remove");i(s).click((function(){var t=i(this),e=i(n);t.css("display","none"),i(o).css("display","none"),i(r).val(e.val()),e.val(null),t.closest("td").find('input[type="button"]').val("Upload a File")}))},checkEmail:function(t,e){var i=!0,n=e.value;return n.length>0&&(i=emailCheck(n,t,e)),i},selectLocation:function(t){var e=t.$,i=e("select[name='COMPANY_ID']"),n=function(){return document.cookie="COMPANY_ID=".concat(i.val(),"; path=/")};n(),i.change((function(){e("select[name='action']").val("default"),n(),e("#inlineContent").html(" ")}))},checkConfirmEmail:function(t,e){var i,n=(0,t.$)("#EMAIL").val().trim().toLowerCase();return n!=(i=e.value.trim().toLowerCase())?(invalidField(t,e,"Confirm Email should match Email."),!1):n==i||void 0},checkRequiredRadio:function(t,e){var i=!1,n=t.$;if("none"==n("#".concat(n(e).attr("name"),"_ROW")).css("display"))return!0;if(e.length)for(var s=0;s<e.length;s++)e[s].checked&&(i=!0);else e.checked&&(i=!0);return!!i||(invalidField(t,e,"You have not filled out all required answers on this page."),!1)},initForms:function(t){function e(t){t.initialized||(t.validatorFunctions=new Array(0),t.validatorFields=new Array(0),t.maskValidatorFields=new Array(0),t.maskValidatorFunctions=new Array(0),t.maskValidatorMasks=new Array(0),t.initialized=!0)}var i=t.document.forms;if(i)for(var n=0;n<i.length;n+=1){e(i[n])}else $("form").whenExists((function(){e(this)}))},checkRequired:function(t,e){var i=t.$,n=i(e),s=n.attr("name"),o=i("#".concat(s,"_ROW"));if((o.length>0?o:n.parents("tr").eq(0)).is(":visible")&&""==getFieldValue(t,e)){var r=s||n.attr("id");logger.log("## checkRequired - INVALID (".concat(r,")")),logger.log(e);var a=i('input[name="customValidationMessage"]');return invalidField(t,e,a.length>0&&""!=a.val()?a.val():"You have not filled out all required fields on this page."),!1}return!0},validForm:function(t,e,i){return!!lib.checkAccess()&&(t.runningValidFields=!0,"applicant.view"!=i&&"dbuser.pwd_no_libraryjsp"!=i&&(i.match("dbuser")||i.match("applicant")&&!i.match("applicant_type"))&&!checkFormatting(t,e.elements.NAME,e.elements.PWD)?(t.runningValidFields=!1,!1):(t.runningValidFields=!1,validFields(t,e)))},compressFormQuery:function(t,e,i){if(!lib.checkAccess())return!1;var n=t.$,s=n(e).find(":input").filter((function(){return""!=n(this).val()})).serialize(),o="".concat(n(e).attr("action"),"?").concat(s);return["/ats/application/applicants","/ats/employer/admin/employee_search_results","/ats/employer/admin/employee"].includes(n(e).attr("action"))?n.post("/servlet/support/login/encryptQueryString",{queryString:s,actionUrl:n(e).attr("action")},(function(e){t.location.href=e.encryptedString}),"json"):t.location.href=o,!1},encryptQueryString:function(t,e,i,n){i.preventDefault();var s=t.$,o=s(e).find(":input").serialize();return s.post("/servlet/support/login/encryptQueryString",{queryString:o,actionUrl:n},(function(e){t.location.href=e.encryptedString}),"json"),!1},appendMulti:function(t,e,i){lib.initForms(t);var n=getFormObjects(t,e),s=0;for(s=0;s<n.length;s+=1){var o=n[s],r=new Array(i),a=o.elements[e];o.validatorFunctions=o.validatorFunctions.concat(r),o.validatorFields=o.validatorFields.concat(a)}},multiCheck:function(t,e){var i=getMultiNumberChecked(t,e),n=t.$,s="".concat(n(e).attr("name"),"_ROW");return!(n("[id='".concat(s,"']")).last().is(":visible")&&i<1)||(invalidField(t,e,"You have not filled out all required answers on this page."),!1)},reqAllMultiCheck:function(t,e){var i=getMultiNumberChecked(t,e),n=Array.from(e).filter((function(t){return"checkbox"===t.type})).length,s=t.$,o="".concat(s(e).attr("name"),"_ROW");return!(s("[id='".concat(o,"']")).last().is(":visible")&&i<n)||(invalidField(t,e,"You have not filled out all required answers on this page."),!1)},appendMask:function(t,e,i){lib.initForms(t);var n,s=e;-1!=e.indexOf(":::")&&(s=e.substring(0,e.indexOf(":::")),-1!=(e=e.substring(e.indexOf(":::")+3)).indexOf(":::")&&(n=e.substring(0,e.indexOf(":::"))));var o=getFormObjects(t,s),r=0;for(r=0;r<o.length;r+=1){var a=o[r],l=a.elements[s],c=new Array(i),u=new Array(l),h=new Array(n);a.maskValidatorFunctions=a.maskValidatorFunctions.concat(c),a.maskValidatorFields=a.maskValidatorFields.concat(u),a.maskValidatorMasks=a.maskValidatorMasks.concat(h)}},append:function(t,e,i){lib.initForms(t);var n=getFormObjects(t,e),s=0;for(s=0;s<n.length;s+=1){var o=n[s],r=o.elements[e],a=new Array(i),l=new Array(r);o.validatorFunctions=o.validatorFunctions.concat(a),o.validatorFields=o.validatorFields.concat(l)}},checkSize:function(t,e){e>0&&t.value.length>e&&(t.value=t.value.substring(0,e),alert("You have reached the maximum size for this field"))},checkSearchNumber:function(t,e){stripSymbols(e);var i=e.value;if(void 0===i)return!0;if(i.indexOf(">")>0||i.indexOf("<")>0)return invalidField(t,e,"An invalid number was entered in this field. If you are using > or <, please make sure it is the first symbol in the field."),!1;var n=i;return 0!=n.indexOf(">")&&0!=n.indexOf("<")||(n=i.substr(1)),!!isValidNumber(n)||(invalidField(t,e,"An invalid number was entered in this field."),!1)},checkNumber:function(t,e){return stripSymbols(e),!!isValidNumber(e.value)||(invalidField(t,e,"An invalid number was entered in this field. This field cannot contain any symbols ($, %, #, etc)."),!1)},checkZeroInterval:function(t,e){return stripSymbols(e),0!==e.value||(invalidField(t,e,"Interval cannot be zero"),!1)},confirmDelete:function(t,e){if(confirm("Are you sure you want to delete this record?")){if(e.indexOf("redirect=")<0)e="".concat(e,"&redirect=").concat(escape(t.location.href));else{var i=e.indexOf("&redirect="),n=e.indexOf("%");if(i>=0&&n<0){var s="&redirect=".length;e=e.substring(0,i+s)+escape(e.substring(i+s))}}t.location.href=e}},handleImpersonation:function(t,e,i){var n=e.split("?")[1].substr("USER_ID=".length);return $.get("/servlet/support/login/impersonation",{companyId:companyId,userId:n,impersonationMode:i},(function(e){e.success?"EMPLOYER"==e.accountType&&top.document.location.replace("/ats/employer/v51_employer_frame"):t.alert(e.errorMessage)}),"json"),!1},checkTime:function(t,e){var i=!0,n=e.value;if(0==n.length)return!0;if(5!=n.length)i=!1;else if(":"!=n.substring(2,3))i=!1;else{var s=n.substring(0,2),o=n.substring(3,5);if(s.charAt(0)>2||s.charAt(1)>9||o.charAt(0)>5||o.charAt(1)>9||2==s.charAt(0)&&s.charAt(1)>3)i=!1;else{var r=parseInt(s),a=parseInt(o),l=parseInt(s.substring(0,1)),c=parseInt(s.substring(1,2)),u=parseInt(o.substring(0,1)),h=parseInt(o.substring(1,2));(r>23||r<0||a>59||a<0||isNaN(r)||isNaN(a)||isNaN(l)||isNaN(c)||isNaN(u)||isNaN(h))&&(i=!1)}}return i||invalidField(t,e,"An invalid time was entered. Use Military Time Format: 00:00 to 23:59"),i},checkDate:function(t,e){var i=getFormattedDate(e);return isValidDate(i,!1)?(e.value=i,!0):(invalidField(t,e,"An invalid date was entered. Use Month Date Year Format MM/DD/YYYY."),!1)},checkBirthDate:function(t,e){return!!isValidBirthDate(e,!1,10,110)||(invalidField(t,e,"An invalid birth date was entered."),!1)},checkShortDate:function(t,e){var i=getFormattedDate(e);return isValidDate(i,!0)?(e.value=i,!0):(invalidField(t,e,"An invalid date was entered. Use Month Date Year Format MM/YYYY."),!1)},storeShortDateToFullDate:function(t,e){var i=e.val(),n=$(e).attr("id"),s=$("#".concat(n,"_ROW"));if(!isValidDate(i,!0)||""==i&&"none"!=s.css("display"))return e.next().val(""),!1;var o=function(t){var e=t.lastIndexOf("/"),i=t.substring(0,e),n=t.substring(e);return"".concat(i,"/01").concat(n)}(i);return e.next().val(o),!0},checkDateTime:function(t,e){if(isValidDateTime(e))return!0;invalidField(t,e,"An invalid date was entered. Use Format MM/DD/YYYY HH:MM am/pm.")},toggleSelectAllCheckboxes:function(t,e){!!$(t).attr("checked")?lib.selectAllCheckboxes(e,!1):lib.deselectAllCheckboxes(e,!1)},selectAllCheckboxes:function(t,e){e&&lib.setAccess(t,!1);var i=0;for(i=0;i<t.document.forms[0].elements.length;i++)"checkbox"==t.document.forms[0].elements[i].type&&(t.document.forms[0].elements[i].checked=!0)},documentSubmit:function(t,e,i,n){return setTimeout((function(){var s=t.$;lib.setAccessNextPage(!0);var o=!!s("input[name='save_as_draft']").length,r="Y"===s("input[name='IGNORE_REQUIRED_FIELDS']").val(),a=r;if(o||r||(a=lib.validForm.call(e[0],t,e[0],i)),o||a){var l=!1;createModal(t,{content:"#".concat(n),attributes:{useCloseX:!0},onOpen:function(t){var i=t.getContent(!0);s(i).css("height","auto"),s(i).css("width","auto"),t.enableOk({enable:!1}),t.setContent("<h3>Submitting...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p>");var n="".concat(e.serialize(),"&ajax=Y");o&&(n+="&save_as_draft=Save+as+Draft"),s.post(e.attr("action"),n,(function(e){l=!0,t.setContent(e),o&&setTimeout((function(){return t.close()}),500)}))},onClose:function(t){l&&t.enableOk({enable:!0})}})}}),500),!1},importCcdSubmit:function(t,e,i,n){return setTimeout((function(){var e=t.$,s=e("#"+n).find("form");lib.setAccessNextPage(!0);lib.disableMouseActions(t);createModal(t,{content:"#".concat(n),onOpen:function(n){n.enableOk({enable:!1}),n.setContent("<div class ='importpopup' style=''><h3>Importing Data...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p></div>");var o=e(n.getContent(!0));o.closest(".vex").find(".vex-content").css({width:"700px",height:"200px"}),o.closest(".vex-content").find(".vex-dialog-input").css({overflow:"unset",width:"unset",height:"unset"});var r="".concat(s.serialize(),"&ajax=Y");e.post(i,r,(function(i){!0;var s=lib.importStatusPopup(t,i.trim());n.setContent("<p>"+s+"</p>");var o=e(n.getContent(!0));o.closest(".vex").find(".vex-content").css({"max-height":"300px",width:"700px"}),o.closest(".vex-content").find(".vex-dialog-input").css({width:"unset"}),lib.enableMouseActions(t)}))}})}),500),!1},disableMouseActions:function(t){var e=t.parent.frames[0],i=e?e.$("#WA00000124"):$("#WA00000124");$("*").css({cursor:"wait","pointer-events":"none"}),i.find("div, li").css({cursor:"wait"}),i.find("a, div .ui-control-help, span").css({"pointer-events":"none"})},enableMouseActions:function(t){var e=t.parent.frames[0],i=e?e.$("#WA00000124"):$("#WA00000124");$("*").css({cursor:"","pointer-events":"all"}),i.find("div, li").css({cursor:""}),i.find("a, div .ui-control-help, span").css({"pointer-events":"all"})},unfollow:function(t,e){var i=t.$,n=i(e);return i.post(n.attr("href"),(function(t){if("Success!"==t){var e=n.closest("tr").nextAll("tr.even");n.closest("tr").nextAll("tr.odd").removeClass("odd").addClass("even"),e.removeClass("even").addClass("odd"),n.closest("tr").remove()}})),!1},deselectAllCheckboxes:function(t,e){e&&lib.setAccess(t,!1);var i=0;for(i=0;i<t.document.forms[0].elements.length;i++)"checkbox"==t.document.forms[0].elements[i].type&&(t.document.forms[0].elements[i].checked=!1)},daysSince:function(t,e){var i,n=e.value,s=new Date((new Date).getTime()),o=new Date(s-24*n*60*60*1e3),r="".concat(o.getMonth()+1,"/").concat(o.getDate(),"/").concat(o.getFullYear()),a=e.name.lastIndexOf("_DAYSSINCE");if(a>0&&(i=e.name.substring(0,a)),n>0&&null!=n)for(var l=0;l<t.document.forms[0].elements.length;l++)t.document.forms[0].elements[l].name==i&&(t.document.forms[0].elements[l].value=r);else for(var c=0;c<t.document.forms[0].elements.length;c++)t.document.forms[0].elements[c].name==i&&(t.document.forms[0].elements[c].value="")},setAvgField:function(t,e){return t.avgField=e},setTotalField:function(t,e){t.totalField=e,t.document.forms[0].elements[e].enabled=!1},appendScore:function(t,e){t.scores=t.scores.concat(e)},calculateScore:function(t){for(var e=0,i=0,n=0;n<t.scores.length;n++){var s=t.document.forms[0].elements[t.scores[n]],o=parseInt(getFieldValue(t,s));!o>0&&(o=0,i++),e+=o}var r=e/(t.scores.length-i);return r=parseInt(r+.5),t.totalField&&e==parseInt(e)&&(t.document.forms[0].elements[t.totalField][0].value=e,t.document.forms[0].elements[t.totalField][1].value=e),t.avgField&&r==parseFloat(r)&&(t.document.forms[0].elements[t.avgField][0].value=r,t.document.forms[0].elements[t.avgField][1].value=r),!0},clearListeners:function(){return lib.pageListeners=[]},updatePage:function(t,e){var i=e.options[e.selectedIndex].value,n=null,s=null;if(i.indexOf(",")>=0&&(n=i.substring(0,i.indexOf(",")),(s=i.substring(i.indexOf(",")+1)).indexOf(",")>=0)){var o=s.substring(0,s.indexOf(",")),r=s.substring(s.indexOf(",")+1),a=o;if(null!=r){var l="?";a.indexOf("?")>=0&&(l="&"),a=a+l+r}}if(lib.checkAccess())lib.loadingPage(!0),s.indexOf(",")>=0&&(t.parent.frames[n].location.href=a,t.parent.frames[n].focus());else{t.alert('You must first click the "Save and Next" or "Undo" buttons before exiting this page.');for(var c=e.options.length,u=t.parent.frames[n].location.pathname,h=0;h<c;h++){if(e.options[h].value.indexOf(u)>=0){e.selectedIndex=h;break}}}},loadingPage:function(t){return setGlobalData("Lib.loading",t),1==t&&lib.setAccessNextPage(!0),!0},isLoadingPage:function(){return getGlobalData("Lib.loading")},pageUpdated:function(t){for(var e=0;e<_this.pageListeners.length;e++){var i=_this.pageListeners[e],n=void 0;try{(n=i.pageUpdated)&&n(t)}catch(s){}}},setAccessNextPage:function(t){var e=lib.checkAccess();return _log("accessNextPage: ".concat(e)),setGlobalData("Lib.accessNextPage",t),!0},authenticateUser:function(t){var e=t.$;e.ajax({contentType:"application/json; charset=utf-8",data:JSON.stringify({value:!0}),method:"POST",url:"/api/eformsdocumentapprove/eformsSignedDocument",success:function(t){var i=JSON.parse(t),n=i.success;if(n){var s,o,r;i.hasOwnProperty("firstName")&&(s=i.firstName),i.hasOwnProperty("lastName")&&(o=i.lastName),i.hasOwnProperty("email")&&(r=i.email),e("#form-data").append("<div></div>").append('<img src="/ats/css-base/images/click-ok.png"/>').append(" ").append(s).append(" ").append(o).append(" ").append("("+r+")").append("<div></div>").css("display","block"),e(".eformsubmit").css("display","block")}e("#authenticatedoc").attr("disabled","disabled")},error:function(t){this.setState({_messageToUser:"Authentication fails"})}})},setAccess:function(t,e){return _this.setAccessNextPage(e),t&&t.document&&t.document.forms&&t.document.forms[0]&&t.document.forms[0].elements&&t.document.forms[0].elements.is_changed&&!t.document.forms[0].elements.force_is_changed&&(t.document.forms[0].elements.is_changed.value=!e),!0},checkAccess:function(){return getGlobalData("Lib.accessNextPage")},checkLinkAccess:function(){return!!_this.checkAccess()||(alert('You must first click the "Save and Next" or "Undo" buttons before exiting this page.'),!1)},addDependentField:function(t,e,i,n){var s=t.$;s(t.document).ready((function(){for(var o,r,a=[],l=e.split("|"),c=n?n.split("|"):[],u=0;u<c.length;u++)c[u]=c?c[u].split("&"):[];for(var h=0;h<l.length;h++){for(var d=[],p=l[h].split("&"),f=0;f<p.length;f++){var m=p[f],g="_NOT"===m.substr(-4);g&&(m=m.substr(0,m.length-4));var v=void 0;(v=dependentFieldCtx?s(dependentFieldCtx).find("[name='".concat(m,"']")).not(":disabled"):s("[name='".concat(m,"']")).not(":disabled")).data("negative",g),d[f]={fields:v,values:c[h]&&c[h][f]?c[h][f]:""}}a[h]=d}if(s.each(a,(function(t,e){return s.each(e,(function(t,e){return o=o?o.add(e.fields):e.fields}))})),r=dependentFieldCtx?s(dependentFieldCtx).find("#".concat(i,"_ROW")):s("#".concat(i,"_ROW")),o&&o.length){var _=function(e){for(var i=!1,n=0;n<a.length&&!i;n++){for(var o=a[n],l=!0,c=function(t){for(var e=o[t],i=e.values.split(","),n=""===e.values,r=!1,a=0;a<e.fields.length&&!r;a++){var c=e.fields.eq(a),u=c.val(),h=c.data("negative");c.is(":radio,:checkbox")&&!c.is(":checked")&&(u=null);var d=!1;null!==u&&(u=s.makeArray(u),s.each(u,(function(t,e){""!=e&&s.inArray(e,i)>=0&&(d=!0)}))),r=d||u&&""!=u&&n,h&&(r=!r)}l=r},u=0;u<o.length&&l;u++)c(u);i=l}i?e?(r.show(),triggerResize(t,!0,!1)):"none"==r.css("display")&&(r.css("display",""),r.css("opacity","0"),r.animate({opacity:"1"},500,"swing",(function(){return triggerResize(t,!0,!1)}))):e?(r.hide(),triggerResize(t,!0,!1)):r.fadeOut({complete:function(){return triggerResize(t,!0,!1)}})};s(":reset").click((function(){s(this).get(0).form.reset(),_(!0)})),o.each((function(e,i){var n=s(i);n.hasClass("select-plus")&&!n.hasClass("select-plus-initialized")?SelectPlus.registerChangeListener(n,_):jqueryUniversalChange(t,i,(function(){return _()}))})),_(!0)}}))},setLocation:function(t,e){_this.checkAccess()?t.document.location.href=e:t.alert('You must first click the "Save and Next" or "Undo" buttons before exiting this page.')},setLocationToDashboard:function(t,e){t.document.location.href=e},historyGo:function(t,e){if(_this.checkAccess())t.$("body").trigger("ss-event-page-cancel"),t.history.go(-1);else{var i=(e=t.event||e).target||e.srcElement,n=$(i).parents("ul").find("input[type=submit]");t.alert('You must first click the "'.concat(n.val(),'" or "Undo" buttons before exiting this page.'))}},maskFormat:function(t,e,i){var n=e.value;return""==n||!!new RegExp(i).exec(n)},autoFormat:function(t,e,i){var n=t.value;if(""!=n){var s=new RegExp(e);s.exec(n)?t.value=n.replace(s,i):alert("".concat(n," is not in the correct format."))}},AppLoginStepFillIn:function(t){var e=t.$,i=e(".pagebuttons ul :has([value='Create New Account'])");i.css("display","block"),e("div.create_account")&&(e("div.create_account").html(i.html()),i.css("display","none")),e("#step2_links")?(e("#preview").hide(),e("#step2_links").html(e("#preview").html())):e("#preview").show()},addStyleClasses:function(t,e){var i=t.$;if(i){_log("addStyleClasses for ".concat(e=e||"body"));var n=i(e);n.find(":text").addClass("textfield"),n.find(":password").addClass("passwordfield"),n.find(":text, :password").focus((function(){i(this).addClass("textfieldfocus")})),n.find(":text, :password").blur((function(){i(this).removeClass("textfieldfocus")})),n.find("td:empty").html(" "),function(){var t=n.find('select[name="ACTION_TYPE"]');t.change((function(){var e=n.find(".rs :checkbox");"all"===t.val()?e.prop("disabled","disabled").hide():e.prop("disabled","").show()}))}(),n.find(":reset").click((function(t){i(".file_upload_field[type='hidden']").each((function(t){var e=i(this).attr("original");i(this).val(e);var n=i("#".concat(i(this).attr("name"),"_link"));n.attr("href",e),""==e&&n.fadeOut()}))}));var s={".embedded_field":function(t){t.closest("label").find(":radio, :checkbox").click((function(){return i(t).children(":text").focus()})),t.closest("label").find(":text").click((function(){i(this).closest("label").find(":radio, :checkbox").attr("checked","checked")}))},"a.wizardpopup":function(t){r(t,!0)},"a.wizardpopupNoReload":r,"a.modalpopuplink":function(e){return e.click((function(n){n.preventDefault();var s="modalpopuplink";return i("#".concat(s)).length||i("body").append("<div id='".concat(s,"' style='display:none;'><h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p></div>")),_this.addToolboxFunction(t,s,(function(){return ajaxFillinPopup(t,s,e.attr("href"))})),_this.showPopup(t,s),!1}))},"input.suggestsearch":function(e){var n="".concat(e.attr("id")||e.attr("name"),"_sug"),s=e.attr("href");s.indexOf("?")<0?s+="?":s+="&";s+="jscallback=?";var o=-1;function r(t){for(var s in c(),i("#".concat(n,"_con")).length||e.after("<div id='".concat(n,"_con'><div id='").concat(n,"' class='search_suggest'></div></div>")),t){var o=n+t[s];i("#".concat(n)).append("<div id='".concat(o,"' class='suggest_link'>").concat(s,"</div>"));var r=i("#".concat(o));r.hover(a,l),r.click((function(){e.val(i(this).html()),c()}))}}function a(){i(this).addClass("suggest_link_over"),e.unbind("blur")}function l(){i(this).removeClass("suggest_link_over"),e.blur(c)}function c(){i("#".concat(n,"_con")).remove()}e.keyup((function(n){-1!=o&&t.clearTimeout(o),o=t.setTimeout((function(){var t=e.val();if(""!=t){t={suggest:t,ajax:"y"};var n=i.param(t);i.getJSON(s,n,r)}}),500)})),e.blur(c)},"input.file_upload_field[type='button']":function(e){i(e).click((function(e){_log("Doing input.file_upload_field[type='button'].click()...");var n=this;i(n).parents().last().find("[id=upload_field]:hidden").remove(),closePopupFirst(t,(function(){_log("Doing fileUploadPopup - popups have been closed."),function(t,e){var i=e.$,n=getModal(e);if(n&&n.isOpen())return void alert("ERROR: cannot have a fileupload field within another pop-up");var s=i(t).attr("hiddenname"),o="FIELD_NAME=".concat(s,"&COMPANY_ID=").concat(companyId);if(!i("#".concat("upload_field")).length){var r='<div id="'.concat("upload_field",'" style="display: none"><h3>Loading...</h3> <p><img src=\'https://cdn.atenterprise.powerschool.com/images/loading.gif\' />Please Wait </p></div>');i("body").append(r)}var a="";i(t).is(".noextcheck")&&(a="?noextcheck=Y");_this.addToolboxFunction(e,"upload_field",(function(){ajaxFillinPopup(e,"upload_field","/ats/upload_field.jsp".concat(a),o)})),_this.addToolboxFunction(e,"".concat("upload_field","_close"),(function(){if(e.fileuploads&&e.fileuploads[s]){var t=e.fileuploads[s];t.id&&t.url&&(i("#".concat(s)).val(t.id),i(".".concat(s,"_link")).attr("href",t.url).fadeIn(),i(".".concat(s,"_remove")).attr("href","#").fadeIn(),i("#".concat(s,"_button")).attr("value","Replace File"),_this.setAccess(e,!1))}})),_this.showPopup(e,"upload_field")}(n,t)}))}))},".nctq_hoverable":function(e){e.mouseenter((function(e){o(t,i(this).next("div"),e,20,20),i(this).next("div").removeClass("nctq_scores_hidden"),i(this).next("div").addClass("nctq_scores_visible")})),e.mouseleave((function(t){i(this).next("div").removeClass("nctq_scores_visible"),i(this).next("div").addClass("nctq_scores_hidden")})),e.mousemove((function(e){o(t,i(this).next("div"),e,20,20)})),e.click((function(t){return t.preventDefault()}))}};!function(){var t="",e=!0;for(var o in s)e||(t+=","),t+=o,e=!1;n.find(t).each((function(){var t=i(this);for(var e in s)t.is(e)&&s[e].call(this,t)}))}()}else _log(new Error("Can not call addStyleClasses; jQuery is not available."));function o(t,e,i,n,s){var o=t.$,r=e.width(),a=e.height();e.css({top:Math.min(i.pageY+n,o(t).height()-a+o(t).scrollTop()),left:i.pageX-r-s})}function r(e,n){e.click((function(s){s.preventDefault();var o=e.attr("name")?e.attr("name"):"awizardpopup";return i("#".concat(o)).length||i("body").append("<div id='".concat(o,"' style='display:none;'><h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p></div>")),closePopupFirst(t,(function(){_this.addToolboxFunction(t,o,(function(){ajaxFillinPopup(t,o,e.attr("href"),null,!0,!0)})),n&&_this.addToolboxFunction(t,"".concat(o,"_close"),(function(){i("body").html("<h3 class='pageTitleCaption'>Please Wait... Loading</h3>");var e=t.location.href,n=top.frames[0]&&"sss_script"===top.frames[0].name;if(-1==e.indexOf("refresh")){var s=e;s.indexOf("?")>-1?s+="&refresh=Y":s+="?refresh=Y",n?t.location.replace(s):t.$("body").trigger("ss-event-page-reload")}else n?t.location.reload():t.$("body").trigger("ss-event-page-reload")})),_this.showPopup(t,o)})),!1}))}},fileUploadComplete:function(t,e,i){var n=t.$;n(".inlineHelp").remove(),n(".searchsoft-modal #file_upload_content").html(i),n(".searchsoft-modal #file_upload_waiting").stop().hide(),n(".searchsoft-modal #file_upload_content").fadeIn(),afterAjaxPopProcess(t,e,n(".file-upload-complete-wrapper-".concat(e)),null,!0,!0),triggerResize(t)},fileUploadStart:function(t){var e=t.$;return e(".inlineHelp").remove(),e(".searchsoft-modal #file_upload_waiting").fadeIn(),e(".searchsoft-modal #file_upload_content").hide(),!0},onReady:function(t,e){if(t.$=checkJQuery(t,t.$),t.$){var i=function i(){if(_log("win.document.readyState: ".concat(t.document.readyState)),"complete"!=t.document.readyState){var n=$.browser&&$.browser.mozilla?1e3:350;return _log("Deferring call to onReady for ".concat(n," ms...")),void t.setTimeout(i,n)}if(_log("Calling onReady() for:".concat(displayFn(e))),t.spinnerOn)t.onReadyFunctions=t.onReadyFunctions||[],t.onReadyFunctions.push(e),_log("Adding function to win.onReadyFunctions (length=".concat(t.onReadyFunctions.length,"), NOT calling function."));else try{_log("Executing onReady() function..."),e.call(_this,t)}catch(s){_log("Error occurred executing onReady function..."),_log(s)}};t.$(t.document).ready(i)}else _log(new Error("Can not call onReady; jQuery is not available."))},perform_cookie_test:function(){return makeTestCookie(),cookie_test=findTestCookie()},ready_modal_popup:function(t,e,i){(0,t.$)(t.document).ready((function(){e?toolboxRegisterSelection(t,i):toolboxRegisterActionGo(t,i),t.toolboxFunctions||(t.toolboxFunctions=new Array(0))}))},addToolboxFunction:function(t,e,i){t.toolboxFunctions||(t.toolboxFunctions=new Array(0)),t.toolboxFunctions[e]=i},ajaxPopupOp:function(t,e,i,n,s){var o=t.$,r=null;null==n&&""!=n||(r="op=".concat(n)),s&&(r="".concat(null==r?"":r+"&").concat(o("form").serialize()));var a=o("[name=table_name]").val();null==a||""==a||null!=r&&-1!=r.indexOf("table_name")||(r="".concat(r?r+"&":"","table_name=").concat(a)),ajaxFillinPopup(t,e,i,r)},ajaxPopup:function(t,e,i){return _this.ajaxPopupOp(t,e,i,null)},showPopup:function(t,e,i){var n=t.$,s=n("#".concat(e)).find("input[name=".concat(e,"]")).val();if(!s&&e.indexOf("_results")>0){var o=e.replace("_results","");s=n("#".concat(e)).find("input[name="+o+"]").val()}var r=n("#".concat(e)).parent(),a=n("#".concat(e)).find(".pagebuttons").hide().end();n(a).css("display","");var l={useCloseX:!0};i=i?n.extend({},l,i):l;var c=!s,u={id:e,attributes:i,content:a,onOpen:function(){n('[id="'.concat(e,'"]')).toArray().slice(0,-1).forEach((function(t){return n(t).remove()})),c&&(toolboxAddCancel(t,e),toolboxRunFunction(t,e))},onClose:function(i){var s=n(i.getContent(!0));s=n(s).children(),n(r).append(s.hide()),toolboxRunFunction(t,"".concat(e,"_close")),n(".inlineHelp").remove(),t.document.thismodal=null}};c?(u.showOk=!1,u.showCancel=!1):u.buttons=[{text:s,type:"ok",callback:function(i){return toolboxRunFunction(t,e)}},{text:"Cancel",type:"cancel"}],createModal(t,u,!0)},addHiddenField:function(t,e,i){(0,t.$)("form").append('<input type="hidden" name="'.concat(e,'" value="').concat(i,'" />'))},addCheckboxApplicants:function(t,e){var i=t.$;doModalOp(t,!1,(function(t,e){var n=i(e).find("form"),s=i("div.rs :checkbox:checked").clone();s.attr("checked","checked"),s.attr("remove","yes"),s.hide(),n.append(s);var o=i("select[name='ACTION_TYPE']");o.length&&n.append('<input type="hidden" name="ACTION_TYPE" value="'.concat(o.val(),'" />')),0==i(n).find(":checkbox:checked").length&&i(n).find(":hidden:checkbox").attr("checked","checked")}))},removeCheckboxApplicants:function(t,e){(0,t.$)("div#".concat(e," :checkbox[remove='yes']")).remove()},addSuperConfirm:function(t){var e=t.$;t.superConfirm=function(i,n){return createModal(t,{content:i,attributes:{useCloseX:!1},buttons:[{text:"Yes",type:"ok",callback:function(i){e.isFunction(n)&&n.apply(),triggerResize(t)}},{text:"Cancel",type:"cancel",callback:function(t){return e(".inlineHelp").remove()}}]})}},replaceAlert:function(t){var e=t.$;t.alert=function(i){if(i=i.replace(/\r\n|\n/g,"<br />"),Modal.anyShowing(t)){var n,s=e("<div class='red inlineHelp' />").html(i);e(".inlineHelp").length?(n=e(".inlineHelp").html(i),t.clearTimeout(t.helpTimeout)):(Modal.getCurrent(t).addContent(s),n=e(".inlineHelp").css("opacity","0").animate({opacity:"1"},500,"linear",(function(){triggerResize(t)}))),t.helpTimeout=t.setTimeout((function(){return n.animate({opacity:"0"},500,"linear",(function(){n.remove(),triggerResize(t)}))}),15e3),triggerResize(t)}else i=e("<p class='help_popup' />").html(i),createModal(t,{content:i,attributes:{useCloseX:!1},buttons:[{text:"Close",type:"ok",callback:function(t){return e(".inlineHelp").remove()}}]})}},addFieldPrompt:function(t){var e=t.$;function i(t,e,i){t.alert(i)}t.fieldPrompt=function n(s,o,r,a){var l=s,c=!(s.name||s.id||s.type)&&s.length;if(c||((s=[])[0]=l),r=!!r,t.runningValidFields&&(r=!0),Modal.anyShowing(t))return a?i(t,0,o):r?t.setTimeout((function(){return n(l,o,r,!0)}),550):i(t,0,o);try{if(e(".gridfield").length>0)for(var u=e(".gridfield"),h=0;h<u.length;h++)if(e.contains(u[h],s[0]))return i(t,0,o)}catch(x){}for(var d=t.fieldDelimiter||"tr",p=null,f=0;f<s.length;f++)p=p?p.add(e(s[f]).closest(d).eq(0)):e(s[f]).closest(d);if(!p.length)return i(t,0,o);var m=0!=e(p).find(".hasDatepicker").length,g=e(p).clone(!m);e(g).find("*").addBack().each((function(){var t=e(this).attr("id");t&&e(this).attr("id","".concat(t,"_COPY"))})),e(g).find(".do-not-copy").remove();var v=[],_=!1;if(g.find("*").each((function(t){for(var i=0;i<s.length;i++){var n=!0,o=s[i],r=e(o).attr("id"),a=e(this).attr("id");"".concat(r,"_COPY")!=a&&(n=!1),e(o).attr("name")!=e(this).attr("name")&&(n=!1),e(o).attr("value")!=e(this).attr("value")&&"select-one"!=e(o).attr("type")&&(n=!1),e(o).attr("type")!=e(this).attr("type")&&(n=!1),n&&(v[i]&&(_=!0),v[i]=e(this).get(0))}})),_)return i(t,0,o);if(s.length!=v.length)return i(t,0,o);s=trimArray(s),v=trimArray(v);var b=!1,y=e("<div class='invalid'>".concat(o,"</div>"));switch(e(y).append(g),d){case"tr":g.wrap('<table class="frmpfields"></table>');break;case"td":g.wrap('<table class="frmpfields"><tr></tr></table>');break;case"li":g.wrap("<ul></ul>");break;default:g.wrap('<div class="fieldprompt"></div>')}createModal(t,{content:y,attributes:{useCloseX:!0},showOk:!0,showCancel:!0,callback:function(i){var n;return v.filter((function(t){return void 0!==t})).forEach((function(t){var i=e("#".concat(t.id))[0];t.checked=i.checked,t.value=i.value})),n=c?v:v[0],!(0==e(p).find(".file_upload_field").length)||!!validNewField(t,l,n)&&void(b=!0)},onOpen:function(){if(m){var i=e(g).find(".hasDatepicker");e(i).removeClass("hasDatepicker"),e(i).datepicker({showOtherMonths:!0,selectOtherMonths:!0,showAnim:"slideDown",changeYear:!0})}triggerResize(t),e("#".concat(v[0].id)).focus()},onClose:function(){if(e(".inlineHelp").remove(),b){var i;i=c?v:v[0],reassignFieldListeners(l,i);for(var n=0;n<s.length;n++){var o=!1;v[n].checked&&(o=!0),e(s[n]).replaceWith(v[n]);var a=e(v[n]).attr("id")||"";(a=a.replace("_COPY",""))&&e(v[n]).attr("id",a),m&&(e(v[n]).removeClass("hasDatepicker"),e(v[n]).datepicker({showOtherMonths:!0,selectOtherMonths:!0,showAnim:"slideDown",changeYear:!0})),o&&e(v[n]).attr("checked","checked")}_this.setAccess(t,!1),r&&e("[name='submit_button']").trigger("click")}}})}},initFormPage:function(t){t.scores=new Array(0),t.avgField=null,t.totalField=null},multiRecordField:function(t,e,i,n){var s=t.$;function o(){var t=s("#".concat(e));t.html('<h3>Loading...</h3> <p><img src="https://cdn.atenterprise.powerschool.com/images/loading.gif" />Please Wait</p>'),s.get(i,"ajax=Y&refresh=Y",(function(e,i){if("success"!==i)throw"AJAX error getting content";t.html(e),r()}),"text")}function r(){if(s("#".concat(e," .resultpageajaxlinks")).length){var i="".concat(e,"_popup");s("#".concat(e,' a:not([class~="resultlink"])')).click((function(e){var n=s(this),r=n.attr("href");return n.hasClass("delete")?t.superConfirm("Are you sure you want to delete this record?",(function(){return s.post(r,null,(function(t,e){if("success"!==e)throw"AJAX error";o()}))})):(_this.addToolboxFunction(t,i,(function(){return ajaxFillinPopup(t,i,r,null,!0)})),_this.addToolboxFunction(t,"".concat(i,"_close"),(function(){return o()})),_this.showPopup(t,i)),e.preventDefault(),!1}))}}this.refreshResultPage=o,n?o():r()},jsExpression:function jsExpression(win,target,expression,defaults){for(var $=win.$,varRegExp=new RegExp("\\b[A-Za-z][A-Za-z0-9_]+\\b","g"),variable;null!=(variable=varRegExp.exec(expression));){var elem=$("[name='".concat(variable,"']"));elem.length&&(elem.unbind(jqueryUniversalChangeSupportedEvents.join(","),runExpression),jqueryUniversalChange(win,elem.get(0),runExpression))}function runExpression(){var expr=buildRawExpression();try{var value=eval(expr),targetField=$("#".concat(target,"_display")),targetHidden=$("#".concat(target));value!=targetHidden.val()&&(targetField.val(value),targetField.trigger("change"),targetHidden.val(value),targetHidden.trigger("change"))}catch(ex){lib.replaceAlert(win);var msg="<span style='font-size: 1em; font-style: normal; font-weight: normal'>It appears that there is an unresolved variable in the JS Expression string provided:</span><br /><br /><span style='font-size: .8em; font-style: italic; font-weight: bold'>".concat(expr,"</span><br /><br /><span style='font-size: 1em; font-style: normal; font-weight: normal'>Check the unresolved field name and ensure that it corresponds with an input on the page.</span>");win.alert(msg),$("#".concat(target,"_display")).val("###")}}function buildRawExpression(){var t=expression;try{for(var e;null!=(e=varRegExp.exec(expression));){var i=null,n=$("[name='".concat(e,"']"));if(0!=n.length&&"###"!=n.val())i=Number(n.val());else{if(null==defaults[e])continue;i=Number(defaults[e])}isFinite(i)||(i=Number(0)),t=t.replace(new RegExp("\\b".concat(e,"\\b"),"g"),i)}t="( ".concat(t," )")}catch(s){_log(s)}return t}runExpression()},reloadNewMcrelYear:function(t,e){var i=t.$;i((function(){var n=i('select[name="'.concat(e,'"]'));n.change((function(){var e=n.val();if(""!==e){var s=i("form").prop("action"),o=URI(s).setQuery("MCREL_YEAR_ID",e).toString();t.location.href=o}}))}))},addReloadOnSelectChange:function(t,e){var i=t.$;_this.onReady(t,(function(){return i("select[name='".concat(e,"']")).change((function(n){var s,o=t.location.href,r=new RegExp("".concat(e,"=[^&]*"));s=r.test(o)?o.replace(r,"".concat(e,"=").concat(i(this).val())):"".concat(o,"&").concat(e,"=").concat(i(this).val());var a=new RegExp("".concat(e,"=([^&]*)"),"g").exec(o);null!=a&&a[1]==i(this).val()||(t.location.href=s)}))}))},activatePreview:function(t,e,i,n,s){var o=t.$;o("#".concat(n)).click((function(){var r=o("[name=".concat(i,"]"));if(!r.length)return t.alert("No input field to preview");var a=r.val();if(""==a||null==a)return t.alert("No input currently selected");var l=s[a];if(""==l||null==l)return t.alert("No preview page for that selection");if(e)t.open(l);else{var c="".concat(n,"_div");_this.addToolboxFunction(t,c,(function(){return ajaxFillinPopup(t,c,l,null)})),_this.showPopup(t,c)}}))},registerStageSelect:function(t,e,i,n,s,o,r){_this.onReady(t,(function(){var a=t.$,l=a("[name='".concat(e,"']")),c="singleValue_".concat(e);if(l.length){var u=a("[name='".concat(n,"']"));if(u.length){var h="text"==u.attr("type"),d=!0;u.bind("change",p),p.apply(u.get(0))}else _log("StagedSelectField parent field is not present: ".concat(n))}else _log("StagedSelectField is not present!");function p(t){var e=a(this),n=e.val();h&&(n+="*"),encodeURIComponent?n=encodeURIComponent(n):escape&&(n=escape(n));var s=e.attr("type"),r="radio"==s||"checkbox"==s,u=e.attr("checked");if(!r||u)if(""!=n&&null!=n){var d="/ats/stage_field_lookup?GUI_FIELD_ID=".concat(i,"&parentvalue=").concat(n,"&ajax=Y&jscallback=?");a.getJSON(d,f)}else!function(){l.html("").show(),a("#".concat(c)).remove(),o||l.append("<option value='' selected='selected'></option>");l.triggerHandler("change")}()}function f(e){if(e){var i=1==e.length&&r,n="";l.html(""),a("#".concat(c)).remove(),i||l.show();var u="",h=!1;if(a.each(e,(function(t,e){var o=e.value;if(""!=o){var r=e.caption,l="";(-1!=a.inArray(o,s)||i)&&(n+=r,l=" selected='selected' ",h=!0),u+="<option value='".concat(o,"'").concat(l,">").concat(r,"</option>")}})),o||i||(u="<option value=''".concat(h?"":" selected='selected' ","></option>").concat(u)),l.append(u),i){l.hide();var p="<div id='".concat(c,"'>").concat(n,"</div>");l.after(p)}l.triggerHandler("change"),d&&(d=!1,l.change((function(){return _this.setAccess(t,!1)})))}else _log("lookups null")}}))},registerStageText:function(t,e,i,n,s,o){_this.onReady(t,(function(){var s=t.$,o=s("[name='".concat(e,"']"));if(o.length){var r=s("[name='".concat(n,"']"));if(r.length){var a=!0;r.bind("change",l),l.apply(r.get(0))}else alert("StageTextField parent field is not present: ".concat(n))}else alert("StageTextField is not present!");function l(t){var e=s(this),n=e.val();encodeURIComponent?n=encodeURIComponent(n):escape&&(n=escape(n));var o=e.attr("type"),r="radio"==o||"checkbox"==o,a=e.attr("checked");if((!r||a)&&""!=n&&null!=n){var l="/ats/stage_field_lookup?GUI_FIELD_ID=".concat(i,"&parentvalue=").concat(n,"&ajax=Y&jscallback=?");s.getJSON(l,c)}}function c(e){if(e)if(1==e.length){var i=e[0].value;if(o.val(i),null!==t&&null!==t.tinymce){var n=t.tinymce.get(o.attr("id"));null!==n&&n.setContent(i)}o.triggerHandler("change"),a&&(a=!1,o.change((function(){return _this.setAccess(t,!1)})))}else alert("lookup must have one value");else alert("lookups null")}}))},registerMoveToSelect:function(t,e){function i(t,e){var i=t.innerHTML,n=e.innerHTML,s=null===i?"":"".concat(i),o=null===n?"":"".concat(n);return s>o?1:s===o?0:-1}function n(t,e){var n=t.find(":selected");n.detach(),e.append(n);var s=e.children();s.detach(),e.append(s.get().sort(i))}var s=t.$,o=s("#".concat(e)),r=s("#".concat(e,"_src"));s("#".concat(e,"_addbtn")).click((function(){_this.setAccess(t,!1),o.children().prop("selected",!1),n(r,o)})),s("#".concat(e,"_rmvbtn")).click((function(){_this.setAccess(t,!1),r.children().prop("selected",!1),n(o,r)})),s("form").on("click","input:submit",(function(){r.children().prop("selected",!1),o.children().prop("selected",!0)}))},browseToNextUrlFromNavigationPulldown:function(t,e){var i=getNextUrlFromNavigationPulldown(t,e);i?t.location.href=i:alert("Already at the end or beginning of the list.")},writeRedirectFromNav:function(t){return t.$("form").append('<input type="hidden" name="redirect" value="'.concat(getNextUrlFromNavigationPulldown(t,!1),'">'))},handlePreviousNavButton:function(t){getNextUrlFromNavigationPulldown(t,!0)||t.$(":button[value=Previous]").remove()},registerQuickSelectGoButton:function(t,e){return _this.onReady(t,(function(){var i=t.$;i("#".concat(e,"_go")).click((function(){var n="[name='".concat(e,"']"),s=i(n).val();""!=s&&(t.location.href=s)}))}))},registerExpandingMultiValue:function(t,e,i,n){var s=t.$;_this.onReady(t,(function(){var o,r,a,l,c,u;function h(){(o=s("#".concat(e,"_ROW"))).find("script").remove(),r=o.html(),a=s("#".concat(e,"_TABLE_CONTAINER tbody")),l=o.find("#".concat(e,"_SIZE")),c=parseFloat(l.val()),u=o.find("#".concat(e,"_TEMPLATE")),n&&f(a.find(".".concat(e,"_subrecord_container"))),n&&p(a.find(".".concat(e,"_subrecord_container"))),i&&function(){var t=a.find(".".concat(e,"_subrecord_container"));g(t),v(t)}();var h="".concat(e,"_addmore");if(!a.parent().find("#".concat(h)).length){var m=s('<a class="addMoreA"></a>').attr({id:h,href:"#"}).html('<img src="/ats/css-base/add.png" class="addMoreImg"/>Add More').click((function(e){return e.preventDefault(),_this.setAccess(t,!1),d(),!1}));a.closest("table").after(m)}parseFloat(l.val())<1&&d()}function d(){var o=parseFloat(l.val());l.val(o+1),c+=1;var r='<tr class="subrecord_container '.concat(e,'_subrecord_container" id="').concat(e,"_").concat(c-1,'">').concat(u.html().replace(/_TEMPLATE/g,"_SUBRECORD_"+(c-1)),"</tr>");a.append(r);var h=s("#".concat(e,"_").concat(c-1));i&&g(h),n&&f(h),n&&p(h),v(h),triggerResize(t)}function p(e){e.each((function(){var e=s(this),i=e.find(".subrecord_min"),n=e.find(jqueryUniversalChangeSupportedTags).get(0);jqueryUniversalChange(t,n,(function(){return function(t,e){var i=s(t),n=parseFloat(e.html()),o=parseFloat(i.val());(isNaN(o)||n>=o)&&i.val(n+1)}(n,i),!0}))}))}function f(t){t.find(".remove_container").append(' greater than <span class="subrecord_min"></span>'),m(t)}function m(i){function n(t,e,i){var n=parseFloat(s(t).val()),o=parseFloat(e.val());i.html(n),!isNaN(o)&&n>=o&&(e.val(n+1),e.trigger("change"))}i.each((function(){var i=s(this),o=i.prev(".".concat(e,"_subrecord_container")),r=i.find(".subrecord_min");if(o.length){var a=i.find(jqueryUniversalChangeSupportedTags).filter(":first"),l=o.find(jqueryUniversalChangeSupportedTags).filter(":first").get(0);jqueryUniversalChange(t,l,(function(){return n(l,a,r),!0})),n(l,a,r)}else r.html("0")}))}function g(t){t.find(".remove_container").prepend('<a class="subrecord_remove"><img title="Remove" alt="remove" src="/ats/css-base/remove.png" /></a>')}function v(e){e.find(".subrecord_remove").click((function(e){_this.setAccess(t,!1),l.val(parseFloat(l.val())-1);var i=s(this).closest(".subrecord_container"),o=i.next(".subrecord_container");i.remove(),n&&m(o)}))}h(),s(":reset").click((function(t){o.html(r),h()}))}))},disableSubmitButtons:function(t){return t.$("input[type='submit']").attr("disabled","disabled"),!0},eformOptionalEventHideFields:function(t,e){function i(t,e){var i=$(t).find("input,select,textarea");$(i).each((function(t,i){e?$(i).prop("disabled",!1):$(i).prop("disabled",!0)})),e?$(t).show():$(t).hide()}_this.onReady(t,(function(){var n=(0,t.$)("#".concat(e)),s=n.closest("tr").nextUntil("tr.endEformEvent");n.change((function(){var t=n.is(":checked");i(s,t)})),n.trigger("change")}))}};function HierCheckboxModel(t,e,i){var n=t.$;this._rootNode={children:[]},this._allNodes=[],this._counter=0;var s=this;function o(e,i,r){var a=r.node,l=r.children;if(i=function(e,i,o,r,a){var l=e.name,c=e.value,u=e.isChecked,h=e.caption,d=e.url;r=void 0===r||"null"==r?null:r,a=void 0===a||"null"==a?null:a;var p,f=n("<li></li>");if(null!=r&&null!=a){p=n("<a></a>").attr("href","#".concat(c)),n(p).click((function(e){try{return lib[a](t,c,i)}catch(n){_log(n)}}));var m=n("<img />").attr("border","0").attr("src",r);n(p).append(m)}else null!=r&&(p=n("<img />").attr("src",r).attr("border","0"));p&&n(f).append(p);var g=n("<input />").attr("type","checkbox").attr("name",l).attr("value",c);u&&n(g).attr("checked","checked");if(n(g).click((function(e){!function(e,i){lib.setAccess(t,!1);var n=s._allNodes[i];if(function t(e){for(var i=e.children,n=0;n<i.length;n++)i[n].field.checked=e.field.checked,t(i[n])}(n),n.field.checked)for(var o=n.parent;null!=o&&null!=o.field;)o.field.checked=n.field.checked,o=o.parent}(0,i)})),n(f).append(g),d){d=0==d.indexOf("http://")?d:"http://"+d;var v=n("<a></a>").attr("target","_blank").attr("href",d).text(h);n(f).append(v)}else n(f).append(t.document.createTextNode(h));var _={html:f,field:g[0],children:[],parent:o};return _.parent.children.push(_),s._allNodes.push(_),_}(a,s._counter++,i),n(e).append(i.html),l.length>0){var c=n("<ul></ul>");n(i.html).append(c),n.each(l,(function(t,e){return o(c,i,e)}))}}this.render=function(){var t=n("script#".concat(e));i=n.parseJSON(i);var r=n("<ul></ul>");o(r,s._rootNode,i),n(r).insertAfter(t)}}function handleError(t,e,i){_log(new Error(t),!0)}function displayError(t,e,i){_log(t)}_this.isDevMode&&(_this.initDevLinks=function(){function t(t){this._useBase;var e=this;this.setToolAltOption=function(n){function s(){e._useBase=!1,i("div.devmenu a").css({background:"#eee"}),i("div.devmenu a.alttool").each((function(){var t=i(this),e=t.attr("href");e=e.replace("&usealt=N",""),t.attr("href",e)}))}function o(){e._useBase=!0,i("div.devmenu a").css({background:"orange"}),i("div.devmenu a.alttool").each((function(){var t=i(this),e=t.attr("href");e=e.replace("&usealt=N",""),e+="&usealt=N",t.attr("href",e)}))}(void 0===e._useBase||void 0!==n)&&(e._useBase=!0===n),i("a.dragalt").unbind("click.devtools").bind("click.devtools",(function(){s(),t.alert("Tools will modify the alt record (default behavior).")})),i("a.dragbase").unbind("click.devtools").bind("click.devtools",(function(){o(),t.alert("Tools will now modify the base records (for all companies)! \nDanger, this will effect all pages until you log-out or set it back to alt!")})),e._useBase?o():s()};var i=checkJQuery(t,t.$),n="devdivid",s=0;function o(){i("a.hidedev").click((function(t){t.preventDefault(),i(".debug,.devmenu").fadeOut()}))}i.extend(i.fn.disableTextSelect=function(){return this.each((function(){}))}),s&&s!=t.yOffset&&_this.onReady(t,(function(){t.scrollTo(0,s),s=0})),this.activateDevLink=function(){var e=i(this),s=e.attr("href");if(s&&!e.hasClass("newwindow")){var o=e.hasClass("wizarddevlink"),r=e.hasClass("search");return _this.addToolboxFunction(t,n,(function(){o?ajaxFillinPopup(t,n,s,null,!0,!0,!0):ajaxFillinPopup(t,n,s,null,!r,!1,!0)})),_this.showPopup(t,n),!1}return!0},_this.onReady(t,(function(){t.devDone||(i("body").children(":last").after("<div id=\"devdivid\" style='display: none;'><h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p></div>"),_this.addToolboxFunction(t,n+"_close",(function(){t.yOffset="number"==typeof t.pageYOffset?t.pageYOffset:t.document.documentElement?t.document.documentElement.scrollTop:t.document.body.scrollTop,s=t.yOffset,i("body").html("<h1>Reloading...</h1>"),t.location.reload()})),e.setToolAltOption(),i("a.showFieldNames").click((function(){return i("span.fieldName").show()})),function(){var s=null;t.document.body.onmouseup=function(){return s=null},"td"==t.fieldDelimiter?i("div.devfieldmenu").each((function(){var o=i(this).closest("td"),r=i(this).find("a[href*='GUI_FIELD_ID']:first").eq(0).attr("href").match(/GUI_FIELD_ID=\w*\d*/)[0].replace(/GUI_FIELD_ID=/,""),a=o.width(),l=o.height()-5,c="width: 10px; height: "+l+"px;",u="width: "+a+"px; height: 10px;",h='style="position: absolute;'+u+'text-align: center;float: left;clear: both;"',d='style="position: absolute;'+c+'"',p='style="display: block;'+u+'"',f='style="display: block;'+c+'overflow: hidden;"',m='style="border: 0; padding-top: '+(l/2-30)+'px;"',g=".uparrow,.rightcon,.leftarrow,.downcon",v='<div class="uparrow" '+h+"><a "+p+' href=""><img style="border: 0;" src="/ats/css-base/up.png"/></a></div><div class="leftarrow" '+d+"><a "+f+' href=""><img '+m+' src="/ats/css-base/left.png"/></a></div><div class="rightcon" style="left: '+(a-5)+'px; position: relative;"> <div class="rightarrow" '+d+"><a "+f+' href=""><img '+m+' src="/ats/css-base/right.png"/></a></div></div>',_='<div class="downcon"><div class="downarrow" '+h+"><a "+p+' href=""><img style="border: 0;" src="/ats/css-base/down.png"/></a></div></div>',b=i(this);b.disableTextSelect(),b.get(0).onmousedown=function(){return s=r};var y="/ats/admin/drag_move_field.jsp?end_field_id="+r;o.get(0).onmouseover=function(a){o.get(0).onmouseover=null,o.hover((function(a){null!=s&&s!=r&&(o.prepend(v),o.append(_),o.children(g).mouseup((function(){if(null!=s&&s!=r){var o=y+"&start_field_id="+s+"&dir="+i(this).attr("class").replace(/arrow/,"")+"&usealt="+(e._useBase?"N":"Y");_this.addToolboxFunction(t,n,(function(){return ajaxFillinPopup(t,n,o)})),_this.showPopup(t,n)}})))}),(function(){o.find(g).remove()})),o.trigger("mouseover")}})):i("div.devfieldmenu").each((function(){var o=i(this).closest("tr"),r=o.find("th"),a=i(this).find("a[href*='GUI_FIELD_ID']:first");if(a.length){a=a.eq(0).attr("href").match(/GUI_FIELD_ID=\w*\d*/)[0].replace(/GUI_FIELD_ID=/,"");var l="width: "+r.width()+"px; height: 1.5em; left: 0;",c='style="position: absolute;text-align: center;'+l+'"',u='style="'+l+'display: block;"',h='<div class="uparrow" '+c+"><a "+u+' href=""><img style="border: 0;" src="/ats/css-base/up.png"/></a></div>',d='<div class="downcon"><div class="downarrow" '+c+"><a "+u+' href=""><img style="border: 0;" src="/ats/css-base/down.png"/></a></div></div>',p=o.find("div.devmenu");p.disableTextSelect(),p.get(0).onmousedown=function(){return s=a};var f="/ats/admin/drag_move_field.jsp?end_field_id="+a;o.get(0).onmouseover=function(l){o.get(0).onmouseover=null,o.hover((function(){null!=s&&s!=a&&(r.prepend(h),r.append(d),o.find(".uparrow,.downcon").mouseup((function(){if(null!=s&&s!=a){var o=f+"&start_field_id="+s+"&dir="+i(this).attr("class").replace(/arrow/,"")+"&usealt="+(e._useBase?"N":"Y");_this.addToolboxFunction(t,n,(function(){return ajaxFillinPopup(t,n,o)})),_this.showPopup(t,n)}})))}),(function(){return o.find(".uparrow,.downcon").remove()})),o.trigger("mouseover")}}}))}(),i("a.dependtool").unbind().click((function(){var n=i(this).closest("div.devfieldmenu"),s=i(this).closest("div.devmenu").find("a[href*='GUI_FIELD_ID']:first").eq(0).attr("href").match(/GUI_FIELD_ID=\w*\d*/)[0].replace(/GUI_FIELD_ID=/,""),o=t.prompt("For what value?");n.replaceWith("<a onclick='window.location.reload()'>Stop</a>"),i("div.devfieldmenu").replaceWith((function(){var t=i(this).find("a[href*='GUI_FIELD_ID']:first").eq(0).attr("href").match(/GUI_FIELD_ID=\w*\d*/)[0].replace(/GUI_FIELD_ID=/,"");return"<a class='makedependlink' href='/ats/admin/field_make_depend.jsp?PARENT_GUI_FIELD_ID="+s+"&GUI_FIELD_ID="+t+"&value="+encodeURIComponent(o)+"&ajax=Y&usealt="+(e._useBase?"N":"Y")+"' > Make Dependant</a>"})),i("a.makedependlink").unbind().click((function(e){var n=i(this);e.preventDefault();var s=i(this).attr("href");return i.get(s,null,(function(e,i){"success"==i?n.remove():t.alert("failed to make dependant, check your console and get a developer")})),!1}))})),i("a.devmenulink").each((function(){this.onclick=e.activateDevLink})),o(),function(t){i(".showhidden").click((function(e){e.preventDefault(),""==t.location.search?t.location.search="?showhidden=Y":t.location.search.match(/showhidden=Y/)?t.location.search=t.location.search.replace(/[\?\&]showhidden=Y/,""):t.location.search+="&showhidden=Y"}))}(t),function(){var t=i("select[name='ALT_COMPANY_ID']");t.length&&!t.val()&&t.val("<%=companyId%>")}()),t.devDone=!0}))}return function(e){return e._ss_devLinks||(e._ss_devLinks=new t(e)),e._ss_devLinks}}()),window.onerror=!1===init.addGlobalErrorHandler?null:this.isDevMode?displayError:handleError,$.each(lib,(function(t,e){return _this[t]=e})),_this.perform_cookie_test(),onLoadCallback.call(this,this),this.loaded=!0}
|
console-api |
log |
URL: https://lausd.atenterprise.powerschool.com/resources/js/library.bundle.js?v=202105210854(Line 2)
Message:
JQMIGRATE: Migrate is installed with logging active, version 1.4.1
|
console-api |
debug |
URL: https://lausd.atenterprise.powerschool.com/resources/js/library.bundle.js?v=202105210854(Line 2)
Message:
Assigning value to moduleName SelectPlusField [object Object]
|
console-api |
debug |
URL: https://lausd.atenterprise.powerschool.com/resources/js/library.bundle.js?v=202105210854(Line 2)
Message:
Assigning value to moduleName Lib function Lib(init){if(init&&init.getGlobalInstance&&window.top._lib)return window.top._lib;window.top._lib||(window.top._lib=this);var isActiveDirectory=init.isActiveDirectory,companyId=init.companyId,sessionId=init.sessionId,onLoadCallback=init.onLoad||function(){};this.isDevMode=configuration.developmentMode,this.loaded=!1;var _this=this,parents=[],kids=[],hiddenDivs={},checkboxElements=[],jqueryUniversalChangeSupportedTags=":input[type!=hidden]",jqueryUniversalChangeSupportedEvents=["change","select","click","blur"],cookie_test=!1,dependentFieldCtx=null,_log=function(t,e){return logger.log(t)};function setGlobalData(t,e){_log("Setting '".concat(t,"' attribute to value '").concat(e,"'"));try{window&&window.top?$(window.top).data(t,e):_log("Can not set '".concat(t,"' attribute with value '").concat(e,"', top window is not available."))}catch(i){_log(new Error("Can not set '".concat(t,"' attribute with value '").concat(e,"': ").concat(i.message)))}}function getGlobalData(t){_log("Getting '".concat(t,"' attribute value."));try{if(window&&window.top){var e=$(window.top).data(t);return _log("Attribute '".concat(t,"' has value '").concat(e,"'")),e}return _log("Can not get '".concat(t,"' attribute value, top window is not available.")),null}catch(i){return _log(new Error("Can not get '".concat(t,"' attribute value: ").concat(i.message))),null}}function checkJQuery(t,e){return e||t.$||$}function getModal(t){return t.document.thismodal}function createModal(t,e,i){function n(e){_log("Doing resize!!!"),triggerResize(t,!1)}(e=e||{}).paddingTop=80,e.onOpen=mergeFunctions(e.onOpen,(function(e){$(t).on("resize",n),function(e){doModalContentFix(t,e)}(e)})),e.onClose=mergeFunctions(e.onClose,(function(){return $(t).off("resize",n)})),e.openOnCreate=!1,e.context=t;var s=Modal.createModal(e);return s&&(i&&(t.document.thismodal=s),s.open()),s}function doModalContentFix(t,e){var i=$(e.getContent(!0)),n=$(i);n.closest(".vex").css("padding-top","40px"),n.closest(".vex").find(".vex-dialog-input").css("overflow","auto"),n.find("#PageParagraphContainer").removeAttr("id"),n.find("#PageMainContainer").removeAttr("id"),n.find('input[type="submit"], input[type="reset"], input[type="file"]').addClass("vex-dialog-button vex-dialog-button-primary ss-modal-ok").css({"margin-top":"5px",float:"none"}),n.find('input[type="submit"]').click((function(){var e=$(document.getElementsByTagName("form")[1]),i=n.find("#footContainer"),s=i.find(".pagebuttons"),o=$('<img id=\'bulkActionInProgressSpinner\' src="https://cdn.atenterprise.powerschool.com/images/loading.gif" class="preventMultipleSubmitButtonClickSpinner" />');if("undefined"!=typeof e.attr("action")&&-1!=e.attr("action").indexOf("mass_transition_documents")){var r=$("<h4 id='bulkActionCompletedP'>Your requested action is complete.</h4>"),a=$("<h4 id='bulkActionFailedP' style='color:red' class='red ajaxerror'>One or more records have failed. Please check your pending items queue</h4>"),l=$("<h4 id='bulkActionInProgressP'>Bulk action requested is in progress</h4>"),c=$("<h4 id='emptySignature' style='color:red'class='red ajaxerror'>Signature field cannot be empty</h4>");try{i.length>1&&null!=i[1]&&void 0!=i[1]&&$($(".vex #footContainer")[0]).hide(),event.preventDefault();var u=$(".passwordfield").attr("value");e.find('input[id="authenticatedoc"]').length>0||void 0!==u&&null!==u&&""!==u.trim()?(s.hide(),i.append(o),i.append(l),$.ajax({data:e.serialize(),type:e.attr("method"),url:e.attr("action"),success:function(e){-1==e.indexOf("ajaxerror")?(o.hide(),l.hide(),i.append(r),t.location.reload()):(o.hide(),l.hide(),alert(e),event.stopPropagation())},error:function(t){o.hide(),l.hide(),i.append(a),event.stopPropagation()}})):(i.append(c),$(".passwordfield").focus((function(){c.hide()})))}catch(h){o.hide(),l.hide(),i.append(a)}}else s.hide(),i.append(o)})),n.find('input[type="button"]').addClass("vex-dialog-button vex-dialog-button-secondary ss-modal-cancel").css({"margin-top":"5px",float:"none"}),$(".linkbutton, .wizardlink").click((function(){return t.setTimeout((function(){doModalContentFix(t,e),triggerResize(t,!1)}),15)}))}function doModalOp(t,e,i){var n=getModal(t);if(n&&(n.isOpen()||!e))try{i(n,n.getContent(!0))}catch(s){_log(s)}}function triggerResize(t,e,i){(e=!1!==e)&&$(t).triggerHandler("resize"),i=!0===i,doModalOp(t,!0,(function(e,n){var s=t._triggerResizeQueue||{timeoutId:null};t._triggerResizeQueue=s,null!==s.timeoutId&&window.clearTimeout(s.timeoutId),s.timeoutId=window.setTimeout((function(){try{e.resizeContent(i)}catch(t){_log(t)}}),15)}))}function isChecked(t,e){return getCheckboxElement(t,e).checked}function getCheckboxElement(t,e){return checkboxElements[e]}function checkCheckBox(t,e,i,n){var s=getCheckboxElement(t,e);return s&&(s.checked=i,n&&lib.assureParentSelected(t,e)),!0}function emailCheck(t,e,i){var n="[^\\s".concat('\\(\\)><@,;:\\\\\\"\\.\\[\\]',"]"),s="".concat(n,"+"),o="(".concat(s,"|").concat('("[^"]*")',")"),r=new RegExp("^".concat(o,"(\\.").concat(o,")*$")),a="[a-zA-Z0-9](?:[a-zA-Z0-9-]*[a-zA-Z0-9]+)*",l=new RegExp("^".concat(a,"(\\.").concat(a,")+\\s*$")),c=t.match(/^\s*(.+)@(.+)$/);if(null==c)return invalidField(e,i,"The email address seems incorrect (check @ and .'s)"),!1;for(var u=c[1],h=c[2],d=0;d<u.length;d++)if(u.charCodeAt(d)>127)return invalidField(e,i,"The email username contains invalid characters."),!1;if(null==u.match(r))return invalidField(e,i,"The email username doesn't seem to be valid."),!1;var p=h.match(/^\[(\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})\]$/);if(null!=p){for(var f=1;f<=4;f++)if(p[f]>255)return invalidField(e,i,"Email destination IP address is invalid!"),!1;return!0}var m=h.match(l);if(null==m)return invalidField(e,i,"The email domain name does not seem to be valid."),!1;if(!(m[1].length>2))return invalidField(e,i,"The email address has an invalid tld domain. Are you missing .com?"),!1;if(h.length>255)return invalidField(e,i,"The email address has to long a domain name."),!1;for(var g=0;g<m.length-1;g++)if(m[g].length>63)return invalidField(e,i,"The email address domain name is to long."),!1;return!0}function getFieldValue(t,e){var i=t.$,n="",s=e.type||i(e).attr("type");if(s)if(s.indexOf("select-")>=0)e.selectedIndex>=0&&(n=e.options[e.selectedIndex].value);else if(s.indexOf("check")>=0||s.indexOf("radio")>=0){if(e.checked&&(n=e.value),e.length)for(var o=0;o<e.length;o++)e[o].checked&&(n=e[o].value)}else n=e.value;else if(e.length)for(var r=0;r<e.length;r++)e[r].checked&&(n=e[r].value);return null==n&&(n=""),n}function reassignFieldListeners(t,e){var i;if(i=t.length?t[0].form:t.form){for(var n=0;n<i.validatorFields.length;n++)i.validatorFields[n]==t&&(i.validatorFields[n]=e);for(var s=0;s<i.maskValidatorFields.length;s++)i.maskValidatorFields[s]==t&&(i.maskValidatorFields[s]=e)}}function validNewField(t,e,i){var n;if(void 0===i[0]&&(i[0]=e[0]),!(n=e.length?e[0].form:e.form))return!0;for(var s=0;s<n.validatorFields.length;s++)if(n.validatorFields[s]==e&&!n.validatorFunctions[s](t,i))return!1;for(var o=0;o<n.maskValidatorFields.length;o++)if(n.maskValidatorFields[o]==e&&!n.maskValidatorFunctions[o](t,i,n.maskValidatorMasks[o]))return!1;return!0}function validFields(t,e){t.runningValidFields=!0;for(var i=0;i<e.validatorFunctions.length;i+=1)if(fieldInForm(e,e.validatorFields[i])&&!e.validatorFunctions[i](t,e.validatorFields[i]))return t.runningValidFields=!1,!1;for(var n=0;n<e.maskValidatorFunctions.length;n+=1)if(fieldInForm(e,e.maskValidatorFields[n])&&!e.maskValidatorFunctions[n](t,e.maskValidatorFields[n],e.maskValidatorMasks[n]))return invalidField(t,e.maskValidatorFields[n],"".concat(e.maskValidatorFields[n].value," is not in the correct format.")),t.runningValidFields=!1,!1;return t.runningValidFields=!1,!0}function fieldInForm(t,e){function i(e){for(var i=0;i<t.elements.length;i++)if(t.elements[i]==e)return!0;return!1}if(!e)return!0;if(e.length&&!e.type){if(e.length<500){for(var n=0;n<e.length;n++)if(!i(e[n]))return!1}else if(!i(e[0]))return!1;return!0}return i(e)}function getMultiNumberChecked(t,e){var i=0;if(e.length)for(var n=0;n<e.length;n++)e[n].checked||e[n].selected?i++:e[n].options&&(i+=getMultiNumberChecked(t,e[n].options));else e.options&&e.options.length>0?i=getMultiNumberChecked(t,e.options):(e.checked||e.selected)&&(i=1);return i}function getFormObjects(t,e){var i=[],n=t.document.forms,s=0;for(s=0;s<n.length;s+=1){var o=n[s];o.elements[e]&&i.push(o)}return i}function stripSymbols(t){var e=t.value;void 0!==e&&(t.value=e.replace(/(\$|\,|\(|\)|\&)/g,""))}function getFormattedDate(t,e){var i=t.value.replace("-","/"),n=i.lastIndexOf("/");if(i.length-n==3){var s="20",o=i.substring(n+1,n+3);o>"30"&&(s="19"),i=i.substring(0,n+1)+s+o}return i}function isValidDate(t,e){var i,n,s,o,r;for(r=1;r<t.length;r++){var a=t.substring(r,r+1);if(isNaN(a)&&"/"!=a&&"-"!=a&&" "==a)return!1}if(""!=(o=t)){if((r=o.indexOf("/"))<1)return!1;if((i=o.substring(0,r)).length<1||i.length>2||i.charAt(0)>"9"||0==i&&1==r)return!1;if("0"==i.substring(0,1)&&(i=i.substring(1,2)),i=parseInt(i),!e){if((r=(o=o.substring(r+1)).indexOf("/"))<1)return!1;if((n=o.substring(0,r)).length<1||n.length>2||n.charAt(0)>"9")return!1;"0"==n.substring(0,1)&&(n=n.substring(1,2)),n=parseInt(n)}if(4!=(s=o.substring(r+1)).length||s.charAt(0)<"0"||s.charAt(0)>"9")return!1;if(s=parseInt(s),i<1||i>12||n<1||n>31||s<1900||s>2299||2==i&&n>29||2==i&&29==n&&s%4!=0||4==i&&n>30||6==i&&n>30||9==i&&n>30||11==i&&n>30)return!1}return!0}function isValidBirthDate(t,e,i,n){var s=!0,o=t.value;if(o.length>0){e&&(o=o.replace(/\//,"/01/"));var r=new Date(o),a=new Date,l=new Date;a.setFullYear(a.getFullYear()-n),l.setFullYear(l.getFullYear()-i),s=r>=a&&r<=l}return s}function isValidDateTime(t){var e=t.value.split(" ");return 3==e.length&&(isValidDate(e[0]),!!isValidStandardTime(e))}function isValidStandardTime(t){if(3!=t.length)return!1;if(5!=t[1].length)return!1;if(2!=t[2].length)return!1;var e=t[1].substring(0,2);if(isNaN(e))return!1;if(":"!=t[1].charAt(2))return!1;e=t[1].substring(3,5);return!isNaN(e)&&("am"==t[2].toLowerCase()||"pm"==t[2].toLowerCase())}function isValidNumber(t){var e,i;if(""!=t.value){if(e=0,"-"==t.charAt(0)&&(e=1,1==t.length))return!1;for(i=0;e<t.length;e++)if("."==t.charAt(e)){if(i>0||e==t.length-1)return!1;i++}else if(t.charAt(e)<"0"||t.charAt(e)>"9")return!1}return!0}function jqueryUniversalChange(t,e,i){(0,t.$)(e).bind(jqueryUniversalTriggerType(t,e),i)}function jqueryUniversalTriggerType(t,e){var i,n=t.$;switch(e.tagName.toUpperCase()){case"INPUT":switch(n(e).attr("type").toUpperCase()){case"RADIO":case"CHECKBOX":case"BUTTON":i="click change";break;case"PASSWORD":case"TEXT":i="blur change";break;case"FILE":i="change";break;default:i="change select click blur"}break;case"TEXTAREA":case"SELECT":i="blur change";break;default:i="change select click blur"}return i}function checkFormatting(t,e,i){var n=i,s=e,o=!0;return"00008698"!=companyId&&!isActiveDirectory&&t.document.location.href.indexOf("employee_form")<0&&(null!=n&&""!=n.value||null==s||""==s.value||(s=s.value).length<6&&(invalidField(t,e,"The username is invalid. Usernames must be at least ".concat(6," characters in length, should not include spaces, and must not be identical to the password.")),o=!1)),o}function makeTestCookie(){document.cookie="cookietest=yes;path=/"}function findTestCookie(){if(document.cookie.length>0&&window.navigator.cookieEnabled&&-1!==document.cookie.indexOf("cookietest="))return!0;return!1}function toolboxRegisterSelection(t,e){var i=t.$,n=i("#".concat(e,"_action_select")),s=n.closest("form");s.find("#inlineContent").length||s.append('<div id="inlineContent" style="height: 30ex"></div>');var o=function(){i("#inlineContent").html("").css("height","30ex"),t.toolbox[e]._parent.append(t.toolbox[e])};i('form input:reset[name="undo"]').click((function(){return o()})),n.change((function(){var n=i("#".concat(e,"_action_select option:selected")).attr("value"),s=!1;if("default"==n)return o(),!1;if(t.toolbox=t.toolbox||{},t.toolbox[e]=t.toolbox[e]||i("#toolbox_".concat(e)),t.toolbox[e]._parent=t.toolbox[e]._parent||t.toolbox[e].parent(),i("#toolbox_".concat(e)).remove(),i("#".concat(n)).length){var r=i("#".concat(n)).clone();r.attr("class",r.attr("id")),r.attr("id",""),i("#inlineContent").html(" ").append(r),r.show()}else s=!0;toolboxRunFunction(t,n),s&&t.document.forms[0].submit()}))}function toolboxRegisterActionGo(t,e){(0,t.$)("#".concat(e,"_go")).click((function(){var i=t.$,n=i("#".concat(e,"_action_select option:selected")).attr("value"),s=!1;if("default"===n)return t.alert("Please select an action to perform."),!1;if("all"===i('select[name="ACTION_TYPE"]').val()){if("RA00000002"===n)return t.alert("At most 100 recipients can be assigned eForms at a time. Please select no more than 100 recipients and try again."),!1}else if(0===i("div.rs tbody :checkbox:checked").length)return t.alert("Please select the records on which to perform the action."),!1;i("#".concat(n)).length?lib.showPopup(t,n):(s=!0,toolboxRunFunction(t,n)||lib.addHiddenField(t,n,n)),s&&t.document.forms[0].submit()}))}function closePopupFirst(t,e){Modal.closeAll(t,(function(){return e(t)}))}function toolboxRunFunction(t,e){if(!t.toolboxFunctions||!t.toolboxFunctions[e])return!1;try{t.toolboxFunctions[e](),triggerResize(t)}catch(i){return!1}return!0}function toolboxAddCancel(t,e){doModalOp(t,!0,(function(t,e){t.enableCancel(!0),$(e).find("input[name='cancel']").attr("onclick","").click((function(e){return e.preventDefault(),t.close(),!1}))}))}function canMakeAjaxCall(t,e){return"#"!=t||(_log("NOT making Ajax call, no valid URL provided (url is '#')."),!1)}function ajaxFillinPopup(t,e,i,n,s,o,r){if(canMakeAjaxCall(i,n)){var a=t.$;null==n?n="ajax=y":-1==n.indexOf("ajax=")&&(n+="&ajax=y");var l="get";n.length+i.length>2e3&&(n+="&fake_post=Y",l="post"),a(t.document).ajaxError((function(t,e,i){return _log("Server error: ".concat(e.status," url: ").concat(i.url))}));var c=getModal(t);c&&c.isOpen()?(dependentFieldCtx=".searchsoft-modal",a[l](i,n,(function(i,l){if("success"!=l)throw"AJAX error getting content";var u=a(c.getContent(!0)),h="div#inlineContent",d=a(u).find("div#inlineContent");d.length||(h=(d=a(u).find("div#".concat(e))).length?"div#".concat(e):null),c.setContent(i,h),d=a(c.getContent(!0)),afterAjaxPopProcess(t,e,d,n,s,o,r)}),"text").always((function(){dependentFieldCtx=null}))):a.get(i,n,(function(i,l){if("success"!=l)throw"AJAX error getting content";var c=a("#inlineContent div.".concat(e)).html(i);a("#inlineContent").css("height","auto"),afterAjaxPopProcess(t,e,c,n,s,o,r),lib.initForms(t)}),"text")}}function afterAjaxPopProcess(t,e,i,n,s,o,r){var a=t.$;lib.initForms(t),lib.addCheckboxApplicants(t,e),toolboxAddCancel(t,e),addMissingPopupRedirect(t,e),alwaysIsChanged(t,e),_this.isDevMode&&(i.find(".devmenulink, .wizardpopup").addClass("wizardlink").removeClass("wizardpopup"),i.find("div.rs a[href!='#ConfirmDelete'], div.rsrange a[href!='#ConfirmDelete']").addClass("wizardlink"),r=!0),s?hijackPopupSubmit(t,e,n,s,o,r):popUpFormSpinner(t);var l=getModal(t);(l&&doModalContentFix(t,l),i.find(".wizardlink").click((function(i){var n=a(this).attr("href");if(canMakeAjaxCall(n,null)){if(i.preventDefault(),l){var c=l.getContent(!0);a(c).find("form").hide().after("<h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p>")}return ajaxFillinPopup(t,e,n,null,s,o,r),!1}})),o)&&i.find(".linkbutton").each((function(){this.onclick=function(){return!0},a(this).click((function(i){var c=a(this).attr("href");if(canMakeAjaxCall(c,n)){if(i.preventDefault(),l){var u=l.getContent(!0);a(u).find("form").hide().after("<h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p>")}return ajaxFillinPopup(t,e,c,n,s,o,r),!1}}))}));l&&lib.addStyleClasses(t,l.getContent(!0)),lib.addStyleClasses(t,"#inlineContent .".concat(e)),triggerResize(t)}function addMissingPopupRedirect(t,e){var i=t.$;if(!i("input[name='searchpage']").length){var n=t.location;doModalOp(t,!0,(function(t,e){return i(e).find("form").append('<input type="hidden" name="searchpage" value="'.concat(n.pathname).concat(n.search,'" />'))}))}}function alwaysIsChanged(t,e){var i=t.$;doModalOp(t,!0,(function(t,e){return i(e).find("input[name='is_changed']").val("true")}))}function popUpFormSpinner(t){var e=t.$;doModalOp(t,!1,(function(t,i){return e(i).closest("form").submit((function(t){var i=e(this),n=i.get(0),s=n.onsubmit,o=!s||s.apply(n);return!1!==o?i.attr("target")&&0===i.attr("action").lastIndexOf("/servlet/jasper",0)?(i.hide().after("<div id='reportmessage'><p>Your report will be downloaded shortly. This could take up to several minutes. Feel free to close this window.</p><p>If your report does not download shortly, please go back and try again.</p><p><a href='#' id='submitshowformagain'> Go Back to Form </a></p></div>"),e("#submitshowformagain").click((function(t){return t.preventDefault(),i.next("#reportmessage").remove(),i.show(),!1}))):i.hide().after("<h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p>"):t.preventDefault(),o}))}))}function hijackPopupSubmit(t,e,i,n,s,o){var r=t.$;doModalOp(t,!1,(function(a,l){return r(l).find("form:not([target])").submit((function(l){l.preventDefault();var c=r(this).prop("onsubmit");if(!c||c.apply(this)){var u=r(this).serialize();u+="&ajax=y";var h=r(this).attr("action"),d=r(this).attr("method");d=null==d||"GET"==d.toUpperCase()?"get":"post";var p=r("<div><h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p></div>").attr("id",e);return a.setContent(p),r[d](h,u,(function(l,c){if("success"!=c)throw new Error("AJAX error");if(s){var d=p.html(l);afterAjaxPopProcess(t,e,d,i,n,s,o)}else/error has occured/.test(l)&&o?(p.html("<h1> Failure </h1>"),p.append("<p>CAUTION: Developer <a id='hijackretry' href='#'>Retry</a>. Will not provide success or failure message! Check your console</p>"),p.append("<xmp> ".concat(l,"</xmp>")),r("#hijackretry").click((function(){return r.post(h,u)}))):/ajaxerror/.test(l)&&-1==h.indexOf("/ats/application/detail/college_attended_form")?p.html(l):(p.html("<h1> Success </h1>"),a.close())})),!1}}))}))}function invalidField(t,e,i){var n=$(e).closest(".vex-dialog-input");n.find(".pagebuttons").show(),n.find(".preventMultipleSubmitButtonClickSpinner").remove(),t.fieldPrompt?t.fieldPrompt(e,i):t.alert(i)}function trimArray(t){for(var e=[],i=0,n=0;n<t.length;n++)e[i++]=t[n];return e}function getNextUrlFromNavigationPulldown(t,e){var i=e?"prev":"next",n=(0,t.parent.frames[0].$)("select[name=navchoice] option:selected")[i]();if(0!=n.length){var s=n.val(),o=s.substring(s.indexOf(",")+1,s.lastIndexOf(",")),r=s.substring(s.lastIndexOf(",")+1);o+="?".concat(r);t.location;return o}}function displayFn(t){return t?"".concat(t.toString().replace(/[\s]+/gim," ").substr(0,50),"..."):"null function"}function loadJsSource(t){return $.ajax({url:t,dataType:"text",async:!1}).responseText}setGlobalData("Lib.accessNextPage",!0),setGlobalData("Lib.loading",!1);var lib={pageListeners:[],log:function(t,e){_log("Call to deprecated Lib.log() function (should call Utils.log() directly)",!0),_log(t,e)},getCookie:function(t){var e=document.cookie.split(/\s*;\s*/),i=null;return $.each(e,(function(e,n){var s=n.split("=");if(s[0]==t)return i=s[1],!1})),i},getParam:function(t){var e=location.href,i=e.indexOf("?");if(i<0)return null;var n=(e=e.substr(i+1)).split("&"),s=null;return $.each(n,(function(e,i){var n=i.split("=");if(2==n.length){var o=n[0];return t==o?(s=n[1],!1):void 0}})),s},getModal:function(){return Modal},doSlowPageLoad:function(t,e){function i(t){var i=t.onReadyFunctions,n=i?i.length:0;_log("In doSlowPageLoad(".concat(e,"), win.onReadyFunctions.length=").concat(n))}var n=t.$;t.spinnerOn=!0,n(t.document).ready((function(){i(t),n("#slowpageloading").fadeIn(400),_log("Doing doSlowPageLoad(".concat(e,")")),window.setTimeout((function(){i(t),n("body").load(e,(function(){t.spinnerOn=!1;var e=t.onReadyFunctions||[];i(t);for(var n=0;n<e.length;n++)try{var s=e[n],o=displayFn(s);_log("Running onReadyFunction:\n".concat(o)),s(t)}catch(r){_log(r)}}))}),1e3)}))},renderHierCheckboxModel:function(t,e,i){new HierCheckboxModel(t,e,i).render()},openNode:function(t,e){return!0},toggleNode:function(t,e,i){var n;(i=void 0==i||!0===i)&&(n=t.document.getElementById("".concat(e,"_img")));var s=t.document.getElementById(e);"none"==s.style.display?(s.style.display="",i&&(n.src="/ats/images/minus.gif")):(s.style.display="none",i&&(n.src="/ats/images/plus.gif"))},assureChildrenMatch:function(t,e){var i=parents[e];if(i)for(var n=isChecked(t,e),s=i.length,o=0;o<s;o++){var r=i[o];checkCheckBox(t,r,n,!1),lib.assureChildrenMatch(t,r)}return!0},assureParentSelected:function(t,e){var i=kids[e];return i&&checkCheckBox(t,i,!0,!0),!0},setCheckboxElements:function(t){checkboxElements=[];for(var e=0;e<t.document.forms[0].elements.length;e++){var i=t.document.forms[0].elements[e];if(i&&"checkbox"==i.type){var n=i.value;checkboxElements[n]=i}}},rmimg:function(t,e){t.document.getElementById(e)||(t.document.getElementById("".concat(e,"_img")).style.display="none")},setParent:function(t,e,i){kids[e]=i;var n=parents[i];n||(n=[]),n=n.concat(e),parents[i]=n},initPageCollapse:function(t){for(var e in hiddenDivs)lib.pageCollapse(t,e)},pageCollapse:function(t,e){var i=t.getElementById("".concat(e,"-collapse-button")),n=t.getElementById(e);n&&i&&("none"==n.style.display?(n.style.display="",delete hiddenDivs[e],i.src="/ats/images/minus.gif"):(n.style.display="none",hiddenDivs[e]||(hiddenDivs[e]=!0),i.src="/ats/images/plus.gif"))},pageCollapseAtsSearchMultiPage:function(t,e){var i=t.$,n="#".concat(e,"-nonWrapper");i(".subPageContent").not(n).addClass("subPageContentHidden"),i(n).toggleClass("subPageContentHidden"),setTimeout((function(){i("html, body").animate({scrollTop:i("#".concat(e,"-wrapper")).offset().top},350)}),351)},checkSessionId:function(t){if(null==sessionId||null==t||""==sessionId||""==t||"null"==sessionId||"null"==t)return!0;if(t==sessionId)return!0;var e=_this.getCookie("SSS_SESSION_ID");return t==e&&(sessionId=e,!0)},helpLink:function(t,e){return t.alert(e),!1},importStatusPopup:function(t,e){var i;switch(e){case"success_annual":i="<b>Annual/Yearly import of all the Florida Certifications and Courses is successful!!</b>";break;case"success_quarterly":i="<b>Quarterly import of the Florida Certifications and Courses is successful!!</b>";break;case"sftp_yearly":i="<b>Exception occurred during import : </b> <br> <b>YearlyImports</b> folder is missing in the SFTP location!";break;case"sftp_quarterly":i="<b>Exception occurred during import : </b> <br> <b>QuarterlyImports</b> folder is missing in the SFTP location!";break;case"ccd_missing":i="<b>Exception occurred during import : </b> <br> <b>CCD</b> folder is missing in the SFTP location!";break;case"not_xlsx_format":i="<b>Exception occurred during import : </b> <br> File(s) should be of .xlsx formats only, other formats are not allowed.";break;case"failure_missing_del":i="<b>Exception occurred during import : </b> <br> <b>Delete</b> column is missing or not in the right column on one of the sheets.<br> When performing Quarterly Imports, Delete columns must be present on all sheets, here's the places to check : <br> 1. <b>Delete</b> column should be in the 11th column for the All Certifications sheet<br> 2. <b>Delete</b> column should be in the 3rd column for all of the Special Certifications sheet<br> 3. <b>Delete</b> column should be in the 11th column for the Dual Certifications sheet<br> 4. <b>Delete</b> column should be in the 7th column for the All Courses sheet";break;case"yearly_missing_file":case"quarterly_missing_file":i="<b>Exception occurred during import :</b> <br> Files are missing or names mismatch in the SFTP location for "+e.split("_")[0]+" import :<br> NOTE : .xlsx files should be available with names in below formats : <b>Certifications_(school_year) or Certifications_(school_year)_(quarter)</b> and <br> <b>Courses_(school_year) or Courses_(school_year)_(quarter)</b>";break;case"errors":i="<b>Exception occurred during import.</b> <br> It might be because of following reasons :<br> 1. invalid certification or course data<br> 2. missing or incomplete data<br> Note : Please refer to logs in SFTP site and check latest log file for more details.";break;default:i="Unknown exception occurred during import of CCD Certifications and Courses!!"}if(i.length>0)return i},removeFileUpload:function(t,e){var i=t.$,n="#".concat(e),s="".concat(n,"_remove"),o="".concat(n,"_view"),r="".concat(n,"_hidden_remove");i(s).click((function(){var t=i(this),e=i(n);t.css("display","none"),i(o).css("display","none"),i(r).val(e.val()),e.val(null),t.closest("td").find('input[type="button"]').val("Upload a File")}))},checkEmail:function(t,e){var i=!0,n=e.value;return n.length>0&&(i=emailCheck(n,t,e)),i},selectLocation:function(t){var e=t.$,i=e("select[name='COMPANY_ID']"),n=function(){return document.cookie="COMPANY_ID=".concat(i.val(),"; path=/")};n(),i.change((function(){e("select[name='action']").val("default"),n(),e("#inlineContent").html(" ")}))},checkConfirmEmail:function(t,e){var i,n=(0,t.$)("#EMAIL").val().trim().toLowerCase();return n!=(i=e.value.trim().toLowerCase())?(invalidField(t,e,"Confirm Email should match Email."),!1):n==i||void 0},checkRequiredRadio:function(t,e){var i=!1,n=t.$;if("none"==n("#".concat(n(e).attr("name"),"_ROW")).css("display"))return!0;if(e.length)for(var s=0;s<e.length;s++)e[s].checked&&(i=!0);else e.checked&&(i=!0);return!!i||(invalidField(t,e,"You have not filled out all required answers on this page."),!1)},initForms:function(t){function e(t){t.initialized||(t.validatorFunctions=new Array(0),t.validatorFields=new Array(0),t.maskValidatorFields=new Array(0),t.maskValidatorFunctions=new Array(0),t.maskValidatorMasks=new Array(0),t.initialized=!0)}var i=t.document.forms;if(i)for(var n=0;n<i.length;n+=1){e(i[n])}else $("form").whenExists((function(){e(this)}))},checkRequired:function(t,e){var i=t.$,n=i(e),s=n.attr("name"),o=i("#".concat(s,"_ROW"));if((o.length>0?o:n.parents("tr").eq(0)).is(":visible")&&""==getFieldValue(t,e)){var r=s||n.attr("id");logger.log("## checkRequired - INVALID (".concat(r,")")),logger.log(e);var a=i('input[name="customValidationMessage"]');return invalidField(t,e,a.length>0&&""!=a.val()?a.val():"You have not filled out all required fields on this page."),!1}return!0},validForm:function(t,e,i){return!!lib.checkAccess()&&(t.runningValidFields=!0,"applicant.view"!=i&&"dbuser.pwd_no_libraryjsp"!=i&&(i.match("dbuser")||i.match("applicant")&&!i.match("applicant_type"))&&!checkFormatting(t,e.elements.NAME,e.elements.PWD)?(t.runningValidFields=!1,!1):(t.runningValidFields=!1,validFields(t,e)))},compressFormQuery:function(t,e,i){if(!lib.checkAccess())return!1;var n=t.$,s=n(e).find(":input").filter((function(){return""!=n(this).val()})).serialize(),o="".concat(n(e).attr("action"),"?").concat(s);return["/ats/application/applicants","/ats/employer/admin/employee_search_results","/ats/employer/admin/employee"].includes(n(e).attr("action"))?n.post("/servlet/support/login/encryptQueryString",{queryString:s,actionUrl:n(e).attr("action")},(function(e){t.location.href=e.encryptedString}),"json"):t.location.href=o,!1},encryptQueryString:function(t,e,i,n){i.preventDefault();var s=t.$,o=s(e).find(":input").serialize();return s.post("/servlet/support/login/encryptQueryString",{queryString:o,actionUrl:n},(function(e){t.location.href=e.encryptedString}),"json"),!1},appendMulti:function(t,e,i){lib.initForms(t);var n=getFormObjects(t,e),s=0;for(s=0;s<n.length;s+=1){var o=n[s],r=new Array(i),a=o.elements[e];o.validatorFunctions=o.validatorFunctions.concat(r),o.validatorFields=o.validatorFields.concat(a)}},multiCheck:function(t,e){var i=getMultiNumberChecked(t,e),n=t.$,s="".concat(n(e).attr("name"),"_ROW");return!(n("[id='".concat(s,"']")).last().is(":visible")&&i<1)||(invalidField(t,e,"You have not filled out all required answers on this page."),!1)},reqAllMultiCheck:function(t,e){var i=getMultiNumberChecked(t,e),n=Array.from(e).filter((function(t){return"checkbox"===t.type})).length,s=t.$,o="".concat(s(e).attr("name"),"_ROW");return!(s("[id='".concat(o,"']")).last().is(":visible")&&i<n)||(invalidField(t,e,"You have not filled out all required answers on this page."),!1)},appendMask:function(t,e,i){lib.initForms(t);var n,s=e;-1!=e.indexOf(":::")&&(s=e.substring(0,e.indexOf(":::")),-1!=(e=e.substring(e.indexOf(":::")+3)).indexOf(":::")&&(n=e.substring(0,e.indexOf(":::"))));var o=getFormObjects(t,s),r=0;for(r=0;r<o.length;r+=1){var a=o[r],l=a.elements[s],c=new Array(i),u=new Array(l),h=new Array(n);a.maskValidatorFunctions=a.maskValidatorFunctions.concat(c),a.maskValidatorFields=a.maskValidatorFields.concat(u),a.maskValidatorMasks=a.maskValidatorMasks.concat(h)}},append:function(t,e,i){lib.initForms(t);var n=getFormObjects(t,e),s=0;for(s=0;s<n.length;s+=1){var o=n[s],r=o.elements[e],a=new Array(i),l=new Array(r);o.validatorFunctions=o.validatorFunctions.concat(a),o.validatorFields=o.validatorFields.concat(l)}},checkSize:function(t,e){e>0&&t.value.length>e&&(t.value=t.value.substring(0,e),alert("You have reached the maximum size for this field"))},checkSearchNumber:function(t,e){stripSymbols(e);var i=e.value;if(void 0===i)return!0;if(i.indexOf(">")>0||i.indexOf("<")>0)return invalidField(t,e,"An invalid number was entered in this field. If you are using > or <, please make sure it is the first symbol in the field."),!1;var n=i;return 0!=n.indexOf(">")&&0!=n.indexOf("<")||(n=i.substr(1)),!!isValidNumber(n)||(invalidField(t,e,"An invalid number was entered in this field."),!1)},checkNumber:function(t,e){return stripSymbols(e),!!isValidNumber(e.value)||(invalidField(t,e,"An invalid number was entered in this field. This field cannot contain any symbols ($, %, #, etc)."),!1)},checkZeroInterval:function(t,e){return stripSymbols(e),0!==e.value||(invalidField(t,e,"Interval cannot be zero"),!1)},confirmDelete:function(t,e){if(confirm("Are you sure you want to delete this record?")){if(e.indexOf("redirect=")<0)e="".concat(e,"&redirect=").concat(escape(t.location.href));else{var i=e.indexOf("&redirect="),n=e.indexOf("%");if(i>=0&&n<0){var s="&redirect=".length;e=e.substring(0,i+s)+escape(e.substring(i+s))}}t.location.href=e}},handleImpersonation:function(t,e,i){var n=e.split("?")[1].substr("USER_ID=".length);return $.get("/servlet/support/login/impersonation",{companyId:companyId,userId:n,impersonationMode:i},(function(e){e.success?"EMPLOYER"==e.accountType&&top.document.location.replace("/ats/employer/v51_employer_frame"):t.alert(e.errorMessage)}),"json"),!1},checkTime:function(t,e){var i=!0,n=e.value;if(0==n.length)return!0;if(5!=n.length)i=!1;else if(":"!=n.substring(2,3))i=!1;else{var s=n.substring(0,2),o=n.substring(3,5);if(s.charAt(0)>2||s.charAt(1)>9||o.charAt(0)>5||o.charAt(1)>9||2==s.charAt(0)&&s.charAt(1)>3)i=!1;else{var r=parseInt(s),a=parseInt(o),l=parseInt(s.substring(0,1)),c=parseInt(s.substring(1,2)),u=parseInt(o.substring(0,1)),h=parseInt(o.substring(1,2));(r>23||r<0||a>59||a<0||isNaN(r)||isNaN(a)||isNaN(l)||isNaN(c)||isNaN(u)||isNaN(h))&&(i=!1)}}return i||invalidField(t,e,"An invalid time was entered. Use Military Time Format: 00:00 to 23:59"),i},checkDate:function(t,e){var i=getFormattedDate(e);return isValidDate(i,!1)?(e.value=i,!0):(invalidField(t,e,"An invalid date was entered. Use Month Date Year Format MM/DD/YYYY."),!1)},checkBirthDate:function(t,e){return!!isValidBirthDate(e,!1,10,110)||(invalidField(t,e,"An invalid birth date was entered."),!1)},checkShortDate:function(t,e){var i=getFormattedDate(e);return isValidDate(i,!0)?(e.value=i,!0):(invalidField(t,e,"An invalid date was entered. Use Month Date Year Format MM/YYYY."),!1)},storeShortDateToFullDate:function(t,e){var i=e.val(),n=$(e).attr("id"),s=$("#".concat(n,"_ROW"));if(!isValidDate(i,!0)||""==i&&"none"!=s.css("display"))return e.next().val(""),!1;var o=function(t){var e=t.lastIndexOf("/"),i=t.substring(0,e),n=t.substring(e);return"".concat(i,"/01").concat(n)}(i);return e.next().val(o),!0},checkDateTime:function(t,e){if(isValidDateTime(e))return!0;invalidField(t,e,"An invalid date was entered. Use Format MM/DD/YYYY HH:MM am/pm.")},toggleSelectAllCheckboxes:function(t,e){!!$(t).attr("checked")?lib.selectAllCheckboxes(e,!1):lib.deselectAllCheckboxes(e,!1)},selectAllCheckboxes:function(t,e){e&&lib.setAccess(t,!1);var i=0;for(i=0;i<t.document.forms[0].elements.length;i++)"checkbox"==t.document.forms[0].elements[i].type&&(t.document.forms[0].elements[i].checked=!0)},documentSubmit:function(t,e,i,n){return setTimeout((function(){var s=t.$;lib.setAccessNextPage(!0);var o=!!s("input[name='save_as_draft']").length,r="Y"===s("input[name='IGNORE_REQUIRED_FIELDS']").val(),a=r;if(o||r||(a=lib.validForm.call(e[0],t,e[0],i)),o||a){var l=!1;createModal(t,{content:"#".concat(n),attributes:{useCloseX:!0},onOpen:function(t){var i=t.getContent(!0);s(i).css("height","auto"),s(i).css("width","auto"),t.enableOk({enable:!1}),t.setContent("<h3>Submitting...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p>");var n="".concat(e.serialize(),"&ajax=Y");o&&(n+="&save_as_draft=Save+as+Draft"),s.post(e.attr("action"),n,(function(e){l=!0,t.setContent(e),o&&setTimeout((function(){return t.close()}),500)}))},onClose:function(t){l&&t.enableOk({enable:!0})}})}}),500),!1},importCcdSubmit:function(t,e,i,n){return setTimeout((function(){var e=t.$,s=e("#"+n).find("form");lib.setAccessNextPage(!0);lib.disableMouseActions(t);createModal(t,{content:"#".concat(n),onOpen:function(n){n.enableOk({enable:!1}),n.setContent("<div class ='importpopup' style=''><h3>Importing Data...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p></div>");var o=e(n.getContent(!0));o.closest(".vex").find(".vex-content").css({width:"700px",height:"200px"}),o.closest(".vex-content").find(".vex-dialog-input").css({overflow:"unset",width:"unset",height:"unset"});var r="".concat(s.serialize(),"&ajax=Y");e.post(i,r,(function(i){!0;var s=lib.importStatusPopup(t,i.trim());n.setContent("<p>"+s+"</p>");var o=e(n.getContent(!0));o.closest(".vex").find(".vex-content").css({"max-height":"300px",width:"700px"}),o.closest(".vex-content").find(".vex-dialog-input").css({width:"unset"}),lib.enableMouseActions(t)}))}})}),500),!1},disableMouseActions:function(t){var e=t.parent.frames[0],i=e?e.$("#WA00000124"):$("#WA00000124");$("*").css({cursor:"wait","pointer-events":"none"}),i.find("div, li").css({cursor:"wait"}),i.find("a, div .ui-control-help, span").css({"pointer-events":"none"})},enableMouseActions:function(t){var e=t.parent.frames[0],i=e?e.$("#WA00000124"):$("#WA00000124");$("*").css({cursor:"","pointer-events":"all"}),i.find("div, li").css({cursor:""}),i.find("a, div .ui-control-help, span").css({"pointer-events":"all"})},unfollow:function(t,e){var i=t.$,n=i(e);return i.post(n.attr("href"),(function(t){if("Success!"==t){var e=n.closest("tr").nextAll("tr.even");n.closest("tr").nextAll("tr.odd").removeClass("odd").addClass("even"),e.removeClass("even").addClass("odd"),n.closest("tr").remove()}})),!1},deselectAllCheckboxes:function(t,e){e&&lib.setAccess(t,!1);var i=0;for(i=0;i<t.document.forms[0].elements.length;i++)"checkbox"==t.document.forms[0].elements[i].type&&(t.document.forms[0].elements[i].checked=!1)},daysSince:function(t,e){var i,n=e.value,s=new Date((new Date).getTime()),o=new Date(s-24*n*60*60*1e3),r="".concat(o.getMonth()+1,"/").concat(o.getDate(),"/").concat(o.getFullYear()),a=e.name.lastIndexOf("_DAYSSINCE");if(a>0&&(i=e.name.substring(0,a)),n>0&&null!=n)for(var l=0;l<t.document.forms[0].elements.length;l++)t.document.forms[0].elements[l].name==i&&(t.document.forms[0].elements[l].value=r);else for(var c=0;c<t.document.forms[0].elements.length;c++)t.document.forms[0].elements[c].name==i&&(t.document.forms[0].elements[c].value="")},setAvgField:function(t,e){return t.avgField=e},setTotalField:function(t,e){t.totalField=e,t.document.forms[0].elements[e].enabled=!1},appendScore:function(t,e){t.scores=t.scores.concat(e)},calculateScore:function(t){for(var e=0,i=0,n=0;n<t.scores.length;n++){var s=t.document.forms[0].elements[t.scores[n]],o=parseInt(getFieldValue(t,s));!o>0&&(o=0,i++),e+=o}var r=e/(t.scores.length-i);return r=parseInt(r+.5),t.totalField&&e==parseInt(e)&&(t.document.forms[0].elements[t.totalField][0].value=e,t.document.forms[0].elements[t.totalField][1].value=e),t.avgField&&r==parseFloat(r)&&(t.document.forms[0].elements[t.avgField][0].value=r,t.document.forms[0].elements[t.avgField][1].value=r),!0},clearListeners:function(){return lib.pageListeners=[]},updatePage:function(t,e){var i=e.options[e.selectedIndex].value,n=null,s=null;if(i.indexOf(",")>=0&&(n=i.substring(0,i.indexOf(",")),(s=i.substring(i.indexOf(",")+1)).indexOf(",")>=0)){var o=s.substring(0,s.indexOf(",")),r=s.substring(s.indexOf(",")+1),a=o;if(null!=r){var l="?";a.indexOf("?")>=0&&(l="&"),a=a+l+r}}if(lib.checkAccess())lib.loadingPage(!0),s.indexOf(",")>=0&&(t.parent.frames[n].location.href=a,t.parent.frames[n].focus());else{t.alert('You must first click the "Save and Next" or "Undo" buttons before exiting this page.');for(var c=e.options.length,u=t.parent.frames[n].location.pathname,h=0;h<c;h++){if(e.options[h].value.indexOf(u)>=0){e.selectedIndex=h;break}}}},loadingPage:function(t){return setGlobalData("Lib.loading",t),1==t&&lib.setAccessNextPage(!0),!0},isLoadingPage:function(){return getGlobalData("Lib.loading")},pageUpdated:function(t){for(var e=0;e<_this.pageListeners.length;e++){var i=_this.pageListeners[e],n=void 0;try{(n=i.pageUpdated)&&n(t)}catch(s){}}},setAccessNextPage:function(t){var e=lib.checkAccess();return _log("accessNextPage: ".concat(e)),setGlobalData("Lib.accessNextPage",t),!0},authenticateUser:function(t){var e=t.$;e.ajax({contentType:"application/json; charset=utf-8",data:JSON.stringify({value:!0}),method:"POST",url:"/api/eformsdocumentapprove/eformsSignedDocument",success:function(t){var i=JSON.parse(t),n=i.success;if(n){var s,o,r;i.hasOwnProperty("firstName")&&(s=i.firstName),i.hasOwnProperty("lastName")&&(o=i.lastName),i.hasOwnProperty("email")&&(r=i.email),e("#form-data").append("<div></div>").append('<img src="/ats/css-base/images/click-ok.png"/>').append(" ").append(s).append(" ").append(o).append(" ").append("("+r+")").append("<div></div>").css("display","block"),e(".eformsubmit").css("display","block")}e("#authenticatedoc").attr("disabled","disabled")},error:function(t){this.setState({_messageToUser:"Authentication fails"})}})},setAccess:function(t,e){return _this.setAccessNextPage(e),t&&t.document&&t.document.forms&&t.document.forms[0]&&t.document.forms[0].elements&&t.document.forms[0].elements.is_changed&&!t.document.forms[0].elements.force_is_changed&&(t.document.forms[0].elements.is_changed.value=!e),!0},checkAccess:function(){return getGlobalData("Lib.accessNextPage")},checkLinkAccess:function(){return!!_this.checkAccess()||(alert('You must first click the "Save and Next" or "Undo" buttons before exiting this page.'),!1)},addDependentField:function(t,e,i,n){var s=t.$;s(t.document).ready((function(){for(var o,r,a=[],l=e.split("|"),c=n?n.split("|"):[],u=0;u<c.length;u++)c[u]=c?c[u].split("&"):[];for(var h=0;h<l.length;h++){for(var d=[],p=l[h].split("&"),f=0;f<p.length;f++){var m=p[f],g="_NOT"===m.substr(-4);g&&(m=m.substr(0,m.length-4));var v=void 0;(v=dependentFieldCtx?s(dependentFieldCtx).find("[name='".concat(m,"']")).not(":disabled"):s("[name='".concat(m,"']")).not(":disabled")).data("negative",g),d[f]={fields:v,values:c[h]&&c[h][f]?c[h][f]:""}}a[h]=d}if(s.each(a,(function(t,e){return s.each(e,(function(t,e){return o=o?o.add(e.fields):e.fields}))})),r=dependentFieldCtx?s(dependentFieldCtx).find("#".concat(i,"_ROW")):s("#".concat(i,"_ROW")),o&&o.length){var _=function(e){for(var i=!1,n=0;n<a.length&&!i;n++){for(var o=a[n],l=!0,c=function(t){for(var e=o[t],i=e.values.split(","),n=""===e.values,r=!1,a=0;a<e.fields.length&&!r;a++){var c=e.fields.eq(a),u=c.val(),h=c.data("negative");c.is(":radio,:checkbox")&&!c.is(":checked")&&(u=null);var d=!1;null!==u&&(u=s.makeArray(u),s.each(u,(function(t,e){""!=e&&s.inArray(e,i)>=0&&(d=!0)}))),r=d||u&&""!=u&&n,h&&(r=!r)}l=r},u=0;u<o.length&&l;u++)c(u);i=l}i?e?(r.show(),triggerResize(t,!0,!1)):"none"==r.css("display")&&(r.css("display",""),r.css("opacity","0"),r.animate({opacity:"1"},500,"swing",(function(){return triggerResize(t,!0,!1)}))):e?(r.hide(),triggerResize(t,!0,!1)):r.fadeOut({complete:function(){return triggerResize(t,!0,!1)}})};s(":reset").click((function(){s(this).get(0).form.reset(),_(!0)})),o.each((function(e,i){var n=s(i);n.hasClass("select-plus")&&!n.hasClass("select-plus-initialized")?SelectPlus.registerChangeListener(n,_):jqueryUniversalChange(t,i,(function(){return _()}))})),_(!0)}}))},setLocation:function(t,e){_this.checkAccess()?t.document.location.href=e:t.alert('You must first click the "Save and Next" or "Undo" buttons before exiting this page.')},setLocationToDashboard:function(t,e){t.document.location.href=e},historyGo:function(t,e){if(_this.checkAccess())t.$("body").trigger("ss-event-page-cancel"),t.history.go(-1);else{var i=(e=t.event||e).target||e.srcElement,n=$(i).parents("ul").find("input[type=submit]");t.alert('You must first click the "'.concat(n.val(),'" or "Undo" buttons before exiting this page.'))}},maskFormat:function(t,e,i){var n=e.value;return""==n||!!new RegExp(i).exec(n)},autoFormat:function(t,e,i){var n=t.value;if(""!=n){var s=new RegExp(e);s.exec(n)?t.value=n.replace(s,i):alert("".concat(n," is not in the correct format."))}},AppLoginStepFillIn:function(t){var e=t.$,i=e(".pagebuttons ul :has([value='Create New Account'])");i.css("display","block"),e("div.create_account")&&(e("div.create_account").html(i.html()),i.css("display","none")),e("#step2_links")?(e("#preview").hide(),e("#step2_links").html(e("#preview").html())):e("#preview").show()},addStyleClasses:function(t,e){var i=t.$;if(i){_log("addStyleClasses for ".concat(e=e||"body"));var n=i(e);n.find(":text").addClass("textfield"),n.find(":password").addClass("passwordfield"),n.find(":text, :password").focus((function(){i(this).addClass("textfieldfocus")})),n.find(":text, :password").blur((function(){i(this).removeClass("textfieldfocus")})),n.find("td:empty").html(" "),function(){var t=n.find('select[name="ACTION_TYPE"]');t.change((function(){var e=n.find(".rs :checkbox");"all"===t.val()?e.prop("disabled","disabled").hide():e.prop("disabled","").show()}))}(),n.find(":reset").click((function(t){i(".file_upload_field[type='hidden']").each((function(t){var e=i(this).attr("original");i(this).val(e);var n=i("#".concat(i(this).attr("name"),"_link"));n.attr("href",e),""==e&&n.fadeOut()}))}));var s={".embedded_field":function(t){t.closest("label").find(":radio, :checkbox").click((function(){return i(t).children(":text").focus()})),t.closest("label").find(":text").click((function(){i(this).closest("label").find(":radio, :checkbox").attr("checked","checked")}))},"a.wizardpopup":function(t){r(t,!0)},"a.wizardpopupNoReload":r,"a.modalpopuplink":function(e){return e.click((function(n){n.preventDefault();var s="modalpopuplink";return i("#".concat(s)).length||i("body").append("<div id='".concat(s,"' style='display:none;'><h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p></div>")),_this.addToolboxFunction(t,s,(function(){return ajaxFillinPopup(t,s,e.attr("href"))})),_this.showPopup(t,s),!1}))},"input.suggestsearch":function(e){var n="".concat(e.attr("id")||e.attr("name"),"_sug"),s=e.attr("href");s.indexOf("?")<0?s+="?":s+="&";s+="jscallback=?";var o=-1;function r(t){for(var s in c(),i("#".concat(n,"_con")).length||e.after("<div id='".concat(n,"_con'><div id='").concat(n,"' class='search_suggest'></div></div>")),t){var o=n+t[s];i("#".concat(n)).append("<div id='".concat(o,"' class='suggest_link'>").concat(s,"</div>"));var r=i("#".concat(o));r.hover(a,l),r.click((function(){e.val(i(this).html()),c()}))}}function a(){i(this).addClass("suggest_link_over"),e.unbind("blur")}function l(){i(this).removeClass("suggest_link_over"),e.blur(c)}function c(){i("#".concat(n,"_con")).remove()}e.keyup((function(n){-1!=o&&t.clearTimeout(o),o=t.setTimeout((function(){var t=e.val();if(""!=t){t={suggest:t,ajax:"y"};var n=i.param(t);i.getJSON(s,n,r)}}),500)})),e.blur(c)},"input.file_upload_field[type='button']":function(e){i(e).click((function(e){_log("Doing input.file_upload_field[type='button'].click()...");var n=this;i(n).parents().last().find("[id=upload_field]:hidden").remove(),closePopupFirst(t,(function(){_log("Doing fileUploadPopup - popups have been closed."),function(t,e){var i=e.$,n=getModal(e);if(n&&n.isOpen())return void alert("ERROR: cannot have a fileupload field within another pop-up");var s=i(t).attr("hiddenname"),o="FIELD_NAME=".concat(s,"&COMPANY_ID=").concat(companyId);if(!i("#".concat("upload_field")).length){var r='<div id="'.concat("upload_field",'" style="display: none"><h3>Loading...</h3> <p><img src=\'https://cdn.atenterprise.powerschool.com/images/loading.gif\' />Please Wait </p></div>');i("body").append(r)}var a="";i(t).is(".noextcheck")&&(a="?noextcheck=Y");_this.addToolboxFunction(e,"upload_field",(function(){ajaxFillinPopup(e,"upload_field","/ats/upload_field.jsp".concat(a),o)})),_this.addToolboxFunction(e,"".concat("upload_field","_close"),(function(){if(e.fileuploads&&e.fileuploads[s]){var t=e.fileuploads[s];t.id&&t.url&&(i("#".concat(s)).val(t.id),i(".".concat(s,"_link")).attr("href",t.url).fadeIn(),i(".".concat(s,"_remove")).attr("href","#").fadeIn(),i("#".concat(s,"_button")).attr("value","Replace File"),_this.setAccess(e,!1))}})),_this.showPopup(e,"upload_field")}(n,t)}))}))},".nctq_hoverable":function(e){e.mouseenter((function(e){o(t,i(this).next("div"),e,20,20),i(this).next("div").removeClass("nctq_scores_hidden"),i(this).next("div").addClass("nctq_scores_visible")})),e.mouseleave((function(t){i(this).next("div").removeClass("nctq_scores_visible"),i(this).next("div").addClass("nctq_scores_hidden")})),e.mousemove((function(e){o(t,i(this).next("div"),e,20,20)})),e.click((function(t){return t.preventDefault()}))}};!function(){var t="",e=!0;for(var o in s)e||(t+=","),t+=o,e=!1;n.find(t).each((function(){var t=i(this);for(var e in s)t.is(e)&&s[e].call(this,t)}))}()}else _log(new Error("Can not call addStyleClasses; jQuery is not available."));function o(t,e,i,n,s){var o=t.$,r=e.width(),a=e.height();e.css({top:Math.min(i.pageY+n,o(t).height()-a+o(t).scrollTop()),left:i.pageX-r-s})}function r(e,n){e.click((function(s){s.preventDefault();var o=e.attr("name")?e.attr("name"):"awizardpopup";return i("#".concat(o)).length||i("body").append("<div id='".concat(o,"' style='display:none;'><h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p></div>")),closePopupFirst(t,(function(){_this.addToolboxFunction(t,o,(function(){ajaxFillinPopup(t,o,e.attr("href"),null,!0,!0)})),n&&_this.addToolboxFunction(t,"".concat(o,"_close"),(function(){i("body").html("<h3 class='pageTitleCaption'>Please Wait... Loading</h3>");var e=t.location.href,n=top.frames[0]&&"sss_script"===top.frames[0].name;if(-1==e.indexOf("refresh")){var s=e;s.indexOf("?")>-1?s+="&refresh=Y":s+="?refresh=Y",n?t.location.replace(s):t.$("body").trigger("ss-event-page-reload")}else n?t.location.reload():t.$("body").trigger("ss-event-page-reload")})),_this.showPopup(t,o)})),!1}))}},fileUploadComplete:function(t,e,i){var n=t.$;n(".inlineHelp").remove(),n(".searchsoft-modal #file_upload_content").html(i),n(".searchsoft-modal #file_upload_waiting").stop().hide(),n(".searchsoft-modal #file_upload_content").fadeIn(),afterAjaxPopProcess(t,e,n(".file-upload-complete-wrapper-".concat(e)),null,!0,!0),triggerResize(t)},fileUploadStart:function(t){var e=t.$;return e(".inlineHelp").remove(),e(".searchsoft-modal #file_upload_waiting").fadeIn(),e(".searchsoft-modal #file_upload_content").hide(),!0},onReady:function(t,e){if(t.$=checkJQuery(t,t.$),t.$){var i=function i(){if(_log("win.document.readyState: ".concat(t.document.readyState)),"complete"!=t.document.readyState){var n=$.browser&&$.browser.mozilla?1e3:350;return _log("Deferring call to onReady for ".concat(n," ms...")),void t.setTimeout(i,n)}if(_log("Calling onReady() for:".concat(displayFn(e))),t.spinnerOn)t.onReadyFunctions=t.onReadyFunctions||[],t.onReadyFunctions.push(e),_log("Adding function to win.onReadyFunctions (length=".concat(t.onReadyFunctions.length,"), NOT calling function."));else try{_log("Executing onReady() function..."),e.call(_this,t)}catch(s){_log("Error occurred executing onReady function..."),_log(s)}};t.$(t.document).ready(i)}else _log(new Error("Can not call onReady; jQuery is not available."))},perform_cookie_test:function(){return makeTestCookie(),cookie_test=findTestCookie()},ready_modal_popup:function(t,e,i){(0,t.$)(t.document).ready((function(){e?toolboxRegisterSelection(t,i):toolboxRegisterActionGo(t,i),t.toolboxFunctions||(t.toolboxFunctions=new Array(0))}))},addToolboxFunction:function(t,e,i){t.toolboxFunctions||(t.toolboxFunctions=new Array(0)),t.toolboxFunctions[e]=i},ajaxPopupOp:function(t,e,i,n,s){var o=t.$,r=null;null==n&&""!=n||(r="op=".concat(n)),s&&(r="".concat(null==r?"":r+"&").concat(o("form").serialize()));var a=o("[name=table_name]").val();null==a||""==a||null!=r&&-1!=r.indexOf("table_name")||(r="".concat(r?r+"&":"","table_name=").concat(a)),ajaxFillinPopup(t,e,i,r)},ajaxPopup:function(t,e,i){return _this.ajaxPopupOp(t,e,i,null)},showPopup:function(t,e,i){var n=t.$,s=n("#".concat(e)).find("input[name=".concat(e,"]")).val();if(!s&&e.indexOf("_results")>0){var o=e.replace("_results","");s=n("#".concat(e)).find("input[name="+o+"]").val()}var r=n("#".concat(e)).parent(),a=n("#".concat(e)).find(".pagebuttons").hide().end();n(a).css("display","");var l={useCloseX:!0};i=i?n.extend({},l,i):l;var c=!s,u={id:e,attributes:i,content:a,onOpen:function(){n('[id="'.concat(e,'"]')).toArray().slice(0,-1).forEach((function(t){return n(t).remove()})),c&&(toolboxAddCancel(t,e),toolboxRunFunction(t,e))},onClose:function(i){var s=n(i.getContent(!0));s=n(s).children(),n(r).append(s.hide()),toolboxRunFunction(t,"".concat(e,"_close")),n(".inlineHelp").remove(),t.document.thismodal=null}};c?(u.showOk=!1,u.showCancel=!1):u.buttons=[{text:s,type:"ok",callback:function(i){return toolboxRunFunction(t,e)}},{text:"Cancel",type:"cancel"}],createModal(t,u,!0)},addHiddenField:function(t,e,i){(0,t.$)("form").append('<input type="hidden" name="'.concat(e,'" value="').concat(i,'" />'))},addCheckboxApplicants:function(t,e){var i=t.$;doModalOp(t,!1,(function(t,e){var n=i(e).find("form"),s=i("div.rs :checkbox:checked").clone();s.attr("checked","checked"),s.attr("remove","yes"),s.hide(),n.append(s);var o=i("select[name='ACTION_TYPE']");o.length&&n.append('<input type="hidden" name="ACTION_TYPE" value="'.concat(o.val(),'" />')),0==i(n).find(":checkbox:checked").length&&i(n).find(":hidden:checkbox").attr("checked","checked")}))},removeCheckboxApplicants:function(t,e){(0,t.$)("div#".concat(e," :checkbox[remove='yes']")).remove()},addSuperConfirm:function(t){var e=t.$;t.superConfirm=function(i,n){return createModal(t,{content:i,attributes:{useCloseX:!1},buttons:[{text:"Yes",type:"ok",callback:function(i){e.isFunction(n)&&n.apply(),triggerResize(t)}},{text:"Cancel",type:"cancel",callback:function(t){return e(".inlineHelp").remove()}}]})}},replaceAlert:function(t){var e=t.$;t.alert=function(i){if(i=i.replace(/\r\n|\n/g,"<br />"),Modal.anyShowing(t)){var n,s=e("<div class='red inlineHelp' />").html(i);e(".inlineHelp").length?(n=e(".inlineHelp").html(i),t.clearTimeout(t.helpTimeout)):(Modal.getCurrent(t).addContent(s),n=e(".inlineHelp").css("opacity","0").animate({opacity:"1"},500,"linear",(function(){triggerResize(t)}))),t.helpTimeout=t.setTimeout((function(){return n.animate({opacity:"0"},500,"linear",(function(){n.remove(),triggerResize(t)}))}),15e3),triggerResize(t)}else i=e("<p class='help_popup' />").html(i),createModal(t,{content:i,attributes:{useCloseX:!1},buttons:[{text:"Close",type:"ok",callback:function(t){return e(".inlineHelp").remove()}}]})}},addFieldPrompt:function(t){var e=t.$;function i(t,e,i){t.alert(i)}t.fieldPrompt=function n(s,o,r,a){var l=s,c=!(s.name||s.id||s.type)&&s.length;if(c||((s=[])[0]=l),r=!!r,t.runningValidFields&&(r=!0),Modal.anyShowing(t))return a?i(t,0,o):r?t.setTimeout((function(){return n(l,o,r,!0)}),550):i(t,0,o);try{if(e(".gridfield").length>0)for(var u=e(".gridfield"),h=0;h<u.length;h++)if(e.contains(u[h],s[0]))return i(t,0,o)}catch(x){}for(var d=t.fieldDelimiter||"tr",p=null,f=0;f<s.length;f++)p=p?p.add(e(s[f]).closest(d).eq(0)):e(s[f]).closest(d);if(!p.length)return i(t,0,o);var m=0!=e(p).find(".hasDatepicker").length,g=e(p).clone(!m);e(g).find("*").addBack().each((function(){var t=e(this).attr("id");t&&e(this).attr("id","".concat(t,"_COPY"))})),e(g).find(".do-not-copy").remove();var v=[],_=!1;if(g.find("*").each((function(t){for(var i=0;i<s.length;i++){var n=!0,o=s[i],r=e(o).attr("id"),a=e(this).attr("id");"".concat(r,"_COPY")!=a&&(n=!1),e(o).attr("name")!=e(this).attr("name")&&(n=!1),e(o).attr("value")!=e(this).attr("value")&&"select-one"!=e(o).attr("type")&&(n=!1),e(o).attr("type")!=e(this).attr("type")&&(n=!1),n&&(v[i]&&(_=!0),v[i]=e(this).get(0))}})),_)return i(t,0,o);if(s.length!=v.length)return i(t,0,o);s=trimArray(s),v=trimArray(v);var b=!1,y=e("<div class='invalid'>".concat(o,"</div>"));switch(e(y).append(g),d){case"tr":g.wrap('<table class="frmpfields"></table>');break;case"td":g.wrap('<table class="frmpfields"><tr></tr></table>');break;case"li":g.wrap("<ul></ul>");break;default:g.wrap('<div class="fieldprompt"></div>')}createModal(t,{content:y,attributes:{useCloseX:!0},showOk:!0,showCancel:!0,callback:function(i){var n;return v.filter((function(t){return void 0!==t})).forEach((function(t){var i=e("#".concat(t.id))[0];t.checked=i.checked,t.value=i.value})),n=c?v:v[0],!(0==e(p).find(".file_upload_field").length)||!!validNewField(t,l,n)&&void(b=!0)},onOpen:function(){if(m){var i=e(g).find(".hasDatepicker");e(i).removeClass("hasDatepicker"),e(i).datepicker({showOtherMonths:!0,selectOtherMonths:!0,showAnim:"slideDown",changeYear:!0})}triggerResize(t),e("#".concat(v[0].id)).focus()},onClose:function(){if(e(".inlineHelp").remove(),b){var i;i=c?v:v[0],reassignFieldListeners(l,i);for(var n=0;n<s.length;n++){var o=!1;v[n].checked&&(o=!0),e(s[n]).replaceWith(v[n]);var a=e(v[n]).attr("id")||"";(a=a.replace("_COPY",""))&&e(v[n]).attr("id",a),m&&(e(v[n]).removeClass("hasDatepicker"),e(v[n]).datepicker({showOtherMonths:!0,selectOtherMonths:!0,showAnim:"slideDown",changeYear:!0})),o&&e(v[n]).attr("checked","checked")}_this.setAccess(t,!1),r&&e("[name='submit_button']").trigger("click")}}})}},initFormPage:function(t){t.scores=new Array(0),t.avgField=null,t.totalField=null},multiRecordField:function(t,e,i,n){var s=t.$;function o(){var t=s("#".concat(e));t.html('<h3>Loading...</h3> <p><img src="https://cdn.atenterprise.powerschool.com/images/loading.gif" />Please Wait</p>'),s.get(i,"ajax=Y&refresh=Y",(function(e,i){if("success"!==i)throw"AJAX error getting content";t.html(e),r()}),"text")}function r(){if(s("#".concat(e," .resultpageajaxlinks")).length){var i="".concat(e,"_popup");s("#".concat(e,' a:not([class~="resultlink"])')).click((function(e){var n=s(this),r=n.attr("href");return n.hasClass("delete")?t.superConfirm("Are you sure you want to delete this record?",(function(){return s.post(r,null,(function(t,e){if("success"!==e)throw"AJAX error";o()}))})):(_this.addToolboxFunction(t,i,(function(){return ajaxFillinPopup(t,i,r,null,!0)})),_this.addToolboxFunction(t,"".concat(i,"_close"),(function(){return o()})),_this.showPopup(t,i)),e.preventDefault(),!1}))}}this.refreshResultPage=o,n?o():r()},jsExpression:function jsExpression(win,target,expression,defaults){for(var $=win.$,varRegExp=new RegExp("\\b[A-Za-z][A-Za-z0-9_]+\\b","g"),variable;null!=(variable=varRegExp.exec(expression));){var elem=$("[name='".concat(variable,"']"));elem.length&&(elem.unbind(jqueryUniversalChangeSupportedEvents.join(","),runExpression),jqueryUniversalChange(win,elem.get(0),runExpression))}function runExpression(){var expr=buildRawExpression();try{var value=eval(expr),targetField=$("#".concat(target,"_display")),targetHidden=$("#".concat(target));value!=targetHidden.val()&&(targetField.val(value),targetField.trigger("change"),targetHidden.val(value),targetHidden.trigger("change"))}catch(ex){lib.replaceAlert(win);var msg="<span style='font-size: 1em; font-style: normal; font-weight: normal'>It appears that there is an unresolved variable in the JS Expression string provided:</span><br /><br /><span style='font-size: .8em; font-style: italic; font-weight: bold'>".concat(expr,"</span><br /><br /><span style='font-size: 1em; font-style: normal; font-weight: normal'>Check the unresolved field name and ensure that it corresponds with an input on the page.</span>");win.alert(msg),$("#".concat(target,"_display")).val("###")}}function buildRawExpression(){var t=expression;try{for(var e;null!=(e=varRegExp.exec(expression));){var i=null,n=$("[name='".concat(e,"']"));if(0!=n.length&&"###"!=n.val())i=Number(n.val());else{if(null==defaults[e])continue;i=Number(defaults[e])}isFinite(i)||(i=Number(0)),t=t.replace(new RegExp("\\b".concat(e,"\\b"),"g"),i)}t="( ".concat(t," )")}catch(s){_log(s)}return t}runExpression()},reloadNewMcrelYear:function(t,e){var i=t.$;i((function(){var n=i('select[name="'.concat(e,'"]'));n.change((function(){var e=n.val();if(""!==e){var s=i("form").prop("action"),o=URI(s).setQuery("MCREL_YEAR_ID",e).toString();t.location.href=o}}))}))},addReloadOnSelectChange:function(t,e){var i=t.$;_this.onReady(t,(function(){return i("select[name='".concat(e,"']")).change((function(n){var s,o=t.location.href,r=new RegExp("".concat(e,"=[^&]*"));s=r.test(o)?o.replace(r,"".concat(e,"=").concat(i(this).val())):"".concat(o,"&").concat(e,"=").concat(i(this).val());var a=new RegExp("".concat(e,"=([^&]*)"),"g").exec(o);null!=a&&a[1]==i(this).val()||(t.location.href=s)}))}))},activatePreview:function(t,e,i,n,s){var o=t.$;o("#".concat(n)).click((function(){var r=o("[name=".concat(i,"]"));if(!r.length)return t.alert("No input field to preview");var a=r.val();if(""==a||null==a)return t.alert("No input currently selected");var l=s[a];if(""==l||null==l)return t.alert("No preview page for that selection");if(e)t.open(l);else{var c="".concat(n,"_div");_this.addToolboxFunction(t,c,(function(){return ajaxFillinPopup(t,c,l,null)})),_this.showPopup(t,c)}}))},registerStageSelect:function(t,e,i,n,s,o,r){_this.onReady(t,(function(){var a=t.$,l=a("[name='".concat(e,"']")),c="singleValue_".concat(e);if(l.length){var u=a("[name='".concat(n,"']"));if(u.length){var h="text"==u.attr("type"),d=!0;u.bind("change",p),p.apply(u.get(0))}else _log("StagedSelectField parent field is not present: ".concat(n))}else _log("StagedSelectField is not present!");function p(t){var e=a(this),n=e.val();h&&(n+="*"),encodeURIComponent?n=encodeURIComponent(n):escape&&(n=escape(n));var s=e.attr("type"),r="radio"==s||"checkbox"==s,u=e.attr("checked");if(!r||u)if(""!=n&&null!=n){var d="/ats/stage_field_lookup?GUI_FIELD_ID=".concat(i,"&parentvalue=").concat(n,"&ajax=Y&jscallback=?");a.getJSON(d,f)}else!function(){l.html("").show(),a("#".concat(c)).remove(),o||l.append("<option value='' selected='selected'></option>");l.triggerHandler("change")}()}function f(e){if(e){var i=1==e.length&&r,n="";l.html(""),a("#".concat(c)).remove(),i||l.show();var u="",h=!1;if(a.each(e,(function(t,e){var o=e.value;if(""!=o){var r=e.caption,l="";(-1!=a.inArray(o,s)||i)&&(n+=r,l=" selected='selected' ",h=!0),u+="<option value='".concat(o,"'").concat(l,">").concat(r,"</option>")}})),o||i||(u="<option value=''".concat(h?"":" selected='selected' ","></option>").concat(u)),l.append(u),i){l.hide();var p="<div id='".concat(c,"'>").concat(n,"</div>");l.after(p)}l.triggerHandler("change"),d&&(d=!1,l.change((function(){return _this.setAccess(t,!1)})))}else _log("lookups null")}}))},registerStageText:function(t,e,i,n,s,o){_this.onReady(t,(function(){var s=t.$,o=s("[name='".concat(e,"']"));if(o.length){var r=s("[name='".concat(n,"']"));if(r.length){var a=!0;r.bind("change",l),l.apply(r.get(0))}else alert("StageTextField parent field is not present: ".concat(n))}else alert("StageTextField is not present!");function l(t){var e=s(this),n=e.val();encodeURIComponent?n=encodeURIComponent(n):escape&&(n=escape(n));var o=e.attr("type"),r="radio"==o||"checkbox"==o,a=e.attr("checked");if((!r||a)&&""!=n&&null!=n){var l="/ats/stage_field_lookup?GUI_FIELD_ID=".concat(i,"&parentvalue=").concat(n,"&ajax=Y&jscallback=?");s.getJSON(l,c)}}function c(e){if(e)if(1==e.length){var i=e[0].value;if(o.val(i),null!==t&&null!==t.tinymce){var n=t.tinymce.get(o.attr("id"));null!==n&&n.setContent(i)}o.triggerHandler("change"),a&&(a=!1,o.change((function(){return _this.setAccess(t,!1)})))}else alert("lookup must have one value");else alert("lookups null")}}))},registerMoveToSelect:function(t,e){function i(t,e){var i=t.innerHTML,n=e.innerHTML,s=null===i?"":"".concat(i),o=null===n?"":"".concat(n);return s>o?1:s===o?0:-1}function n(t,e){var n=t.find(":selected");n.detach(),e.append(n);var s=e.children();s.detach(),e.append(s.get().sort(i))}var s=t.$,o=s("#".concat(e)),r=s("#".concat(e,"_src"));s("#".concat(e,"_addbtn")).click((function(){_this.setAccess(t,!1),o.children().prop("selected",!1),n(r,o)})),s("#".concat(e,"_rmvbtn")).click((function(){_this.setAccess(t,!1),r.children().prop("selected",!1),n(o,r)})),s("form").on("click","input:submit",(function(){r.children().prop("selected",!1),o.children().prop("selected",!0)}))},browseToNextUrlFromNavigationPulldown:function(t,e){var i=getNextUrlFromNavigationPulldown(t,e);i?t.location.href=i:alert("Already at the end or beginning of the list.")},writeRedirectFromNav:function(t){return t.$("form").append('<input type="hidden" name="redirect" value="'.concat(getNextUrlFromNavigationPulldown(t,!1),'">'))},handlePreviousNavButton:function(t){getNextUrlFromNavigationPulldown(t,!0)||t.$(":button[value=Previous]").remove()},registerQuickSelectGoButton:function(t,e){return _this.onReady(t,(function(){var i=t.$;i("#".concat(e,"_go")).click((function(){var n="[name='".concat(e,"']"),s=i(n).val();""!=s&&(t.location.href=s)}))}))},registerExpandingMultiValue:function(t,e,i,n){var s=t.$;_this.onReady(t,(function(){var o,r,a,l,c,u;function h(){(o=s("#".concat(e,"_ROW"))).find("script").remove(),r=o.html(),a=s("#".concat(e,"_TABLE_CONTAINER tbody")),l=o.find("#".concat(e,"_SIZE")),c=parseFloat(l.val()),u=o.find("#".concat(e,"_TEMPLATE")),n&&f(a.find(".".concat(e,"_subrecord_container"))),n&&p(a.find(".".concat(e,"_subrecord_container"))),i&&function(){var t=a.find(".".concat(e,"_subrecord_container"));g(t),v(t)}();var h="".concat(e,"_addmore");if(!a.parent().find("#".concat(h)).length){var m=s('<a class="addMoreA"></a>').attr({id:h,href:"#"}).html('<img src="/ats/css-base/add.png" class="addMoreImg"/>Add More').click((function(e){return e.preventDefault(),_this.setAccess(t,!1),d(),!1}));a.closest("table").after(m)}parseFloat(l.val())<1&&d()}function d(){var o=parseFloat(l.val());l.val(o+1),c+=1;var r='<tr class="subrecord_container '.concat(e,'_subrecord_container" id="').concat(e,"_").concat(c-1,'">').concat(u.html().replace(/_TEMPLATE/g,"_SUBRECORD_"+(c-1)),"</tr>");a.append(r);var h=s("#".concat(e,"_").concat(c-1));i&&g(h),n&&f(h),n&&p(h),v(h),triggerResize(t)}function p(e){e.each((function(){var e=s(this),i=e.find(".subrecord_min"),n=e.find(jqueryUniversalChangeSupportedTags).get(0);jqueryUniversalChange(t,n,(function(){return function(t,e){var i=s(t),n=parseFloat(e.html()),o=parseFloat(i.val());(isNaN(o)||n>=o)&&i.val(n+1)}(n,i),!0}))}))}function f(t){t.find(".remove_container").append(' greater than <span class="subrecord_min"></span>'),m(t)}function m(i){function n(t,e,i){var n=parseFloat(s(t).val()),o=parseFloat(e.val());i.html(n),!isNaN(o)&&n>=o&&(e.val(n+1),e.trigger("change"))}i.each((function(){var i=s(this),o=i.prev(".".concat(e,"_subrecord_container")),r=i.find(".subrecord_min");if(o.length){var a=i.find(jqueryUniversalChangeSupportedTags).filter(":first"),l=o.find(jqueryUniversalChangeSupportedTags).filter(":first").get(0);jqueryUniversalChange(t,l,(function(){return n(l,a,r),!0})),n(l,a,r)}else r.html("0")}))}function g(t){t.find(".remove_container").prepend('<a class="subrecord_remove"><img title="Remove" alt="remove" src="/ats/css-base/remove.png" /></a>')}function v(e){e.find(".subrecord_remove").click((function(e){_this.setAccess(t,!1),l.val(parseFloat(l.val())-1);var i=s(this).closest(".subrecord_container"),o=i.next(".subrecord_container");i.remove(),n&&m(o)}))}h(),s(":reset").click((function(t){o.html(r),h()}))}))},disableSubmitButtons:function(t){return t.$("input[type='submit']").attr("disabled","disabled"),!0},eformOptionalEventHideFields:function(t,e){function i(t,e){var i=$(t).find("input,select,textarea");$(i).each((function(t,i){e?$(i).prop("disabled",!1):$(i).prop("disabled",!0)})),e?$(t).show():$(t).hide()}_this.onReady(t,(function(){var n=(0,t.$)("#".concat(e)),s=n.closest("tr").nextUntil("tr.endEformEvent");n.change((function(){var t=n.is(":checked");i(s,t)})),n.trigger("change")}))}};function HierCheckboxModel(t,e,i){var n=t.$;this._rootNode={children:[]},this._allNodes=[],this._counter=0;var s=this;function o(e,i,r){var a=r.node,l=r.children;if(i=function(e,i,o,r,a){var l=e.name,c=e.value,u=e.isChecked,h=e.caption,d=e.url;r=void 0===r||"null"==r?null:r,a=void 0===a||"null"==a?null:a;var p,f=n("<li></li>");if(null!=r&&null!=a){p=n("<a></a>").attr("href","#".concat(c)),n(p).click((function(e){try{return lib[a](t,c,i)}catch(n){_log(n)}}));var m=n("<img />").attr("border","0").attr("src",r);n(p).append(m)}else null!=r&&(p=n("<img />").attr("src",r).attr("border","0"));p&&n(f).append(p);var g=n("<input />").attr("type","checkbox").attr("name",l).attr("value",c);u&&n(g).attr("checked","checked");if(n(g).click((function(e){!function(e,i){lib.setAccess(t,!1);var n=s._allNodes[i];if(function t(e){for(var i=e.children,n=0;n<i.length;n++)i[n].field.checked=e.field.checked,t(i[n])}(n),n.field.checked)for(var o=n.parent;null!=o&&null!=o.field;)o.field.checked=n.field.checked,o=o.parent}(0,i)})),n(f).append(g),d){d=0==d.indexOf("http://")?d:"http://"+d;var v=n("<a></a>").attr("target","_blank").attr("href",d).text(h);n(f).append(v)}else n(f).append(t.document.createTextNode(h));var _={html:f,field:g[0],children:[],parent:o};return _.parent.children.push(_),s._allNodes.push(_),_}(a,s._counter++,i),n(e).append(i.html),l.length>0){var c=n("<ul></ul>");n(i.html).append(c),n.each(l,(function(t,e){return o(c,i,e)}))}}this.render=function(){var t=n("script#".concat(e));i=n.parseJSON(i);var r=n("<ul></ul>");o(r,s._rootNode,i),n(r).insertAfter(t)}}function handleError(t,e,i){_log(new Error(t),!0)}function displayError(t,e,i){_log(t)}_this.isDevMode&&(_this.initDevLinks=function(){function t(t){this._useBase;var e=this;this.setToolAltOption=function(n){function s(){e._useBase=!1,i("div.devmenu a").css({background:"#eee"}),i("div.devmenu a.alttool").each((function(){var t=i(this),e=t.attr("href");e=e.replace("&usealt=N",""),t.attr("href",e)}))}function o(){e._useBase=!0,i("div.devmenu a").css({background:"orange"}),i("div.devmenu a.alttool").each((function(){var t=i(this),e=t.attr("href");e=e.replace("&usealt=N",""),e+="&usealt=N",t.attr("href",e)}))}(void 0===e._useBase||void 0!==n)&&(e._useBase=!0===n),i("a.dragalt").unbind("click.devtools").bind("click.devtools",(function(){s(),t.alert("Tools will modify the alt record (default behavior).")})),i("a.dragbase").unbind("click.devtools").bind("click.devtools",(function(){o(),t.alert("Tools will now modify the base records (for all companies)! \nDanger, this will effect all pages until you log-out or set it back to alt!")})),e._useBase?o():s()};var i=checkJQuery(t,t.$),n="devdivid",s=0;function o(){i("a.hidedev").click((function(t){t.preventDefault(),i(".debug,.devmenu").fadeOut()}))}i.extend(i.fn.disableTextSelect=function(){return this.each((function(){}))}),s&&s!=t.yOffset&&_this.onReady(t,(function(){t.scrollTo(0,s),s=0})),this.activateDevLink=function(){var e=i(this),s=e.attr("href");if(s&&!e.hasClass("newwindow")){var o=e.hasClass("wizarddevlink"),r=e.hasClass("search");return _this.addToolboxFunction(t,n,(function(){o?ajaxFillinPopup(t,n,s,null,!0,!0,!0):ajaxFillinPopup(t,n,s,null,!r,!1,!0)})),_this.showPopup(t,n),!1}return!0},_this.onReady(t,(function(){t.devDone||(i("body").children(":last").after("<div id=\"devdivid\" style='display: none;'><h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p></div>"),_this.addToolboxFunction(t,n+"_close",(function(){t.yOffset="number"==typeof t.pageYOffset?t.pageYOffset:t.document.documentElement?t.document.documentElement.scrollTop:t.document.body.scrollTop,s=t.yOffset,i("body").html("<h1>Reloading...</h1>"),t.location.reload()})),e.setToolAltOption(),i("a.showFieldNames").click((function(){return i("span.fieldName").show()})),function(){var s=null;t.document.body.onmouseup=function(){return s=null},"td"==t.fieldDelimiter?i("div.devfieldmenu").each((function(){var o=i(this).closest("td"),r=i(this).find("a[href*='GUI_FIELD_ID']:first").eq(0).attr("href").match(/GUI_FIELD_ID=\w*\d*/)[0].replace(/GUI_FIELD_ID=/,""),a=o.width(),l=o.height()-5,c="width: 10px; height: "+l+"px;",u="width: "+a+"px; height: 10px;",h='style="position: absolute;'+u+'text-align: center;float: left;clear: both;"',d='style="position: absolute;'+c+'"',p='style="display: block;'+u+'"',f='style="display: block;'+c+'overflow: hidden;"',m='style="border: 0; padding-top: '+(l/2-30)+'px;"',g=".uparrow,.rightcon,.leftarrow,.downcon",v='<div class="uparrow" '+h+"><a "+p+' href=""><img style="border: 0;" src="/ats/css-base/up.png"/></a></div><div class="leftarrow" '+d+"><a "+f+' href=""><img '+m+' src="/ats/css-base/left.png"/></a></div><div class="rightcon" style="left: '+(a-5)+'px; position: relative;"> <div class="rightarrow" '+d+"><a "+f+' href=""><img '+m+' src="/ats/css-base/right.png"/></a></div></div>',_='<div class="downcon"><div class="downarrow" '+h+"><a "+p+' href=""><img style="border: 0;" src="/ats/css-base/down.png"/></a></div></div>',b=i(this);b.disableTextSelect(),b.get(0).onmousedown=function(){return s=r};var y="/ats/admin/drag_move_field.jsp?end_field_id="+r;o.get(0).onmouseover=function(a){o.get(0).onmouseover=null,o.hover((function(a){null!=s&&s!=r&&(o.prepend(v),o.append(_),o.children(g).mouseup((function(){if(null!=s&&s!=r){var o=y+"&start_field_id="+s+"&dir="+i(this).attr("class").replace(/arrow/,"")+"&usealt="+(e._useBase?"N":"Y");_this.addToolboxFunction(t,n,(function(){return ajaxFillinPopup(t,n,o)})),_this.showPopup(t,n)}})))}),(function(){o.find(g).remove()})),o.trigger("mouseover")}})):i("div.devfieldmenu").each((function(){var o=i(this).closest("tr"),r=o.find("th"),a=i(this).find("a[href*='GUI_FIELD_ID']:first");if(a.length){a=a.eq(0).attr("href").match(/GUI_FIELD_ID=\w*\d*/)[0].replace(/GUI_FIELD_ID=/,"");var l="width: "+r.width()+"px; height: 1.5em; left: 0;",c='style="position: absolute;text-align: center;'+l+'"',u='style="'+l+'display: block;"',h='<div class="uparrow" '+c+"><a "+u+' href=""><img style="border: 0;" src="/ats/css-base/up.png"/></a></div>',d='<div class="downcon"><div class="downarrow" '+c+"><a "+u+' href=""><img style="border: 0;" src="/ats/css-base/down.png"/></a></div></div>',p=o.find("div.devmenu");p.disableTextSelect(),p.get(0).onmousedown=function(){return s=a};var f="/ats/admin/drag_move_field.jsp?end_field_id="+a;o.get(0).onmouseover=function(l){o.get(0).onmouseover=null,o.hover((function(){null!=s&&s!=a&&(r.prepend(h),r.append(d),o.find(".uparrow,.downcon").mouseup((function(){if(null!=s&&s!=a){var o=f+"&start_field_id="+s+"&dir="+i(this).attr("class").replace(/arrow/,"")+"&usealt="+(e._useBase?"N":"Y");_this.addToolboxFunction(t,n,(function(){return ajaxFillinPopup(t,n,o)})),_this.showPopup(t,n)}})))}),(function(){return o.find(".uparrow,.downcon").remove()})),o.trigger("mouseover")}}}))}(),i("a.dependtool").unbind().click((function(){var n=i(this).closest("div.devfieldmenu"),s=i(this).closest("div.devmenu").find("a[href*='GUI_FIELD_ID']:first").eq(0).attr("href").match(/GUI_FIELD_ID=\w*\d*/)[0].replace(/GUI_FIELD_ID=/,""),o=t.prompt("For what value?");n.replaceWith("<a onclick='window.location.reload()'>Stop</a>"),i("div.devfieldmenu").replaceWith((function(){var t=i(this).find("a[href*='GUI_FIELD_ID']:first").eq(0).attr("href").match(/GUI_FIELD_ID=\w*\d*/)[0].replace(/GUI_FIELD_ID=/,"");return"<a class='makedependlink' href='/ats/admin/field_make_depend.jsp?PARENT_GUI_FIELD_ID="+s+"&GUI_FIELD_ID="+t+"&value="+encodeURIComponent(o)+"&ajax=Y&usealt="+(e._useBase?"N":"Y")+"' > Make Dependant</a>"})),i("a.makedependlink").unbind().click((function(e){var n=i(this);e.preventDefault();var s=i(this).attr("href");return i.get(s,null,(function(e,i){"success"==i?n.remove():t.alert("failed to make dependant, check your console and get a developer")})),!1}))})),i("a.devmenulink").each((function(){this.onclick=e.activateDevLink})),o(),function(t){i(".showhidden").click((function(e){e.preventDefault(),""==t.location.search?t.location.search="?showhidden=Y":t.location.search.match(/showhidden=Y/)?t.location.search=t.location.search.replace(/[\?\&]showhidden=Y/,""):t.location.search+="&showhidden=Y"}))}(t),function(){var t=i("select[name='ALT_COMPANY_ID']");t.length&&!t.val()&&t.val("<%=companyId%>")}()),t.devDone=!0}))}return function(e){return e._ss_devLinks||(e._ss_devLinks=new t(e)),e._ss_devLinks}}()),window.onerror=!1===init.addGlobalErrorHandler?null:this.isDevMode?displayError:handleError,$.each(lib,(function(t,e){return _this[t]=e})),_this.perform_cookie_test(),onLoadCallback.call(this,this),this.loaded=!0}
|
console-api |
debug |
URL: https://lausd.atenterprise.powerschool.com/resources/js/library.bundle.js?v=202105210854(Line 2)
Message:
Assigning value to moduleName Lib function Lib(init){if(init&&init.getGlobalInstance&&window.top._lib)return window.top._lib;window.top._lib||(window.top._lib=this);var isActiveDirectory=init.isActiveDirectory,companyId=init.companyId,sessionId=init.sessionId,onLoadCallback=init.onLoad||function(){};this.isDevMode=configuration.developmentMode,this.loaded=!1;var _this=this,parents=[],kids=[],hiddenDivs={},checkboxElements=[],jqueryUniversalChangeSupportedTags=":input[type!=hidden]",jqueryUniversalChangeSupportedEvents=["change","select","click","blur"],cookie_test=!1,dependentFieldCtx=null,_log=function(t,e){return logger.log(t)};function setGlobalData(t,e){_log("Setting '".concat(t,"' attribute to value '").concat(e,"'"));try{window&&window.top?$(window.top).data(t,e):_log("Can not set '".concat(t,"' attribute with value '").concat(e,"', top window is not available."))}catch(i){_log(new Error("Can not set '".concat(t,"' attribute with value '").concat(e,"': ").concat(i.message)))}}function getGlobalData(t){_log("Getting '".concat(t,"' attribute value."));try{if(window&&window.top){var e=$(window.top).data(t);return _log("Attribute '".concat(t,"' has value '").concat(e,"'")),e}return _log("Can not get '".concat(t,"' attribute value, top window is not available.")),null}catch(i){return _log(new Error("Can not get '".concat(t,"' attribute value: ").concat(i.message))),null}}function checkJQuery(t,e){return e||t.$||$}function getModal(t){return t.document.thismodal}function createModal(t,e,i){function n(e){_log("Doing resize!!!"),triggerResize(t,!1)}(e=e||{}).paddingTop=80,e.onOpen=mergeFunctions(e.onOpen,(function(e){$(t).on("resize",n),function(e){doModalContentFix(t,e)}(e)})),e.onClose=mergeFunctions(e.onClose,(function(){return $(t).off("resize",n)})),e.openOnCreate=!1,e.context=t;var s=Modal.createModal(e);return s&&(i&&(t.document.thismodal=s),s.open()),s}function doModalContentFix(t,e){var i=$(e.getContent(!0)),n=$(i);n.closest(".vex").css("padding-top","40px"),n.closest(".vex").find(".vex-dialog-input").css("overflow","auto"),n.find("#PageParagraphContainer").removeAttr("id"),n.find("#PageMainContainer").removeAttr("id"),n.find('input[type="submit"], input[type="reset"], input[type="file"]').addClass("vex-dialog-button vex-dialog-button-primary ss-modal-ok").css({"margin-top":"5px",float:"none"}),n.find('input[type="submit"]').click((function(){var e=$(document.getElementsByTagName("form")[1]),i=n.find("#footContainer"),s=i.find(".pagebuttons"),o=$('<img id=\'bulkActionInProgressSpinner\' src="https://cdn.atenterprise.powerschool.com/images/loading.gif" class="preventMultipleSubmitButtonClickSpinner" />');if("undefined"!=typeof e.attr("action")&&-1!=e.attr("action").indexOf("mass_transition_documents")){var r=$("<h4 id='bulkActionCompletedP'>Your requested action is complete.</h4>"),a=$("<h4 id='bulkActionFailedP' style='color:red' class='red ajaxerror'>One or more records have failed. Please check your pending items queue</h4>"),l=$("<h4 id='bulkActionInProgressP'>Bulk action requested is in progress</h4>"),c=$("<h4 id='emptySignature' style='color:red'class='red ajaxerror'>Signature field cannot be empty</h4>");try{i.length>1&&null!=i[1]&&void 0!=i[1]&&$($(".vex #footContainer")[0]).hide(),event.preventDefault();var u=$(".passwordfield").attr("value");e.find('input[id="authenticatedoc"]').length>0||void 0!==u&&null!==u&&""!==u.trim()?(s.hide(),i.append(o),i.append(l),$.ajax({data:e.serialize(),type:e.attr("method"),url:e.attr("action"),success:function(e){-1==e.indexOf("ajaxerror")?(o.hide(),l.hide(),i.append(r),t.location.reload()):(o.hide(),l.hide(),alert(e),event.stopPropagation())},error:function(t){o.hide(),l.hide(),i.append(a),event.stopPropagation()}})):(i.append(c),$(".passwordfield").focus((function(){c.hide()})))}catch(h){o.hide(),l.hide(),i.append(a)}}else s.hide(),i.append(o)})),n.find('input[type="button"]').addClass("vex-dialog-button vex-dialog-button-secondary ss-modal-cancel").css({"margin-top":"5px",float:"none"}),$(".linkbutton, .wizardlink").click((function(){return t.setTimeout((function(){doModalContentFix(t,e),triggerResize(t,!1)}),15)}))}function doModalOp(t,e,i){var n=getModal(t);if(n&&(n.isOpen()||!e))try{i(n,n.getContent(!0))}catch(s){_log(s)}}function triggerResize(t,e,i){(e=!1!==e)&&$(t).triggerHandler("resize"),i=!0===i,doModalOp(t,!0,(function(e,n){var s=t._triggerResizeQueue||{timeoutId:null};t._triggerResizeQueue=s,null!==s.timeoutId&&window.clearTimeout(s.timeoutId),s.timeoutId=window.setTimeout((function(){try{e.resizeContent(i)}catch(t){_log(t)}}),15)}))}function isChecked(t,e){return getCheckboxElement(t,e).checked}function getCheckboxElement(t,e){return checkboxElements[e]}function checkCheckBox(t,e,i,n){var s=getCheckboxElement(t,e);return s&&(s.checked=i,n&&lib.assureParentSelected(t,e)),!0}function emailCheck(t,e,i){var n="[^\\s".concat('\\(\\)><@,;:\\\\\\"\\.\\[\\]',"]"),s="".concat(n,"+"),o="(".concat(s,"|").concat('("[^"]*")',")"),r=new RegExp("^".concat(o,"(\\.").concat(o,")*$")),a="[a-zA-Z0-9](?:[a-zA-Z0-9-]*[a-zA-Z0-9]+)*",l=new RegExp("^".concat(a,"(\\.").concat(a,")+\\s*$")),c=t.match(/^\s*(.+)@(.+)$/);if(null==c)return invalidField(e,i,"The email address seems incorrect (check @ and .'s)"),!1;for(var u=c[1],h=c[2],d=0;d<u.length;d++)if(u.charCodeAt(d)>127)return invalidField(e,i,"The email username contains invalid characters."),!1;if(null==u.match(r))return invalidField(e,i,"The email username doesn't seem to be valid."),!1;var p=h.match(/^\[(\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})\]$/);if(null!=p){for(var f=1;f<=4;f++)if(p[f]>255)return invalidField(e,i,"Email destination IP address is invalid!"),!1;return!0}var m=h.match(l);if(null==m)return invalidField(e,i,"The email domain name does not seem to be valid."),!1;if(!(m[1].length>2))return invalidField(e,i,"The email address has an invalid tld domain. Are you missing .com?"),!1;if(h.length>255)return invalidField(e,i,"The email address has to long a domain name."),!1;for(var g=0;g<m.length-1;g++)if(m[g].length>63)return invalidField(e,i,"The email address domain name is to long."),!1;return!0}function getFieldValue(t,e){var i=t.$,n="",s=e.type||i(e).attr("type");if(s)if(s.indexOf("select-")>=0)e.selectedIndex>=0&&(n=e.options[e.selectedIndex].value);else if(s.indexOf("check")>=0||s.indexOf("radio")>=0){if(e.checked&&(n=e.value),e.length)for(var o=0;o<e.length;o++)e[o].checked&&(n=e[o].value)}else n=e.value;else if(e.length)for(var r=0;r<e.length;r++)e[r].checked&&(n=e[r].value);return null==n&&(n=""),n}function reassignFieldListeners(t,e){var i;if(i=t.length?t[0].form:t.form){for(var n=0;n<i.validatorFields.length;n++)i.validatorFields[n]==t&&(i.validatorFields[n]=e);for(var s=0;s<i.maskValidatorFields.length;s++)i.maskValidatorFields[s]==t&&(i.maskValidatorFields[s]=e)}}function validNewField(t,e,i){var n;if(void 0===i[0]&&(i[0]=e[0]),!(n=e.length?e[0].form:e.form))return!0;for(var s=0;s<n.validatorFields.length;s++)if(n.validatorFields[s]==e&&!n.validatorFunctions[s](t,i))return!1;for(var o=0;o<n.maskValidatorFields.length;o++)if(n.maskValidatorFields[o]==e&&!n.maskValidatorFunctions[o](t,i,n.maskValidatorMasks[o]))return!1;return!0}function validFields(t,e){t.runningValidFields=!0;for(var i=0;i<e.validatorFunctions.length;i+=1)if(fieldInForm(e,e.validatorFields[i])&&!e.validatorFunctions[i](t,e.validatorFields[i]))return t.runningValidFields=!1,!1;for(var n=0;n<e.maskValidatorFunctions.length;n+=1)if(fieldInForm(e,e.maskValidatorFields[n])&&!e.maskValidatorFunctions[n](t,e.maskValidatorFields[n],e.maskValidatorMasks[n]))return invalidField(t,e.maskValidatorFields[n],"".concat(e.maskValidatorFields[n].value," is not in the correct format.")),t.runningValidFields=!1,!1;return t.runningValidFields=!1,!0}function fieldInForm(t,e){function i(e){for(var i=0;i<t.elements.length;i++)if(t.elements[i]==e)return!0;return!1}if(!e)return!0;if(e.length&&!e.type){if(e.length<500){for(var n=0;n<e.length;n++)if(!i(e[n]))return!1}else if(!i(e[0]))return!1;return!0}return i(e)}function getMultiNumberChecked(t,e){var i=0;if(e.length)for(var n=0;n<e.length;n++)e[n].checked||e[n].selected?i++:e[n].options&&(i+=getMultiNumberChecked(t,e[n].options));else e.options&&e.options.length>0?i=getMultiNumberChecked(t,e.options):(e.checked||e.selected)&&(i=1);return i}function getFormObjects(t,e){var i=[],n=t.document.forms,s=0;for(s=0;s<n.length;s+=1){var o=n[s];o.elements[e]&&i.push(o)}return i}function stripSymbols(t){var e=t.value;void 0!==e&&(t.value=e.replace(/(\$|\,|\(|\)|\&)/g,""))}function getFormattedDate(t,e){var i=t.value.replace("-","/"),n=i.lastIndexOf("/");if(i.length-n==3){var s="20",o=i.substring(n+1,n+3);o>"30"&&(s="19"),i=i.substring(0,n+1)+s+o}return i}function isValidDate(t,e){var i,n,s,o,r;for(r=1;r<t.length;r++){var a=t.substring(r,r+1);if(isNaN(a)&&"/"!=a&&"-"!=a&&" "==a)return!1}if(""!=(o=t)){if((r=o.indexOf("/"))<1)return!1;if((i=o.substring(0,r)).length<1||i.length>2||i.charAt(0)>"9"||0==i&&1==r)return!1;if("0"==i.substring(0,1)&&(i=i.substring(1,2)),i=parseInt(i),!e){if((r=(o=o.substring(r+1)).indexOf("/"))<1)return!1;if((n=o.substring(0,r)).length<1||n.length>2||n.charAt(0)>"9")return!1;"0"==n.substring(0,1)&&(n=n.substring(1,2)),n=parseInt(n)}if(4!=(s=o.substring(r+1)).length||s.charAt(0)<"0"||s.charAt(0)>"9")return!1;if(s=parseInt(s),i<1||i>12||n<1||n>31||s<1900||s>2299||2==i&&n>29||2==i&&29==n&&s%4!=0||4==i&&n>30||6==i&&n>30||9==i&&n>30||11==i&&n>30)return!1}return!0}function isValidBirthDate(t,e,i,n){var s=!0,o=t.value;if(o.length>0){e&&(o=o.replace(/\//,"/01/"));var r=new Date(o),a=new Date,l=new Date;a.setFullYear(a.getFullYear()-n),l.setFullYear(l.getFullYear()-i),s=r>=a&&r<=l}return s}function isValidDateTime(t){var e=t.value.split(" ");return 3==e.length&&(isValidDate(e[0]),!!isValidStandardTime(e))}function isValidStandardTime(t){if(3!=t.length)return!1;if(5!=t[1].length)return!1;if(2!=t[2].length)return!1;var e=t[1].substring(0,2);if(isNaN(e))return!1;if(":"!=t[1].charAt(2))return!1;e=t[1].substring(3,5);return!isNaN(e)&&("am"==t[2].toLowerCase()||"pm"==t[2].toLowerCase())}function isValidNumber(t){var e,i;if(""!=t.value){if(e=0,"-"==t.charAt(0)&&(e=1,1==t.length))return!1;for(i=0;e<t.length;e++)if("."==t.charAt(e)){if(i>0||e==t.length-1)return!1;i++}else if(t.charAt(e)<"0"||t.charAt(e)>"9")return!1}return!0}function jqueryUniversalChange(t,e,i){(0,t.$)(e).bind(jqueryUniversalTriggerType(t,e),i)}function jqueryUniversalTriggerType(t,e){var i,n=t.$;switch(e.tagName.toUpperCase()){case"INPUT":switch(n(e).attr("type").toUpperCase()){case"RADIO":case"CHECKBOX":case"BUTTON":i="click change";break;case"PASSWORD":case"TEXT":i="blur change";break;case"FILE":i="change";break;default:i="change select click blur"}break;case"TEXTAREA":case"SELECT":i="blur change";break;default:i="change select click blur"}return i}function checkFormatting(t,e,i){var n=i,s=e,o=!0;return"00008698"!=companyId&&!isActiveDirectory&&t.document.location.href.indexOf("employee_form")<0&&(null!=n&&""!=n.value||null==s||""==s.value||(s=s.value).length<6&&(invalidField(t,e,"The username is invalid. Usernames must be at least ".concat(6," characters in length, should not include spaces, and must not be identical to the password.")),o=!1)),o}function makeTestCookie(){document.cookie="cookietest=yes;path=/"}function findTestCookie(){if(document.cookie.length>0&&window.navigator.cookieEnabled&&-1!==document.cookie.indexOf("cookietest="))return!0;return!1}function toolboxRegisterSelection(t,e){var i=t.$,n=i("#".concat(e,"_action_select")),s=n.closest("form");s.find("#inlineContent").length||s.append('<div id="inlineContent" style="height: 30ex"></div>');var o=function(){i("#inlineContent").html("").css("height","30ex"),t.toolbox[e]._parent.append(t.toolbox[e])};i('form input:reset[name="undo"]').click((function(){return o()})),n.change((function(){var n=i("#".concat(e,"_action_select option:selected")).attr("value"),s=!1;if("default"==n)return o(),!1;if(t.toolbox=t.toolbox||{},t.toolbox[e]=t.toolbox[e]||i("#toolbox_".concat(e)),t.toolbox[e]._parent=t.toolbox[e]._parent||t.toolbox[e].parent(),i("#toolbox_".concat(e)).remove(),i("#".concat(n)).length){var r=i("#".concat(n)).clone();r.attr("class",r.attr("id")),r.attr("id",""),i("#inlineContent").html(" ").append(r),r.show()}else s=!0;toolboxRunFunction(t,n),s&&t.document.forms[0].submit()}))}function toolboxRegisterActionGo(t,e){(0,t.$)("#".concat(e,"_go")).click((function(){var i=t.$,n=i("#".concat(e,"_action_select option:selected")).attr("value"),s=!1;if("default"===n)return t.alert("Please select an action to perform."),!1;if("all"===i('select[name="ACTION_TYPE"]').val()){if("RA00000002"===n)return t.alert("At most 100 recipients can be assigned eForms at a time. Please select no more than 100 recipients and try again."),!1}else if(0===i("div.rs tbody :checkbox:checked").length)return t.alert("Please select the records on which to perform the action."),!1;i("#".concat(n)).length?lib.showPopup(t,n):(s=!0,toolboxRunFunction(t,n)||lib.addHiddenField(t,n,n)),s&&t.document.forms[0].submit()}))}function closePopupFirst(t,e){Modal.closeAll(t,(function(){return e(t)}))}function toolboxRunFunction(t,e){if(!t.toolboxFunctions||!t.toolboxFunctions[e])return!1;try{t.toolboxFunctions[e](),triggerResize(t)}catch(i){return!1}return!0}function toolboxAddCancel(t,e){doModalOp(t,!0,(function(t,e){t.enableCancel(!0),$(e).find("input[name='cancel']").attr("onclick","").click((function(e){return e.preventDefault(),t.close(),!1}))}))}function canMakeAjaxCall(t,e){return"#"!=t||(_log("NOT making Ajax call, no valid URL provided (url is '#')."),!1)}function ajaxFillinPopup(t,e,i,n,s,o,r){if(canMakeAjaxCall(i,n)){var a=t.$;null==n?n="ajax=y":-1==n.indexOf("ajax=")&&(n+="&ajax=y");var l="get";n.length+i.length>2e3&&(n+="&fake_post=Y",l="post"),a(t.document).ajaxError((function(t,e,i){return _log("Server error: ".concat(e.status," url: ").concat(i.url))}));var c=getModal(t);c&&c.isOpen()?(dependentFieldCtx=".searchsoft-modal",a[l](i,n,(function(i,l){if("success"!=l)throw"AJAX error getting content";var u=a(c.getContent(!0)),h="div#inlineContent",d=a(u).find("div#inlineContent");d.length||(h=(d=a(u).find("div#".concat(e))).length?"div#".concat(e):null),c.setContent(i,h),d=a(c.getContent(!0)),afterAjaxPopProcess(t,e,d,n,s,o,r)}),"text").always((function(){dependentFieldCtx=null}))):a.get(i,n,(function(i,l){if("success"!=l)throw"AJAX error getting content";var c=a("#inlineContent div.".concat(e)).html(i);a("#inlineContent").css("height","auto"),afterAjaxPopProcess(t,e,c,n,s,o,r),lib.initForms(t)}),"text")}}function afterAjaxPopProcess(t,e,i,n,s,o,r){var a=t.$;lib.initForms(t),lib.addCheckboxApplicants(t,e),toolboxAddCancel(t,e),addMissingPopupRedirect(t,e),alwaysIsChanged(t,e),_this.isDevMode&&(i.find(".devmenulink, .wizardpopup").addClass("wizardlink").removeClass("wizardpopup"),i.find("div.rs a[href!='#ConfirmDelete'], div.rsrange a[href!='#ConfirmDelete']").addClass("wizardlink"),r=!0),s?hijackPopupSubmit(t,e,n,s,o,r):popUpFormSpinner(t);var l=getModal(t);(l&&doModalContentFix(t,l),i.find(".wizardlink").click((function(i){var n=a(this).attr("href");if(canMakeAjaxCall(n,null)){if(i.preventDefault(),l){var c=l.getContent(!0);a(c).find("form").hide().after("<h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p>")}return ajaxFillinPopup(t,e,n,null,s,o,r),!1}})),o)&&i.find(".linkbutton").each((function(){this.onclick=function(){return!0},a(this).click((function(i){var c=a(this).attr("href");if(canMakeAjaxCall(c,n)){if(i.preventDefault(),l){var u=l.getContent(!0);a(u).find("form").hide().after("<h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p>")}return ajaxFillinPopup(t,e,c,n,s,o,r),!1}}))}));l&&lib.addStyleClasses(t,l.getContent(!0)),lib.addStyleClasses(t,"#inlineContent .".concat(e)),triggerResize(t)}function addMissingPopupRedirect(t,e){var i=t.$;if(!i("input[name='searchpage']").length){var n=t.location;doModalOp(t,!0,(function(t,e){return i(e).find("form").append('<input type="hidden" name="searchpage" value="'.concat(n.pathname).concat(n.search,'" />'))}))}}function alwaysIsChanged(t,e){var i=t.$;doModalOp(t,!0,(function(t,e){return i(e).find("input[name='is_changed']").val("true")}))}function popUpFormSpinner(t){var e=t.$;doModalOp(t,!1,(function(t,i){return e(i).closest("form").submit((function(t){var i=e(this),n=i.get(0),s=n.onsubmit,o=!s||s.apply(n);return!1!==o?i.attr("target")&&0===i.attr("action").lastIndexOf("/servlet/jasper",0)?(i.hide().after("<div id='reportmessage'><p>Your report will be downloaded shortly. This could take up to several minutes. Feel free to close this window.</p><p>If your report does not download shortly, please go back and try again.</p><p><a href='#' id='submitshowformagain'> Go Back to Form </a></p></div>"),e("#submitshowformagain").click((function(t){return t.preventDefault(),i.next("#reportmessage").remove(),i.show(),!1}))):i.hide().after("<h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p>"):t.preventDefault(),o}))}))}function hijackPopupSubmit(t,e,i,n,s,o){var r=t.$;doModalOp(t,!1,(function(a,l){return r(l).find("form:not([target])").submit((function(l){l.preventDefault();var c=r(this).prop("onsubmit");if(!c||c.apply(this)){var u=r(this).serialize();u+="&ajax=y";var h=r(this).attr("action"),d=r(this).attr("method");d=null==d||"GET"==d.toUpperCase()?"get":"post";var p=r("<div><h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p></div>").attr("id",e);return a.setContent(p),r[d](h,u,(function(l,c){if("success"!=c)throw new Error("AJAX error");if(s){var d=p.html(l);afterAjaxPopProcess(t,e,d,i,n,s,o)}else/error has occured/.test(l)&&o?(p.html("<h1> Failure </h1>"),p.append("<p>CAUTION: Developer <a id='hijackretry' href='#'>Retry</a>. Will not provide success or failure message! Check your console</p>"),p.append("<xmp> ".concat(l,"</xmp>")),r("#hijackretry").click((function(){return r.post(h,u)}))):/ajaxerror/.test(l)&&-1==h.indexOf("/ats/application/detail/college_attended_form")?p.html(l):(p.html("<h1> Success </h1>"),a.close())})),!1}}))}))}function invalidField(t,e,i){var n=$(e).closest(".vex-dialog-input");n.find(".pagebuttons").show(),n.find(".preventMultipleSubmitButtonClickSpinner").remove(),t.fieldPrompt?t.fieldPrompt(e,i):t.alert(i)}function trimArray(t){for(var e=[],i=0,n=0;n<t.length;n++)e[i++]=t[n];return e}function getNextUrlFromNavigationPulldown(t,e){var i=e?"prev":"next",n=(0,t.parent.frames[0].$)("select[name=navchoice] option:selected")[i]();if(0!=n.length){var s=n.val(),o=s.substring(s.indexOf(",")+1,s.lastIndexOf(",")),r=s.substring(s.lastIndexOf(",")+1);o+="?".concat(r);t.location;return o}}function displayFn(t){return t?"".concat(t.toString().replace(/[\s]+/gim," ").substr(0,50),"..."):"null function"}function loadJsSource(t){return $.ajax({url:t,dataType:"text",async:!1}).responseText}setGlobalData("Lib.accessNextPage",!0),setGlobalData("Lib.loading",!1);var lib={pageListeners:[],log:function(t,e){_log("Call to deprecated Lib.log() function (should call Utils.log() directly)",!0),_log(t,e)},getCookie:function(t){var e=document.cookie.split(/\s*;\s*/),i=null;return $.each(e,(function(e,n){var s=n.split("=");if(s[0]==t)return i=s[1],!1})),i},getParam:function(t){var e=location.href,i=e.indexOf("?");if(i<0)return null;var n=(e=e.substr(i+1)).split("&"),s=null;return $.each(n,(function(e,i){var n=i.split("=");if(2==n.length){var o=n[0];return t==o?(s=n[1],!1):void 0}})),s},getModal:function(){return Modal},doSlowPageLoad:function(t,e){function i(t){var i=t.onReadyFunctions,n=i?i.length:0;_log("In doSlowPageLoad(".concat(e,"), win.onReadyFunctions.length=").concat(n))}var n=t.$;t.spinnerOn=!0,n(t.document).ready((function(){i(t),n("#slowpageloading").fadeIn(400),_log("Doing doSlowPageLoad(".concat(e,")")),window.setTimeout((function(){i(t),n("body").load(e,(function(){t.spinnerOn=!1;var e=t.onReadyFunctions||[];i(t);for(var n=0;n<e.length;n++)try{var s=e[n],o=displayFn(s);_log("Running onReadyFunction:\n".concat(o)),s(t)}catch(r){_log(r)}}))}),1e3)}))},renderHierCheckboxModel:function(t,e,i){new HierCheckboxModel(t,e,i).render()},openNode:function(t,e){return!0},toggleNode:function(t,e,i){var n;(i=void 0==i||!0===i)&&(n=t.document.getElementById("".concat(e,"_img")));var s=t.document.getElementById(e);"none"==s.style.display?(s.style.display="",i&&(n.src="/ats/images/minus.gif")):(s.style.display="none",i&&(n.src="/ats/images/plus.gif"))},assureChildrenMatch:function(t,e){var i=parents[e];if(i)for(var n=isChecked(t,e),s=i.length,o=0;o<s;o++){var r=i[o];checkCheckBox(t,r,n,!1),lib.assureChildrenMatch(t,r)}return!0},assureParentSelected:function(t,e){var i=kids[e];return i&&checkCheckBox(t,i,!0,!0),!0},setCheckboxElements:function(t){checkboxElements=[];for(var e=0;e<t.document.forms[0].elements.length;e++){var i=t.document.forms[0].elements[e];if(i&&"checkbox"==i.type){var n=i.value;checkboxElements[n]=i}}},rmimg:function(t,e){t.document.getElementById(e)||(t.document.getElementById("".concat(e,"_img")).style.display="none")},setParent:function(t,e,i){kids[e]=i;var n=parents[i];n||(n=[]),n=n.concat(e),parents[i]=n},initPageCollapse:function(t){for(var e in hiddenDivs)lib.pageCollapse(t,e)},pageCollapse:function(t,e){var i=t.getElementById("".concat(e,"-collapse-button")),n=t.getElementById(e);n&&i&&("none"==n.style.display?(n.style.display="",delete hiddenDivs[e],i.src="/ats/images/minus.gif"):(n.style.display="none",hiddenDivs[e]||(hiddenDivs[e]=!0),i.src="/ats/images/plus.gif"))},pageCollapseAtsSearchMultiPage:function(t,e){var i=t.$,n="#".concat(e,"-nonWrapper");i(".subPageContent").not(n).addClass("subPageContentHidden"),i(n).toggleClass("subPageContentHidden"),setTimeout((function(){i("html, body").animate({scrollTop:i("#".concat(e,"-wrapper")).offset().top},350)}),351)},checkSessionId:function(t){if(null==sessionId||null==t||""==sessionId||""==t||"null"==sessionId||"null"==t)return!0;if(t==sessionId)return!0;var e=_this.getCookie("SSS_SESSION_ID");return t==e&&(sessionId=e,!0)},helpLink:function(t,e){return t.alert(e),!1},importStatusPopup:function(t,e){var i;switch(e){case"success_annual":i="<b>Annual/Yearly import of all the Florida Certifications and Courses is successful!!</b>";break;case"success_quarterly":i="<b>Quarterly import of the Florida Certifications and Courses is successful!!</b>";break;case"sftp_yearly":i="<b>Exception occurred during import : </b> <br> <b>YearlyImports</b> folder is missing in the SFTP location!";break;case"sftp_quarterly":i="<b>Exception occurred during import : </b> <br> <b>QuarterlyImports</b> folder is missing in the SFTP location!";break;case"ccd_missing":i="<b>Exception occurred during import : </b> <br> <b>CCD</b> folder is missing in the SFTP location!";break;case"not_xlsx_format":i="<b>Exception occurred during import : </b> <br> File(s) should be of .xlsx formats only, other formats are not allowed.";break;case"failure_missing_del":i="<b>Exception occurred during import : </b> <br> <b>Delete</b> column is missing or not in the right column on one of the sheets.<br> When performing Quarterly Imports, Delete columns must be present on all sheets, here's the places to check : <br> 1. <b>Delete</b> column should be in the 11th column for the All Certifications sheet<br> 2. <b>Delete</b> column should be in the 3rd column for all of the Special Certifications sheet<br> 3. <b>Delete</b> column should be in the 11th column for the Dual Certifications sheet<br> 4. <b>Delete</b> column should be in the 7th column for the All Courses sheet";break;case"yearly_missing_file":case"quarterly_missing_file":i="<b>Exception occurred during import :</b> <br> Files are missing or names mismatch in the SFTP location for "+e.split("_")[0]+" import :<br> NOTE : .xlsx files should be available with names in below formats : <b>Certifications_(school_year) or Certifications_(school_year)_(quarter)</b> and <br> <b>Courses_(school_year) or Courses_(school_year)_(quarter)</b>";break;case"errors":i="<b>Exception occurred during import.</b> <br> It might be because of following reasons :<br> 1. invalid certification or course data<br> 2. missing or incomplete data<br> Note : Please refer to logs in SFTP site and check latest log file for more details.";break;default:i="Unknown exception occurred during import of CCD Certifications and Courses!!"}if(i.length>0)return i},removeFileUpload:function(t,e){var i=t.$,n="#".concat(e),s="".concat(n,"_remove"),o="".concat(n,"_view"),r="".concat(n,"_hidden_remove");i(s).click((function(){var t=i(this),e=i(n);t.css("display","none"),i(o).css("display","none"),i(r).val(e.val()),e.val(null),t.closest("td").find('input[type="button"]').val("Upload a File")}))},checkEmail:function(t,e){var i=!0,n=e.value;return n.length>0&&(i=emailCheck(n,t,e)),i},selectLocation:function(t){var e=t.$,i=e("select[name='COMPANY_ID']"),n=function(){return document.cookie="COMPANY_ID=".concat(i.val(),"; path=/")};n(),i.change((function(){e("select[name='action']").val("default"),n(),e("#inlineContent").html(" ")}))},checkConfirmEmail:function(t,e){var i,n=(0,t.$)("#EMAIL").val().trim().toLowerCase();return n!=(i=e.value.trim().toLowerCase())?(invalidField(t,e,"Confirm Email should match Email."),!1):n==i||void 0},checkRequiredRadio:function(t,e){var i=!1,n=t.$;if("none"==n("#".concat(n(e).attr("name"),"_ROW")).css("display"))return!0;if(e.length)for(var s=0;s<e.length;s++)e[s].checked&&(i=!0);else e.checked&&(i=!0);return!!i||(invalidField(t,e,"You have not filled out all required answers on this page."),!1)},initForms:function(t){function e(t){t.initialized||(t.validatorFunctions=new Array(0),t.validatorFields=new Array(0),t.maskValidatorFields=new Array(0),t.maskValidatorFunctions=new Array(0),t.maskValidatorMasks=new Array(0),t.initialized=!0)}var i=t.document.forms;if(i)for(var n=0;n<i.length;n+=1){e(i[n])}else $("form").whenExists((function(){e(this)}))},checkRequired:function(t,e){var i=t.$,n=i(e),s=n.attr("name"),o=i("#".concat(s,"_ROW"));if((o.length>0?o:n.parents("tr").eq(0)).is(":visible")&&""==getFieldValue(t,e)){var r=s||n.attr("id");logger.log("## checkRequired - INVALID (".concat(r,")")),logger.log(e);var a=i('input[name="customValidationMessage"]');return invalidField(t,e,a.length>0&&""!=a.val()?a.val():"You have not filled out all required fields on this page."),!1}return!0},validForm:function(t,e,i){return!!lib.checkAccess()&&(t.runningValidFields=!0,"applicant.view"!=i&&"dbuser.pwd_no_libraryjsp"!=i&&(i.match("dbuser")||i.match("applicant")&&!i.match("applicant_type"))&&!checkFormatting(t,e.elements.NAME,e.elements.PWD)?(t.runningValidFields=!1,!1):(t.runningValidFields=!1,validFields(t,e)))},compressFormQuery:function(t,e,i){if(!lib.checkAccess())return!1;var n=t.$,s=n(e).find(":input").filter((function(){return""!=n(this).val()})).serialize(),o="".concat(n(e).attr("action"),"?").concat(s);return["/ats/application/applicants","/ats/employer/admin/employee_search_results","/ats/employer/admin/employee"].includes(n(e).attr("action"))?n.post("/servlet/support/login/encryptQueryString",{queryString:s,actionUrl:n(e).attr("action")},(function(e){t.location.href=e.encryptedString}),"json"):t.location.href=o,!1},encryptQueryString:function(t,e,i,n){i.preventDefault();var s=t.$,o=s(e).find(":input").serialize();return s.post("/servlet/support/login/encryptQueryString",{queryString:o,actionUrl:n},(function(e){t.location.href=e.encryptedString}),"json"),!1},appendMulti:function(t,e,i){lib.initForms(t);var n=getFormObjects(t,e),s=0;for(s=0;s<n.length;s+=1){var o=n[s],r=new Array(i),a=o.elements[e];o.validatorFunctions=o.validatorFunctions.concat(r),o.validatorFields=o.validatorFields.concat(a)}},multiCheck:function(t,e){var i=getMultiNumberChecked(t,e),n=t.$,s="".concat(n(e).attr("name"),"_ROW");return!(n("[id='".concat(s,"']")).last().is(":visible")&&i<1)||(invalidField(t,e,"You have not filled out all required answers on this page."),!1)},reqAllMultiCheck:function(t,e){var i=getMultiNumberChecked(t,e),n=Array.from(e).filter((function(t){return"checkbox"===t.type})).length,s=t.$,o="".concat(s(e).attr("name"),"_ROW");return!(s("[id='".concat(o,"']")).last().is(":visible")&&i<n)||(invalidField(t,e,"You have not filled out all required answers on this page."),!1)},appendMask:function(t,e,i){lib.initForms(t);var n,s=e;-1!=e.indexOf(":::")&&(s=e.substring(0,e.indexOf(":::")),-1!=(e=e.substring(e.indexOf(":::")+3)).indexOf(":::")&&(n=e.substring(0,e.indexOf(":::"))));var o=getFormObjects(t,s),r=0;for(r=0;r<o.length;r+=1){var a=o[r],l=a.elements[s],c=new Array(i),u=new Array(l),h=new Array(n);a.maskValidatorFunctions=a.maskValidatorFunctions.concat(c),a.maskValidatorFields=a.maskValidatorFields.concat(u),a.maskValidatorMasks=a.maskValidatorMasks.concat(h)}},append:function(t,e,i){lib.initForms(t);var n=getFormObjects(t,e),s=0;for(s=0;s<n.length;s+=1){var o=n[s],r=o.elements[e],a=new Array(i),l=new Array(r);o.validatorFunctions=o.validatorFunctions.concat(a),o.validatorFields=o.validatorFields.concat(l)}},checkSize:function(t,e){e>0&&t.value.length>e&&(t.value=t.value.substring(0,e),alert("You have reached the maximum size for this field"))},checkSearchNumber:function(t,e){stripSymbols(e);var i=e.value;if(void 0===i)return!0;if(i.indexOf(">")>0||i.indexOf("<")>0)return invalidField(t,e,"An invalid number was entered in this field. If you are using > or <, please make sure it is the first symbol in the field."),!1;var n=i;return 0!=n.indexOf(">")&&0!=n.indexOf("<")||(n=i.substr(1)),!!isValidNumber(n)||(invalidField(t,e,"An invalid number was entered in this field."),!1)},checkNumber:function(t,e){return stripSymbols(e),!!isValidNumber(e.value)||(invalidField(t,e,"An invalid number was entered in this field. This field cannot contain any symbols ($, %, #, etc)."),!1)},checkZeroInterval:function(t,e){return stripSymbols(e),0!==e.value||(invalidField(t,e,"Interval cannot be zero"),!1)},confirmDelete:function(t,e){if(confirm("Are you sure you want to delete this record?")){if(e.indexOf("redirect=")<0)e="".concat(e,"&redirect=").concat(escape(t.location.href));else{var i=e.indexOf("&redirect="),n=e.indexOf("%");if(i>=0&&n<0){var s="&redirect=".length;e=e.substring(0,i+s)+escape(e.substring(i+s))}}t.location.href=e}},handleImpersonation:function(t,e,i){var n=e.split("?")[1].substr("USER_ID=".length);return $.get("/servlet/support/login/impersonation",{companyId:companyId,userId:n,impersonationMode:i},(function(e){e.success?"EMPLOYER"==e.accountType&&top.document.location.replace("/ats/employer/v51_employer_frame"):t.alert(e.errorMessage)}),"json"),!1},checkTime:function(t,e){var i=!0,n=e.value;if(0==n.length)return!0;if(5!=n.length)i=!1;else if(":"!=n.substring(2,3))i=!1;else{var s=n.substring(0,2),o=n.substring(3,5);if(s.charAt(0)>2||s.charAt(1)>9||o.charAt(0)>5||o.charAt(1)>9||2==s.charAt(0)&&s.charAt(1)>3)i=!1;else{var r=parseInt(s),a=parseInt(o),l=parseInt(s.substring(0,1)),c=parseInt(s.substring(1,2)),u=parseInt(o.substring(0,1)),h=parseInt(o.substring(1,2));(r>23||r<0||a>59||a<0||isNaN(r)||isNaN(a)||isNaN(l)||isNaN(c)||isNaN(u)||isNaN(h))&&(i=!1)}}return i||invalidField(t,e,"An invalid time was entered. Use Military Time Format: 00:00 to 23:59"),i},checkDate:function(t,e){var i=getFormattedDate(e);return isValidDate(i,!1)?(e.value=i,!0):(invalidField(t,e,"An invalid date was entered. Use Month Date Year Format MM/DD/YYYY."),!1)},checkBirthDate:function(t,e){return!!isValidBirthDate(e,!1,10,110)||(invalidField(t,e,"An invalid birth date was entered."),!1)},checkShortDate:function(t,e){var i=getFormattedDate(e);return isValidDate(i,!0)?(e.value=i,!0):(invalidField(t,e,"An invalid date was entered. Use Month Date Year Format MM/YYYY."),!1)},storeShortDateToFullDate:function(t,e){var i=e.val(),n=$(e).attr("id"),s=$("#".concat(n,"_ROW"));if(!isValidDate(i,!0)||""==i&&"none"!=s.css("display"))return e.next().val(""),!1;var o=function(t){var e=t.lastIndexOf("/"),i=t.substring(0,e),n=t.substring(e);return"".concat(i,"/01").concat(n)}(i);return e.next().val(o),!0},checkDateTime:function(t,e){if(isValidDateTime(e))return!0;invalidField(t,e,"An invalid date was entered. Use Format MM/DD/YYYY HH:MM am/pm.")},toggleSelectAllCheckboxes:function(t,e){!!$(t).attr("checked")?lib.selectAllCheckboxes(e,!1):lib.deselectAllCheckboxes(e,!1)},selectAllCheckboxes:function(t,e){e&&lib.setAccess(t,!1);var i=0;for(i=0;i<t.document.forms[0].elements.length;i++)"checkbox"==t.document.forms[0].elements[i].type&&(t.document.forms[0].elements[i].checked=!0)},documentSubmit:function(t,e,i,n){return setTimeout((function(){var s=t.$;lib.setAccessNextPage(!0);var o=!!s("input[name='save_as_draft']").length,r="Y"===s("input[name='IGNORE_REQUIRED_FIELDS']").val(),a=r;if(o||r||(a=lib.validForm.call(e[0],t,e[0],i)),o||a){var l=!1;createModal(t,{content:"#".concat(n),attributes:{useCloseX:!0},onOpen:function(t){var i=t.getContent(!0);s(i).css("height","auto"),s(i).css("width","auto"),t.enableOk({enable:!1}),t.setContent("<h3>Submitting...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p>");var n="".concat(e.serialize(),"&ajax=Y");o&&(n+="&save_as_draft=Save+as+Draft"),s.post(e.attr("action"),n,(function(e){l=!0,t.setContent(e),o&&setTimeout((function(){return t.close()}),500)}))},onClose:function(t){l&&t.enableOk({enable:!0})}})}}),500),!1},importCcdSubmit:function(t,e,i,n){return setTimeout((function(){var e=t.$,s=e("#"+n).find("form");lib.setAccessNextPage(!0);lib.disableMouseActions(t);createModal(t,{content:"#".concat(n),onOpen:function(n){n.enableOk({enable:!1}),n.setContent("<div class ='importpopup' style=''><h3>Importing Data...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p></div>");var o=e(n.getContent(!0));o.closest(".vex").find(".vex-content").css({width:"700px",height:"200px"}),o.closest(".vex-content").find(".vex-dialog-input").css({overflow:"unset",width:"unset",height:"unset"});var r="".concat(s.serialize(),"&ajax=Y");e.post(i,r,(function(i){!0;var s=lib.importStatusPopup(t,i.trim());n.setContent("<p>"+s+"</p>");var o=e(n.getContent(!0));o.closest(".vex").find(".vex-content").css({"max-height":"300px",width:"700px"}),o.closest(".vex-content").find(".vex-dialog-input").css({width:"unset"}),lib.enableMouseActions(t)}))}})}),500),!1},disableMouseActions:function(t){var e=t.parent.frames[0],i=e?e.$("#WA00000124"):$("#WA00000124");$("*").css({cursor:"wait","pointer-events":"none"}),i.find("div, li").css({cursor:"wait"}),i.find("a, div .ui-control-help, span").css({"pointer-events":"none"})},enableMouseActions:function(t){var e=t.parent.frames[0],i=e?e.$("#WA00000124"):$("#WA00000124");$("*").css({cursor:"","pointer-events":"all"}),i.find("div, li").css({cursor:""}),i.find("a, div .ui-control-help, span").css({"pointer-events":"all"})},unfollow:function(t,e){var i=t.$,n=i(e);return i.post(n.attr("href"),(function(t){if("Success!"==t){var e=n.closest("tr").nextAll("tr.even");n.closest("tr").nextAll("tr.odd").removeClass("odd").addClass("even"),e.removeClass("even").addClass("odd"),n.closest("tr").remove()}})),!1},deselectAllCheckboxes:function(t,e){e&&lib.setAccess(t,!1);var i=0;for(i=0;i<t.document.forms[0].elements.length;i++)"checkbox"==t.document.forms[0].elements[i].type&&(t.document.forms[0].elements[i].checked=!1)},daysSince:function(t,e){var i,n=e.value,s=new Date((new Date).getTime()),o=new Date(s-24*n*60*60*1e3),r="".concat(o.getMonth()+1,"/").concat(o.getDate(),"/").concat(o.getFullYear()),a=e.name.lastIndexOf("_DAYSSINCE");if(a>0&&(i=e.name.substring(0,a)),n>0&&null!=n)for(var l=0;l<t.document.forms[0].elements.length;l++)t.document.forms[0].elements[l].name==i&&(t.document.forms[0].elements[l].value=r);else for(var c=0;c<t.document.forms[0].elements.length;c++)t.document.forms[0].elements[c].name==i&&(t.document.forms[0].elements[c].value="")},setAvgField:function(t,e){return t.avgField=e},setTotalField:function(t,e){t.totalField=e,t.document.forms[0].elements[e].enabled=!1},appendScore:function(t,e){t.scores=t.scores.concat(e)},calculateScore:function(t){for(var e=0,i=0,n=0;n<t.scores.length;n++){var s=t.document.forms[0].elements[t.scores[n]],o=parseInt(getFieldValue(t,s));!o>0&&(o=0,i++),e+=o}var r=e/(t.scores.length-i);return r=parseInt(r+.5),t.totalField&&e==parseInt(e)&&(t.document.forms[0].elements[t.totalField][0].value=e,t.document.forms[0].elements[t.totalField][1].value=e),t.avgField&&r==parseFloat(r)&&(t.document.forms[0].elements[t.avgField][0].value=r,t.document.forms[0].elements[t.avgField][1].value=r),!0},clearListeners:function(){return lib.pageListeners=[]},updatePage:function(t,e){var i=e.options[e.selectedIndex].value,n=null,s=null;if(i.indexOf(",")>=0&&(n=i.substring(0,i.indexOf(",")),(s=i.substring(i.indexOf(",")+1)).indexOf(",")>=0)){var o=s.substring(0,s.indexOf(",")),r=s.substring(s.indexOf(",")+1),a=o;if(null!=r){var l="?";a.indexOf("?")>=0&&(l="&"),a=a+l+r}}if(lib.checkAccess())lib.loadingPage(!0),s.indexOf(",")>=0&&(t.parent.frames[n].location.href=a,t.parent.frames[n].focus());else{t.alert('You must first click the "Save and Next" or "Undo" buttons before exiting this page.');for(var c=e.options.length,u=t.parent.frames[n].location.pathname,h=0;h<c;h++){if(e.options[h].value.indexOf(u)>=0){e.selectedIndex=h;break}}}},loadingPage:function(t){return setGlobalData("Lib.loading",t),1==t&&lib.setAccessNextPage(!0),!0},isLoadingPage:function(){return getGlobalData("Lib.loading")},pageUpdated:function(t){for(var e=0;e<_this.pageListeners.length;e++){var i=_this.pageListeners[e],n=void 0;try{(n=i.pageUpdated)&&n(t)}catch(s){}}},setAccessNextPage:function(t){var e=lib.checkAccess();return _log("accessNextPage: ".concat(e)),setGlobalData("Lib.accessNextPage",t),!0},authenticateUser:function(t){var e=t.$;e.ajax({contentType:"application/json; charset=utf-8",data:JSON.stringify({value:!0}),method:"POST",url:"/api/eformsdocumentapprove/eformsSignedDocument",success:function(t){var i=JSON.parse(t),n=i.success;if(n){var s,o,r;i.hasOwnProperty("firstName")&&(s=i.firstName),i.hasOwnProperty("lastName")&&(o=i.lastName),i.hasOwnProperty("email")&&(r=i.email),e("#form-data").append("<div></div>").append('<img src="/ats/css-base/images/click-ok.png"/>').append(" ").append(s).append(" ").append(o).append(" ").append("("+r+")").append("<div></div>").css("display","block"),e(".eformsubmit").css("display","block")}e("#authenticatedoc").attr("disabled","disabled")},error:function(t){this.setState({_messageToUser:"Authentication fails"})}})},setAccess:function(t,e){return _this.setAccessNextPage(e),t&&t.document&&t.document.forms&&t.document.forms[0]&&t.document.forms[0].elements&&t.document.forms[0].elements.is_changed&&!t.document.forms[0].elements.force_is_changed&&(t.document.forms[0].elements.is_changed.value=!e),!0},checkAccess:function(){return getGlobalData("Lib.accessNextPage")},checkLinkAccess:function(){return!!_this.checkAccess()||(alert('You must first click the "Save and Next" or "Undo" buttons before exiting this page.'),!1)},addDependentField:function(t,e,i,n){var s=t.$;s(t.document).ready((function(){for(var o,r,a=[],l=e.split("|"),c=n?n.split("|"):[],u=0;u<c.length;u++)c[u]=c?c[u].split("&"):[];for(var h=0;h<l.length;h++){for(var d=[],p=l[h].split("&"),f=0;f<p.length;f++){var m=p[f],g="_NOT"===m.substr(-4);g&&(m=m.substr(0,m.length-4));var v=void 0;(v=dependentFieldCtx?s(dependentFieldCtx).find("[name='".concat(m,"']")).not(":disabled"):s("[name='".concat(m,"']")).not(":disabled")).data("negative",g),d[f]={fields:v,values:c[h]&&c[h][f]?c[h][f]:""}}a[h]=d}if(s.each(a,(function(t,e){return s.each(e,(function(t,e){return o=o?o.add(e.fields):e.fields}))})),r=dependentFieldCtx?s(dependentFieldCtx).find("#".concat(i,"_ROW")):s("#".concat(i,"_ROW")),o&&o.length){var _=function(e){for(var i=!1,n=0;n<a.length&&!i;n++){for(var o=a[n],l=!0,c=function(t){for(var e=o[t],i=e.values.split(","),n=""===e.values,r=!1,a=0;a<e.fields.length&&!r;a++){var c=e.fields.eq(a),u=c.val(),h=c.data("negative");c.is(":radio,:checkbox")&&!c.is(":checked")&&(u=null);var d=!1;null!==u&&(u=s.makeArray(u),s.each(u,(function(t,e){""!=e&&s.inArray(e,i)>=0&&(d=!0)}))),r=d||u&&""!=u&&n,h&&(r=!r)}l=r},u=0;u<o.length&&l;u++)c(u);i=l}i?e?(r.show(),triggerResize(t,!0,!1)):"none"==r.css("display")&&(r.css("display",""),r.css("opacity","0"),r.animate({opacity:"1"},500,"swing",(function(){return triggerResize(t,!0,!1)}))):e?(r.hide(),triggerResize(t,!0,!1)):r.fadeOut({complete:function(){return triggerResize(t,!0,!1)}})};s(":reset").click((function(){s(this).get(0).form.reset(),_(!0)})),o.each((function(e,i){var n=s(i);n.hasClass("select-plus")&&!n.hasClass("select-plus-initialized")?SelectPlus.registerChangeListener(n,_):jqueryUniversalChange(t,i,(function(){return _()}))})),_(!0)}}))},setLocation:function(t,e){_this.checkAccess()?t.document.location.href=e:t.alert('You must first click the "Save and Next" or "Undo" buttons before exiting this page.')},setLocationToDashboard:function(t,e){t.document.location.href=e},historyGo:function(t,e){if(_this.checkAccess())t.$("body").trigger("ss-event-page-cancel"),t.history.go(-1);else{var i=(e=t.event||e).target||e.srcElement,n=$(i).parents("ul").find("input[type=submit]");t.alert('You must first click the "'.concat(n.val(),'" or "Undo" buttons before exiting this page.'))}},maskFormat:function(t,e,i){var n=e.value;return""==n||!!new RegExp(i).exec(n)},autoFormat:function(t,e,i){var n=t.value;if(""!=n){var s=new RegExp(e);s.exec(n)?t.value=n.replace(s,i):alert("".concat(n," is not in the correct format."))}},AppLoginStepFillIn:function(t){var e=t.$,i=e(".pagebuttons ul :has([value='Create New Account'])");i.css("display","block"),e("div.create_account")&&(e("div.create_account").html(i.html()),i.css("display","none")),e("#step2_links")?(e("#preview").hide(),e("#step2_links").html(e("#preview").html())):e("#preview").show()},addStyleClasses:function(t,e){var i=t.$;if(i){_log("addStyleClasses for ".concat(e=e||"body"));var n=i(e);n.find(":text").addClass("textfield"),n.find(":password").addClass("passwordfield"),n.find(":text, :password").focus((function(){i(this).addClass("textfieldfocus")})),n.find(":text, :password").blur((function(){i(this).removeClass("textfieldfocus")})),n.find("td:empty").html(" "),function(){var t=n.find('select[name="ACTION_TYPE"]');t.change((function(){var e=n.find(".rs :checkbox");"all"===t.val()?e.prop("disabled","disabled").hide():e.prop("disabled","").show()}))}(),n.find(":reset").click((function(t){i(".file_upload_field[type='hidden']").each((function(t){var e=i(this).attr("original");i(this).val(e);var n=i("#".concat(i(this).attr("name"),"_link"));n.attr("href",e),""==e&&n.fadeOut()}))}));var s={".embedded_field":function(t){t.closest("label").find(":radio, :checkbox").click((function(){return i(t).children(":text").focus()})),t.closest("label").find(":text").click((function(){i(this).closest("label").find(":radio, :checkbox").attr("checked","checked")}))},"a.wizardpopup":function(t){r(t,!0)},"a.wizardpopupNoReload":r,"a.modalpopuplink":function(e){return e.click((function(n){n.preventDefault();var s="modalpopuplink";return i("#".concat(s)).length||i("body").append("<div id='".concat(s,"' style='display:none;'><h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p></div>")),_this.addToolboxFunction(t,s,(function(){return ajaxFillinPopup(t,s,e.attr("href"))})),_this.showPopup(t,s),!1}))},"input.suggestsearch":function(e){var n="".concat(e.attr("id")||e.attr("name"),"_sug"),s=e.attr("href");s.indexOf("?")<0?s+="?":s+="&";s+="jscallback=?";var o=-1;function r(t){for(var s in c(),i("#".concat(n,"_con")).length||e.after("<div id='".concat(n,"_con'><div id='").concat(n,"' class='search_suggest'></div></div>")),t){var o=n+t[s];i("#".concat(n)).append("<div id='".concat(o,"' class='suggest_link'>").concat(s,"</div>"));var r=i("#".concat(o));r.hover(a,l),r.click((function(){e.val(i(this).html()),c()}))}}function a(){i(this).addClass("suggest_link_over"),e.unbind("blur")}function l(){i(this).removeClass("suggest_link_over"),e.blur(c)}function c(){i("#".concat(n,"_con")).remove()}e.keyup((function(n){-1!=o&&t.clearTimeout(o),o=t.setTimeout((function(){var t=e.val();if(""!=t){t={suggest:t,ajax:"y"};var n=i.param(t);i.getJSON(s,n,r)}}),500)})),e.blur(c)},"input.file_upload_field[type='button']":function(e){i(e).click((function(e){_log("Doing input.file_upload_field[type='button'].click()...");var n=this;i(n).parents().last().find("[id=upload_field]:hidden").remove(),closePopupFirst(t,(function(){_log("Doing fileUploadPopup - popups have been closed."),function(t,e){var i=e.$,n=getModal(e);if(n&&n.isOpen())return void alert("ERROR: cannot have a fileupload field within another pop-up");var s=i(t).attr("hiddenname"),o="FIELD_NAME=".concat(s,"&COMPANY_ID=").concat(companyId);if(!i("#".concat("upload_field")).length){var r='<div id="'.concat("upload_field",'" style="display: none"><h3>Loading...</h3> <p><img src=\'https://cdn.atenterprise.powerschool.com/images/loading.gif\' />Please Wait </p></div>');i("body").append(r)}var a="";i(t).is(".noextcheck")&&(a="?noextcheck=Y");_this.addToolboxFunction(e,"upload_field",(function(){ajaxFillinPopup(e,"upload_field","/ats/upload_field.jsp".concat(a),o)})),_this.addToolboxFunction(e,"".concat("upload_field","_close"),(function(){if(e.fileuploads&&e.fileuploads[s]){var t=e.fileuploads[s];t.id&&t.url&&(i("#".concat(s)).val(t.id),i(".".concat(s,"_link")).attr("href",t.url).fadeIn(),i(".".concat(s,"_remove")).attr("href","#").fadeIn(),i("#".concat(s,"_button")).attr("value","Replace File"),_this.setAccess(e,!1))}})),_this.showPopup(e,"upload_field")}(n,t)}))}))},".nctq_hoverable":function(e){e.mouseenter((function(e){o(t,i(this).next("div"),e,20,20),i(this).next("div").removeClass("nctq_scores_hidden"),i(this).next("div").addClass("nctq_scores_visible")})),e.mouseleave((function(t){i(this).next("div").removeClass("nctq_scores_visible"),i(this).next("div").addClass("nctq_scores_hidden")})),e.mousemove((function(e){o(t,i(this).next("div"),e,20,20)})),e.click((function(t){return t.preventDefault()}))}};!function(){var t="",e=!0;for(var o in s)e||(t+=","),t+=o,e=!1;n.find(t).each((function(){var t=i(this);for(var e in s)t.is(e)&&s[e].call(this,t)}))}()}else _log(new Error("Can not call addStyleClasses; jQuery is not available."));function o(t,e,i,n,s){var o=t.$,r=e.width(),a=e.height();e.css({top:Math.min(i.pageY+n,o(t).height()-a+o(t).scrollTop()),left:i.pageX-r-s})}function r(e,n){e.click((function(s){s.preventDefault();var o=e.attr("name")?e.attr("name"):"awizardpopup";return i("#".concat(o)).length||i("body").append("<div id='".concat(o,"' style='display:none;'><h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p></div>")),closePopupFirst(t,(function(){_this.addToolboxFunction(t,o,(function(){ajaxFillinPopup(t,o,e.attr("href"),null,!0,!0)})),n&&_this.addToolboxFunction(t,"".concat(o,"_close"),(function(){i("body").html("<h3 class='pageTitleCaption'>Please Wait... Loading</h3>");var e=t.location.href,n=top.frames[0]&&"sss_script"===top.frames[0].name;if(-1==e.indexOf("refresh")){var s=e;s.indexOf("?")>-1?s+="&refresh=Y":s+="?refresh=Y",n?t.location.replace(s):t.$("body").trigger("ss-event-page-reload")}else n?t.location.reload():t.$("body").trigger("ss-event-page-reload")})),_this.showPopup(t,o)})),!1}))}},fileUploadComplete:function(t,e,i){var n=t.$;n(".inlineHelp").remove(),n(".searchsoft-modal #file_upload_content").html(i),n(".searchsoft-modal #file_upload_waiting").stop().hide(),n(".searchsoft-modal #file_upload_content").fadeIn(),afterAjaxPopProcess(t,e,n(".file-upload-complete-wrapper-".concat(e)),null,!0,!0),triggerResize(t)},fileUploadStart:function(t){var e=t.$;return e(".inlineHelp").remove(),e(".searchsoft-modal #file_upload_waiting").fadeIn(),e(".searchsoft-modal #file_upload_content").hide(),!0},onReady:function(t,e){if(t.$=checkJQuery(t,t.$),t.$){var i=function i(){if(_log("win.document.readyState: ".concat(t.document.readyState)),"complete"!=t.document.readyState){var n=$.browser&&$.browser.mozilla?1e3:350;return _log("Deferring call to onReady for ".concat(n," ms...")),void t.setTimeout(i,n)}if(_log("Calling onReady() for:".concat(displayFn(e))),t.spinnerOn)t.onReadyFunctions=t.onReadyFunctions||[],t.onReadyFunctions.push(e),_log("Adding function to win.onReadyFunctions (length=".concat(t.onReadyFunctions.length,"), NOT calling function."));else try{_log("Executing onReady() function..."),e.call(_this,t)}catch(s){_log("Error occurred executing onReady function..."),_log(s)}};t.$(t.document).ready(i)}else _log(new Error("Can not call onReady; jQuery is not available."))},perform_cookie_test:function(){return makeTestCookie(),cookie_test=findTestCookie()},ready_modal_popup:function(t,e,i){(0,t.$)(t.document).ready((function(){e?toolboxRegisterSelection(t,i):toolboxRegisterActionGo(t,i),t.toolboxFunctions||(t.toolboxFunctions=new Array(0))}))},addToolboxFunction:function(t,e,i){t.toolboxFunctions||(t.toolboxFunctions=new Array(0)),t.toolboxFunctions[e]=i},ajaxPopupOp:function(t,e,i,n,s){var o=t.$,r=null;null==n&&""!=n||(r="op=".concat(n)),s&&(r="".concat(null==r?"":r+"&").concat(o("form").serialize()));var a=o("[name=table_name]").val();null==a||""==a||null!=r&&-1!=r.indexOf("table_name")||(r="".concat(r?r+"&":"","table_name=").concat(a)),ajaxFillinPopup(t,e,i,r)},ajaxPopup:function(t,e,i){return _this.ajaxPopupOp(t,e,i,null)},showPopup:function(t,e,i){var n=t.$,s=n("#".concat(e)).find("input[name=".concat(e,"]")).val();if(!s&&e.indexOf("_results")>0){var o=e.replace("_results","");s=n("#".concat(e)).find("input[name="+o+"]").val()}var r=n("#".concat(e)).parent(),a=n("#".concat(e)).find(".pagebuttons").hide().end();n(a).css("display","");var l={useCloseX:!0};i=i?n.extend({},l,i):l;var c=!s,u={id:e,attributes:i,content:a,onOpen:function(){n('[id="'.concat(e,'"]')).toArray().slice(0,-1).forEach((function(t){return n(t).remove()})),c&&(toolboxAddCancel(t,e),toolboxRunFunction(t,e))},onClose:function(i){var s=n(i.getContent(!0));s=n(s).children(),n(r).append(s.hide()),toolboxRunFunction(t,"".concat(e,"_close")),n(".inlineHelp").remove(),t.document.thismodal=null}};c?(u.showOk=!1,u.showCancel=!1):u.buttons=[{text:s,type:"ok",callback:function(i){return toolboxRunFunction(t,e)}},{text:"Cancel",type:"cancel"}],createModal(t,u,!0)},addHiddenField:function(t,e,i){(0,t.$)("form").append('<input type="hidden" name="'.concat(e,'" value="').concat(i,'" />'))},addCheckboxApplicants:function(t,e){var i=t.$;doModalOp(t,!1,(function(t,e){var n=i(e).find("form"),s=i("div.rs :checkbox:checked").clone();s.attr("checked","checked"),s.attr("remove","yes"),s.hide(),n.append(s);var o=i("select[name='ACTION_TYPE']");o.length&&n.append('<input type="hidden" name="ACTION_TYPE" value="'.concat(o.val(),'" />')),0==i(n).find(":checkbox:checked").length&&i(n).find(":hidden:checkbox").attr("checked","checked")}))},removeCheckboxApplicants:function(t,e){(0,t.$)("div#".concat(e," :checkbox[remove='yes']")).remove()},addSuperConfirm:function(t){var e=t.$;t.superConfirm=function(i,n){return createModal(t,{content:i,attributes:{useCloseX:!1},buttons:[{text:"Yes",type:"ok",callback:function(i){e.isFunction(n)&&n.apply(),triggerResize(t)}},{text:"Cancel",type:"cancel",callback:function(t){return e(".inlineHelp").remove()}}]})}},replaceAlert:function(t){var e=t.$;t.alert=function(i){if(i=i.replace(/\r\n|\n/g,"<br />"),Modal.anyShowing(t)){var n,s=e("<div class='red inlineHelp' />").html(i);e(".inlineHelp").length?(n=e(".inlineHelp").html(i),t.clearTimeout(t.helpTimeout)):(Modal.getCurrent(t).addContent(s),n=e(".inlineHelp").css("opacity","0").animate({opacity:"1"},500,"linear",(function(){triggerResize(t)}))),t.helpTimeout=t.setTimeout((function(){return n.animate({opacity:"0"},500,"linear",(function(){n.remove(),triggerResize(t)}))}),15e3),triggerResize(t)}else i=e("<p class='help_popup' />").html(i),createModal(t,{content:i,attributes:{useCloseX:!1},buttons:[{text:"Close",type:"ok",callback:function(t){return e(".inlineHelp").remove()}}]})}},addFieldPrompt:function(t){var e=t.$;function i(t,e,i){t.alert(i)}t.fieldPrompt=function n(s,o,r,a){var l=s,c=!(s.name||s.id||s.type)&&s.length;if(c||((s=[])[0]=l),r=!!r,t.runningValidFields&&(r=!0),Modal.anyShowing(t))return a?i(t,0,o):r?t.setTimeout((function(){return n(l,o,r,!0)}),550):i(t,0,o);try{if(e(".gridfield").length>0)for(var u=e(".gridfield"),h=0;h<u.length;h++)if(e.contains(u[h],s[0]))return i(t,0,o)}catch(x){}for(var d=t.fieldDelimiter||"tr",p=null,f=0;f<s.length;f++)p=p?p.add(e(s[f]).closest(d).eq(0)):e(s[f]).closest(d);if(!p.length)return i(t,0,o);var m=0!=e(p).find(".hasDatepicker").length,g=e(p).clone(!m);e(g).find("*").addBack().each((function(){var t=e(this).attr("id");t&&e(this).attr("id","".concat(t,"_COPY"))})),e(g).find(".do-not-copy").remove();var v=[],_=!1;if(g.find("*").each((function(t){for(var i=0;i<s.length;i++){var n=!0,o=s[i],r=e(o).attr("id"),a=e(this).attr("id");"".concat(r,"_COPY")!=a&&(n=!1),e(o).attr("name")!=e(this).attr("name")&&(n=!1),e(o).attr("value")!=e(this).attr("value")&&"select-one"!=e(o).attr("type")&&(n=!1),e(o).attr("type")!=e(this).attr("type")&&(n=!1),n&&(v[i]&&(_=!0),v[i]=e(this).get(0))}})),_)return i(t,0,o);if(s.length!=v.length)return i(t,0,o);s=trimArray(s),v=trimArray(v);var b=!1,y=e("<div class='invalid'>".concat(o,"</div>"));switch(e(y).append(g),d){case"tr":g.wrap('<table class="frmpfields"></table>');break;case"td":g.wrap('<table class="frmpfields"><tr></tr></table>');break;case"li":g.wrap("<ul></ul>");break;default:g.wrap('<div class="fieldprompt"></div>')}createModal(t,{content:y,attributes:{useCloseX:!0},showOk:!0,showCancel:!0,callback:function(i){var n;return v.filter((function(t){return void 0!==t})).forEach((function(t){var i=e("#".concat(t.id))[0];t.checked=i.checked,t.value=i.value})),n=c?v:v[0],!(0==e(p).find(".file_upload_field").length)||!!validNewField(t,l,n)&&void(b=!0)},onOpen:function(){if(m){var i=e(g).find(".hasDatepicker");e(i).removeClass("hasDatepicker"),e(i).datepicker({showOtherMonths:!0,selectOtherMonths:!0,showAnim:"slideDown",changeYear:!0})}triggerResize(t),e("#".concat(v[0].id)).focus()},onClose:function(){if(e(".inlineHelp").remove(),b){var i;i=c?v:v[0],reassignFieldListeners(l,i);for(var n=0;n<s.length;n++){var o=!1;v[n].checked&&(o=!0),e(s[n]).replaceWith(v[n]);var a=e(v[n]).attr("id")||"";(a=a.replace("_COPY",""))&&e(v[n]).attr("id",a),m&&(e(v[n]).removeClass("hasDatepicker"),e(v[n]).datepicker({showOtherMonths:!0,selectOtherMonths:!0,showAnim:"slideDown",changeYear:!0})),o&&e(v[n]).attr("checked","checked")}_this.setAccess(t,!1),r&&e("[name='submit_button']").trigger("click")}}})}},initFormPage:function(t){t.scores=new Array(0),t.avgField=null,t.totalField=null},multiRecordField:function(t,e,i,n){var s=t.$;function o(){var t=s("#".concat(e));t.html('<h3>Loading...</h3> <p><img src="https://cdn.atenterprise.powerschool.com/images/loading.gif" />Please Wait</p>'),s.get(i,"ajax=Y&refresh=Y",(function(e,i){if("success"!==i)throw"AJAX error getting content";t.html(e),r()}),"text")}function r(){if(s("#".concat(e," .resultpageajaxlinks")).length){var i="".concat(e,"_popup");s("#".concat(e,' a:not([class~="resultlink"])')).click((function(e){var n=s(this),r=n.attr("href");return n.hasClass("delete")?t.superConfirm("Are you sure you want to delete this record?",(function(){return s.post(r,null,(function(t,e){if("success"!==e)throw"AJAX error";o()}))})):(_this.addToolboxFunction(t,i,(function(){return ajaxFillinPopup(t,i,r,null,!0)})),_this.addToolboxFunction(t,"".concat(i,"_close"),(function(){return o()})),_this.showPopup(t,i)),e.preventDefault(),!1}))}}this.refreshResultPage=o,n?o():r()},jsExpression:function jsExpression(win,target,expression,defaults){for(var $=win.$,varRegExp=new RegExp("\\b[A-Za-z][A-Za-z0-9_]+\\b","g"),variable;null!=(variable=varRegExp.exec(expression));){var elem=$("[name='".concat(variable,"']"));elem.length&&(elem.unbind(jqueryUniversalChangeSupportedEvents.join(","),runExpression),jqueryUniversalChange(win,elem.get(0),runExpression))}function runExpression(){var expr=buildRawExpression();try{var value=eval(expr),targetField=$("#".concat(target,"_display")),targetHidden=$("#".concat(target));value!=targetHidden.val()&&(targetField.val(value),targetField.trigger("change"),targetHidden.val(value),targetHidden.trigger("change"))}catch(ex){lib.replaceAlert(win);var msg="<span style='font-size: 1em; font-style: normal; font-weight: normal'>It appears that there is an unresolved variable in the JS Expression string provided:</span><br /><br /><span style='font-size: .8em; font-style: italic; font-weight: bold'>".concat(expr,"</span><br /><br /><span style='font-size: 1em; font-style: normal; font-weight: normal'>Check the unresolved field name and ensure that it corresponds with an input on the page.</span>");win.alert(msg),$("#".concat(target,"_display")).val("###")}}function buildRawExpression(){var t=expression;try{for(var e;null!=(e=varRegExp.exec(expression));){var i=null,n=$("[name='".concat(e,"']"));if(0!=n.length&&"###"!=n.val())i=Number(n.val());else{if(null==defaults[e])continue;i=Number(defaults[e])}isFinite(i)||(i=Number(0)),t=t.replace(new RegExp("\\b".concat(e,"\\b"),"g"),i)}t="( ".concat(t," )")}catch(s){_log(s)}return t}runExpression()},reloadNewMcrelYear:function(t,e){var i=t.$;i((function(){var n=i('select[name="'.concat(e,'"]'));n.change((function(){var e=n.val();if(""!==e){var s=i("form").prop("action"),o=URI(s).setQuery("MCREL_YEAR_ID",e).toString();t.location.href=o}}))}))},addReloadOnSelectChange:function(t,e){var i=t.$;_this.onReady(t,(function(){return i("select[name='".concat(e,"']")).change((function(n){var s,o=t.location.href,r=new RegExp("".concat(e,"=[^&]*"));s=r.test(o)?o.replace(r,"".concat(e,"=").concat(i(this).val())):"".concat(o,"&").concat(e,"=").concat(i(this).val());var a=new RegExp("".concat(e,"=([^&]*)"),"g").exec(o);null!=a&&a[1]==i(this).val()||(t.location.href=s)}))}))},activatePreview:function(t,e,i,n,s){var o=t.$;o("#".concat(n)).click((function(){var r=o("[name=".concat(i,"]"));if(!r.length)return t.alert("No input field to preview");var a=r.val();if(""==a||null==a)return t.alert("No input currently selected");var l=s[a];if(""==l||null==l)return t.alert("No preview page for that selection");if(e)t.open(l);else{var c="".concat(n,"_div");_this.addToolboxFunction(t,c,(function(){return ajaxFillinPopup(t,c,l,null)})),_this.showPopup(t,c)}}))},registerStageSelect:function(t,e,i,n,s,o,r){_this.onReady(t,(function(){var a=t.$,l=a("[name='".concat(e,"']")),c="singleValue_".concat(e);if(l.length){var u=a("[name='".concat(n,"']"));if(u.length){var h="text"==u.attr("type"),d=!0;u.bind("change",p),p.apply(u.get(0))}else _log("StagedSelectField parent field is not present: ".concat(n))}else _log("StagedSelectField is not present!");function p(t){var e=a(this),n=e.val();h&&(n+="*"),encodeURIComponent?n=encodeURIComponent(n):escape&&(n=escape(n));var s=e.attr("type"),r="radio"==s||"checkbox"==s,u=e.attr("checked");if(!r||u)if(""!=n&&null!=n){var d="/ats/stage_field_lookup?GUI_FIELD_ID=".concat(i,"&parentvalue=").concat(n,"&ajax=Y&jscallback=?");a.getJSON(d,f)}else!function(){l.html("").show(),a("#".concat(c)).remove(),o||l.append("<option value='' selected='selected'></option>");l.triggerHandler("change")}()}function f(e){if(e){var i=1==e.length&&r,n="";l.html(""),a("#".concat(c)).remove(),i||l.show();var u="",h=!1;if(a.each(e,(function(t,e){var o=e.value;if(""!=o){var r=e.caption,l="";(-1!=a.inArray(o,s)||i)&&(n+=r,l=" selected='selected' ",h=!0),u+="<option value='".concat(o,"'").concat(l,">").concat(r,"</option>")}})),o||i||(u="<option value=''".concat(h?"":" selected='selected' ","></option>").concat(u)),l.append(u),i){l.hide();var p="<div id='".concat(c,"'>").concat(n,"</div>");l.after(p)}l.triggerHandler("change"),d&&(d=!1,l.change((function(){return _this.setAccess(t,!1)})))}else _log("lookups null")}}))},registerStageText:function(t,e,i,n,s,o){_this.onReady(t,(function(){var s=t.$,o=s("[name='".concat(e,"']"));if(o.length){var r=s("[name='".concat(n,"']"));if(r.length){var a=!0;r.bind("change",l),l.apply(r.get(0))}else alert("StageTextField parent field is not present: ".concat(n))}else alert("StageTextField is not present!");function l(t){var e=s(this),n=e.val();encodeURIComponent?n=encodeURIComponent(n):escape&&(n=escape(n));var o=e.attr("type"),r="radio"==o||"checkbox"==o,a=e.attr("checked");if((!r||a)&&""!=n&&null!=n){var l="/ats/stage_field_lookup?GUI_FIELD_ID=".concat(i,"&parentvalue=").concat(n,"&ajax=Y&jscallback=?");s.getJSON(l,c)}}function c(e){if(e)if(1==e.length){var i=e[0].value;if(o.val(i),null!==t&&null!==t.tinymce){var n=t.tinymce.get(o.attr("id"));null!==n&&n.setContent(i)}o.triggerHandler("change"),a&&(a=!1,o.change((function(){return _this.setAccess(t,!1)})))}else alert("lookup must have one value");else alert("lookups null")}}))},registerMoveToSelect:function(t,e){function i(t,e){var i=t.innerHTML,n=e.innerHTML,s=null===i?"":"".concat(i),o=null===n?"":"".concat(n);return s>o?1:s===o?0:-1}function n(t,e){var n=t.find(":selected");n.detach(),e.append(n);var s=e.children();s.detach(),e.append(s.get().sort(i))}var s=t.$,o=s("#".concat(e)),r=s("#".concat(e,"_src"));s("#".concat(e,"_addbtn")).click((function(){_this.setAccess(t,!1),o.children().prop("selected",!1),n(r,o)})),s("#".concat(e,"_rmvbtn")).click((function(){_this.setAccess(t,!1),r.children().prop("selected",!1),n(o,r)})),s("form").on("click","input:submit",(function(){r.children().prop("selected",!1),o.children().prop("selected",!0)}))},browseToNextUrlFromNavigationPulldown:function(t,e){var i=getNextUrlFromNavigationPulldown(t,e);i?t.location.href=i:alert("Already at the end or beginning of the list.")},writeRedirectFromNav:function(t){return t.$("form").append('<input type="hidden" name="redirect" value="'.concat(getNextUrlFromNavigationPulldown(t,!1),'">'))},handlePreviousNavButton:function(t){getNextUrlFromNavigationPulldown(t,!0)||t.$(":button[value=Previous]").remove()},registerQuickSelectGoButton:function(t,e){return _this.onReady(t,(function(){var i=t.$;i("#".concat(e,"_go")).click((function(){var n="[name='".concat(e,"']"),s=i(n).val();""!=s&&(t.location.href=s)}))}))},registerExpandingMultiValue:function(t,e,i,n){var s=t.$;_this.onReady(t,(function(){var o,r,a,l,c,u;function h(){(o=s("#".concat(e,"_ROW"))).find("script").remove(),r=o.html(),a=s("#".concat(e,"_TABLE_CONTAINER tbody")),l=o.find("#".concat(e,"_SIZE")),c=parseFloat(l.val()),u=o.find("#".concat(e,"_TEMPLATE")),n&&f(a.find(".".concat(e,"_subrecord_container"))),n&&p(a.find(".".concat(e,"_subrecord_container"))),i&&function(){var t=a.find(".".concat(e,"_subrecord_container"));g(t),v(t)}();var h="".concat(e,"_addmore");if(!a.parent().find("#".concat(h)).length){var m=s('<a class="addMoreA"></a>').attr({id:h,href:"#"}).html('<img src="/ats/css-base/add.png" class="addMoreImg"/>Add More').click((function(e){return e.preventDefault(),_this.setAccess(t,!1),d(),!1}));a.closest("table").after(m)}parseFloat(l.val())<1&&d()}function d(){var o=parseFloat(l.val());l.val(o+1),c+=1;var r='<tr class="subrecord_container '.concat(e,'_subrecord_container" id="').concat(e,"_").concat(c-1,'">').concat(u.html().replace(/_TEMPLATE/g,"_SUBRECORD_"+(c-1)),"</tr>");a.append(r);var h=s("#".concat(e,"_").concat(c-1));i&&g(h),n&&f(h),n&&p(h),v(h),triggerResize(t)}function p(e){e.each((function(){var e=s(this),i=e.find(".subrecord_min"),n=e.find(jqueryUniversalChangeSupportedTags).get(0);jqueryUniversalChange(t,n,(function(){return function(t,e){var i=s(t),n=parseFloat(e.html()),o=parseFloat(i.val());(isNaN(o)||n>=o)&&i.val(n+1)}(n,i),!0}))}))}function f(t){t.find(".remove_container").append(' greater than <span class="subrecord_min"></span>'),m(t)}function m(i){function n(t,e,i){var n=parseFloat(s(t).val()),o=parseFloat(e.val());i.html(n),!isNaN(o)&&n>=o&&(e.val(n+1),e.trigger("change"))}i.each((function(){var i=s(this),o=i.prev(".".concat(e,"_subrecord_container")),r=i.find(".subrecord_min");if(o.length){var a=i.find(jqueryUniversalChangeSupportedTags).filter(":first"),l=o.find(jqueryUniversalChangeSupportedTags).filter(":first").get(0);jqueryUniversalChange(t,l,(function(){return n(l,a,r),!0})),n(l,a,r)}else r.html("0")}))}function g(t){t.find(".remove_container").prepend('<a class="subrecord_remove"><img title="Remove" alt="remove" src="/ats/css-base/remove.png" /></a>')}function v(e){e.find(".subrecord_remove").click((function(e){_this.setAccess(t,!1),l.val(parseFloat(l.val())-1);var i=s(this).closest(".subrecord_container"),o=i.next(".subrecord_container");i.remove(),n&&m(o)}))}h(),s(":reset").click((function(t){o.html(r),h()}))}))},disableSubmitButtons:function(t){return t.$("input[type='submit']").attr("disabled","disabled"),!0},eformOptionalEventHideFields:function(t,e){function i(t,e){var i=$(t).find("input,select,textarea");$(i).each((function(t,i){e?$(i).prop("disabled",!1):$(i).prop("disabled",!0)})),e?$(t).show():$(t).hide()}_this.onReady(t,(function(){var n=(0,t.$)("#".concat(e)),s=n.closest("tr").nextUntil("tr.endEformEvent");n.change((function(){var t=n.is(":checked");i(s,t)})),n.trigger("change")}))}};function HierCheckboxModel(t,e,i){var n=t.$;this._rootNode={children:[]},this._allNodes=[],this._counter=0;var s=this;function o(e,i,r){var a=r.node,l=r.children;if(i=function(e,i,o,r,a){var l=e.name,c=e.value,u=e.isChecked,h=e.caption,d=e.url;r=void 0===r||"null"==r?null:r,a=void 0===a||"null"==a?null:a;var p,f=n("<li></li>");if(null!=r&&null!=a){p=n("<a></a>").attr("href","#".concat(c)),n(p).click((function(e){try{return lib[a](t,c,i)}catch(n){_log(n)}}));var m=n("<img />").attr("border","0").attr("src",r);n(p).append(m)}else null!=r&&(p=n("<img />").attr("src",r).attr("border","0"));p&&n(f).append(p);var g=n("<input />").attr("type","checkbox").attr("name",l).attr("value",c);u&&n(g).attr("checked","checked");if(n(g).click((function(e){!function(e,i){lib.setAccess(t,!1);var n=s._allNodes[i];if(function t(e){for(var i=e.children,n=0;n<i.length;n++)i[n].field.checked=e.field.checked,t(i[n])}(n),n.field.checked)for(var o=n.parent;null!=o&&null!=o.field;)o.field.checked=n.field.checked,o=o.parent}(0,i)})),n(f).append(g),d){d=0==d.indexOf("http://")?d:"http://"+d;var v=n("<a></a>").attr("target","_blank").attr("href",d).text(h);n(f).append(v)}else n(f).append(t.document.createTextNode(h));var _={html:f,field:g[0],children:[],parent:o};return _.parent.children.push(_),s._allNodes.push(_),_}(a,s._counter++,i),n(e).append(i.html),l.length>0){var c=n("<ul></ul>");n(i.html).append(c),n.each(l,(function(t,e){return o(c,i,e)}))}}this.render=function(){var t=n("script#".concat(e));i=n.parseJSON(i);var r=n("<ul></ul>");o(r,s._rootNode,i),n(r).insertAfter(t)}}function handleError(t,e,i){_log(new Error(t),!0)}function displayError(t,e,i){_log(t)}_this.isDevMode&&(_this.initDevLinks=function(){function t(t){this._useBase;var e=this;this.setToolAltOption=function(n){function s(){e._useBase=!1,i("div.devmenu a").css({background:"#eee"}),i("div.devmenu a.alttool").each((function(){var t=i(this),e=t.attr("href");e=e.replace("&usealt=N",""),t.attr("href",e)}))}function o(){e._useBase=!0,i("div.devmenu a").css({background:"orange"}),i("div.devmenu a.alttool").each((function(){var t=i(this),e=t.attr("href");e=e.replace("&usealt=N",""),e+="&usealt=N",t.attr("href",e)}))}(void 0===e._useBase||void 0!==n)&&(e._useBase=!0===n),i("a.dragalt").unbind("click.devtools").bind("click.devtools",(function(){s(),t.alert("Tools will modify the alt record (default behavior).")})),i("a.dragbase").unbind("click.devtools").bind("click.devtools",(function(){o(),t.alert("Tools will now modify the base records (for all companies)! \nDanger, this will effect all pages until you log-out or set it back to alt!")})),e._useBase?o():s()};var i=checkJQuery(t,t.$),n="devdivid",s=0;function o(){i("a.hidedev").click((function(t){t.preventDefault(),i(".debug,.devmenu").fadeOut()}))}i.extend(i.fn.disableTextSelect=function(){return this.each((function(){}))}),s&&s!=t.yOffset&&_this.onReady(t,(function(){t.scrollTo(0,s),s=0})),this.activateDevLink=function(){var e=i(this),s=e.attr("href");if(s&&!e.hasClass("newwindow")){var o=e.hasClass("wizarddevlink"),r=e.hasClass("search");return _this.addToolboxFunction(t,n,(function(){o?ajaxFillinPopup(t,n,s,null,!0,!0,!0):ajaxFillinPopup(t,n,s,null,!r,!1,!0)})),_this.showPopup(t,n),!1}return!0},_this.onReady(t,(function(){t.devDone||(i("body").children(":last").after("<div id=\"devdivid\" style='display: none;'><h3>Loading...</h3> <p><img src='https://cdn.atenterprise.powerschool.com/images/loading.gif' />Please Wait </p></div>"),_this.addToolboxFunction(t,n+"_close",(function(){t.yOffset="number"==typeof t.pageYOffset?t.pageYOffset:t.document.documentElement?t.document.documentElement.scrollTop:t.document.body.scrollTop,s=t.yOffset,i("body").html("<h1>Reloading...</h1>"),t.location.reload()})),e.setToolAltOption(),i("a.showFieldNames").click((function(){return i("span.fieldName").show()})),function(){var s=null;t.document.body.onmouseup=function(){return s=null},"td"==t.fieldDelimiter?i("div.devfieldmenu").each((function(){var o=i(this).closest("td"),r=i(this).find("a[href*='GUI_FIELD_ID']:first").eq(0).attr("href").match(/GUI_FIELD_ID=\w*\d*/)[0].replace(/GUI_FIELD_ID=/,""),a=o.width(),l=o.height()-5,c="width: 10px; height: "+l+"px;",u="width: "+a+"px; height: 10px;",h='style="position: absolute;'+u+'text-align: center;float: left;clear: both;"',d='style="position: absolute;'+c+'"',p='style="display: block;'+u+'"',f='style="display: block;'+c+'overflow: hidden;"',m='style="border: 0; padding-top: '+(l/2-30)+'px;"',g=".uparrow,.rightcon,.leftarrow,.downcon",v='<div class="uparrow" '+h+"><a "+p+' href=""><img style="border: 0;" src="/ats/css-base/up.png"/></a></div><div class="leftarrow" '+d+"><a "+f+' href=""><img '+m+' src="/ats/css-base/left.png"/></a></div><div class="rightcon" style="left: '+(a-5)+'px; position: relative;"> <div class="rightarrow" '+d+"><a "+f+' href=""><img '+m+' src="/ats/css-base/right.png"/></a></div></div>',_='<div class="downcon"><div class="downarrow" '+h+"><a "+p+' href=""><img style="border: 0;" src="/ats/css-base/down.png"/></a></div></div>',b=i(this);b.disableTextSelect(),b.get(0).onmousedown=function(){return s=r};var y="/ats/admin/drag_move_field.jsp?end_field_id="+r;o.get(0).onmouseover=function(a){o.get(0).onmouseover=null,o.hover((function(a){null!=s&&s!=r&&(o.prepend(v),o.append(_),o.children(g).mouseup((function(){if(null!=s&&s!=r){var o=y+"&start_field_id="+s+"&dir="+i(this).attr("class").replace(/arrow/,"")+"&usealt="+(e._useBase?"N":"Y");_this.addToolboxFunction(t,n,(function(){return ajaxFillinPopup(t,n,o)})),_this.showPopup(t,n)}})))}),(function(){o.find(g).remove()})),o.trigger("mouseover")}})):i("div.devfieldmenu").each((function(){var o=i(this).closest("tr"),r=o.find("th"),a=i(this).find("a[href*='GUI_FIELD_ID']:first");if(a.length){a=a.eq(0).attr("href").match(/GUI_FIELD_ID=\w*\d*/)[0].replace(/GUI_FIELD_ID=/,"");var l="width: "+r.width()+"px; height: 1.5em; left: 0;",c='style="position: absolute;text-align: center;'+l+'"',u='style="'+l+'display: block;"',h='<div class="uparrow" '+c+"><a "+u+' href=""><img style="border: 0;" src="/ats/css-base/up.png"/></a></div>',d='<div class="downcon"><div class="downarrow" '+c+"><a "+u+' href=""><img style="border: 0;" src="/ats/css-base/down.png"/></a></div></div>',p=o.find("div.devmenu");p.disableTextSelect(),p.get(0).onmousedown=function(){return s=a};var f="/ats/admin/drag_move_field.jsp?end_field_id="+a;o.get(0).onmouseover=function(l){o.get(0).onmouseover=null,o.hover((function(){null!=s&&s!=a&&(r.prepend(h),r.append(d),o.find(".uparrow,.downcon").mouseup((function(){if(null!=s&&s!=a){var o=f+"&start_field_id="+s+"&dir="+i(this).attr("class").replace(/arrow/,"")+"&usealt="+(e._useBase?"N":"Y");_this.addToolboxFunction(t,n,(function(){return ajaxFillinPopup(t,n,o)})),_this.showPopup(t,n)}})))}),(function(){return o.find(".uparrow,.downcon").remove()})),o.trigger("mouseover")}}}))}(),i("a.dependtool").unbind().click((function(){var n=i(this).closest("div.devfieldmenu"),s=i(this).closest("div.devmenu").find("a[href*='GUI_FIELD_ID']:first").eq(0).attr("href").match(/GUI_FIELD_ID=\w*\d*/)[0].replace(/GUI_FIELD_ID=/,""),o=t.prompt("For what value?");n.replaceWith("<a onclick='window.location.reload()'>Stop</a>"),i("div.devfieldmenu").replaceWith((function(){var t=i(this).find("a[href*='GUI_FIELD_ID']:first").eq(0).attr("href").match(/GUI_FIELD_ID=\w*\d*/)[0].replace(/GUI_FIELD_ID=/,"");return"<a class='makedependlink' href='/ats/admin/field_make_depend.jsp?PARENT_GUI_FIELD_ID="+s+"&GUI_FIELD_ID="+t+"&value="+encodeURIComponent(o)+"&ajax=Y&usealt="+(e._useBase?"N":"Y")+"' > Make Dependant</a>"})),i("a.makedependlink").unbind().click((function(e){var n=i(this);e.preventDefault();var s=i(this).attr("href");return i.get(s,null,(function(e,i){"success"==i?n.remove():t.alert("failed to make dependant, check your console and get a developer")})),!1}))})),i("a.devmenulink").each((function(){this.onclick=e.activateDevLink})),o(),function(t){i(".showhidden").click((function(e){e.preventDefault(),""==t.location.search?t.location.search="?showhidden=Y":t.location.search.match(/showhidden=Y/)?t.location.search=t.location.search.replace(/[\?\&]showhidden=Y/,""):t.location.search+="&showhidden=Y"}))}(t),function(){var t=i("select[name='ALT_COMPANY_ID']");t.length&&!t.val()&&t.val("<%=companyId%>")}()),t.devDone=!0}))}return function(e){return e._ss_devLinks||(e._ss_devLinks=new t(e)),e._ss_devLinks}}()),window.onerror=!1===init.addGlobalErrorHandler?null:this.isDevMode?displayError:handleError,$.each(lib,(function(t,e){return _this[t]=e})),_this.perform_cookie_test(),onLoadCallback.call(this,this),this.loaded=!0}
|
console-api |
log |
URL: https://lausd.atenterprise.powerschool.com/resources/js/autosave.bundle.js?v=202105210854(Line 2)
Message:
JQMIGRATE: Migrate is installed with logging active, version 1.4.1
|
console-api |
warning |
URL: https://lausd.atenterprise.powerschool.com/resources/js/library.bundle.js?v=202105210854(Line 2)
Message:
JQMIGRATE: jQuery.fn.size() is deprecated; use the .length property
|
console-api |
log |
URL: https://lausd.atenterprise.powerschool.com/resources/js/library.bundle.js?v=202105210854(Line 2)
Message:
console.trace
|
console-api |
warning |
URL: https://lausd.atenterprise.powerschool.com/resources/js/library.bundle.js?v=202105210854(Line 2)
Message:
JQMIGRATE: jQuery.browser is deprecated
|
console-api |
log |
URL: https://lausd.atenterprise.powerschool.com/resources/js/library.bundle.js?v=202105210854(Line 2)
Message:
console.trace
|
console-api |
warning |
URL: https://lausd.atenterprise.powerschool.com/resources/js/library.bundle.js?v=202105210854(Line 2)
Message:
JQMIGRATE: jQuery.support.boxModel is deprecated
|
console-api |
log |
URL: https://lausd.atenterprise.powerschool.com/resources/js/library.bundle.js?v=202105210854(Line 2)
Message:
console.trace
|
console-api |
warning |
URL: https://lausd.atenterprise.powerschool.com/resources/js/library.bundle.js?v=202105210854(Line 2)
Message:
JQMIGRATE: jQuery.boxModel is deprecated
|
console-api |
log |
URL: https://lausd.atenterprise.powerschool.com/resources/js/library.bundle.js?v=202105210854(Line 2)
Message:
console.trace
|
console-api |
warning |
URL: https://lausd.atenterprise.powerschool.com/resources/js/library.bundle.js?v=202105210854(Line 2)
Message:
JQMIGRATE: jQuery.browser is deprecated
|
console-api |
log |
URL: https://lausd.atenterprise.powerschool.com/resources/js/library.bundle.js?v=202105210854(Line 2)
Message:
console.trace
|