PageSourceSearch

https://evalground.com/code4/assets/js/ngscriptfiles/TestInviteController.min.js

js evalground.com collected 2026-09-26 03:58:37 UTC 65,377 bytes, 112 lines download raw bytes

1function TestInviteController(n,a,e,H,q,C,D,I,w,E,g,h,u){function x(){for(var b=0;b<a.candidatesInvited.length;b++)"Locked"!=a.candidatesInvited[b].testStatus&&"Attempted"!=a.candidatesInvited[b].testStatus&&"Knocked Out"!=a.candidatesInvited[b].testStatus&&"Attempting"!=a.candidatesInvited[b].testStatus||r.push(a.candidatesInvited[b])}function y(){return""!=a.allAtsCandidatesFilterTags.name||""!=a.allAtsCandidatesFilterTags.email||"all"!=a.allAtsCandidatesFilterTags.gender||""!=a.allAtsCandidatesFilterTags.certificates||
2""!=a.allAtsCandidatesFilterTags.education||0!=a.allAtsCandidatesFilterTags.location.length||0!=a.allAtsCandidatesFilterTags.skills.length||null!=a.allAtsCandidatesFilterTags.noticePeriod||null!=a.allAtsCandidatesFilterTags.workExperienceFrom||null!=a.allAtsCandidatesFilterTags.workExperienceTo||a.allAtsCandidatesFilterTags.referral||2!=a.allAtsCandidatesFilterTags.isArchived?!0:!1}function z(){return""==a.allEgCandidatesFilterTags.name&&""==a.allEgCandidatesFilterTags.email&&"all"==a.allEgCandidatesFilterTags.gender&&
3""==a.allEgCandidatesFilterTags.certificates&&""==a.allEgCandidatesFilterTags.education&&0==a.allEgCandidatesFilterTags.location.length&&0==a.allEgCandidatesFilterTags.skills.length&&null==a.allEgCandidatesFilterTags.noticePeriod&&null==a.allEgCandidatesFilterTags.workExperienceFrom&&null==a.allEgCandidatesFilterTags.workExperienceTo&&"lastUpdated_desc"==a.allEgCandidatesFilterTags.sortBy?!1:!0}var m=H.testId;a.downloadLink="./generate/excel/invitedCandidates/"+m;e.currentPage="testinvite";e.activeTab=
4"managetests";a.testExpired=!1;a.select=!1;a.customMessage="Hi,\nYou are invited to take the test.";a.customSubject="Test Invitation";a.customMailTitle="\x3ccompanyName\x3e - Test Invitation";a.isCustomTemplate=!1;a.page=1;a.pageSize=1E3;a.loadMoreInvites=!0;a.enableWhatsappNotifs=!1;a.enableStudentManagementFeature=!1;a.studentsBatch={};a.inviteStudentMode="addEmails";a.inviteEmails="";a.timingInHours=48;a.customTiming=0;a.sEmails="";a.emails="";a.smObject={};a.smObject.skipStudentsWithLimitReached=
5!1;a.hideIssueTable=!1;a.customMailTemplatesMap={};a.customMailTemplatesTitles=[];a.sendNormalLinks=!1;a.isEmailLessAttemptEnabled=!1;a.names="";a.hintNote="HINT : You can use following shortcuts for automatic data conversion : \x3ccandidateEmail\x3e, \x3ctestTitle\x3e.";a.hintNoteBulk="HINT : You can use following shortcuts for automatic data conversion : \x3ccandidateEmail\x3e, \x3ccandidateName\x3e, \x3ctestTitle\x3e.";var t=/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{1,63})+$/;D.userInfo().then(function(b){a.enableWhatsappNotifs=
6b.hrMetaDataWebDto.enableWhatsappNotifications;b.hrMetaDataWebDto.enableStudentManagementFeature&&a.studentManagementInit();a.hasSMSubscription=b.hrMetaDataWebDto.hasSMSubscription});a.studentManagementInit=function(){a.enableStudentManagementFeature=!0;u.init().then(function(b){a.allCourses=u.getAllCourses();a.semesterOrYearDetails=u.getSemestersOrYearsByCourse();null!=a.allCourses&&0<a.allCourses.length&&(a.inviteStudentMode="selectBatch",a.selectedCourseName=a.allCourses[0],a.changeCourseName(a.selectedCourseName))})};
7a.whatsappEnabled=ENABLE_WHATSAPP;a.showFilterBox=!1;a.filterObject={};a.filterObject.testStatus={};a.filterObject.inviteStatus={};a.filterTagsObj={};(function(){var b={height:200,toolbar:[["style","style bold italic underline strikethrough superscript subscript clear".split(" ")],["font",["fontname","fontsize"]],["color",["color"]],["para",["ol","ul","paragraph"]],["table",["table"]],["insert",["link","hr"]],["misc",["codeview","undo","redo"]]],fontNames:["Arial","Arial Black","Times New Roman"],
8fontNamesIgnoreCheck:["Arial","Arial Black","Times New Roman"],dialogsInBody:!0,dialogsFade:!1,disableLinkTarget:!0};$("#custMailBodySummernote").summernote(b);$("#custMailBodySummernote").summernote("code",a.customMessage);$("#custBulkMailBodySummernote").summernote(b)})();a.allAtsCandidatesFilter={};a.allAtsCandidatesFilter.shortlist={};a.allAtsCandidatesFilter.shortlist.genderFilterTag={};a.enableEgCandidates=!1;a.allEgCandidatesFilter={};a.allEgCandidatesFilter.shortlist={};a.allEgCandidatesFilter.shortlist.genderFilterTag=
9{};a.egCandidatesSortByOptions=[{name:"Last Updated - DESC",value:"lastUpdated_desc"},{name:"Last Updated - ASC",value:"lastUpdated_asc"},{name:"CTC - ASC",value:"currentAnnualSalary_asc"},{name:"CTC - DESC",value:"currentAnnualSalary_desc"},{name:"Notice Period - ASC",value:"currentNoticePeriod_asc"},{name:"Notice Period - DESC",value:"currentNoticePeriod_desc"},{name:"Work Experience - ASC",value:"totalExperience_asc"},{name:"Work Experience - DESC",value:"totalExperience_desc"}];var p={};a.allEgCandidatesPagination=
10{};a.allEgCandidatesPagination.page=0;a.allEgCandidatesPagination.pageSize=100;a.allAtsGridOptions={enableFiltering:!0,enableSorting:!0,gridMenuCustomItems:[{title:"Refresh Data",action:function(){a.getAllAtsCandidatesWithFilter()}}],onRegisterApi:function(b){a.allAtsGridApi=b;b.selection.on.rowSelectionChangedBatch(a,function(){if(!b.selection.getSelectAllState()){var a=this.grid.getVisibleRows();b.selection.clearSelectedRows();_.each(a,function(a){a.setSelected(!0)})}});b.pagination.on.paginationChanged(a,
11function(){b.selection.clearSelectedRows()})}};a.allEgGridOptions={enableFiltering:!0,enableSorting:!0,useExternalPagination:!0,paginationPageSize:100,paginationPageSizes:[10,100,200],gridMenuCustomItems:[{title:"Refresh Data",action:function(){a.getAllEgCandidatesWithFilter()}}],onRegisterApi:function(b){a.allEgGridApi=b;b.selection.on.rowSelectionChangedBatch(a,function(){if(!b.selection.getSelectAllState()){var a=this.grid.getVisibleRows();b.selection.clearSelectedRows();_.each(a,function(a){a.setSelected(!0)})}});
12b.pagination.on.paginationChanged(a,function(c,d){b.selection.clearSelectedRows();a.allEgCandidatesPagination.page=c-1;a.allEgCandidatesPagination.pageSize=d;F(p)})}};"Expired"==e.testStatus&&(a.testExpired=!0);"invited-candidates"===q.search().view?(w.show("invited-candidates"),a.partial="invitedCandidates"):(w.show("invite-candidates"),a.partial="invite");a.showTimingsFunctionality=!1;var r=[];
12a.candidatesInvited=[];D.redirectIfInvalidUser(hrRole);"invited-candidates"===q.search().view&&(a.partial=
13"invitedCandidates",n.get("./ajax/recruiter/invitedcandidates/"+m+"?page\x3d"+a.page+"\x26pageSize\x3d"+a.pageSize).success(function(b){a.loadMoreInvites=b.length>=a.pageSize?!0:!1;l.candidateEmails=[];_.each(b,function(b){a.candidatesInvited.push(b)})}).error(function(b,c,d,f){0==c?(alertify.error(msgNetworkDown),delete a.candidatesInvited):401===c&&(console.log("Unauthorized"),UnauthorizedUserPrompt())}));a.sendInviteResponse=null;a.testData={};a.fetchInvitedCandidates=function(){a.candidatesInvited=
14[];l.candidateEmails=[];var b="./ajax/recruiter/invitedcandidates/"+m+"?page\x3d"+a.page+"\x26pageSize\x3d"+a.pageSize;a.filterObject.isFilterApplied&&(b+="\x26filterObject\x3d"+encodeURIComponent(angular.toJson(a.filterTagsObj)));n.get(b).success(function(b){a.loadMoreInvites=b.length>=a.pageSize?!0:!1;l.candidateEmails=[];_.each(b,function(b){a.candidatesInvited.push(b)})}).error(function(b,d,f,e){0==d?(alertify.error(msgNetworkDown),delete a.candidatesInvited):401===d&&(console.log("Unauthorized"),
15UnauthorizedUserPrompt())});w.show("invited-candidates");a.partial="invitedCandidates"};a.changeTestInviteStatus=function(b){var c=[];angular.copy(l.candidateEmails,c);var d="./ajax/recruiter/changeInviteStatus/"+m+"?status\x3d"+b;x();for(var f=0;f<r.length;f++){var e=c.indexOf(r[f].email);-1!=e&&c.splice(e,1)}"CANCELLED"===b?swal({title:"Are you sure?",type:"warning",text:"If you cancel the invitation these candidates will not be able to attempt the test. Please note that this will only cancel the invitation if the candidate(s) has not started the test",
16icon:"warning",showCancelButton:!0,confirmButtonText:"Yes, Cancel",cancelButtonText:"No, Don't Do",allowOutsideClick:!1,confirmButtonColor:"#DD6B55"},function(f){f&&(0==c.length?alertify.error("Invitation can be updated only for the candidates who has not started the test yet."):n.put(d,c).success(function(d,f,e,G){for(f=0;f<d.length;f++)e=c.indexOf(d[f]),-1!=e&&c.splice(e,1);_.each(a.candidatesInvited,function(a){-1<c.indexOf(a.email)&&(a.status=b)});alertify.success("Cancelled Successfully")}).error(function(a,
17b,c,d){0==b?alertify.error(msgNetworkDown):401===b?(console.log("Unauthorized"),UnauthorizedUserPrompt()):alertify.error("Some Error occurred")}))}):0==c.length?alertify.error("Invitation can be updated only for the candidates who has not started the test yet."):n.put(d,c).success(function(d,f,e,G){swal("Invitation has been restored","We have undone the canceled invitation and the candidates will  be able to take a test now but we suggest you check the test timing for  these candidates and update the timing if needed",
18"success");_.each(a.candidatesInvited,function(a){-1<c.indexOf(a.email)&&(a.status=b)})}).error(function(a,b,c,d){0==b?alertify.error(msgNetworkDown):401===b&&(console.log("Unauthorized"),UnauthorizedUserPrompt())})};a.showInviteCandidates=function(){w.show("invite-candidates");a.partial="invite"};n.get("./ajax/recruiter/testInvite/testDetails/"+m).success(function(b,c,d,f){a.testData.title=b.title;a.testData.description=b.description;a.testData.startTime=b.startTime;a.testData.endTime=b.endTime;
19a.testData.selectedTimezoneId=b.selectedTimezoneId;a.showTimingsFunctionality=!b.loginTest;a.testData.status=b.status;a.customSubject=a.customSubject+" | "+e.companyName+" | "+a.testData.title;"Expired"==b.status&&(a.testExpired=!0);a.testData.enableImageProcessing=b.enableImageProcessing;a.testData.enableSafeExamBrowser=b.enableSafeExamBrowser;a.isEmailLessAttemptEnabled=b.emailLessAttempt}).error(function(a,c,d,f){0==c?alertify.error(msgNetworkDown):401===c?(console.log("Unauthorized"),UnauthorizedUserPrompt()):
20(I.message=msgGeneralError,q.path("/error"))});a.sendOrGenerateInvitation=function(){if(a.enableCCorBCCmails)if(a.ccEmailId||a.bccEmailId){if(a.ccEmailId&&!t.test(a.ccEmailId)){alertify.error("Please Enter valid CC email");return}if(a.bccEmailId&&!t.test(a.bccEmailId)){alertify.error("Please Enter valid BCC email");return}}else{alertify.error("Please Enter valid cc and/or bcc email ids");return}a.enableStudentManagementFeature?a.inviteStudents():a.isEmailLessAttemptEnabled?a.inviteCandidatesByNames():
21a.inviteCandidates()};a.inviteCandidates=function(){var b=[],c=[];a.showExistingCand=!1;var d="",f="",e=[],k=a.emails,g=!1,k=k.replace(/ /g,""),k=k+" ";if(a.emails&&0!=a.emails.length){for(i=0;i<k.length;i++)","==k[i]&&(g=!0),"\n"==k[i]||i==k.length-1?(1===b.length-c.length&&c.push(""),g&&(f=f.trim().substring(1,f.len),f.startsWith("+")?-1==c.indexOf(f)&&c.push(f):c.push(""),g=!1),d=d.trim(),t.test(d)?-1==b.indexOf(d)&&b.push(d):0!=d.length&&e.push(d),f=d=""):g?f+=k[i]:d+=k[i];1===b.length-c.length&&
22c.push("");if(0!=e.length)a.validationErrorMessage="The following addresses are invalid\n",_.each(e,function(b){a.validationErrorMessage+=b+"\n"}),a.validationErrorMessage+="Please correct them.";else{d={};d.testId=m;d.emails=b;d.whatsappNumbers=c;
22a.isCustomTemplate&&(a.customMessage=$("#custMailBodySummernote").summernote("code"),a.customMessage=a.customMessage.replace(/&lt;/g,"\x3c"),a.customMessage=a.customMessage.replace(/&gt;/g,"\x3e"),d.customMessage=a.customMessage,d.customSubject=a.customSubject,
23d.customMailTitle=a.customMailTitle);if(a.showNewInviteTimings){if(a.overridenOpenTime>=a.overridenCloseTime){alertify.error("Closing time should be greater than opening time");return}d.testInviteOpenTime=a.overridenOpenTime;d.testInviteCloseTime=a.overridenCloseTime}a.enableCCorBCCmails&&(d.ccEmailId=a.ccEmailId,d.bccEmailId=a.bccEmailId);d.sendNormalLinks=a.sendNormalLinks;a.validationErrorMessage="";n.post("./ajax/recruiter/test/"+m+"/invite",d).success(function(b,c,d,f){a.sendInviteResponse=b;
24a.emails=""}).error(function(b,c,d,f){0==c?alertify.error(msgNetworkDown):c===CUSTOM_RESPONSE_STATUS.NoCreditLeft?(a.sendInviteResponse=b,swal({title:b})):401===c?(console.log("Unauthorized"),UnauthorizedUserPrompt()):690===c?alertify.error(b):691===c?swal({title:"Your Student Management Subscription has expired."}):400==c?alertify.error(b):alertify.error(msgGeneralError)})}}else alertify.error("Please Enter emails, if already there then please refresh the page and try again")};a.inviteCandidatesByNames=
25function(){var b=[],c="";if(null==a.names||0==a.names.length)alertify.error("Please enter any name to generate invitation");else if(a.names.match(/[^ a-zA-Z0-9./\n-]/g))alertify.error("Please do not use any special characters except 'period' and 'dash' in the name(s)");else{var d=a.names+" ";if(a.names&&0<a.names.length)for(i=0;i<d.length;i++)"\n"==d[i]||i==d.length-1?(c=c.trim(),b.push(c),c=""):c+=d[i];if(0==b.length)alertify.error("Please Enter candidate full names, if already there then please refresh the page and try again");
26else{c={};c.testId=m;c.names=b;c.invitedByNames=!0;if(a.showNewInviteTimings){if(a.overridenOpenTime>=a.overridenCloseTime){alertify.error("Closing time should be greater than opening time");return}c.testInviteOpenTime=a.overridenOpenTime;c.testInviteCloseTime=a.overridenCloseTime}c.sendNormalLinks=a.sendNormalLinks;a.validationErrorMessage="";n.post("./ajax/recruiter/test/"+m+"/invite",c).success(function(b,c,d,e){a.sendInviteResponse=b;a.names=""}).error(function(b,c,d,e){0==c?alertify.error(msgNetworkDown):
27c===CUSTOM_RESPONSE_STATUS.NoCreditLeft?(a.sendInviteResponse=b,swal({title:b})):401===c?(console.log("Unauthorized"),UnauthorizedUserPrompt()):400===c?alertify.error(b):690===c?alertify.error(b):691===c?swal({title:"Your Student Management Subscription has expired."}):alertify.error(msgGeneralError)})}}};a.selectCout=0;a.TickAllCheckBoxes=function(){l.candidateEmails=[];angular.forEach(a.candidatesInvited,function(b){a.select?(b.selected=!0,l.candidateEmails.push(b.email)):b.selected=!1});a.selectCout=
28a.select?l.candidateEmails.length:0;console.log(l)};var l={candidateEmails:[]};a.updateTestInvitedSelectedCandidatesService=function(b){b.selected?(l.candidateEmails.push(b.email),a.selectCout++):(l.candidateEmails.splice(l.candidateEmails.indexOf(b.email),1),a.select=!1,a.selectCout--)};a.showEditTimings=!1;a.showNewInviteTimings=!1;a.enableCCorBCCmails=!1;a.ccEmailId;a.bccEmailId;a.updateOverridenTime=function(){if(1==a.customTiming)a.overridenOpenTime=a.testData.startTime,a.overridenCloseTime=
29a.testData.endTime;else{var b=new Date;a.testData.startTime>b.getTime()?(a.overridenOpenTime=a.testData.startTime,a.overridenCloseTime=a.testData.startTime+36E5*a.timingInHours):(a.overridenOpenTime=b.getTime(),b.setHours(b.getHours()+a.timingInHours),a.overridenCloseTime=b.getTime())}};a.changeTimeClicked=function(){a.showEditTimings=!0;a.updateOverridenTime()};a.changeTimeConfirm=function(b,c){if(c<=b)alertify.error("Closing time should be greater than opening time");else if(0==l.candidateEmails.length)alertify.error("Please select atleast one invite to change the timings");
30else{a.postObject={};a.postObject.emails=[];angular.copy(l.candidateEmails,a.postObject.emails);x();a.updateTimeMessage=null;for(var d=0;d<r.length;d++){var f=a.postObject.emails.indexOf(r[d].email);-1!=f&&a.postObject.emails.splice(f,1)}for(var e=[],d=0;
30d<a.candidatesInvited.length;d++)"CANCELLED"==a.candidatesInvited[d].status&&(f={},f=a.candidatesInvited[d],e.push(f));for(d=0;d<e.length;d++)f=a.postObject.emails.indexOf(e[d].email),-1!=f&&a.postObject.emails.splice(f,1);a.postObject.testInviteOpenTime=
31b;a.postObject.testInviteCloseTime=c;0==a.postObject.emails.length?alertify.error("Time can be updated only for the candidate who has not completed the test yet."):n.post("./ajax/recruiter/updateTestInviteTimings/"+m,a.postObject).success(function(d,f,e,G){a.showEditTimings=!1;alertify.success("Changed timing successFully");_.each(a.candidatesInvited,function(d){-1<a.postObject.emails.indexOf(d.email)&&(d.opensAt=b,d.closesAt=c)})}).error(function(a,b,c,d){0==b?alertify.error(msgNetworkDown):401===
32b?(console.log("Unauthorized"),UnauthorizedUserPrompt()):alertify.error("An error occured")})}};a.sendReminder=function(){e.modalObject={};e.modalObject.candidateEmails=[];angular.copy(l.candidateEmails,e.modalObject.candidateEmails);x();for(var b=[],c=0;c<a.candidatesInvited.length;c++)if("CANCELLED"==a.candidatesInvited[c].status){var d={},d=a.candidatesInvited[c];b.push(d)}for(c=0;c<r.length;c++)d=e.modalObject.candidateEmails.indexOf(r[c].email),-1!=d&&e.modalObject.candidateEmails.splice(d,1);
33for(c=0;c<b.length;c++)d=e.modalObject.candidateEmails.indexOf(b[c].email),-1!=d&&e.modalObject.candidateEmails.splice(d,1);e.modalObject.sendButton=0==e.modalObject.candidateEmails.length?!0:!1;e.modalObject.selectedAll=!1;e.modalObject.testId=m;e.modalObject.isSebEnabled=a.testData.enableSafeExamBrowser;e.modalObject.mailType="reminderMail";e.modalObject.enableRichEditor=!0;e.modalObject.subject="Evalground : Reminder for test "+a.testData.title;e.modalObject.body="Dear candidate,\nThis is to remind you that the test \x3ctestTitle\x3e will commence on  \x3ctestStartTime\x3e  and ends on \x3ctestEndTime\x3e.\nWe wish you the best of luck.";
34a.select&&(0==e.modalObject.candidateEmails.length&&angular.forEach(a.candidatesInvited,function(a){e.modalObject.candidateEmails.push(a.email)}),e.modalObject.selectedAll=!0,e.modalObject.mailStatement="All Candidates");e.modalObject.candidateEmails.length<l.candidateEmails.length&&(e.modalObject.message="*The reminder mail will only go to the candidate(s) who has not completed the test yet.");e.currentModal="./views/application/modalSendMail.html"};a.sendMail=function(){e.modalObject={};e.modalObject.candidateEmails=
35[];angular.copy(l.candidateEmails,e.modalObject.candidateEmails);0==e.modalObject.candidateEmails.length?(e.modalObject={},alertify.error("You have not selected any candidates to send mail. Select some candidates first.")):(e.modalObject.selectedAll=!1,e.modalObject.hint=a.hintNote,a.select&&(e.modalObject.selectedAll=!0,e.modalObject.mailStatement="All Candidates"),e.modalObject.testId=m,e.modalObject.sendCopy=!1,e.modalObject.sendCopyTo=null,e.modalObject.enableRichEditor=!0,e.currentModal="./views/application/modalSendMail.html")};
36a.openResume=function(a){window.open(a,"CV","height\x3d680,width\x3d800,left\x3d10,top\x3d10,resizable\x3dyes,scrollbars\x3dyes,toolbar\x3dyes,menubar\x3dno,location\x3dno,directories\x3dno,status\x3dyes")};a.callCandidate=function(a){e.showVoiceCallIframe=!0;console.log(a);var b={};b.phone=a.contactNumber.slice();b.name=a.name.slice();document.getElementById("voicecall-frame").contentWindow.updatedata(b)};a.fetchMoreInvites=function(){a.page+=1;var b="./ajax/recruiter/invitedcandidates/"+m+"?page\x3d"+
37a.page+"\x26pageSize\x3d"+a.pageSize;a.filterObject.isFilterApplied&&(b+="\x26filterObject\x3d"+encodeURIComponent(angular.toJson(a.filterTagsObj)));n.get(b).success(function(b){a.loadMoreInvites=b.length>=a.pageSize?!0:!1;l.candidateEmails=[];_.each(b,function(b){a.candidatesInvited.push(b)})}).error(function(b,d,f,e){0==d?(alertify.error(msgNetworkDown),delete a.candidatesInvited):401===d&&(console.log("Unauthorized"),UnauthorizedUserPrompt())})};a.isImageProcessingAllowed=CANDIDATE_REFERENCE_IMG_CHECK_ALLOWED;
38a.fileUploadInProgress=!1;a.candRefImage=null;a.uploadAndCheckCandRefImage=function(b,c){console.log(b,c);var d=b.name.split("."),d=d[d.length-1].toLowerCase();0==("png"==d||"jpg"==d||"jpeg"==d)?alertify.error("Only png, jpg and jpeg file extensions are allowed. Please upload candidate image in proper format."):512E3<b.size?alertify.error("File size more than 500 KB is not allowed "):(a.fileUploadInProgress=!0,E.upload({url:"./ajax/recruiter/uploadAndCheckCandRefImage?candEmail\x3d"+c,file:b}).success(function(b,
39c,d,e){alertify.success("Uploaded Candidate Ref Image successfully.");a.candRefImage=b;a.candRefImageUrl=b.url;a.fileUploadInProgress=!1;a.closeSingleCandRefImageUploadModal()}).error(function(b,c,d,e){0==c?alertify.error(msgNetworkDown):401===c?UnauthorizedUserPrompt():420===c?alertify.error(b):alertify.error("Couldn't upload image.");a.fileUploadInProgress=!1;a.closeSingleCandRefImageUploadModal()}))};a.openBulkCandRefImagesUploadModal=function(){window.location=window.location.href.replace(window.location.hash,
40"#/recruiter/hrCandidates")};a.openSingleCandRefImageUploadModal=function(b){$("#singleRefImageUploadModal").modal({backdrop:"static",keyboard:!1});a.selectedInviteCandidate={};a.selectedInviteCandidate.email=b.email};a.closeSingleCandRefImageUploadModal=function(){$("#singleRefImageUploadModal").modal("hide");a.selectedInviteCandidate={};a.candRefImage=null};a.showAtsCandidatesModal=function(){$("#allAtsCandidatesModal").modal({backdrop:"static",keyboard:!1});
40a.getAllAtsCandidatesInit();a.getAllEgCandidatesInit()};
41a.closeAtsCandidatesModal=function(){$("#allAtsCandidatesModal").modal("hide")};a.getAllAtsCandidates=function(b){n.get(b).success(function(b,d,f,e){void 0===b&&q.url("/error");void 0!=a.allAtsGridApi&&(a.allAtsGridApi.selection.clearSelectedRows(),a.allAtsGridApi.core.refresh());a.allAtsCandidates=[];_.each(b,function(b){a.allAtsCandidates.push(b)});setUiGridDataForAllAtsCandidates(a.allAtsCandidates)}).error(function(a,b,f,e){0==b?alertify.error(msgNetworkDown):401===b?(console.log("Unauthorized"),
42UnauthorizedUserPrompt()):q.url("/error")})};var A=function(b){b="./ajax/ats/recruiter/candidateDetails?candidatesFilter\x3d"+encodeURIComponent(angular.toJson(b));a.getAllAtsCandidates(b)};setAllAtsCandidatesPostObj=function(a,c){a.name=c.shortlist.nameFilterTag;a.isArchived=c.shortlist.isArchivedTag;a.email=c.shortlist.emailFilterTag;c.shortlist.genderFilterTag.all?a.gender="all":c.shortlist.genderFilterTag.male&&!c.shortlist.genderFilterTag.female?a.gender="MALE":!c.shortlist.genderFilterTag.male&&
43c.shortlist.genderFilterTag.female&&(a.gender="FEMALE");a.location=[];0<c.shortlist.locationFilterTag.length&&(a.location=c.shortlist.locationFilterTag.split(",").map(function(a){return a.trim().toLowerCase()}));a.education=c.shortlist.educationFilterTag;var b=c.shortlist.skillsFilterTag;a.skills=[];0<b.length&&(a.skills=b.split(",").map(function(a){return a.trim().toLowerCase()}));a.certificates=c.shortlist.certificationFilterTag;1==c.shortlist.referralFilterTag?(a.referral=c.shortlist.referralFilterTag,
44a.referredBy=c.shortlist.referredByFilterTag):a.referredBy="";a.noticePeriod=c.shortlist.npLessThanEqualToFilterTag;a.workExperienceFrom=null!=c.shortlist.wExperienceFromFilterTag?12*c.shortlist.wExperienceFromFilterTag:null;a.workExperienceTo=null!=c.shortlist.wExperienceToFilterTag?12*c.shortlist.wExperienceToFilterTag:null};updateAllAtsCandidatesFilterService=function(a,c){a.shortlist.nameFilterTag=c.shortlist.nameFilterTag;a.shortlist.emailFilterTag=c.shortlist.emailFilterTag;a.shortlist.genderFilterTag.male=
45c.shortlist.genderFilterTag.male;a.shortlist.genderFilterTag.female=c.shortlist.genderFilterTag.female;a.shortlist.genderFilterTag.all=c.shortlist.genderFilterTag.all;a.shortlist.locationFilterTag=c.shortlist.locationFilterTag;a.shortlist.educationFilterTag=c.shortlist.educationFilterTag;a.shortlist.skillsFilterTag=c.shortlist.skillsFilterTag;a.shortlist.certificationFilterTag=c.shortlist.certificationFilterTag;a.shortlist.referralFilterTag=c.shortlist.referralFilterTag;a.shortlist.referredByFilterTag=
46c.shortlist.referredByFilterTag;a.shortlist.npLessThanEqualToFilterTag=c.shortlist.npLessThanEqualToFilterTag;a.shortlist.wExperienceFromFilterTag=c.shortlist.wExperienceFromFilterTag;a.shortlist.wExperienceToFilterTag=c.shortlist.wExperienceToFilterTag;a.shortlist.isArchivedTag=c.shortlist.isArchivedTag};a.allAtsCandidatesFilter.checkGenderFilter=function(){a.allAtsCandidatesFilter.shortlist.genderFilterTag.male&&a.allAtsCandidatesFilter.shortlist.genderFilterTag.female?a.allAtsCandidatesFilter.shortlist.genderFilterTag.all=
47!0:(a.allAtsCandidatesFilter.shortlist.genderFilterTag.all=!1,a.allAtsCandidatesFilter.shortlist.genderFilterTag.male||a.allAtsCandidatesFilter.shortlist.genderFilterTag.female||(a.allAtsCandidatesFilter.shortlist.genderFilterTag.all=!0,a.allAtsCandidatesFilter.shortlist.genderFilterTag.male=!0,a.allAtsCandidatesFilter.shortlist.genderFilterTag.female=!0))};a.allAtsCandidatesFilter.checkGenderFilterAll=function(){a.allAtsCandidatesFilter.shortlist.genderFilterTag.all||(a.allAtsCandidatesFilter.shortlist.genderFilterTag.all=
48!0);a.allAtsCandidatesFilter.shortlist.genderFilterTag.male=!0;a.allAtsCandidatesFilter.shortlist.genderFilterTag.female=!0};a.checkAllAtsCandidatesFilter=function(){var b="";(null!=a.allAtsCandidatesFilter.shortlist.npLessThanEqualToFilterTag||""!=a.allAtsCandidatesFilter.shortlist.npLessThanEqualToFilterTag)&&0>a.allAtsCandidatesFilter.shortlist.npLessThanEqualToFilterTag&&(b="*Notice Period can't be less than zero.");(null!=a.allAtsCandidatesFilter.shortlist.wExperienceFromFilterTag||""!=a.allAtsCandidatesFilter.shortlist.wExperienceFromFilterTag)&&
490>a.allAtsCandidatesFilter.shortlist.wExperienceFromFilterTag&&(b="*Work Experience can't be less than zero.");(null!=a.allAtsCandidatesFilter.shortlist.wExperienceToFilterTag||""!=a.allAtsCandidatesFilter.shortlist.wExperienceToFilterTag)&&0>a.allAtsCandidatesFilter.shortlist.wExperienceToFilterTag&&(b="*Work Experience can't be less than zero.");a.allAtsCandidatesWarningMessage=b;return""==a.allAtsCandidatesWarningMessage?!1:!0};a.updateAllAtsFilterWithTags=function(b){var c={};a.allAtsCandidatesFilter.shortlist.nameFilterTag=
50b.name;a.allAtsCandidatesFilter.shortlist.emailFilterTag=b.email;a.allAtsCandidatesFilter.shortlist.educationFilterTag=b.education;a.allAtsCandidatesFilter.shortlist.certificationFilterTag=b.certificates;a.allAtsCandidatesFilter.shortlist.referralFilterTag=b.referral;
50a.allAtsCandidatesFilter.shortlist.referredByFilterTag=b.referral?b.referredBy:"";a.allAtsCandidatesFilter.shortlist.npLessThanEqualToFilterTag=b.noticePeriod;a.allAtsCandidatesFilter.shortlist.wExperienceFromFilterTag=null!=b.workExperienceFrom?
51Math.round(b.workExperienceFrom/12):null;a.allAtsCandidatesFilter.shortlist.wExperienceToFilterTag=null!=b.workExperienceTo?Math.round(b.workExperienceTo/12):null;"all"==b.gender&&(a.allAtsCandidatesFilter.shortlist.genderFilterTag.all=!0,a.allAtsCandidatesFilter.shortlist.genderFilterTag.male=!0,a.allAtsCandidatesFilter.shortlist.genderFilterTag.female=!0);a.allAtsCandidatesFilter.shortlist.locationFilterTag="";for(i=0;i<b.location.length;i++)a.allAtsCandidatesFilter.shortlist.locationFilterTag+=
52b.location[i],i<b.location.length-1&&(a.allAtsCandidatesFilter.shortlist.locationFilterTag+=",");a.allAtsCandidatesFilter.shortlist.skillsFilterTag="";for(i=0;i<b.skills.length;i++)a.allAtsCandidatesFilter.shortlist.skillsFilterTag+=b.skills[i],i<b.skills.length-1&&(a.allAtsCandidatesFilter.shortlist.skillsFilterTag+=",");a.allAtsCandidatesFilter.shortlist.isArchivedTag=b.isArchived;updateAllAtsCandidatesFilterService(g,a.allAtsCandidatesFilter);setAllAtsCandidatesPostObj(c,g);A(c);a.allEgGridOptions=
53c;a.allAtsCandidatesFilter.isFilterApplied=y()};a.getAllAtsCandidatesInit=function(){var b=a.allAtsCandidatesFilter;b.shortlist.nameFilterTag=g.shortlist.nameFilterTag;b.shortlist.emailFilterTag=g.shortlist.emailFilterTag;b.shortlist.genderFilterTag.male=g.shortlist.genderFilterTag.male;b.shortlist.genderFilterTag.female=g.shortlist.genderFilterTag.female;b.shortlist.genderFilterTag.all=g.shortlist.genderFilterTag.all;b.shortlist.locationFilterTag=g.shortlist.locationFilterTag;b.shortlist.educationFilterTag=
54g.shortlist.educationFilterTag;b.shortlist.skillsFilterTag=g.shortlist.skillsFilterTag;b.shortlist.certificationFilterTag=g.shortlist.certificationFilterTag;b.shortlist.referralFilterTag=g.shortlist.referralFilterTag;b.shortlist.referredByFilterTag=g.shortlist.referredByFilterTag;b.shortlist.npLessThanEqualToFilterTag=g.shortlist.npLessThanEqualToFilterTag;b.shortlist.wExperienceFromFilterTag=g.shortlist.wExperienceFromFilterTag;b.shortlist.wExperienceToFilterTag=g.shortlist.wExperienceToFilterTag;
55b.shortlist.isArchivedTag=g.shortlist.isArchivedTag;b={};setAllAtsCandidatesPostObj(b,g);A(b);a.allAtsCandidatesFilterTags=b;a.allAtsCandidatesFilter.isFilterApplied=y()};a.getAllAtsCandidatesWithFilter=function(){updateAllAtsCandidatesFilterService(g,a.allAtsCandidatesFilter);var b={};setAllAtsCandidatesPostObj(b,g);A(b);a.allAtsCandidatesFilterTags=b;a.allAtsCandidatesFilter.isFilterApplied=y()};setUiGridDataForAllAtsCandidates=function(b){a.allAtsGridOptions.data=b;a.allAtsGridOptions.exporterMenuPdf=
56!1;a.allAtsGridOptions.enableGridMenu=!0;a.allAtsGridOptions.enablePaginationControls=!0;a.allAtsGridOptions.paginationPageSize=100;a.allAtsGridOptions.paginationPageSizes=[10,50,100,500,1E3,1E4,1E5];a.allAtsGridOptions.minimumColumnSize=100;a.allAtsGridOptions.rowHeight=45;a.allAtsGridOptions.columnDefs=[];a.allAtsGridOptions.columnDefs.push({name:"Candidate Name",type:"string",field:"name",enableFiltering:!0,minWidth:200,cellTooltip:!0,headerToolTip:"Candidate Name",enablePinning:!0,filter:{condition:function(a,
57b,f,e){a=a.replace(/\\./g,".");return-1<b.toLowerCase().indexOf(a.toLowerCase())||-1<f.entity.email.toLowerCase().indexOf(a.toLowerCase())?!0:!1}},cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center" title\x3d"{{COL_FIELD}}"\x3e\x3ca href\x3d"" title\x3d"Candidate\'s name. Click to go to candidate\'s profile." ng-if\x3d"(row.entity.userId !\x3d undefined) \x26\x26 (row.entity.userId !\x3d null)" ng-click\x3d"grid.appScope.goToCandidateProfile(row.entity.userId)"\x3e{{row.entity.name}}\x3c/a\x3e\x3cspan ng-if\x3d"(row.entity.userId \x3d\x3d undefined) || (row.entity.userId \x3d\x3d null)"\x3e{{row.entity.name}}\x3c/span\x3e\x3cbr\x3e\x3cspan title\x3d"Candidate\'s email" style\x3d"color:#999"\x3e{{row.entity.email}}\x3c/span\x3e\x3c/div\x3e\x3c/div\x3e'});
58a.allAtsGridOptions.columnDefs.push({name:"Contact Details",type:"string",field:"contactNumber",cellTooltip:!0,headerToolTip:"Contact Details",enablePinning:!0,filter:{condition:function(a,b,f,e){a=a.replace(/\\./g,".");return null!=f.entity.contactNumber&&-1<f.entity.contactNumber.toLowerCase().indexOf(a.toLowerCase())||null!=f.entity.skypeId&&-1<f.entity.skypeId.toLowerCase().indexOf(a.toLowerCase())?!0:!1}},cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center"\x3e\x3cdiv\x3e\x3cspan title\x3d"Conatct Number" \x3e{{COL_FIELD}} \x3c/span\x3e\x26nbsp;\x3cbr\x3e\x3cspan style\x3d"color:#999"\x3e\x3cdiv title\x3d"Skype Id" data-ng-show\x3d"row.entity.skypeId !\x3d null "\x3e{{row.entity.skypeId}}\x3c/div\x3e\x3c/span\x3e\x3c/div\x3e\x3c/div\x3e',
59visible:!0,enableFiltering:!0,minWidth:150});a.allAtsGridOptions.columnDefs.push({name:"Location",field:"location",cellTooltip:!0,headerToolTip:"Location",cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center" title\x3d"{{COL_FIELD}}"\x3e{{COL_FIELD}}\x3c/div\x3e',visible:!0,enableFiltering:!0,minWidth:150});a.allAtsGridOptions.columnDefs.push({name:"Work Experience",field:"totalWorkExpInWords",cellTooltip:!0,headerToolTip:"Work Experience",cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center" title\x3d"{{COL_FIELD}}"\x3e{{COL_FIELD}}\x3c/div\x3e',
60visible:!0,enableFiltering:!0,minWidth:150});a.allAtsGridOptions.columnDefs.push({name:"Skills",field:"skills",cellTooltip:!0,headerToolTip:"Skills",cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center" title\x3d"{{COL_FIELD}}"\x3e{{COL_FIELD}}\x3c/div\x3e',visible:!0,enableFiltering:!0,minWidth:150});a.allAtsGridOptions.columnDefs.push({name:"Notice Period (In Days)",field:"noticePeriod",cellTooltip:!0,headerToolTip:"Notice Period",cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center" title\x3d"{{COL_FIELD}}"\x3e\x3cspan ng-if\x3d"row.entity.currentNoticePeriod !\x3d \'null\'"\x3e{{COL_FIELD}}\x3c/span\x3e\x3c/div\x3e',
61visible:!0,enableFiltering:!0,minWidth:150});a.allAtsGridOptions.columnDefs.push({name:"Resume",field:"resume",cellTooltip:!0,headerToolTip:"Resume",enableFiltering:!1,cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center" title\x3d"Resume"\x3e\x3ca ng-show\x3d"row.entity.resume !\x3d null \x26\x26 row.entity.resume !\x3d \'\' " href\x3d"" ng-click\x3d"grid.appScope.setEmbeddedRes
61ourceUrl(row.entity.resume, true)"\x3e\x3ci class\x3d"fa fa-file"\x3e\x3c/i\x3e\x3c/a\x3e\x3cspan ng-hide\x3d"row.entity.resume !\x3d null \x26\x26 row.entity.resume !\x3d \'\' "\x3eNA\x3c/span\x3e\x3c/div\x3e',
62visible:!0,minWidth:150});a.allAtsGridOptions.columnDefs.push({name:"Referral",field:"referral",cellTooltip:!0,headerToolTip:"Referral",cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center" title\x3d"{{COL_FIELD}}"\x3e{{COL_FIELD| date:"dd/MM/yyyy"}}\x3c/div\x3e',visible:!0,enableFiltering:!0,minWidth:150});a.allAtsGridOptions.columnDefs.push({name:"Referred By",field:"referredBy",cellTooltip:!0,headerToolTip:"Referred By",cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center" title\x3d"{{COL_FIELD}}"\x3e{{COL_FIELD| date:"dd/MM/yyyy"}}\x3c/div\x3e',
63visible:!0,enableFiltering:!0,minWidth:150})};a.goToCandidateProfile=function(a){void 0!=a&&null!=a&&window.open(window.location.protocol+"//"+window.location.host+ARCHIVES_URL_PREFIX+"/candidate#/public/profile/"+a)};a.addAtsCandidates=function(){var b=a.allAtsGridApi.selection.getSelectedRows();if(void 0==a.emails||null==a.emails)a.email="";angular.forEach(b,function(b){a.emails=""==a.emails||void 0==a.emails||null==a.emails?b.email:a.emails+("\n"+b.email)});a.closeAtsCandidatesModal()};a.addNewCandidate=
64function(){window.open(ARCHIVES_URL_PREFIX+"/ats#/recruiter/candidates","_blank")};a.getAllEgCandidates=function(b){n.get(b).success(function(b,d,f,e){void 0===b&&q.url("/error");void 0!=a.allEgGridApi&&(a.allEgGridApi.selection.clearSelectedRows(),a.allEgGridApi.core.refresh());a.allEgCandidates=[];_.each(b,function(b){a.allEgCandidates.push(b)});setUiGridDataForAllEgCandidates(a.allEgCandidates)}).error(function(a,b,f,e){0==b?alertify.error(msgNetworkDown):401===b?(console.log("Unauthorized"),UnauthorizedUserPrompt()):
65q.url("/error")})};var F=function(b){b="./ajax/recruiter/getAllActiveCandidates?page\x3d"+a.allEgCandidatesPagination.page+"\x26pageSize\x3d"+a.allEgCandidatesPagination.pageSize+"\x26filter\x3d"+encodeURIComponent(angular.toJson(b));a.getAllEgCandidates(b)},B=function(b){var c="./ajax/recruiter/getAllActiveCandidatesCount?filter\x3d"+encodeURIComponent(angular.toJson(b));n.get(c).success(function(c,f){a.allEgGridOptions.totalItems=c;0==a.allEgCandidatesPagination.page?F(b):a.allEgGridApi.pagination.seek(1)}).error(function(a,
66b){0==b?alertify.error(msgNetworkDown):401===b?UnauthorizedUserPrompt():q.url("/error")})};setAllEgCandidatesPostObj=function(a,c){a.name=c.shortlist.nameFilterTag;a.email=c.shortlist.emailFilterTag;c.shortlist.genderFilterTag.all?a.gender="all":c.shortlist.genderFilterTag.male&&!c.shortlist.genderFilterTag.female?a.gender="MALE":!c.shortlist.genderFilterTag.male&&c.shortlist.genderFilterTag.female&&(a.gender="FEMALE");a.location=[];0<c.shortlist.locationFilterTag.length&&(a.location=c.shortlist.locationFilterTag.split(",").map(function(a){return a.trim().toLowerCase()}));
67a.education=c.shortlist.educationFilterTag;var b=c.shortlist.skillsFilterTag;a.skills=[];0<b.length&&(a.skills=b.split(",").map(function(a){return a.trim().toLowerCase()}));a.certificates=c.shortlist.certificationFilterTag;a.noticePeriod=c.shortlist.npLessThanEqualToFilterTag;a.workExperienceFrom=null!=c.shortlist.wExperienceFromFilterTag?12*c.shortlist.wExperienceFromFilterTag:null;a.workExperienceTo=null!=c.shortlist.wExperienceToFilterTag?12*c.shortlist.wExperienceToFilterTag:null;a.sortBy=c.shortlist.sortBy};
68updateAllEgCandidatesFilterService=function(a,c){a.shortlist.nameFilterTag=c.shortlist.nameFilterTag;a.shortlist.emailFilterTag=c.shortlist.emailFilterTag;a.shortlist.genderFilterTag.male=c.shortlist.genderFilterTag.male;a.shortlist.genderFilterTag.female=c.shortlist.genderFilterTag.female;a.shortlist.genderFilterTag.all=c.shortlist.genderFilterTag.all;a.shortlist.locationFilterTag=c.shortlist.locationFilterTag;a.shortlist.educationFilterTag=c.shortlist.educationFilterTag;a.shortlist.skillsFilterTag=
69c.shortlist.skillsFilterTag;a.shortlist.certificationFilterTag=c.shortlist.certificationFilterTag;a.shortlist.npLessThanEqualToFilterTag=c.shortlist.npLessThanEqualToFilterTag;a.shortlist.wExperienceFromFilterTag=c.shortlist.wExperienceFromFilterTag;a.shortlist.wExperienceToFilterTag=c.shortlist.wExperienceToFilterTag;a.shortlist.sortBy=c.shortlist.sortBy};a.allEgCandidatesFilter.checkGenderFilter=function(){a.allEgCandidatesFilter.shortlist.genderFilterTag.male&&a.allEgCandidatesFilter.shortlist.genderFilterTag.female?
70a.allEgCandidatesFilter.shortlist.genderFilterTag.all=!0:(a.allEgCandidatesFilter.shortlist.genderFilterTag.all=!1,a.allEgCandidatesFilter.shortlist.genderFilterTag.male||a.allEgCandidatesFilter.shortlist.genderFilterTag.female||(a.allEgCandidatesFilter.shortlist.genderFilterTag.all=!0,a.allEgCandidatesFilter.shortlist.genderFilterTag.male=!0,a.allEgCandidatesFilter.shortlist.genderFilterTag.female=!0))};a.allEgCandidatesFilter.checkGenderFilterAll=function(){a.allEgCandidatesFilter.shortlist.genderFilterTag.all||
71(a.allEgCandidatesFilter.shortlist.genderFilterTag.all=!0);a.allEgCandidatesFilter.shortlist.genderFilterTag.male=!0;a.allEgCandidatesFilter.shortlist.genderFilterTag.female=!0};a.checkallEgCandidatesFilter=function(){var b="";(null!=a.allEgCandidatesFilter.shortlist.npLessThanEqualToFilterTag||""!=a.allEgCandidatesFilter.shortlist.npLessThanEqualToFilterTag)&&0>a.allEgCandidatesFilter.shortlist.npLessThanEqualToFilterTag&&(b="*Notice Period can't be less than zero.");(null!=a.allEgCandidatesFilter.shortlist.wExperienceFromFilterTag||
72""!=a.allEgCandidatesFilter.shortlist.wExperienceFromFilterTag)&&0>a.allEgCandidatesFilter.shortlist.wExperienceFromFilterTag&&(b="*Work Experience can't be less than zero.");(null!=a.allEgCandidatesFilter.shortlist.wExperienceToFilterTag||""!=a.allEgCandidatesFilter.shortlist.wExperienceToFilterTag)&&0>a.allEgCandidatesFilter.shortlist.wExperienceToFilterTag&&(b="*Work Experience can't be less than zero.");a.allEgCandidatesWarningMessage=b;return""==a.allEgCandidatesWarningMessage?!1:!0};a.updateAllEgFilterWithTags=
73function(b){a.allEgCandidatesFilter.shortlist.nameFilterTag=b.name;a.allEgCandidatesFilter.shortlist.emailFilterTag=b.email;a.allEgCandidatesFilter.shortlist.educationFilterTag=b.education;a.allEgCandidatesFilter.shortlist.certificationFilterTag=b.certificates;a.allEgCandidatesFilter.shortlist.npLessThanEqualToFilterTag=b.noticePeriod;a.allEgCandidatesFilter.shortlist.wExperienceFromFilterTag=null!=b.workExperienceFrom?Math.round(b.workExperienceFrom/12):null;a.allEgCandidatesFilter.shortlist.wExperienceToFilterTag=
74null!=b.workExperienceTo?Math.round(b.workExperienceTo/12):null;"all"==b.gender&&(a.allEgCandidatesFilter.shortlist.genderFilterTag.all=!0,a.allEgCandidatesFilter.shortlist.genderFilterTag.male=!0,a.allEgCandidatesFilter.shortlist.genderFilterTag.female=!0);a.allEgCandidatesFilter.shortlist.locationFilterTag="";for(i=0;i<b.location.length;i++)a.allEgCandidatesFilter.shortlist.locationFilterTag+=b.location[i],i<b.location.length-1&&(a.allEgCandidatesFilter.shortlist.locationFilterTag+=",");a.allEgCandidatesFilter.shortlist.skillsFilterTag=
75"";for(i=0;i<b.skills.length;i++)a.allEgCandidatesFilter.shortlist.skillsFilterTag+=b.skills[i],i<b.skills.length-1&&(a.allEgCandidatesFilter.shortlist.skillsFilterTag+=",");a.allEgCandidatesFilter.shortlist.sortBy=b.sortBy;updateAllEgCandidatesFilterService(h,a.allEgCandidatesFilter);setAllEgCandidatesPostObj(p,h);B(p);a.allEgCandidatesFilterTags=p;a.allEgCandidatesFilter.isFilterApplied=z()};
75a.getAllEgCandidatesInit=function(){var b=a.allEgCandidatesFilter;b.shortlist.nameFilterTag=h.shortlist.nameFilterTag;
76b.shortlist.emailFilterTag=h.shortlist.emailFilterTag;b.shortlist.genderFilterTag.male=h.shortlist.genderFilterTag.male;b.shortlist.genderFilterTag.female=h.shortlist.genderFilterTag.female;b.shortlist.genderFilterTag.all=h.shortlist.genderFilterTag.all;b.shortlist.locationFilterTag=h.shortlist.locationFilterTag;b.shortlist.educationFilterTag=h.shortlist.educationFilterTag;b.shortlist.skillsFilterTag=h.shortlist.skillsFilterTag;b.shortlist.certificationFilterTag=h.shortlist.certificationFilterTag;
77b.shortlist.npLessThanEqualToFilterTag=h.shortlist.npLessThanEqualToFilterTag;b.shortlist.wExperienceFromFilterTag=h.shortlist.wExperienceFromFilterTag;b.shortlist.wExperienceToFilterTag=h.shortlist.wExperienceToFilterTag;b.shortlist.sortBy=h.shortlist.sortBy;setAllEgCandidatesPostObj(p,h);a.allEgCandidatesFilterTags=p;a.allEgCandidatesFilter.isFilterApplied=z()};a.getAllEgCandidatesWithFilter=function(){updateAllEgCandidatesFilterService(h,a.allEgCandidatesFilter);setAllEgCandidatesPostObj(p,h);
78B(p);a.allEgCandidatesFilterTags=p;a.allEgCandidatesFilter.isFilterApplied=z();a.enableEgCandidates=!0};setUiGridDataForAllEgCandidates=function(b){a.allEgGridOptions.data=b;a.allEgGridOptions.exporterMenuPdf=!1;a.allEgGridOptions.enableGridMenu=!0;a.allEgGridOptions.enablePaginationControls=!0;a.allEgGridOptions.minimumColumnSize=100;a.allEgGridOptions.rowHeight=45;b=function(a,b,e,g,k){return void 0!=a&&null!=a&&void 0!=b&&null!=b?a.toLowerCase()==b.toLowerCase()?0:"average"==a.toLowerCase()?-1:
79"best"==a.toLowerCase()?1:"best"==b.toLowerCase()?-1:1:void 0!=a&&null!=a?-1:void 0!=b&&null!=b?1:0};a.allEgGridOptions.columnDefs=[];a.allEgGridOptions.columnDefs.push({name:"Candidate Name",type:"string",field:"name",enableFiltering:!0,minWidth:200,cellTooltip:!0,headerToolTip:"Candidate Name",enablePinning:!0,filter:{condition:function(a,b,e,g){a=a.replace(/\\./g,".");return-1<b.toLowerCase().indexOf(a.toLowerCase())||-1<e.entity.email.toLowerCase().indexOf(a.toLowerCase())?!0:!1}},cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center" title\x3d"{{COL_FIELD}}"\x3e\x3ca href\x3d"" title\x3d"Candidate\'s name. Click to go to candidate\'s profile." ng-if\x3d"(row.entity.appuserId !\x3d undefined) \x26\x26 (row.entity.appuserId !\x3d null)" ng-click\x3d"grid.appScope.goToCandidateProfile(row.entity.appuserId)"\x3e{{row.entity.name}}\x3c/a\x3e\x3cspan ng-if\x3d"(row.entity.appuserId \x3d\x3d undefined) || (row.entity.appuserId \x3d\x3d null)"\x3e{{row.entity.name}}\x3c/span\x3e\x3cbr\x3e\x3cspan title\x3d"Candidate\'s email" style\x3d"color:#999"\x3e{{row.entity.email}}\x3c/span\x3e\x3c/div\x3e\x3c/div\x3e'});
80a.allEgGridOptions.columnDefs.push({name:"Contact Details",type:"string",field:"contactNo",cellTooltip:!0,headerToolTip:"Contact Details",enablePinning:!0,filter:{condition:function(a,b,e,g){a=a.replace(/\\./g,".");return null!=e.entity.contactNumber&&-1<e.entity.contactNumber.toLowerCase().indexOf(a.toLowerCase())||null!=e.entity.skypeId&&-1<e.entity.skypeId.toLowerCase().indexOf(a.toLowerCase())?!0:!1}},cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center"\x3e\x3cdiv\x3e\x3cspan title\x3d"Conatct Number" \x3e{{COL_FIELD}} \x3c/span\x3e\x26nbsp;\x3cbr\x3e\x3cspan style\x3d"color:#999"\x3e\x3cdiv title\x3d"Skype Id" data-ng-show\x3d"row.entity.skypeId !\x3d null "\x3e{{row.entity.skypeId}}\x3c/div\x3e\x3c/span\x3e\x3c/div\x3e\x3c/div\x3e',
81visible:!0,enableFiltering:!0,minWidth:150});a.allEgGridOptions.columnDefs.push({name:"Location",field:"location",cellTooltip:!0,headerToolTip:"Location",cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center" title\x3d"{{COL_FIELD}}"\x3e{{COL_FIELD}}\x3c/div\x3e',visible:!0,enableFiltering:!0,minWidth:150});a.allEgGridOptions.columnDefs.push({name:"Work Experience",field:"totalExpInWords",cellTooltip:!0,headerToolTip:"Work Experience",cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center" title\x3d"{{COL_FIELD}}"\x3e{{COL_FIELD}}\x3c/div\x3e',
82visible:!0,enableFiltering:!0,minWidth:150});a.allEgGridOptions.columnDefs.push({name:"Skills",field:"skills",cellTooltip:!0,headerToolTip:"Skills",cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center" title\x3d"{{COL_FIELD}}"\x3e{{COL_FIELD}}\x3c/div\x3e',visible:!0,enableFiltering:!0,minWidth:150});a.allEgGridOptions.columnDefs.push({name:"Notice Period (In Days)",field:"currentNoticePeriod",cellTooltip:!0,headerToolTip:"Notice Period",cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center" title\x3d"{{COL_FIELD}}"\x3e\x3cspan ng-if\x3d"row.entity.currentNoticePeriod !\x3d \'null\'"\x3e{{COL_FIELD}}\x3c/span\x3e\x3c/div\x3e',
83visible:!0,enableFiltering:!0,minWidth:150});a.allEgGridOptions.columnDefs.push({name:"Resume",field:"resume",cellTooltip:!0,headerToolTip:"Resume",enableFiltering:!1,cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center" title\x3d"Resume"\x3e\x3ca ng-show\x3d"row.entity.resume !\x3d null \x26\x26 row.entity.resume.url !\x3d null \x26\x26 row.entity.resume.url !\x3d \'\'" href\x3d"" ng-click\x3d"grid.appScope.setEmbeddedRes
83ourceUrl(row.entity.resume.url, true)"\x3e\x3ci class\x3d"fa fa-file"\x3e\x3c/i\x3e\x3c/a\x3e\x3cspan ng-hide\x3d"row.entity.resume !\x3d null \x26\x26 row.entity.resume.url !\x3d null \x26\x26 row.entity.resume.url !\x3d \'\'"\x3eNA\x3c/span\x3e\x3c/div\x3e',
84visible:!0,minWidth:150});a.allEgGridOptions.columnDefs.push({name:"CTC",field:"currentAnnualSalary",cellToolTip:!0,headerToolTip:"CTC",cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center" title\x3d"{{COL_FIELD}}"\x3e{{COL_FIELD}}\x3c/div\x3e',visible:!0,enableFiltering:!0,minWidth:150});a.allEgGridOptions.columnDefs.push({name:"Aptitude",field:"skillScores.aptitudeScoreLabel",cellTooltip:!0,enableFiltering:!0,cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center"\x3e\x3cdiv class\x3d"progress"\x3e\x3cdiv class\x3d"best" role\x3d"progressbar" ng-if\x3d"COL_FIELD \x3d\x3d \'Best\'" style\x3d"width: {{grid.appScope.getSkillLabelValue(COL_FIELD)}}%;" aria-valuenow\x3d"{{grid.appScope.getSkillLabelValue(COL_FIELD)}}" aria-valuemin\x3d"0" aria-valuemax\x3d"100"\x3e{{COL_FIELD}}\x3c/div\x3e\x3cdiv class\x3d"good" role\x3d"progressbar" ng-if\x3d"COL_FIELD \x3d\x3d \'Good\'" style\x3d"width: {{grid.appScope.getSkillLabelValue(COL_FIELD)}}%;" aria-valuenow\x3d"{{grid.appScope.getSkillLabelValue(COL_FIELD)}}" aria-valuemin\x3d"0" aria-valuemax\x3d"100"\x3e{{COL_FIELD}}\x3c/div\x3e\x3cdiv class\x3d"average" role\x3d"progressbar" ng-if\x3d"COL_FIELD \x3d\x3d \'Average\'" style\x3d"width: {{grid.appScope.getSkillLabelValue(COL_FIELD)}}%;" aria-valuenow\x3d"{{grid.appScope.getSkillLabelValue(COL_FIELD)}}" aria-valuemin\x3d"0" aria-valuemax\x3d"100"\x3e{{COL_FIELD}}\x3c/div\x3e\x3cdiv class\x3d"progress-bar" role\x3d"progressbar" ng-if\x3d"COL_FIELD \x3d\x3d \'NA\'" style\x3d"width: {{grid.appScope.getSkillLabelValue(COL_FIELD)}}%;" aria-valuenow\x3d"{{grid.appScope.getSkillLabelValue(COL_FIELD)}}" aria-valuemin\x3d"0" aria-valuemax\x3d"100"\x3e{{COL_FIELD}}\x3c/div\x3e\x3c/div\x3e\x3c/div\x3e',
85visible:!0,minWidth:110,sortingAlgorithm:b});a.allEgGridOptions.columnDefs.push({name:"Communication",field:"skillScores.communicationScoreLabel",cellTooltip:!0,enableFiltering:!0,cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center"\x3e\x3cdiv class\x3d"progress"\x3e\x3cdiv class\x3d"best" role\x3d"progressbar" ng-if\x3d"COL_FIELD \x3d\x3d \'Best\'" style\x3d"width: {{grid.appScope.getSkillLabelValue(COL_FIELD)}}%;" aria-valuenow\x3d"{{grid.appScope.getSkillLabelValue(COL_FIELD)}}" aria-valuemin\x3d"0" aria-valuemax\x3d"100"\x3e{{COL_FIELD}}\x3c/div\x3e\x3cdiv class\x3d"good" role\x3d"progressbar" ng-if\x3d"COL_FIELD \x3d\x3d \'Good\'" style\x3d"width: {{grid.appScope.getSkillLabelValue(COL_FIELD)}}%;" aria-valuenow\x3d"{{grid.appScope.getSkillLabelValue(COL_FIELD)}}" aria-valuemin\x3d"0" aria-valuemax\x3d"100"\x3e{{COL_FIELD}}\x3c/div\x3e\x3cdiv class\x3d"average" role\x3d"progressbar" ng-if\x3d"COL_FIELD \x3d\x3d \'Average\'" style\x3d"width: {{grid.appScope.getSkillLabelValue(COL_FIELD)}}%;" aria-valuenow\x3d"{{grid.appScope.getSkillLabelValue(COL_FIELD)}}" aria-valuemin\x3d"0" aria-valuemax\x3d"100"\x3e{{COL_FIELD}}\x3c/div\x3e\x3cdiv class\x3d"progress-bar" role\x3d"progressbar" ng-if\x3d"COL_FIELD \x3d\x3d \'NA\'" style\x3d"width: {{grid.appScope.getSkillLabelValue(COL_FIELD)}}%;" aria-valuenow\x3d"{{grid.appScope.getSkillLabelValue(COL_FIELD)}}" aria-valuemin\x3d"0" aria-valuemax\x3d"100"\x3e{{COL_FIELD}}\x3c/div\x3e\x3c/div\x3e\x3c/div\x3e',
86visible:!0,minWidth:110,sortingAlgorithm:b});a.allEgGridOptions.columnDefs.push({name:"Coding",field:"skillScores.codingScoreLabel",cellTooltip:!0,enableFiltering:!0,cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center"\x3e\x3cdiv class\x3d"progress"\x3e\x3cdiv class\x3d"best" role\x3d"progressbar" ng-if\x3d"COL_FIELD \x3d\x3d \'Best\'" style\x3d"width: {{grid.appScope.getSkillLabelValue(COL_FIELD)}}%;" aria-valuenow\x3d"{{grid.appScope.getSkillLabelValue(COL_FIELD)}}" aria-valuemin\x3d"0" aria-valuemax\x3d"100"\x3e{{COL_FIELD}}\x3c/div\x3e\x3cdiv class\x3d"good" role\x3d"progressbar" ng-if\x3d"COL_FIELD \x3d\x3d \'Good\'" style\x3d"width: {{grid.appScope.getSkillLabelValue(COL_FIELD)}}%;" aria-valuenow\x3d"{{grid.appScope.getSkillLabelValue(COL_FIELD)}}" aria-valuemin\x3d"0" aria-valuemax\x3d"100"\x3e{{COL_FIELD}}\x3c/div\x3e\x3cdiv class\x3d"average" role\x3d"progressbar" ng-if\x3d"COL_FIELD \x3d\x3d \'Average\'" style\x3d"width: {{grid.appScope.getSkillLabelValue(COL_FIELD)}}%;" aria-valuenow\x3d"{{grid.appScope.getSkillLabelValue(COL_FIELD)}}" aria-valuemin\x3d"0" aria-valuemax\x3d"100"\x3e{{COL_FIELD}}\x3c/div\x3e\x3cdiv class\x3d"progress-bar" role\x3d"progressbar" ng-if\x3d"COL_FIELD \x3d\x3d \'NA\'" style\x3d"width: {{grid.appScope.getSkillLabelValue(COL_FIELD)}}%;" aria-valuenow\x3d"{{grid.appScope.getSkillLabelValue(COL_FIELD)}}" aria-valuemin\x3d"0" aria-valuemax\x3d"100"\x3e{{COL_FIELD}}\x3c/div\x3e\x3c/div\x3e\x3c/div\x3e',
87visible:!0,minWidth:110,sortingAlgorithm:b});a.allEgGridOptions.columnDefs.push({name:"Concept",field:"skillScores.conceptScoreLabel",cellTooltip:!0,enableFiltering:!0,cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center"\x3e\x3cdiv class\x3d"progress"\x3e\x3cdiv class\x3d"best" role\x3d"progressbar" ng-if\x3d"COL_FIELD \x3d\x3d \'Best\'" style\x3d"width: {{grid.appScope.getSkillLabelValue(COL_FIELD)}}%;" aria-valuenow\x3d"{{grid.appScope.getSkillLabelValue(COL_FIELD)}}" aria-valuemin\x3d"0" aria-valuemax\x3d"100"\x3e{{COL_FIELD}}\x3c/div\x3e\x3cdiv class\x3d"good" role\x3d"progressbar" ng-if\x3d"COL_FIELD \x3d\x3d \'Good\'" style\x3d"width: {{grid.appScope.getSkillLabelValue(COL_FIELD)}}%;" aria-valuenow\x3d"{{grid.appScope.getSkillLabelValue(COL_FIELD)}}" aria-valuemin\x3d"0" aria-valuemax\x3d"100"\x3e{{COL_FIELD}}\x3c/div\x3e\x3cdiv class\x3d"average" role\x3d"progressbar" ng-if\x3d"COL_FIELD \x3d\x3d \'Average\'" style\x3d"width: {{grid.appScope.getSkillLabelValue(COL_FIELD)}}%;" aria-valuenow\x3d"{{grid.appScope.getSkillLabelValue(COL_FIELD)}}" aria-valuemin\x3d"0" aria-valuemax\x3d"100"\x3e{{COL_FIELD}}\x3c/div\x3e\x3cdiv class\x3d"progress-bar" role\x3d"progressbar" ng-if\x3d"COL_FIELD \x3d\x3d \'NA\'" style\x3d"width: {{grid.appScope.getSkillLabelValue(COL_FIELD)}}%;" aria-valuenow\x3d"{{grid.appScope.getSkillLabelValue(COL_FIELD)}}" aria-valuemin\x3d"0" aria-valuemax\x3d"100"\x3e{{COL_FIELD}}\x3c/div\x3e\x3c/div\x3e\x3c/div\x3e',
88visible:!0,minWidth:110,sortingAlgorithm:b});a.allEgGridOptions.columnDefs.push({name:"Other Areas",field:"skillScores.otherScoreLabel",cellTooltip:!0,enableFiltering:!0,cellTemplate:'\x3cdiv class\x3d"ui-grid-cell-contents" align\x3d"center"\x3e\x3cdiv class\x3d"progress"\x3e\x3cdiv class\x3d"best" role\x3d"progressbar" ng-if\x3d"COL_FIELD \x3d\x3d \'Best\'" style\x3d"width: {{grid.appScope.getSkillLabelValue(COL_FIELD)}}%;" aria-valuenow\x3d"{{grid.appScope.getSkillLabelValue(COL_FIELD)}}" aria-valuemin\x3d"0" aria-valuemax\x3d"100"\x3e{{COL_FIELD}}\x3c/div\x3e\x3cdiv class\x3d"good" role\x3d"progressbar" ng-if\x3d"COL_FIELD \x3d\x3d \'Good\'" style\x3d"width: {{grid.appScope.getSkillLabelValue(COL_FIELD)}}%;" aria-valuenow\x3d"{{grid.appScope.getSkillLabelValue(COL_FIELD)}}" aria-valuemin\x3d"0" aria-valuemax\x3d"100"\x3e{{COL_FIELD}}\x3c/div\x3e\x3cdiv class\x3d"average" role\x3d"progressbar" ng-if\x3d"COL_FIELD \x3d\x3d \'Average\'" style\x3d"width: {{grid.appScope.getSkillLabelValue(COL_FIELD)}}%;" aria-valuenow\x3d"{{grid.appScope.getSkillLabelValue(COL_FIELD)}}" aria-valuemin\x3d"0" aria-valuemax\x3d"100"\x3e{{COL_FIELD}}\x3c/div\x3e\x3cdiv class\x3d"progress-bar" role\x3d"progressbar" ng-if\x3d"COL_FIELD \x3d\x3d \'NA\'" style\x3d"width: {{grid.appScope.getSkillLabelValue(COL_FIELD)}}%;" aria-valuenow\x3d"{{grid.appScope.getSkillLabelValue(COL_FIELD)}}" aria-valuemin\x3d"0" aria-valuemax\x3d"100"\x3e{{COL_FIELD}}\x3c/div\x3e\x3c/div\x3e\x3c/div\x3e',
89visible:!0,minWidth:110,sortingAlgorithm:b})};a.addEgCandidates=function(){var b=a.allEgGridApi.selection.getSelectedRows();angular.forEach(b,function(b){a.emails=""==a.emails||void 0==a.emails||null==a.emails?b.email:a.emails+("\n"+b.email)});a.closeAtsCandidatesModal()};a.getSkillLabelValue=function(a){return void 0==a||null==a?0:"best"==a.toLowerCase()?100:"good"==a.toLowerCase()?66:"average"==a.toLowerCase()?33:0};a.showEgCandidates=function(){0==a.enableEgCandidates&&(B(p),a.enableEgCandidates=
90!0)};
90a.setEmbeddedResourceUrl=function(b,c){if(void 0!=b&&null!=b){var d=b.split(".").pop().toLowerCase();if("doc"==d||"docx"==d||"xls"==d||"xlsx"==d)b="https://view.officeapps.live.com/op/embed.aspx?src\x3d"+b;a.embeddedResourceUrl=C.trustAsResourceUrl(b);c?a.showEmbeddedModalDiv=!0:a.showEmbeddedDiv=!0}else alertify.error("Invalid resource.")};a.copyToClipboard=function(a){a=encodeURI(a);var b=document.createElement("textarea");b.value=a;b.setAttribute("readonly",!0);b.style={position:"absolute",
91left:"-9999px"};document.body.appendChild(b);b.select();document.execCommand("copy");document.body.removeChild(b);alertify.success("Link copied to clipboard")};a.checkTestStatusFilter=function(){a.filterObject.testStatus.attempted&&a.filterObject.testStatus.pending?a.filterObject.testStatus.all=!0:(a.filterObject.testStatus.all=!1,a.filterObject.testStatus.attempted||a.filterObject.testStatus.pending||(a.filterObject.testStatus.all=!0,a.filterObject.testStatus.attempted=!0,a.filterObject.testStatus.pending=
92!0))};a.checkTestStatusFilterAll=function(){a.filterObject.testStatus.all?(a.filterObject.testStatus.attempted=!0,a.filterObject.testStatus.pending=!0):(a.filterObject.testStatus.all=!0,a.filterObject.testStatus.pending=!0,a.filterObject.testStatus.attempted=!0)};a.checkInviteStatusFilter=function(){a.filterObject.inviteStatus.cancelled&&a.filterObject.inviteStatus.confirm?a.filterObject.inviteStatus.all=!0:(a.filterObject.inviteStatus.all=!1,a.filterObject.inviteStatus.cancelled||a.filterObject.inviteStatus.confirm||
93(a.filterObject.inviteStatus.all=!0,a.filterObject.inviteStatus.cancelled=!0,a.filterObject.inviteStatus.confirm=!0))};a.checkInviteStatusFilterAll=function(){a.filterObject.inviteStatus.all||(a.filterObject.inviteStatus.all=!0);a.filterObject.inviteStatus.cancelled=!0;a.filterObject.inviteStatus.confirm=!0};a.updateFilterObjectWithTags=function(b){a.filterObject.email=b.email;a.filterObject.name=b.name;"all"==b.inviteStatus&&(a.filterObject.inviteStatus.all=!0,a.filterObject.inviteStatus.cancelled=
94!0,a.filterObject.inviteStatus.confirm=!0);"all"==b.testStatus&&(a.filterObject.testStatus.all=!0,a.filterObject.testStatus.pending=!0,a.filterObject.testStatus.attempted=!0);a.filterObject.isFilterApplied=a.checkFilterStatus();a.fetchInvitedCandidates()};a.updateFilterTags=function(){a.filterTagsObj.email=a.filterObject.email;a.filterTagsObj.name=a.filterObject.name;a.filterTagsObj.inviteStatus=a.filterObject.inviteStatus.all?"all":a.filterObject.inviteStatus.cancelled?"CANCELLED":"CONFIRM";a.filterTagsObj.testStatus=
95a.filterObject.testStatus.all?"all":a.filterObject.testStatus.pending?"PENDING":"ATTEMPTED"};a.checkFilterStatus=function(){return null!=a.filterTagsObj&&(null!=a.filterTagsObj.email||null!=a.filterTagsObj.name||null!=a.filterTagsObj.testStatus&&"all"!=a.filterTagsObj.testStatus||null!=a.filterTagsObj.inviteStatus&&"all"!=a.filterTagsObj.inviteStatus)?!0:!1};a.applyFilter=function(){a.showFilterBox=!1;a.updateFilterTags();a.filterObject.isFilterApplied=a.checkFilterStatus();a.fetchInvitedCandidates();
96a.select=!1};a.checkTestStatusFilterAll();a.checkInviteStatusFilterAll();a.goToCandidateReport=function(a){null!=a&&window.open("./#/candidatereport/"+a,"_blank")};a.inviteStudents=function(){var b=[],c=[];a.showExistingCand=!1;var d="",f="",g=[],k=a.sEmails,h=!1,l="",p=!0,q=0,r=0,v=!0,t=null;a.validationErrorMessage="";if("addEmails"==a.inviteStudentMode){if(null==k||0< !k.length){alertify.error("Please add email(s) to invite");return}k=k.replace(/ /g,"");k+=" ";for(i=0;i<k.length;i++)","==k[i]&&
97(h=!0),"\n"==k[i]||i==k.length-1?(1===b.length-c.length&&c.push(""),h&&(f=f.trim().substring(1,f.len),f.startsWith("+")?-1==c.indexOf(f)&&c.push(f):c.push(""),h=!1),d=d.trim(),/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,10})+$/.test(d)?-1==b.indexOf(d)&&b.push(d):0!=d.length&&g.push(d),f=d=""):h?f+=k[i]:d+=k[i];1===b.length-c.length&&c.push("");0!=g.length&&(a.validationErrorMessage="The following addresses are invalid\n",_.each(g,function(b){a.validationErrorMessage+=b+"\n"}),a.validationErrorMessage+=
98"Please correct them.",v=!1)}else{if(a.enableStudentManagementFeature&&!a.hasSMSubscription){alertify.error("You don't have active Student Management Subscription. Please buy plan to continue the service.");return}void 0!=a.selectedCourseName&&(l=a.selectedCourseName);void 0!=e.semesterOrYearDetails[a.selectedCourseName]&&(e.semesterOrYearDetails[a.selectedCourseName].isSemSystem?q=parseInt(a.selectedSemester):(r=parseInt(a.selectedYear),p=!1));""==l?(a.validationErrorMessage="Please select a course.\n",
99v=!1):e.semesterOrYearDetails[a.selectedCourseName].isSemSystem?0==q&&(a.validationErrorMessage="Please select semester.",v=!1):e.semesterOrYearDetails[a.selectedCourseName].isSemSystem||0!=r||(a.validationErrorMessage="Please select year.",v=!1);t=p?u.getCourseIdByCourseNSemester(l,q):u.getCourseIdByCourseNYear(l,r)}d={};d.testId=m;"addEmails"==a.inviteStudentMode?(d.emails=b,d.whatsappNumbers=c):d.courseId=t;a.isCustomTemplate&&(a.customMessage=$("#custMailBodySummernote").summernote("code"),a.customMessage=
100a.customMessage.replace(/&lt;/g,"\x3c"),a.customMessage=a.customMessage.replace(/&gt;/g,"\x3e"),d.customMessage=a.customMessage,d.customSubject=a.customSubject,d.customMailTitle=a.customMailTitle);a.showNewInviteTimings&&(a.overridenOpenTime>=a.overridenCloseTime&&(alertify.error("Closing time should be greater than opening time"),v=!1),d.testInviteOpenTime=a.overridenOpenTime,d.testInviteCloseTime=a.overridenCloseTime);a.enableCCorBCCmails&&(d.ccEmailId=a.ccEmailId,d.bccEmailId=a.bccEmailId);d.sendNormalLinks=
101a.sendNormalLinks;v&&(a.validationErrorMessage="",n.post("./ajax/recruiter/test/"+m+"/invite?skipStudentsWithLimitReached\x3d"+a.smObject.skipStudentsWithLimitReached,d).success(function(b,c,d,e){a.studentsWithMaxedOutTests=b.studentsWithMaxedTests;a.sendInviteResponse=b;a.emails="";a.sEmails="";0<a.studentsWithMaxedOutTests.length&&!a.smObject.skipStudentsWithLimitReached&&(a.hideIssueTable=!0)}).error(function(b,c,d,e){0==c?alertify.error(msgNetworkDown):c===CUSTOM_RESPONSE_STATUS.NoCreditLeft?
102(a.sendInviteResponse=b,swal({title:"You have used all your credit. Please get more credit."})):678===c?alertify.error("No candidates found to invite"):690===c?alertify.error(b):691===c?swal({title:"Your Student Management Subscription has expired."}):401===c?(console.log("Unauthorized"),UnauthorizedUserPrompt()):400===c?alertify.error(b):alertify.error(msgGeneralError)}))};a.changeCourseName=function(){a.semesterOrYearDetails[a.selectedCourseName].isSemSystem?a.selectedSemester=a.semesterOrYearDetails[a.selectedCourseName].semesters[0]:
103a.selectedYear=a.semesterOrYearDetails[a.selectedCourseName].years[0]};a.openStudentManagementPageBasedOnSelection=function(){var b=a.selectedCourseName,c=a.selectedYear,d=a.selectedSemester,f=e.semesterOrYearDetails[b].isSemSystem;null==b||void 0==b||""==b?window.open(ARCHIVES_URL_PREFIX+"/#/recruiter/student-management/home","_blank"):!f||null!=d&&void 0!=d&&""!=d?f||null!=c&&void 0!=c&&""!=c?(b=f?u.getCourseIdByCourseNSemester(b,d):u.getCourseIdByCourseNYear(b,c),window.open(ARCHIVES_URL_PREFIX+
104"/#/recruiter/student-management/class/"+b+"/students","_blank")):window.open(ARCHIVES_URL_PREFIX+"/#/recruiter/student-management/course/"+b+"/students","_blank"):window.open(ARCHIVES_URL_PREFIX+"/#/recruiter/student-management/course/"+b+"/students","_blank")};a.getTemplateList=function(){n.get("./ajax/ats/recruiter/customMailTemplate/list?source\x3dASSESSMENT").success(function(b,c,d,e){_.each(b,function(b){a.customMailTemplatesMap[b.title]=b;a.customMailTemplatesTitles.push(b.title)})}).error(function(a,
105c,d,e){0==c?alertify.error(msgNetworkDown):401===c?(console.log("Unauthorized"),UnauthorizedUserPrompt()):alertify.error(msgGeneralError)})};
105a.checkUseCustomTemplate=function(){a.isCustomTemplate&&0==a.customMailTemplatesTitles.length&&a.getTemplateList()};a.changeTemplate=function(b){var c=a.customMailTemplatesMap[b];null!=c?(a.customSubject=c.subject,a.customMessage=c.body,$("#custMailBodySummernote").summernote("code",a.customMessage),$("#custBulkMailBodySummernote").summernote("code",a.customMessage)):
106"Empty"==b&&(a.customSubject="",a.customMessage="",$("#custMailBodySummernote").summernote("code",""),$("#custBulkMailBodySummernote").summernote("code",""))};a.inviteCandidatesInBulk=function(){if(""==a.trackerId||""!=a.errorLog)alertify.error("Please upload a valid excel file.");else{var b={};b.testId=m;b.names=[];b.emails=[];b.invitedByNames=a.isEmailLessAttemptEnabled;b.excelTrackerId=a.trackerId;if(a.bulkUploadObj.enableCCorBCCmails)if(a.bulkUploadObj.ccEmailId||a.bulkUploadObj.bccEmailId){if(a.bulkUploadObj.ccEmailId&&
107!t.test(a.bulkUploadObj.ccEmailId)){alertify.error("Please Enter valid CC email");return}if(a.bulkUploadObj.bccEmailId&&!t.test(a.bulkUploadObj.bccEmailId)){alertify.error("Please Enter valid BCC email");return}b.ccEmailId=a.bulkUploadObj.ccEmailId;b.bccEmailId=a.bulkUploadObj.bccEmailId}else{alertify.error("Please Enter valid CC and/or BCC email ids");return}a.bulkUploadObj.isCustomTemplate&&(a.customMessage=$("#custBulkMailBodySummernote").summernote("code"),a.customMessage=a.customMessage.replace(/&lt;/g,
108"\x3c"),a.customMessage=a.customMessage.replace(/&gt;/g,"\x3e"),b.customMessage=a.customMessage,b.customSubject=a.customSubject,b.customMailTitle=a.customMailTitle);if(a.bulkUploadObj.showNewInviteTimings){if(a.overridenOpenTime>=a.overridenCloseTime){alertify.error("Closing time should be greater than opening time");return}b.testInviteOpenTime=a.overridenOpenTime;b.testInviteCloseTime=a.overridenCloseTime}b.sendNormalLinks=a.bulkUploadObj.sendNormalLinks;a.validationErrorMessage="";n.post("./ajax/recruiter/test/"+
109m+"/invite",b).success(function(b,d,e,g){a.sendInviteResponse=b;a.names="";$("#inviteInBulkModal").modal("hide");a.showProceedForBulkUpload=!1;a.showErrorLogAndCandidates=!1;a.candidatesToInviteHtml=null}).error(function(b,d,e,g){0==d?alertify.error(msgNetworkDown):d===CUSTOM_RESPONSE_STATUS.NoCreditLeft?(a.sendInviteResponse=b,swal({title:b})):401===d?(console.log("Unauthorized"),UnauthorizedUserPrompt()):690===d?alertify.error(b):691===d?swal({title:"Your Student Management Subscription has expired."}):
110400==d?alertify.error(b):alertify.error(msgGeneralError)})}};a.uploadTestInvitesExcel=function(b){null!=b&&("xlsx"!=b.name.split(".").pop().toLowerCase()?alertify.error("Only .xlsx format is allowed"):b.size>CLOUD_FILE_UPLOAD_LIMIT?alertify.error("This file is too large to upload. Maximum supported file size is "+CLOUD_FILE_UPLOAD_LIMIT/1048576+" MB."):(a.trackerId="",a.errorLog="",a.showProceedForBulkUpload=!1,a.showErrorLogAndCandidates=!0,$("#custBulkMailBodySummernote").summernote("code",a.customMessage),
111a.bulkUploadObj={},E.upload({url:"./ajax/recruiter/test/"+m+"/uploadInvitesExcel",file:b}).success(function(b,d,e,g){b=JSON.parse(b);a.trackerId=b.trackerId;a.candidatesToInviteHtml=C.trustAsHtml(b.candidateList)}).error(function(b,d,e,g){401===d&&(console.log("Unauthorized"),UnauthorizedUserPrompt());a.errorLog=b})))};a.openModal=function(a){$("#"+a).modal({backdrop:"static",keyboard:!1})};a.downloadSampleExcel=function(){a.sampleExcelData=a.isEmailLessAttemptEnabled?[{Index:"1",Email:"",Name:"CandidateName1"},
112{Index:"2",Email:"",Name:"CandidateName2"},{Index:"3",Email:"[email protected](Optional)",Name:"CandidateName3"}]:[{Index:"1",Email:"[email protected]",Name:"CandidateName1"},{Index:"2",Email:"[email protected]",Name:"CandidateName2(Optional)"},{Index:"3",Email:"[email protected]",Name:""}];alasql('SELECT * INTO XLSX("EG_Test_Invite_Upload_Format_'+m+'.xlsx",{headers:true}) FROM ?',[a.sampleExcelData])}};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.