Built files from Bizgaze WebServer
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1
  1. var Bizgaze;(function(n){let t;(function(t){let i;(function(t){let i;(function(i){class r extends Unibase.Platform.Core.BaseComponent{loaddata(i,r,u,f,e,o,s){var p=this,l=moment(i.replaceAll("/","-"),"DD/MM/YYYY").format("YYYY/MM/DD"),a=moment(r.replaceAll("/","-"),"DD/MM/YYYY").format("YYYY/MM/DD"),v=0,c=0,y=0,h;p.fileCacheHelper.loadJsFiles(["apps/hrms/components/leavetype.js","apps/hrms/managers/leavemanager.js","apps/hrms/managers/leavemanager.js","apps/hrms/enums/leavetypes.js"],function(){n.Apps.Hrms.Managers.LeaveManager.Instance().getleavescountData(u,f).then(function(u){var p=0,w="";u.result!=null&&u.result!=""&&(w=u.result,p=u.result.totaldays);n.Apps.Hrms.Managers.LeaveManager.Instance().Getleavetypedata(f).then(function(n){var g,k,d,tt,it,rt,ut,ft,et,ot,st,ht,ct,lt,at,vt,yt,pt,wt,bt;if(n.result!=null&&n.result!=""){w=n.result;var ii=n.result.fromvalidity,ri=n.result.accuraldate,kt=n.result.mothname,tt=n.result.jan,it=n.result.feb,rt=n.result.mar,ut=n.result.apr,ft=n.result.may,et=n.result.jun,ot=n.result.jul,st=n.result.aug,ht=n.result.sep,ct=n.result.oct,lt=n.result.nov,at=n.result.dec,vt=n.result.jantojun,yt=n.result.jultodec,pt=n.result.jantoaprl,wt=n.result.maytoaug,bt=n.result.septodec}g=t.Enums.LeaveTypes.None;tt!=0||it!=0||rt!=0||ut!=0||ft!=0||et!=0||ot!=0||st!=0||ht!=0||ct!=0||lt!=0||at!=0?g=t.Enums.LeaveTypes.Monthly:vt!=0||yt!=0?g=t.Enums.LeaveTypes.HalfYearly:(pt!=0||wt!=0||bt!=0)&&(g=t.Enums.LeaveTypes.Quarterly);var dt=moment(l,"YYYY/MM/DD").year(),u=1+moment(l,"YYYY/MM/DD").month(),gt=moment(l,"YYYY/MM/DD").date(),ni=moment(a,"YYYY/MM/DD").year(),f=1+moment(a,"YYYY/MM/DD").month(),ti=moment(a,"YYYY/MM/DD").date(),ui=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"].indexOf(kt);if(r=new Date(a),i=new Date(l),r<i)return 0;k=i.getDay();d=r.getDay();k=k==0?7:k;d=d==0?7:d;k>5&&d>5&&(y=1);k=k>5?5:k;d=d>5?5:d;v=Math.floor((r.getTime()-i.getTime())/6048e5);k<d&&(c=v*5+(d-k));dt==ni&&u==f&&gt==ti?k==d&&(c=0):i!=r?k==d?c=5-(k-d):k!=d&&(c=(v+1)*5-(k-d)):c=(v+1)*5-(k-d);c-=y;h=c+1;p>0&&(h=h+p);$("#"+e).val(h);$("#"+s).val(h);var b=h+" Days",nt=Number($("#"+o).val());nt==1?g==t.Enums.LeaveTypes.Monthly?u==1&&f==1?(tt=n.result.jan,h<=tt?(alert("these days are applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(b)):(alert("these days are not applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(""))):u==2&&f==2?(it=n.result.feb,h<=it?(alert("these days are applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(b)):(alert("these days are not applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(""))):u==3&&f==3?(rt=n.result.mar,h<=rt?(alert("these days are applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(b)):(alert("these days are not applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(""))):u==4&&f==4?(ut=n.result.apr,h<=ut?(alert("these days are applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(b)):(alert("these days are not applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(""))):u==5&&f==5?(ft=n.result.may,h<=ft?(alert("these days are applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(b)):(alert("these days are not applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(""))):u==6&&f==6?(et=n.result.jun,h<=et?(alert("these days are applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(b)):(alert("these days are not applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(""))):u==7&&f==7?(ot=n.result.jul,h<=ot?(alert("these days are applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(b)):(alert("these days are not applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(""))):u==8&&f==8?(st=n.result.aug,h<=st?(alert("these days are applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(b)):(alert("these days are not applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(""))):u==9&&f==9?(ht=n.result.sep,h<=ht?(alert("these days are applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(b)):(alert("these days are not applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(""))):u==10&&f==10?(ct=n.result.oct,h<=ct?(alert("these days are applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(b)):(alert("these days are not applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(""))):u==11&&f==11?(lt=n.result.nov,h<=lt?(alert("these days are applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(b)):(alert("these days are not applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(""))):u==12&&f==12&&(at=n.result.dec,h<=at?(alert("these days are applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(b)):(alert("these days are not applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(""))):g==t.Enums.LeaveTypes.HalfYearly?u==1||f<=6?(vt=n.result.jantojun,h<=vt?(alert("these days are applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(b)):(alert("these days are not applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(""))):(u==7||f<=12)&&(yt=n.result.jultodec,h<=yt?(alert("these days are applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(b)):(alert("these days are not applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(""))):g==t.Enums.LeaveTypes.Quarterly&&(u==1||f<=4?(pt=n.result.jantoaprl,h<=pt?(alert("these days are applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(b)):(alert("these days are not applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(""))):u==5||f<=8?(wt=n.result.maytoaug,h<=wt?(alert("these days are applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(b)):(alert("these days are not applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(""))):u==9||f<=12?(bt=n.result.septodec,h<=bt?(alert("these days are applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(b)):(alert("these days are not applicable for this month"),$("#divSectionProperties_Totalcountdays_ActionProperty").html(""))):alert("these days are not applicable for this month")):nt==2?$("#divSectionProperties_Totalcountdays_ActionProperty").html("Hourly"):nt==3?$("#divSectionProperties_Totalcountdays_ActionProperty").html("QuaterDay"):nt==4&&$("#divSectionProperties_Totalcountdays_ActionProperty").html("HalfDay")})})})}static Instance(){return this._instance===undefined&&(this._instance=new r),this._instance}}i.Leaves=r})(i=t.Components||(t.Components={}))})(i=t.Hrms||(t.Hrms={}))})(t=n.Apps||(n.Apps={}))})(Bizgaze||(Bizgaze={}));