Iniit
This commit is contained in:
commit
b6c4e025bc
5124 files changed
+1153349
No files matched your search
@@ -0,0 +1,309 @@
|
||||
var Bizgaze;
|
||||
(function (Bizgaze) {
|
||||
let Apps;
|
||||
(function (Apps) {
|
||||
let Hrms;
|
||||
(function (Hrms) {
|
||||
let Components;
|
||||
(function (Components) {
|
||||
class AttendanceRequest extends Unibase.Platform.Core.BaseComponent {
|
||||
init(formpropertyid, prop, callback) {
|
||||
}
|
||||
loadControl(containerid, prop) {
|
||||
let html = '';
|
||||
html = `<div class="card attendace_card_view d-none"><div class="card-header d-sm-block d-none"><div class="row text-dark"><div class="col-11"><div class="row"><div class="col-sm-2"></div><div class="col-sm-5"><div class="row"><div class="col-6">Check-in <span class="text-dark">*</span></div><div class="col-6">Check-out <span class="text-dark">*</span></div></div></div><div class="col-sm-2">Total Hours</div><div class="col-sm-3">Description</div></div></div><div class="col-1"></div></div></div><div class="card-body"><ul class="attendance_list"></ul><input type="hidden" id = "hdn_AttendanceRequestControl" class="value-control" value = "Bizgaze.Apps.Hrms.Components.AttendanceRequest.Instance().Attendancerequestobj();" ></div></div>`;
|
||||
$('#' + containerid).html(html);
|
||||
}
|
||||
loadControlSettings(controlsettingjson, formpropertyid) {
|
||||
return null;
|
||||
}
|
||||
loadPropertySettings(propertysettings, formpropertyid, DocPropertyName) {
|
||||
return null;
|
||||
}
|
||||
bindEditFormDetails(formpropertyid, propval, DocPropertyName) {
|
||||
var id = propval;
|
||||
let html = `<div class="row text-dark"><div class="col-sm-2"></div><div class="col-sm-5"><div class="row"><div class="col-6">Check-in <span class="text-dark">*</span></div><div class="col-6">Check-out <span class="text-dark">*</span></div></div></div><div class="col-sm-2">Total Hours</div><div class="col-sm-3">Description</div></div>;`;
|
||||
return html;
|
||||
}
|
||||
getEmployeeCheckinAndCheckout(employeeid, fromdate, todate) {
|
||||
debugger;
|
||||
var fdate = moment(fromdate.replaceAll("/", "-"), "DD-MM-YYYY").format("YYYY-MM-DD");
|
||||
var tdate = moment(todate.replaceAll("/", "-"), "DD-MM-YYYY").format("YYYY-MM-DD");
|
||||
if (tdate < fdate) {
|
||||
MessageHelper.Instance().showError("Todate cannot be lesser than Fromdate", 'div_ErrorMessage_' + $('#' + Unibase.Platform.Helpers.NavigationHelper.Instance().getLastContainerId()).find('#hf_FormId').val());
|
||||
}
|
||||
let Todatehf = moment(todate, "DD/MM/YYYY").format("YYYY/MM/DD");
|
||||
let Fromdatehf = moment(fromdate, "DD/MM/YYYY").format("YYYY/MM/DD");
|
||||
$(".hfdate_fromdate").val(Fromdatehf);
|
||||
$(".hfdate_todate").val(Todatehf);
|
||||
$(".attendace_card_view").removeClass("d-none");
|
||||
if ($("#div_FormName").text() == "Create Regularization") {
|
||||
this.fileCacheHelper.loadJsFile("apps/hrms/managers/attendencemanager.js", function () {
|
||||
Bizgaze.Apps.Hrms.Managers.AttendenceManager.Instance().getEmployeeCheckinAndCheckout(employeeid, fdate, tdate).then(function (response) {
|
||||
$('.attendance_list').html('');
|
||||
const datestotal = [];
|
||||
function getDates(startDate, endDate) {
|
||||
const dates = [];
|
||||
let currentDate = startDate;
|
||||
const addDays = function (days) {
|
||||
const date = new Date(this.valueOf());
|
||||
date.setDate(date.getDate() + days);
|
||||
return date;
|
||||
};
|
||||
while (currentDate <= endDate) {
|
||||
dates.push(currentDate);
|
||||
currentDate = addDays.call(currentDate, 1);
|
||||
}
|
||||
return dates;
|
||||
}
|
||||
let totaldates, html_content = '';
|
||||
const dates = getDates(new Date(fdate), new Date(tdate));
|
||||
dates.forEach(function (date) {
|
||||
datestotal.push(date);
|
||||
});
|
||||
totaldates = datestotal;
|
||||
for (let j = 0; j < totaldates.length; j++) {
|
||||
let selecteddates = totaldates[j];
|
||||
let datesbetween = moment(selecteddates).format("YYYY-MM-DD");
|
||||
let displaydate = moment(selecteddates).format('llll');
|
||||
displaydate = displaydate.substring(0, 17);
|
||||
html_content = `<li class="row align-items-center text-dark py-2 border-bottom datesbetween" id='` + datesbetween + `'>
|
||||
<div class="col-sm-11 col-11"><div class="row">
|
||||
<div class="col-sm-2 text-left px-1">
|
||||
<div class="date font-weight-500">` + displaydate + `</div>
|
||||
</div> <div class="row"> <div class="col-3 hf_date">
|
||||
<input type ="hidden" class="hf_date" id = "hf_date" value=` + datesbetween + `></div></div>
|
||||
<div class="row"> <div class="col-3 hf_attendanceid">
|
||||
<input type ="hidden" class="hf_attendanceid" id = "hf_attendanceid" value="0"></div></div>
|
||||
<div class="row"> <div class="col-3 hf_regularizationapprovalid">
|
||||
<input type ="hidden" class="hf_regularizationapprovalid" id = "hf_regularizationapprovalid" value="0"></div></div>
|
||||
|
||||
<div class="col-sm-5">
|
||||
<div class="row">
|
||||
<div class="col-6 check_in"><input type="time" id="Check_in" class="Check_in_btn form-control datepicker-input hasDatepicker floating-label-control date_startdate hello" ></div>
|
||||
<div class="col-6 check_out"><input type="time" id="Check_out" class="Check_out_btn form-control type-control datepicker-input hasDatepicker floating-label-control date_startdate" ></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-sm-2 totaltime">00:00</div>
|
||||
<div class="col-sm-3 txt_Description">
|
||||
<input type ="text" class="form-control floating-label-control txt_Description" id="txt_Description" data-isdynamic="false" placeholder="Enter Description" data-placeholder="Description" data-label="Description" >
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-1 col-sm-1 text-right">
|
||||
<input type="checkbox" id="txt_checkbox" class="floating-label-control txt_checkbox hidden"></div>
|
||||
</li>`;
|
||||
$('.attendance_list').append(html_content);
|
||||
}
|
||||
if (response.result.length > 0) {
|
||||
for (var i = 0; i < response.result.length; i++) {
|
||||
var data = response.result[i];
|
||||
let attendanceid = data.AttendanceId, date = data, checkindate = Unibase.Platform.Helpers.DateTimeHelper.instance.formatLocalDateTime(data.CheckIn), checkindate_format = moment(data.Date).format("YYYY-MM-DD"), checkoutdate = Unibase.Platform.Helpers.DateTimeHelper.instance.formatLocalDateTime(data.CheckOut), totaltime = data.TotalMinutes, description = data.Description;
|
||||
let attendeddate = checkindate.substring(0, 10);
|
||||
if (checkindate.length != 0) {
|
||||
let ckeckintime = checkindate.substring(11, 16);
|
||||
let checkindates = moment(ckeckintime, 'HHmm').format("HH:mm");
|
||||
$("#" + checkindate_format).find(".check_in").html(`<input type="time" id="Check_in" class="Check_in_btn form-control datepicker-input hasDatepicker" value=` + checkindates + ` >`);
|
||||
}
|
||||
if (checkoutdate > checkindate) {
|
||||
if (checkoutdate.length != 0) {
|
||||
let ckeckouttime = checkoutdate.substring(11, 16);
|
||||
let checkoutdates = moment(ckeckouttime, 'HHmm').format("HH:mm");
|
||||
$("#" + checkindate_format).find(".check_out").html(`<input type="time" id="Check_out" class="Check_out_btn form-control datepicker-input hasDatepicker " value=` + checkoutdates + ` >`);
|
||||
}
|
||||
}
|
||||
if (description != null && description != "") {
|
||||
$("#" + checkindate_format).find(".txt_Description").html(`<input type="text" id="txt_Description" class="form-control" value=` + description + ` >`);
|
||||
}
|
||||
if (totaltime != 0) {
|
||||
var m = totaltime % 60;
|
||||
var h = (totaltime - m) / 60;
|
||||
var HHMM = (h < 10 ? "0" : "") + h.toString() + ":" + (m < 10 ? "0" : "") + m.toString();
|
||||
$("#" + checkindate_format).find(".totaltime").html(HHMM);
|
||||
}
|
||||
if (attendanceid != 0) {
|
||||
$("#" + checkindate_format).find(".hf_attendanceid").html(`<input type ="hidden" id="hf_attendanceid" class="form-control" value=` + attendanceid + ` >`);
|
||||
}
|
||||
}
|
||||
}
|
||||
$(".Check_out_btn,.Check_in_btn").change(function () {
|
||||
debugger;
|
||||
var checkin = $(this).parents(".datesbetween").find("#Check_in").val();
|
||||
var checkout = $(this).parents(".datesbetween").find("#Check_out").val();
|
||||
var start = new Date("01/01/2007 " + checkin).getTime();
|
||||
var end = new Date("01/01/2007 " + checkout).getTime();
|
||||
let difference = Math.abs(end - start);
|
||||
difference = difference / 1000;
|
||||
let hourDifference = Math.floor(difference / 3600);
|
||||
difference -= hourDifference * 3600;
|
||||
let minuteDifference = Math.floor(difference / 60);
|
||||
difference -= minuteDifference * 60;
|
||||
var value = (hourDifference < 10 ? "0" : "") + hourDifference.toString() + ":" + (minuteDifference < 10 ? "0" : "") + minuteDifference.toString();
|
||||
$(this).parents(".datesbetween").find(".totaltime").html(value);
|
||||
});
|
||||
});
|
||||
});
|
||||
}
|
||||
else {
|
||||
this.fileCacheHelper.loadJsFile("apps/hrms/managers/attendencemanager.js", function () {
|
||||
Bizgaze.Apps.Hrms.Managers.AttendenceManager.Instance().getRegularizationCheckinAndCheckout(employeeid, fdate, tdate).then(function (response) {
|
||||
$('.attendance_list').html('');
|
||||
const datestotal = [];
|
||||
function getDates(startDate, endDate) {
|
||||
const dates = [];
|
||||
let currentDate = startDate;
|
||||
const addDays = function (days) {
|
||||
const date = new Date(this.valueOf());
|
||||
date.setDate(date.getDate() + days);
|
||||
return date;
|
||||
};
|
||||
while (currentDate <= endDate) {
|
||||
dates.push(currentDate);
|
||||
currentDate = addDays.call(currentDate, 1);
|
||||
}
|
||||
return dates;
|
||||
}
|
||||
let totaldates, html_content = '';
|
||||
const dates = getDates(new Date(fdate), new Date(tdate));
|
||||
dates.forEach(function (date) {
|
||||
datestotal.push(date);
|
||||
});
|
||||
totaldates = datestotal;
|
||||
for (let j = 0; j < totaldates.length; j++) {
|
||||
let selecteddates = totaldates[j];
|
||||
let datesbetween = moment(selecteddates).format("YYYY-MM-DD");
|
||||
let displaydate = moment(selecteddates).format('llll');
|
||||
displaydate = displaydate.substring(0, 17);
|
||||
html_content = `<li class="row align-items-center text-dark py-2 border-bottom datesbetween" id='` + datesbetween + `'>
|
||||
<div class="col-sm-11 col-11"><div class="row">
|
||||
<div class="col-sm-2 text-left px-1">
|
||||
<div class="date font-weight-500">` + displaydate + `</div>
|
||||
</div> <div class="row"> <div class="col-3 hf_date">
|
||||
<input type ="hidden" class="hf_date" id = "hf_date" value=` + datesbetween + `></div></div>
|
||||
<div class="row"> <div class="col-3 hf_attendanceid">
|
||||
<input type ="hidden" class="hf_attendanceid" id = "hf_attendanceid" value="0"></div></div>
|
||||
<div class="row"> <div class="col-3 hf_regularizationapprovalid">
|
||||
<input type ="hidden" class="hf_regularizationapprovalid" id = "hf_regularizationapprovalid" value="0"></div></div>
|
||||
|
||||
<div class="col-sm-5">
|
||||
<div class="row">
|
||||
<div class="col-6 check_in"><input type="time" id="Check_in" class="Check_in_btn form-control datepicker-input hasDatepicker floating-label-control date_startdate hello" ></div>
|
||||
<div class="col-6 check_out"><input type="time" id="Check_out" class="Check_out_btn form-control type-control datepicker-input hasDatepicker floating-label-control date_startdate" ></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-sm-2 totaltime">00:00</div>
|
||||
<div class="col-sm-3 txt_Description">
|
||||
<input type ="text" class="form-control floating-label-control txt_Description" id="txt_Description" data-isdynamic="false" placeholder="Enter Description" data-placeholder="Description" data-label="Description" >
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-1 col-sm-1 text-right">
|
||||
<input type="checkbox" id="txt_checkbox" class="floating-label-control txt_checkbox hidden"></div>
|
||||
</li>`;
|
||||
$('.attendance_list').append(html_content);
|
||||
}
|
||||
if (response.result.length > 0) {
|
||||
debugger;
|
||||
for (var i = 0; i < response.result.length; i++) {
|
||||
var data = response.result[i];
|
||||
let attendanceid = data.attendanceid, regularizationapprovalid = data.regularizationapprovalid, date = data, checkindate = Unibase.Platform.Helpers.DateTimeHelper.instance.formatLocalDateTime(data.checkin), checkindate_format = moment(data.date).format("YYYY-MM-DD"), checkoutdate = Unibase.Platform.Helpers.DateTimeHelper.instance.formatLocalDateTime(data.checkout), totaltime = data.totalminutes, description = data.description;
|
||||
let attendeddate = checkindate.substring(0, 10);
|
||||
if (checkindate.length != 0) {
|
||||
let ckeckintime = checkindate.substring(11, 16);
|
||||
let checkindates = moment(ckeckintime, 'HHmm').format("HH:mm");
|
||||
$("#" + checkindate_format).find(".check_in").html(`<input type="time" id="Check_in" class="Check_in_btn form-control datepicker-input hasDatepicker" value=` + checkindates + ` >`);
|
||||
}
|
||||
if (checkoutdate.length != 0) {
|
||||
let ckeckouttime = checkoutdate.substring(11, 16);
|
||||
let checkoutdates = moment(ckeckouttime, 'HHmm').format("HH:mm");
|
||||
$("#" + checkindate_format).find(".check_out").html(`<input type="time" id="Check_out" class="Check_out_btn form-control datepicker-input hasDatepicker " value=` + checkoutdates + ` >`);
|
||||
}
|
||||
if (description != null && description != "") {
|
||||
$("#" + checkindate_format).find(".txt_Description").html(`<input type="text" id="txt_Description" class="form-control" value=` + description + ` >`);
|
||||
}
|
||||
if (totaltime != 0) {
|
||||
var m = totaltime % 60;
|
||||
var h = (totaltime - m) / 60;
|
||||
var HHMM = (h < 10 ? "0" : "") + h.toString() + ":" + (m < 10 ? "0" : "") + m.toString();
|
||||
$("#" + checkindate_format).find(".totaltime").html(HHMM);
|
||||
}
|
||||
if (attendanceid != 0) {
|
||||
$("#" + checkindate_format).find(".hf_attendanceid").html(`<input type ="hidden" id="hf_attendanceid" class="form-control" value=` + attendanceid + ` >`);
|
||||
}
|
||||
if (regularizationapprovalid != 0) {
|
||||
$("#" + checkindate_format).find(".hf_regularizationapprovalid").html(`<input type ="hidden" id="hf_regularizationapprovalid" class="form-control" value=` + regularizationapprovalid + ` >`);
|
||||
}
|
||||
}
|
||||
}
|
||||
$(".Check_out_btn ,.Check_in_btn").change(function () {
|
||||
debugger;
|
||||
var checkin = $(this).parents(".datesbetween").find("#Check_in").val();
|
||||
var checkout = $(this).parents(".datesbetween").find("#Check_out").val();
|
||||
var start = new Date("01/01/2007 " + checkin).getTime();
|
||||
var end = new Date("01/01/2007 " + checkout).getTime();
|
||||
let difference = Math.abs(end - start);
|
||||
difference = difference / 1000;
|
||||
let hourDifference = Math.floor(difference / 3600);
|
||||
difference -= hourDifference * 3600;
|
||||
let minuteDifference = Math.floor(difference / 60);
|
||||
difference -= minuteDifference * 60;
|
||||
var value = (hourDifference < 10 ? "0" : "") + hourDifference.toString() + ":" + (minuteDifference < 10 ? "0" : "") + minuteDifference.toString();
|
||||
$(this).parents(".datesbetween").find(".totaltime").html(value);
|
||||
});
|
||||
if ($("#div_FormName").text() == "Regularization_ApprovedForm") {
|
||||
$(".txt_checkbox").removeClass("hidden");
|
||||
$(".Check_out_btn").attr("disabled", "disabled");
|
||||
$(".Check_in_btn").attr("disabled", "disabled");
|
||||
$(".dropdown_periodtypeid").attr("disabled", "disabled");
|
||||
$(".txtAutoComplete_employeeid").attr("disabled", "disabled");
|
||||
$(".date_fromdate").attr("disabled", "disabled");
|
||||
$(".date_todate").attr("disabled", "disabled");
|
||||
$(".calender_fromdate").addClass("hidden");
|
||||
$(".calender_todate").addClass("hidden");
|
||||
}
|
||||
});
|
||||
});
|
||||
}
|
||||
}
|
||||
Attendancerequestobj() {
|
||||
debugger;
|
||||
var attendanceRequest = new Array();
|
||||
$('.datesbetween').each(function (index) {
|
||||
var element = $(this);
|
||||
var date_nontz = element.find("#hf_date").val();
|
||||
var date_withtz = new Date(date_nontz.toString());
|
||||
var isApproved = $(this).find('.txt_checkbox').is(':checked');
|
||||
attendanceRequest.push({
|
||||
Date: date_withtz,
|
||||
Description: element.find('#txt_Description').val(),
|
||||
CheckIn: element.find('#Check_in').val(),
|
||||
CheckOut: element.find('#Check_out').val(),
|
||||
AttendanceId: Number(element.find('#hf_attendanceid').val()),
|
||||
RegularizationapprovalId: Number(element.find('#hf_regularizationapprovalid').val()),
|
||||
IsApproved: isApproved,
|
||||
});
|
||||
});
|
||||
return attendanceRequest;
|
||||
}
|
||||
regularizationapprove() {
|
||||
let detailContainer = $("._bizgaze_detail_container:visible");
|
||||
let refstatusId = (Unibase.Themes.Providers.Detail_Settings.Instance().InputParameters.filter(function (o) {
|
||||
return o.Key === "hf_" + Unibase.Themes.Providers.DetailHelper.installedAppId + "_refstatusid";
|
||||
})[0].Value);
|
||||
$(detailContainer).find('.DetailSetting_' + Unibase.Themes.Providers.DetailHelper.installedAppId + '_Approve').addClass('hidden');
|
||||
if (refstatusId != '3' && refstatusId != '5') {
|
||||
$(detailContainer).find('.DetailSetting_' + Unibase.Themes.Providers.DetailHelper.installedAppId + '_Approve').removeClass('hidden');
|
||||
}
|
||||
}
|
||||
static Instance() {
|
||||
if (this.instance === undefined) {
|
||||
this.instance = new AttendanceRequest();
|
||||
}
|
||||
return this.instance;
|
||||
}
|
||||
}
|
||||
Components.AttendanceRequest = AttendanceRequest;
|
||||
})(Components = Hrms.Components || (Hrms.Components = {}));
|
||||
})(Hrms = Apps.Hrms || (Apps.Hrms = {}));
|
||||
})(Apps = Bizgaze.Apps || (Bizgaze.Apps = {}));
|
||||
})(Bizgaze || (Bizgaze = {}));
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"attendancerequest.js","sourceRoot":"","sources":["attendancerequest.ts"],"names":[],"mappings":"AAAA,IAAU,OAAO,CA2LhB;AA3LD,WAAU,OAAO;IACb,IAAiB,IAAI,CAyLpB;IAzLD,WAAiB,IAAI;QACjB,IAAiB,IAAI,CAuLpB;QAvLD,WAAiB,IAAI;YACjB,IAAiB,UAAU,CAqL1B;YArLD,WAAiB,UAAU;gBACvB,MAAa,iBAAkB,SAAQ,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAC,aAAa;oBAGtE,IAAI,CAAC,cAAsB,EAAE,IAAgB,EAAE,QAAkB;oBAEjE,CAAC;oBACD,WAAW,CAAC,WAAgB,EAAE,IAAgB;wBAC1C,IAAI,IAAI,GAAG,EAAE,CAAA;wBACb,IAAI,GAAG,mpBAAmpB,CAAC;wBAC3pB,CAAC,CAAC,GAAG,GAAG,WAAW,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;oBAIpC,CAAC;oBACD,mBAAmB,CAAC,kBAA0B,EAAE,cAAsB;wBAClE,OAAO,IAAI,CAAC;oBAChB,CAAC;oBACD,oBAAoB,CAAC,gBAA0C,EAAE,cAAsB,EAAE,eAAuB;wBAC5G,OAAO,IAAI,CAAC;oBAChB,CAAC;oBACD,mBAAmB,CAAC,cAAsB,EAAE,OAAY,EAAE,eAAu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AAC,IAAI,CAAC,CAAC,OAAO,CAAC,eAAe,CAAC,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,GAAG,EAAE,CAAC;oCACvE,IAAI,QAAQ,GAAG,CAAC,CALine truncated
|
||||
@@ -0,0 +1,40 @@
|
||||
var Bizgaze;
|
||||
(function (Bizgaze) {
|
||||
let Apps;
|
||||
(function (Apps) {
|
||||
let Hrms;
|
||||
(function (Hrms) {
|
||||
let Components;
|
||||
(function (Components) {
|
||||
class AttendanceRequest_Settings {
|
||||
loadControlPropertiesHtml(controlpropList, container) {
|
||||
return ``;
|
||||
}
|
||||
bindPropertySettings(prop) {
|
||||
var propertySettings = prop.PropertySettings;
|
||||
return "";
|
||||
}
|
||||
savePropertySettings(prop) {
|
||||
var propertySettings = prop.PropertySettings;
|
||||
return "";
|
||||
}
|
||||
loadSettingHtml() {
|
||||
return null;
|
||||
}
|
||||
bindControlData(controldatajson) {
|
||||
return null;
|
||||
}
|
||||
SaveControlData(controldatajson) {
|
||||
return controldatajson;
|
||||
}
|
||||
static Instance() {
|
||||
if (this._instance === undefined)
|
||||
this._instance = new AttendanceRequest_Settings();
|
||||
return this._instance;
|
||||
}
|
||||
}
|
||||
Components.AttendanceRequest_Settings = AttendanceRequest_Settings;
|
||||
})(Components = Hrms.Components || (Hrms.Components = {}));
|
||||
})(Hrms = Apps.Hrms || (Apps.Hrms = {}));
|
||||
})(Apps = Bizgaze.Apps || (Bizgaze.Apps = {}));
|
||||
})(Bizgaze || (Bizgaze = {}));
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"attendancerequest.settings.js","sourceRoot":"","sources":["attendancerequest.settings.ts"],"names":[],"mappings":"AAAA,IAAU,OAAO,CAsChB;AAtCD,WAAU,OAAO;IACb,IAAiB,IAAI,CAoCpB;IApCD,WAAiB,IAAI;QACjB,IAAiB,IAAI,CAkCpB;QAlCD,WAAiB,IAAI;YACjB,IAAiB,UAAU,CAgC1B;YAhCD,WAAiB,UAAU;gBACvB,MAAa,0BAA0B;oBACnC,yBAAyB,CAAC,eAAsC,EAAE,SAAS;wBAEvE,OAAO,EAAE,CAAC;oBAEd,CAAC;oBACD,oBAAoB,CAAC,IAAgB;wBACjC,IAAI,gBAAgB,GAA6B,IAAI,CAAC,gBAAgB,CAAC;wBACvE,OAAO,EAAE,CAAC;oBACd,CAAC;oBACD,oBAAoB,CAAC,IAAgB;wBACjC,IAAI,gBAAgB,GAA6B,IAAI,CAAC,gBAAgB,CAAC;wBACvE,OAAO,EAAE,CAAC;oBACd,CAAC;oBACD,eAAe;wBACX,OAAO,IAAI,CAAC;oBAChB,CAAC;oBACD,eAAe,CAAC,eAAoB;wBAChC,OAAO,IAAI,CAAC;oBAChB,CAAC;oBACD,eAAe,CAAC,eAAoB;wBAChC,OAAO,eAAe,CAAC;oBAC3B,CAAC;oBAGD,MAAM,CAAC,QAAQ;wBACX,IAAI,IAAI,CAAC,SAAS,KAAK,SAAS;4BAC5B,IAAI,CAAC,SAAS,GAAG,IAAI,0BAA0B,EAAE,CAAC;wBACtD,OAAO,IAAI,CAAC,SAAS,CAAC;oBAC1B,CAAC;iBACJ;gBA9BY,qCAA0B,6BA8BtC,CAAA;YACL,CAAC,EAhCgB,UAAU,GAAV,eAAU,KAAV,eAAU,QAgC1B;QACL,CAAC,EAlCgB,IAAI,GAAJ,SAAI,KAAJ,SAAI,QAkCpB;IACL,CAAC,EApCgB,IAAI,GAAJ,YAAI,KAAJ,YAAI,QAoCpB;AACL,CAAC,EAtCS,OAAO,KAAP,OAAO,QAsChB"}
|
||||
File diff suppressed because it is too large.
Load diff
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"attendence.js","sourceRoot":"","sources":["attendence.ts"],"names":[],"mappings":";;;;;;;;;AAAA,IAAU,OAAO,CA+1BhB;AA/1BD,WAAU,OAAO;IACb,IAAiB,IAAI,CA61BpB;IA71BD,WAAiB,IAAI;QACjB,IAAiB,IAAI,CA21BpB;QA31BD,WAAiB,IAAI;YACjB,IAAiB,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AAQ,EAAE,MAAM,EAAE,YAAY,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAE,SAAS,EAAE,QAAQ,CAAC;wBAEpI,IAAI,MAAM,GAAG,OAAO,CAAC,QAAQ,CAAC,UAAU,CAAC,KAAK,CAAC,QAAQ,CAAC,WAAW,CAAC,SAAS,CAAC;wBAC9E,IAAI,QAAQ,GAAG,QAAQ,CAAC,WAAW,CAAC,IAAI,CAAC;wBAEzC,SAAS,WAAW;4BAChB,MAAM,GAAG,QAAQ,CAAC,cAAc,CAAC,QAAQ,CAAC,CAAC;4BAC3C,MAAM,GAAG,QAAQ,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC;4BACxC,IAAI,KAAK,GAAG,QAAQ,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC;4BAC7C,IAAI,OAAO,GAAG,MAAM,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;4BAEtC,MAAM,MAAM,GAAG,MAAM,CAAC,WAAW,CAAC;4BAClC,MAAM,KAAK,GAAG,MAAM,CAAC,UAAU,CAAC;4BAEhC,IAAI,KAAK,IAAI,MAAM,EAAE;gCACjB,MAAM,CAAC,KAAK,GAAG,Line truncated
|
||||
@@ -0,0 +1,40 @@
|
||||
var Bizgaze;
|
||||
(function (Bizgaze) {
|
||||
let Apps;
|
||||
(function (Apps) {
|
||||
let Hrms;
|
||||
(function (Hrms) {
|
||||
let Controls;
|
||||
(function (Controls) {
|
||||
class EmployeeLeaves_Settings {
|
||||
loadControlPropertiesHtml(controlpropList, container) {
|
||||
return ``;
|
||||
}
|
||||
bindPropertySettings(prop) {
|
||||
var propertySettings = prop.PropertySettings;
|
||||
return "";
|
||||
}
|
||||
savePropertySettings(prop) {
|
||||
var propertySettings = prop.PropertySettings;
|
||||
return "";
|
||||
}
|
||||
loadSettingHtml() {
|
||||
return null;
|
||||
}
|
||||
bindControlData(controldatajson) {
|
||||
return null;
|
||||
}
|
||||
SaveControlData(controldatajson) {
|
||||
return controldatajson;
|
||||
}
|
||||
static Instance() {
|
||||
if (this._instance === undefined)
|
||||
this._instance = new EmployeeLeaves_Settings();
|
||||
return this._instance;
|
||||
}
|
||||
}
|
||||
Controls.EmployeeLeaves_Settings = EmployeeLeaves_Settings;
|
||||
})(Controls = Hrms.Controls || (Hrms.Controls = {}));
|
||||
})(Hrms = Apps.Hrms || (Apps.Hrms = {}));
|
||||
})(Apps = Bizgaze.Apps || (Bizgaze.Apps = {}));
|
||||
})(Bizgaze || (Bizgaze = {}));
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"employeeleave.settings.js","sourceRoot":"","sources":["employeeleave.settings.ts"],"names":[],"mappings":"AACA,IAAU,OAAO,CAsChB;AAtCD,WAAU,OAAO;IACb,IAAiB,IAAI,CAoCpB;IApCD,WAAiB,IAAI;QACjB,IAAiB,IAAI,CAkCpB;QAlCD,WAAiB,IAAI;YACjB,IAAiB,QAAQ,CAgCxB;YAhCD,WAAiB,QAAQ;gBACrB,MAAa,uBAAuB;oBAChC,yBAAyB,CAAC,eAAsC,EAAE,SAAS;wBAEvE,OAAO,EAAE,CAAC;oBAEd,CAAC;oBACD,oBAAoB,CAAC,IAAgB;wBACjC,IAAI,gBAAgB,GAA6B,IAAI,CAAC,gBAAgB,CAAC;wBACvE,OAAO,EAAE,CAAC;oBACd,CAAC;oBACD,oBAAoB,CAAC,IAAgB;wBACjC,IAAI,gBAAgB,GAA6B,IAAI,CAAC,gBAAgB,CAAC;wBACvE,OAAO,EAAE,CAAC;oBACd,CAAC;oBACD,eAAe;wBACX,OAAO,IAAI,CAAC;oBAChB,CAAC;oBACD,eAAe,CAAC,eAAoB;wBAChC,OAAO,IAAI,CAAC;oBAChB,CAAC;oBACD,eAAe,CAAC,eAAoB;wBAChC,OAAO,eAAe,CAAC;oBAC3B,CAAC;oBAGD,MAAM,CAAC,QAAQ;wBACX,IAAI,IAAI,CAAC,SAAS,KAAK,SAAS;4BAC5B,IAAI,CAAC,SAAS,GAAG,IAAI,uBAAuB,EAAE,CAAC;wBACnD,OAAO,IAAI,CAAC,SAAS,CAAC;oBAC1B,CAAC;iBACJ;gBA9BY,gCAAuB,0BA8BnC,CAAA;YACL,CAAC,EAhCgB,QAAQ,GAAR,aAAQ,KAAR,aAAQ,QAgCxB;QACL,CAAC,EAlCgB,IAAI,GAAJ,SAAI,KAAJ,SAAI,QAkCpB;IACL,CAAC,EApCgB,IAAI,GAAJ,YAAI,KAAJ,YAAI,QAoCpB;AACL,CAAC,EAtCS,OAAO,KAAP,OAAO,QAsChB"}
|
||||
@@ -0,0 +1,144 @@
|
||||
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
||||
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
||||
return new (P || (P = Promise))(function (resolve, reject) {
|
||||
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
||||
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
||||
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
||||
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
||||
});
|
||||
};
|
||||
var Bizgaze;
|
||||
(function (Bizgaze) {
|
||||
let Apps;
|
||||
(function (Apps) {
|
||||
let Hrms;
|
||||
(function (Hrms) {
|
||||
let Controls;
|
||||
(function (Controls) {
|
||||
class EmployeeLeaves extends Unibase.Platform.Core.BaseComponent {
|
||||
constructor() {
|
||||
super(...arguments);
|
||||
this.availablebalance = 0;
|
||||
this.currentlybooked = "0";
|
||||
this.balanceleaves = 0;
|
||||
this.employeeid = 0;
|
||||
this.leavetypeid = 0;
|
||||
this.containerid = "";
|
||||
this.currentlybookedcount = 0;
|
||||
this.leavepolicyid = 0;
|
||||
}
|
||||
init(formpropertyid, prop, callback) {
|
||||
let instance = this;
|
||||
if (this.employeeid == 0 && this.leavetypeid == 0) {
|
||||
this.availablebalance = 0;
|
||||
this.currentlybooked = "0";
|
||||
this.currentlybookedcount = 0;
|
||||
this.balanceleaves = 0;
|
||||
this.leavepolicyid = 0;
|
||||
instance.loadControl(instance.containerid, null);
|
||||
}
|
||||
if (callback != null)
|
||||
callback();
|
||||
}
|
||||
loadControl(containerid, prop) {
|
||||
let instance = this;
|
||||
instance.todate1 = moment(new Date($.now())).format("DD/MM/YYYY");
|
||||
instance.yearlastdate = new Date(new Date().getFullYear(), 11, 31);
|
||||
instance.yearlastdate = moment(instance.yearlastdate).format("DD/MM/YYYY");
|
||||
instance.containerid = containerid;
|
||||
var html = `<table class="table"><thead><tr><div class="todate-date d-flex align-items-center"><th scope ="col">AS of ${instance.todate1}</th><th scope ="col">Day(s)</th></tr></thead></div><thead><tr><div class="dayscount-date d-flex align-items-center"><th scope ="col">Available Balance:</th><th scope ="col" id="availble">${instance.availablebalance}</th> </tr></thead></div><thead><tr><div class="totaldays-date d-flex align-items-center"><th scope ="col">Currently Booked:</th><th scope ="col">${instance.currentlybooked}</th></tr></thead></div><thead><tr><div class="total-date d-flex align-items-center"><th scope ="col">Balance After Booked Leave:</th><th scope ="col">${instance.balanceleaves}</th></tr></thead></div></table>
|
||||
<input type="hidden" id="hdn_employeeleavescountcontrol" class="value-control" value="Bizgaze.Apps.Hrms.Controls.EmployeeLeaves.Instance().employeeleavesControlObj();">`;
|
||||
$("#" + containerid).html(html);
|
||||
}
|
||||
getEmployeeAvailableLeaves(employeeid, leavetypeid) {
|
||||
let instance = this;
|
||||
instance.fileCacheHelper.loadJsFile("apps/hrms/managers/leavemanager.js", function () {
|
||||
Bizgaze.Apps.Hrms.Managers.LeaveManager.Instance().getleavescountData(Number(employeeid), Number(leavetypeid)).then(function (response) {
|
||||
if (response.result.length > 0) {
|
||||
var data = response.result;
|
||||
instance.leavepolicyid = data[0].leavepolicyid;
|
||||
instance.availablebalance = data[0].availableleaves;
|
||||
Bizgaze.Apps.Hrms.Controls.EmployeeLeaves.Instance().getCurrentlyBookedLeaves();
|
||||
instance.loadControl(instance.containerid, null);
|
||||
}
|
||||
});
|
||||
});
|
||||
}
|
||||
getCurrentlyBookedLeaves() {
|
||||
let instance = this;
|
||||
let fromdate = $(".hfdate_fromdate").val();
|
||||
let todate = $(".hfdate_todate").val();
|
||||
var firstDate = moment(fromdate);
|
||||
var secondDate = moment(todate);
|
||||
var leavefromdate = moment(fromdate).format("YYYY-MM-DD");
|
||||
var leavetodate = moment(todate).format("YYYY-MM-DD");
|
||||
var diffInDays = Math.abs(firstDate.diff(secondDate, 'days'));
|
||||
instance.fileCacheHelper.loadJsFile("apps/hrms/managers/holidaymanager.js", function () {
|
||||
Bizgaze.Apps.Hrms.Managers.HolidayManager.Instance().getHolidayDates(leavefromdate, leavetodate, instance.leavepolicyid).then(function (response) {
|
||||
var data = response.result;
|
||||
instance.currentlybooked = data + "(days)";
|
||||
instance.currentlybookedcount = data;
|
||||
instance.balanceleaves = instance.availablebalance - instance.currentlybookedcount;
|
||||
instance.loadControl(instance.containerid, null);
|
||||
});
|
||||
});
|
||||
}
|
||||
employeeleavesControlObj() {
|
||||
let instance = this;
|
||||
var EmployeeId = Number($(".txtAutoComplete_employeeid").val());
|
||||
var LeaveTypeId = Number($(".ddl_cascading_leavetypeid").val());
|
||||
if (instance.currentlybookedcount == 0 && EmployeeId != 0 && LeaveTypeId != 0) {
|
||||
MessageHelper.Instance().showError("Currently Booked Leaves Is Zero.Please check once.", 'div_ErrorMessage_' + $('#' + Unibase.Platform.Helpers.NavigationHelper.Instance().getLastContainerId()).find('#hf_FormId').val());
|
||||
return false;
|
||||
}
|
||||
}
|
||||
loadControlSettings(controlsettingjson, formpropertyid) {
|
||||
return null;
|
||||
}
|
||||
loadPropertySettings(propertysettings, formpropertyid, DocPropertyName) {
|
||||
return null;
|
||||
}
|
||||
bindEditFormDetails(formpropertyid, propval, DocPropertyName) {
|
||||
var instance = this;
|
||||
var leaverequestid = Number(propval);
|
||||
let employeeid;
|
||||
let leavetypeid;
|
||||
instance.fileCacheHelper.loadJsFiles(["apps/hrms/managers/leavemanager.js"], function () {
|
||||
return __awaiter(this, void 0, void 0, function* () {
|
||||
if ($("#div_FormName").text() == "Employee Leave Request") {
|
||||
yield Bizgaze.Apps.Hrms.Managers.LeaveManager.Instance().getLeaveRequest(leaverequestid).then(function (response) {
|
||||
var requsetdata = response.result;
|
||||
employeeid = requsetdata[0].employeeid;
|
||||
leavetypeid = requsetdata[0].leavetypeid;
|
||||
});
|
||||
}
|
||||
else {
|
||||
var InstalledAppId = Unibase.Themes.Providers.DetailHelper.installedAppId;
|
||||
employeeid = Unibase.Themes.Providers.Detail_Settings.Instance().InputParameters.find(x => x.Key == "hf_" + InstalledAppId + "_employeeid").Value;
|
||||
leavetypeid = Unibase.Themes.Providers.Detail_Settings.Instance().InputParameters.find(x => x.Key == "hf_" + InstalledAppId + "_leavetypeid").Value;
|
||||
}
|
||||
Bizgaze.Apps.Hrms.Managers.LeaveManager.Instance().getleavescountData(Number(employeeid), Number(leavetypeid)).then(function (response) {
|
||||
if (response.result.length > 0) {
|
||||
var data = response.result;
|
||||
instance.availablebalance = data[0].availableleaves + data[0].currentlybooked;
|
||||
instance.balanceleaves = data[0].balanceleaves;
|
||||
instance.currentlybookedcount = data[0].currentlybooked;
|
||||
instance.currentlybooked = data[0].currentlybooked + "(days)";
|
||||
instance.leavepolicyid = data[0].leavepolicyid;
|
||||
instance.loadControl(instance.containerid, null);
|
||||
}
|
||||
});
|
||||
});
|
||||
});
|
||||
}
|
||||
static Instance() {
|
||||
if (this._instance === undefined)
|
||||
this._instance = new EmployeeLeaves();
|
||||
return this._instance;
|
||||
}
|
||||
}
|
||||
Controls.EmployeeLeaves = EmployeeLeaves;
|
||||
})(Controls = Hrms.Controls || (Hrms.Controls = {}));
|
||||
})(Hrms = Apps.Hrms || (Apps.Hrms = {}));
|
||||
})(Apps = Bizgaze.Apps || (Bizgaze.Apps = {}));
|
||||
})(Bizgaze || (Bizgaze = {}));
|
||||
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"employeeleaves.js","sourceRoot":"","sources":["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IAAI,CAAC,QAAQ,CAAC,YAAY,CAAC,QAAQ,EAAE,CAAC,eAAe,CAAC,cAAc,CAAC,CAAC,IAAI,CAAC,UAAU,QAAQ;wCAE1G,IAAI,WAAW,GAAG,QAAQ,CAAC,MAAM,CAAC;wCAClC,UAAU,GAAG,WAAW,CAAC,CAAC,CAAC,CAAC,UAAU,CAAC;wCACvC,WAAW,GAAG,WAAW,CAAC,CAAC,CAAC,CAAC,WAAW,CAAC;oCAEhD,CAAC,CAAC,CAAC;iCACJ;qCACI;oCAEA,IAAI,cAAc,GAAG,OAAO,CAAC,MAAM,CAAC,SAAS,CAAC,YAAY,CAAC,cAAc,CAAC;oCACzE,UAAU,GAAG,OAAO,CAAC,MAAM,CAAC,SAAS,CAAC,eAAe,CAAC,QAAQ,EAAE,CAAC,eAAe,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,IAAI,KAAK,GAAG,cAAc,GAAG,aAAa,CAAC,CAAC,KAAK,CAAC;oCAClJ,WAAW,GAAG,OAAO,CAAC,MAAM,CAAC,SAAS,CAAC,eAAe,CAAC,QAAQ,EAAE,CAAC,eAAe,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,IAAI,KAAK,GAAG,cAAc,GAAG,cAAc,CAAC,CAAC,KAAK,CAAC;iCAEzJ;gCAEJ,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,QAAQ,CAAC,YAAY,CAAC,QAAQ,EAAE,CAAC,kBAAkB,CAAC,MAAM,CALine truncated
|
||||
@@ -0,0 +1,333 @@
|
||||
var Bizgaze;
|
||||
(function (Bizgaze) {
|
||||
let Apps;
|
||||
(function (Apps) {
|
||||
let Hrms;
|
||||
(function (Hrms) {
|
||||
let Components;
|
||||
(function (Components) {
|
||||
class Leaves extends Unibase.Platform.Core.BaseComponent {
|
||||
loaddata(fromdate, todate, employeeid, leavetypeid, totalDayPropertyId, durationProperyId, totaldaysleavehistoryProperyId) {
|
||||
var instance = this;
|
||||
var fdate = moment(fromdate.replaceAll("/", "-"), "DD/MM/YYYY").format("YYYY/MM/DD");
|
||||
var tdate = moment(todate.replaceAll("/", "-"), "DD/MM/YYYY").format("YYYY/MM/DD");
|
||||
var iWeeks = 0;
|
||||
var iDateDiff = 0;
|
||||
var iAdjust = 0;
|
||||
var dd;
|
||||
instance.fileCacheHelper.loadJsFiles(["apps/hrms/components/leavetype.js", "apps/hrms/managers/leavemanager.js", "apps/hrms/managers/leavemanager.js", "apps/hrms/enums/leavetypes.js"], function () {
|
||||
Bizgaze.Apps.Hrms.Managers.LeaveManager.Instance().getleavescountData(employeeid, leavetypeid).then(function (response) {
|
||||
var totaldays = 0;
|
||||
var result = "";
|
||||
if (response.result != null && response.result != "") {
|
||||
result = response.result;
|
||||
totaldays = response.result.totaldays;
|
||||
}
|
||||
Bizgaze.Apps.Hrms.Managers.LeaveManager.Instance().Getleavetypedata(leavetypeid).then(function (response) {
|
||||
if (response.result != null && response.result != "") {
|
||||
result = response.result;
|
||||
var fromvalidity = response.result.fromvalidity;
|
||||
var accuraldate = response.result.accuraldate;
|
||||
var mothname = response.result.mothname;
|
||||
var jan = response.result.jan;
|
||||
var feb = response.result.feb;
|
||||
var mar = response.result.mar;
|
||||
var apr = response.result.apr;
|
||||
var may = response.result.may;
|
||||
var jun = response.result.jun;
|
||||
var jul = response.result.jul;
|
||||
var aug = response.result.aug;
|
||||
var sep = response.result.sep;
|
||||
var oct = response.result.oct;
|
||||
var nov = response.result.nov;
|
||||
var dec = response.result.dec;
|
||||
var jantojun = response.result.jantojun;
|
||||
var jultodec = response.result.jultodec;
|
||||
var jantoaprl = response.result.jantoaprl;
|
||||
var maytoaug = response.result.maytoaug;
|
||||
var septodec = response.result.septodec;
|
||||
}
|
||||
var leaveType = Hrms.Enums.LeaveTypes.None;
|
||||
if (jan != 0 || feb != 0 || mar != 0 || apr != 0 || may != 0 || jun != 0 || jul != 0 || aug != 0 || sep != 0 || oct != 0 || nov != 0 || dec != 0) {
|
||||
leaveType = Hrms.Enums.LeaveTypes.Monthly;
|
||||
}
|
||||
else if (jantojun != 0 || jultodec != 0) {
|
||||
leaveType = Hrms.Enums.LeaveTypes.HalfYearly;
|
||||
}
|
||||
else if (jantoaprl != 0 || maytoaug != 0 || septodec != 0) {
|
||||
leaveType = Hrms.Enums.LeaveTypes.Quarterly;
|
||||
}
|
||||
var leavefromyear = moment(fdate, "YYYY/MM/DD").year();
|
||||
var leavefromonth = 1 + moment(fdate, "YYYY/MM/DD").month();
|
||||
var leavefromdate = moment(fdate, "YYYY/MM/DD").date();
|
||||
var leavetodateyear = moment(tdate, "YYYY/MM/DD").year();
|
||||
var leavetodatemonth = 1 + moment(tdate, "YYYY/MM/DD").month();
|
||||
var leavetodate = moment(tdate, "YYYY/MM/DD").date();
|
||||
var months = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"];
|
||||
var month = months.indexOf(mothname);
|
||||
todate = new Date(tdate);
|
||||
fromdate = new Date(fdate);
|
||||
if (todate < fromdate)
|
||||
return 0;
|
||||
var iWeekday1 = fromdate.getDay();
|
||||
var iWeekday2 = todate.getDay();
|
||||
iWeekday1 = (iWeekday1 == 0) ? 7 : iWeekday1;
|
||||
iWeekday2 = (iWeekday2 == 0) ? 7 : iWeekday2;
|
||||
if ((iWeekday1 > 5) && (iWeekday2 > 5))
|
||||
iAdjust = 1;
|
||||
iWeekday1 = (iWeekday1 > 5) ? 5 : iWeekday1;
|
||||
iWeekday2 = (iWeekday2 > 5) ? 5 : iWeekday2;
|
||||
iWeeks = Math.floor((todate.getTime() - fromdate.getTime()) / 604800000);
|
||||
if (iWeekday1 < iWeekday2) {
|
||||
iDateDiff = (iWeeks * 5) + (iWeekday2 - iWeekday1);
|
||||
}
|
||||
if ((leavefromyear == leavetodateyear) && (leavefromonth == leavetodatemonth) && (leavefromdate == leavetodate)) {
|
||||
if (iWeekday1 == iWeekday2) {
|
||||
iDateDiff = 0;
|
||||
}
|
||||
}
|
||||
else if (fromdate != todate) {
|
||||
if (iWeekday1 == iWeekday2) {
|
||||
iDateDiff = ((0 + 1) * 5) - (iWeekday1 - iWeekday2);
|
||||
}
|
||||
else if (iWeekday1 != iWeekday2) {
|
||||
iDateDiff = ((iWeeks + 1) * 5) - (iWeekday1 - iWeekday2);
|
||||
}
|
||||
}
|
||||
else {
|
||||
iDateDiff = ((iWeeks + 1) * 5) - (iWeekday1 - iWeekday2);
|
||||
}
|
||||
iDateDiff -= iAdjust;
|
||||
dd = iDateDiff + 1;
|
||||
if (totaldays > 0) {
|
||||
dd = dd + totaldays;
|
||||
}
|
||||
$("#" + totalDayPropertyId).val(dd);
|
||||
$("#" + totaldaysleavehistoryProperyId).val(dd);
|
||||
var FulDay = dd + " " + "Days";
|
||||
var HalfDay = "HalfDay";
|
||||
var QuaterDay = "QuaterDay";
|
||||
var Hourly = "Hourly";
|
||||
var duration = Number($("#" + durationProperyId).val());
|
||||
if (duration == 1) {
|
||||
if (leaveType == Hrms.Enums.LeaveTypes.Monthly) {
|
||||
if (leavefromonth == 1 && leavetodatemonth == 1) {
|
||||
var jan = response.result.jan;
|
||||
if (dd <= jan) {
|
||||
alert("these days are applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html(FulDay);
|
||||
}
|
||||
else {
|
||||
alert("these days are not applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html("");
|
||||
}
|
||||
}
|
||||
else if (leavefromonth == 2 && leavetodatemonth == 2) {
|
||||
var feb = response.result.feb;
|
||||
if (dd <= feb) {
|
||||
alert("these days are applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html(FulDay);
|
||||
}
|
||||
else {
|
||||
alert("these days are not applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html("");
|
||||
}
|
||||
}
|
||||
else if (leavefromonth == 3 && leavetodatemonth == 3) {
|
||||
var mar = response.result.mar;
|
||||
if (dd <= mar) {
|
||||
alert("these days are applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html(FulDay);
|
||||
}
|
||||
else {
|
||||
alert("these days are not applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html("");
|
||||
}
|
||||
}
|
||||
else if (leavefromonth == 4 && leavetodatemonth == 4) {
|
||||
var apr = response.result.apr;
|
||||
if (dd <= apr) {
|
||||
alert("these days are applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html(FulDay);
|
||||
}
|
||||
else {
|
||||
alert("these days are not applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html("");
|
||||
}
|
||||
}
|
||||
else if (leavefromonth == 5 && leavetodatemonth == 5) {
|
||||
var may = response.result.may;
|
||||
if (dd <= may) {
|
||||
alert("these days are applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html(FulDay);
|
||||
}
|
||||
else {
|
||||
alert("these days are not applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html("");
|
||||
}
|
||||
}
|
||||
else if (leavefromonth == 6 && leavetodatemonth == 6) {
|
||||
var jun = response.result.jun;
|
||||
if (dd <= jun) {
|
||||
alert("these days are applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html(FulDay);
|
||||
}
|
||||
else {
|
||||
alert("these days are not applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html("");
|
||||
}
|
||||
}
|
||||
else if (leavefromonth == 7 && leavetodatemonth == 7) {
|
||||
var jul = response.result.jul;
|
||||
if (dd <= jul) {
|
||||
alert("these days are applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html(FulDay);
|
||||
}
|
||||
else {
|
||||
alert("these days are not applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html("");
|
||||
}
|
||||
}
|
||||
else if (leavefromonth == 8 && leavetodatemonth == 8) {
|
||||
var aug = response.result.aug;
|
||||
if (dd <= aug) {
|
||||
alert("these days are applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html(FulDay);
|
||||
}
|
||||
else {
|
||||
alert("these days are not applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html("");
|
||||
}
|
||||
}
|
||||
else if (leavefromonth == 9 && leavetodatemonth == 9) {
|
||||
var sep = response.result.sep;
|
||||
if (dd <= sep) {
|
||||
alert("these days are applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html(FulDay);
|
||||
}
|
||||
else {
|
||||
alert("these days are not applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html("");
|
||||
}
|
||||
}
|
||||
else if (leavefromonth == 10 && leavetodatemonth == 10) {
|
||||
var oct = response.result.oct;
|
||||
if (dd <= oct) {
|
||||
alert("these days are applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html(FulDay);
|
||||
}
|
||||
else {
|
||||
alert("these days are not applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html("");
|
||||
}
|
||||
}
|
||||
else if (leavefromonth == 11 && leavetodatemonth == 11) {
|
||||
var nov = response.result.nov;
|
||||
if (dd <= nov) {
|
||||
alert("these days are applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html(FulDay);
|
||||
}
|
||||
else {
|
||||
alert("these days are not applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html("");
|
||||
}
|
||||
}
|
||||
else if (leavefromonth == 12 && leavetodatemonth == 12) {
|
||||
var dec = response.result.dec;
|
||||
if (dd <= dec) {
|
||||
alert("these days are applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html(FulDay);
|
||||
}
|
||||
else {
|
||||
alert("these days are not applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html("");
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (leaveType == Hrms.Enums.LeaveTypes.HalfYearly) {
|
||||
if (leavefromonth == 1 || leavetodatemonth <= 6) {
|
||||
var jantojun = response.result.jantojun;
|
||||
if (dd <= jantojun) {
|
||||
alert("these days are applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html(FulDay);
|
||||
}
|
||||
else {
|
||||
alert("these days are not applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html("");
|
||||
}
|
||||
}
|
||||
else if (leavefromonth == 7 || leavetodatemonth <= 12) {
|
||||
var jultodec = response.result.jultodec;
|
||||
if (dd <= jultodec) {
|
||||
alert("these days are applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html(FulDay);
|
||||
}
|
||||
else {
|
||||
alert("these days are not applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html("");
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (leaveType == Hrms.Enums.LeaveTypes.Quarterly) {
|
||||
if (leavefromonth == 1 || leavetodatemonth <= 4) {
|
||||
var jantoaprl = response.result.jantoaprl;
|
||||
if (dd <= jantoaprl) {
|
||||
alert("these days are applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html(FulDay);
|
||||
}
|
||||
else {
|
||||
alert("these days are not applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html("");
|
||||
}
|
||||
}
|
||||
else if (leavefromonth == 5 || leavetodatemonth <= 8) {
|
||||
var maytoaug = response.result.maytoaug;
|
||||
if (dd <= maytoaug) {
|
||||
alert("these days are applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html(FulDay);
|
||||
}
|
||||
else {
|
||||
alert("these days are not applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html("");
|
||||
}
|
||||
}
|
||||
else if (leavefromonth == 9 || leavetodatemonth <= 12) {
|
||||
var septodec = response.result.septodec;
|
||||
if (dd <= septodec) {
|
||||
alert("these days are applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html(FulDay);
|
||||
}
|
||||
else {
|
||||
alert("these days are not applicable for this month");
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html("");
|
||||
}
|
||||
}
|
||||
else {
|
||||
alert("these days are not applicable for this month");
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (duration == 2) {
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html(Hourly);
|
||||
}
|
||||
else if (duration == 3) {
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html(QuaterDay);
|
||||
}
|
||||
else if (duration == 4) {
|
||||
$("#divSectionProperties_Totalcountdays_ActionProperty").html(HalfDay);
|
||||
}
|
||||
});
|
||||
});
|
||||
});
|
||||
}
|
||||
static Instance() {
|
||||
if (this._instance === undefined)
|
||||
this._instance = new Leaves();
|
||||
return this._instance;
|
||||
}
|
||||
}
|
||||
Components.Leaves = Leaves;
|
||||
})(Components = Hrms.Components || (Hrms.Components = {}));
|
||||
})(Hrms = Apps.Hrms || (Apps.Hrms = {}));
|
||||
})(Apps = Bizgaze.Apps || (Bizgaze.Apps = {}));
|
||||
})(Bizgaze || (Bizgaze = {}));
|
||||
Executable
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"leaves.js","sourceRoot":"","sources":["leaves.ts"],"names":[],"mappings":"AAAA,IAAU,OAAO,CAkYhB;AAlYD,WAAU,OAAO;IACb,IAAiB,IAAI,CAgYpB;IAhYD,WAAiB,IAAI;QACjB,IAAiB,IAAI,CA8XpB;QA9XD,WAAiB,IAAI;YACjB,IAAiB,UAAU,CA4X1B;YA5XD,WAAiB,UAAU;gBAEvB,MAAa,MAAO,SAAQ,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAC,aAAa;oBAE3D,QAAQ,CAAC,QAAQ,EAAE,MAAM,EAAE,UAAU,EAAE,WAAW,EAAE,kBAAkB,EAAE,iBAAiB,EAAE,8BAA8B;wBAErH,IAAI,QAAQ,GAAG,IAAI,CAA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O,EAAE,GAAG,QAAQ,CAAC,OAAO,EAAE,CAAC,GAAG,SAAS,CAAC,CAAC;oCAEzE,IAAI,SAAS,GAAG,SAAS,EAAE;wCACvB,SAAS,GAAG,CAAC,MAAM,GAAG,CAAC,CAAC,GAAG,CAAC,SAAS,GAAG,SAAS,CAAC,CAAC;qCAEtD;oCACD,IAAI,CAAC,aAAa,IAAI,eAAe,CAAC,IAAG,CAAC,aAAa,IAAI,gBAAgB,CAAC,IAAI,CAAC,aAAa,IAAI,WAAW,CAAC,EAAC;wCAE3G,IAAI,SAAS,IAAI,SAAS,EAAE;4CACxB,SAAS,GAAG,CAAC,CAAC;yCACjB;qCACJ;yCACI,IAAI,QAAQ,IAAI,MAAM,EAAE;wCACzB,IAAI,SAAS,IAAI,SAAS,EAAE;4CACxB,SAAS,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC,GAAG,CAAC,SAAS,GAALine truncated
|
||||
+1
@@ -0,0 +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&>==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 mLine truncated
|
||||
@@ -0,0 +1,53 @@
|
||||
var Bizgaze;
|
||||
(function (Bizgaze) {
|
||||
let Apps;
|
||||
(function (Apps) {
|
||||
let Hrms;
|
||||
(function (Hrms) {
|
||||
let Components;
|
||||
(function (Components) {
|
||||
class LeavesTypes extends Unibase.Platform.Core.BaseComponent {
|
||||
loadForms(TenureName) {
|
||||
var FormName = TenureName;
|
||||
let FormUniquId = "";
|
||||
var instance = this;
|
||||
instance.fileCacheHelper.loadJsFiles(["apps/hrms/components/leavetype.js", "platform/forms/managers/formmanager.js"], function () {
|
||||
if (FormName == "Monthly") {
|
||||
FormUniquId = "Bizgaze_Extension_HRMs_Forms_MONTHS";
|
||||
}
|
||||
else if (FormName == "Half Yearly") {
|
||||
FormUniquId = "Bizgaze_Extension_HRMs_Forms_Half_Yearly";
|
||||
}
|
||||
else if (FormName == "Tri Annually") {
|
||||
FormUniquId = "Bizgaze_Extension_HRMs_Forms_Tri Annually";
|
||||
}
|
||||
else if (FormName == "Annually") {
|
||||
FormUniquId = "Bizgaze_Extension_HRMs_Forms_ANNUALLY";
|
||||
}
|
||||
Unibase.Platform.Forms.Managers.FormManager.Instance().getFormbyUniqueId(FormUniquId).then(function (response) {
|
||||
var data = response.result;
|
||||
var formid = data.FormId;
|
||||
var viewerobject = {
|
||||
FormId: formid,
|
||||
Pk_Value: 0,
|
||||
AppConfigurationId: 0,
|
||||
PortletWidgetId: 0,
|
||||
OnSuccess: null,
|
||||
OnLoad: null,
|
||||
OnFail: null,
|
||||
};
|
||||
Unibase.Platform.Forms.Components.FormViewer.Instance().init(viewerobject);
|
||||
});
|
||||
});
|
||||
}
|
||||
static Instance() {
|
||||
if (this._instance === undefined)
|
||||
this._instance = new LeavesTypes();
|
||||
return this._instance;
|
||||
}
|
||||
}
|
||||
Components.LeavesTypes = LeavesTypes;
|
||||
})(Components = Hrms.Components || (Hrms.Components = {}));
|
||||
})(Hrms = Apps.Hrms || (Apps.Hrms = {}));
|
||||
})(Apps = Bizgaze.Apps || (Bizgaze.Apps = {}));
|
||||
})(Bizgaze || (Bizgaze = {}));
|
||||
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"leavetype.js","sourceRoot":"","sources":["leavetype.ts"],"names":[],"mappings":"AACA,IAAU,OAAO,CAsDhB;AAtDD,WAAU,OAAO;IACb,IAAiB,IAAI,CAoDpB;IApDD,WAAiB,IAAI;QACjB,IAAiB,IAAI,CAkDpB;QAlDD,WAAiB,IAAI;YACjB,IAAiB,UAAU,CAgD1B;YAhDD,WAAiB,UAAU;gBACvB,MAAa,WAAY,SAAQ,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAC,aAAa;oBAEhE,SAAS,CAAC,UAAU;wBAEhB,IAAI,QAAQ,GAAG,UAAU,CAAC;wBAC1B,IAAI,WAAW,GAAG,EAAE,CAAC;wBACrB,IAAI,QAAQ,GAAG,IAAI,CAAC;wBACpB,QAAQ,CAAC,eAAe,CAAC,WAAW,CAAC,CAAC,mCAAmC,EAAE,wCAAwC,CAAC,EAAE;4BAClH,IAAI,QAAQ,IAAI,SAAS,EAAE;gCACvB,WAAW,GAAG,qCAAqC,CAAC;6BACvD;iCACI,IAAI,QAAQ,IAAI,aAAa,EAAE;gCAChC,WAAW,GAAG,0CAA0C,CAAC;6BAC5D;iCACI,IAAI,QAAQ,IAAI,cAAc,EAAE;gCACjC,WAAW,GAAG,2CAA2C,CAAC;6BAC7D;iCACI,IAAI,QAAQ,IAAI,UAAU,EAAE;gCAC7B,WAAW,GAAG,uCAAuC,CAAC;6BACzD;4BACD,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAC,QAAQ,CAAC,WAAW,CAAC,QAAQ,EAAE,CAAC,iBAAiB,CAAC,WAAW,CAAC,CAAC,IAAI,CAAC,UAAU,QAAQ;gCACzG,IAAI,IAAI,GAAG,QAAQ,CAAC,MAAM,CAAC;gCAC3B,IAAI,MAAM,GAAG,IAAI,CAAC,MAAM,CAAC;gCAEzB,IAAI,YAAY,GAAqD;oCACjE,MAAM,EAAE,MAAM;oCACd,QAAQ,EAAE,CAAC;oCACX,kBAAkB,EAAE,CAAC;oCAErB,eAAe,EAAE,CAAC;oCAClB,SAAS,EAAE,IAAI;oCACf,MAAM,EAAE,IAAI;oCACZ,MAAM,EAAE,IAAI;iCACf,CAAA;gCACD,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAC,UAAU,CAAC,UAAU,CAAC,QAAQ,EAAE,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC;4BAC/E,CAAC,CAAC,CAAC;wBAEP,CAAC,CAAC,CAAC;oBACP,CAAC;oBAGD,MAAM,CAAC,QAAQ;wBACX,IAAI,IAAI,CAAC,SAAS,KAAK,SAAS;4BAC5B,IAAI,CAAC,SAAS,GAAG,IAAI,WAAW,EAAE,CAAC;wBACvC,OAAO,IAAI,CAAC,SAAS,CAAC;oBAC1B,CAAC;iBACJ;gBA9CY,sBAAW,cA8CvB,CAAA;YACL,CAAC,EAhDgB,UAAU,GAAV,eAAU,KAAV,eAAU,QAgD1B;QACL,CAAC,EAlDgB,IAAI,GAAJ,SAAI,KAAJ,SAAI,QAkDpB;IACL,CAAC,EApDgB,IAAI,GAAJ,YAAI,KAAJ,YAAI,QAoDpB;AACL,CAAC,EAtDS,OAAO,KAAP,OAAO,QAsDhB"}
|
||||
@@ -0,0 +1,149 @@
|
||||
var Bizgaze;
|
||||
(function (Bizgaze) {
|
||||
let Apps;
|
||||
(function (Apps) {
|
||||
let Hrms;
|
||||
(function (Hrms) {
|
||||
let Components;
|
||||
(function (Components) {
|
||||
class LoanButton extends Unibase.Platform.Core.BaseComponent {
|
||||
cssFiles() {
|
||||
return [];
|
||||
}
|
||||
jsFiles() {
|
||||
return [''];
|
||||
}
|
||||
html(id, containerid) {
|
||||
return "";
|
||||
}
|
||||
init(containerid) {
|
||||
}
|
||||
load(loanid, containerid, callback) {
|
||||
}
|
||||
disburse() {
|
||||
debugger;
|
||||
let detailContainer = $("._bizgaze_detail_container:visible");
|
||||
let refstatusId = (Unibase.Themes.Providers.Detail_Settings.Instance().InputParameters.filter(function (o) {
|
||||
return o.Key === "hf_" + Unibase.Themes.Providers.DetailHelper.installedAppId + "_refstatusid";
|
||||
})[0].Value);
|
||||
let stage = (Unibase.Themes.Providers.Detail_Settings.Instance().InputParameters.filter(function (o) {
|
||||
return o.Key === "hf_" + Unibase.Themes.Providers.DetailHelper.installedAppId + "_stage";
|
||||
})[0].Value);
|
||||
$(detailContainer).find('.DetailSetting_' + Unibase.Themes.Providers.DetailHelper.installedAppId + '_Disburse').addClass('hidden');
|
||||
if (refstatusId == '3') {
|
||||
$(detailContainer).find('.DetailSetting_' + Unibase.Themes.Providers.DetailHelper.installedAppId + '_Disburse').removeClass('hidden');
|
||||
}
|
||||
var instance = this;
|
||||
$(detailContainer).find('.DetailSetting_' + Unibase.Themes.Providers.DetailHelper.installedAppId + '_Disburse').click(function () {
|
||||
let uniqueid = 'Bizgaze_Extension_HRMs_LoanDisbursal';
|
||||
Unibase.Platform.Helpers.FileCacheHelper.Instance().loadJsFiles(['platform/forms/managers/formmanager.js', 'platform/forms/components/formviewer/formviewer.js', 'platform/forms/requests/forms.js'], function () {
|
||||
Unibase.Platform.Forms.Managers.FormManager.Instance().getFormbyUniqueId(uniqueid).then(function (responce) {
|
||||
var formid = responce.result.FormId;
|
||||
var successobj = {
|
||||
CallBack: function () {
|
||||
var loanid = (Unibase.Themes.Providers.Detail_Settings.Instance().InputParameters.filter(function (o) {
|
||||
return o.Key === "hf_" + Unibase.Themes.Providers.DetailHelper.installedAppId + "_loanid";
|
||||
})[0].Value);
|
||||
instance.UpdateLoanStage(loanid);
|
||||
},
|
||||
Parameters: null,
|
||||
};
|
||||
var formviewerObj = {
|
||||
FormId: formid,
|
||||
AppConfigurationId: 0,
|
||||
Pk_Value: 0,
|
||||
PortletWidgetId: 0,
|
||||
OnSuccess: successobj,
|
||||
OnFail: null,
|
||||
OnLoad: null,
|
||||
};
|
||||
Unibase.Platform.Forms.Components.FormViewer.Instance().init(formviewerObj);
|
||||
});
|
||||
});
|
||||
});
|
||||
$(detailContainer).find('.DetailSetting_' + Unibase.Themes.Providers.DetailHelper.installedAppId + '_Repayment').addClass('hidden');
|
||||
if (refstatusId == '4') {
|
||||
$(detailContainer).find('.DetailSetting_' + Unibase.Themes.Providers.DetailHelper.installedAppId + '_Repayment').removeClass('hidden');
|
||||
}
|
||||
$(detailContainer).find('.DetailSetting_' + Unibase.Themes.Providers.DetailHelper.installedAppId + '_Repayment').click(function () {
|
||||
let uniqueid = 'Bizgaze_Extension_HRMs_LoanRepayment';
|
||||
Unibase.Platform.Helpers.FileCacheHelper.Instance().loadJsFiles(['platform/forms/managers/formmanager.js', 'platform/forms/components/formviewer/formviewer.js', 'platform/forms/requests/forms.js'], function () {
|
||||
Unibase.Platform.Forms.Managers.FormManager.Instance().getFormbyUniqueId(uniqueid).then(function (res) {
|
||||
var formid = res.result.FormId;
|
||||
var successobj = {
|
||||
CallBack: function () {
|
||||
var portal = Unibase.Themes.Compact.Components.Details.Instance().loadPortlets(Unibase.Themes.Compact.Components.Details.Instance());
|
||||
var loanid = (Unibase.Themes.Providers.Detail_Settings.Instance().InputParameters.filter(function (o) {
|
||||
return o.Key === "hf_" + Unibase.Themes.Providers.DetailHelper.installedAppId + "_loanid";
|
||||
})[0].Value);
|
||||
},
|
||||
Parameters: null,
|
||||
};
|
||||
var formviewerObj = {
|
||||
FormId: formid,
|
||||
AppConfigurationId: 0,
|
||||
Pk_Value: 0,
|
||||
PortletWidgetId: 0,
|
||||
OnSuccess: successobj,
|
||||
OnFail: null,
|
||||
OnLoad: null,
|
||||
FormContainer: null,
|
||||
};
|
||||
Unibase.Platform.Forms.Components.FormViewer.Instance().init(formviewerObj);
|
||||
});
|
||||
});
|
||||
});
|
||||
}
|
||||
UpdateLoanStage(loanid) {
|
||||
var instance = this;
|
||||
var jsfiles = ['apps/hrms/components/loanbutton.js', 'apps/hrms/managers/loanmanager.js'];
|
||||
instance.fileCacheHelper.loadJsFiles(jsfiles, function (response) {
|
||||
Bizgaze.Apps.Hrms.Managers.LoanManager.Instance().UpdateLoanStage(loanid).then(function (response) {
|
||||
MessageHelper.Instance().showSuccess(response.message, '');
|
||||
var detailobj = Unibase.Themes.Compact.Components.Details.Instance();
|
||||
detailobj._recordId = Unibase.Themes.Providers.DetailHelper.recordId;
|
||||
detailobj._installedAppId = Unibase.Themes.Providers.DetailHelper.installedAppId;
|
||||
detailobj._containerId = instance.navigationHelper.getLastContainerId();
|
||||
var IdetailObj = detailobj;
|
||||
detailobj.loadPortlets(IdetailObj);
|
||||
instance.disburse();
|
||||
});
|
||||
});
|
||||
}
|
||||
saveAsDraft() {
|
||||
let instance = this;
|
||||
let InstalledAppId = Unibase.Platform.Forms.Components.FormViewer.instance.InstalledAppId;
|
||||
let RefStatusId = 1;
|
||||
Unibase.Platform.Apps.Managers.StageManager.Instance().getStagesByInstalledAppandRefStatus(InstalledAppId, RefStatusId).then(function (response) {
|
||||
const containerid = instance.navigationHelper.getLastContainerId();
|
||||
$("#" + containerid).find(".hdn_stageid").val(response.result.StageId);
|
||||
$("#" + containerid).find("#btnDynamicSave").click();
|
||||
});
|
||||
}
|
||||
calendar() {
|
||||
debugger;
|
||||
const dateFormat = moment().format("DD/MM/YYYY");
|
||||
$(".date_installmentstartdate").daterangepicker({
|
||||
startDate: dateFormat,
|
||||
autoUpdateInput: false,
|
||||
singleDatePicker: true,
|
||||
showDropdowns: true,
|
||||
minYear: 1901,
|
||||
minDate: dateFormat,
|
||||
locale: {
|
||||
format: 'DD/MM/YYYY',
|
||||
firstDay: 1,
|
||||
},
|
||||
});
|
||||
}
|
||||
static Instance() {
|
||||
if (this._instance === undefined)
|
||||
this._instance = new LoanButton();
|
||||
return this._instance;
|
||||
}
|
||||
}
|
||||
Components.LoanButton = LoanButton;
|
||||
})(Components = Hrms.Components || (Hrms.Components = {}));
|
||||
})(Hrms = Apps.Hrms || (Apps.Hrms = {}));
|
||||
})(Apps = Bizgaze.Apps || (Bizgaze.Apps = {}));
|
||||
})(Bizgaze || (Bizgaze = {}));
|
||||
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"loanbutton.js","sourceRoot":"","sources":["loanbutton.ts"],"names":[],"mappings":"AAAA,IAAU,OAAO,CA2IhB;AA3ID,WAAU,OAAO;IACb,IAAiB,IAAI,CAyIpB;IAzID,WAAiB,IAAI;QACjB,IAAiB,IAAI,CAuIpB;QAvID,WAAiB,IAAI;YACjB,IAAiB,UAAU,CAqI1B;YArID,WAAiB,UAAU;gBACvB,MAAa,UAAW,SAAQ,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAC,aAAa;oBAC/D,QAAQ;wBACJ,OAAO,EAAE,CAAC;oBACd,CAAC;oBACD,OAAO;wBACH,OAAO,CAAC,EAAE,CAAC,CAAC;oBAChB,CAAC;oBACD,IAAI,CAAC,EAAO,EAAE,WAAmB;wBAC7B,OAAO,EAAE,CAAC;oBACd,CAAC;oBACD,IAAI,CAAC,WAAW;oBAEhB,CAAC;oBACD,IAAI,CAAC,MAAW,EAAE,WAAmB,EAAE,QAAkB;oBAEzD,CAAC;oBACD,QAAQ;wBACJ,IAAI,eAAe,GAAG,CAAC,CAAC,oCAAoC,CAAC,CAAC;wBAC9D,IAAI,WAAW,GAAG,CAAC,OAAO,CAAC,MAAM,CAAC,SAAS,CAAC,eAAe,CAAC,QAAQ,EAAE,CAAC,eAAe,CAAC,MAAM,CAAC,UAAU,CAAC;4BACrG,OAAO,CAAC,CAAC,GAAG,KAAK,KAAK,GAAG,OAAO,CAAC,MAAM,CAAC,SAAS,CAAC,YAAY,CAAC,cAAc,GAAG,cAAc,CAAC;wBACnG,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAA;wBACZ,IAAI,KAAK,GAAG,CAAC,OAAO,CAAC,MAAM,CAAC,SAAS,CAAC,eAA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
let Apps;
|
||||
(function (Apps) {
|
||||
let Hrms;
|
||||
(function (Hrms) {
|
||||
let Components;
|
||||
(function (Components) {
|
||||
class ManualBalance extends Unibase.Platform.Core.BaseComponent {
|
||||
constructor() {
|
||||
super(...arguments);
|
||||
this.existingbalance = 0;
|
||||
this.newbalance = 0;
|
||||
this.reason = "";
|
||||
}
|
||||
init(formpropertyid, prop, callback) {
|
||||
var instance = this;
|
||||
instance.existingbalance = 0;
|
||||
instance.newbalance = 0;
|
||||
var employeeid = Unibase.Themes.Providers.DetailHelper.recordId;
|
||||
instance.getManualBalance(employeeid);
|
||||
if (callback != null) {
|
||||
callback();
|
||||
}
|
||||
}
|
||||
loadControl(containerid, prop) {
|
||||
var html = '<ul class="mt-10 align-items-center" id="Employee_ManualBalance">' +
|
||||
'<li class="list-group-item hidden" id="EmployeeManual_Balance">' +
|
||||
'<div class="row">' +
|
||||
'<div class="col-sm-2"><strong>Leave Type</strong></div>' +
|
||||
'<div class="col-sm-2"><strong>Date</strong></div>' +
|
||||
'<div class="col-sm-2"><strong>Existing Balance</strong></div>' +
|
||||
'<div class="col-sm-3"><strong>New Balance</strong></div>' +
|
||||
'<div class="col-sm-3"><strong>Reason</strong></div>' +
|
||||
'</div>' +
|
||||
'</li>' +
|
||||
'<li class="length-row" id="li_EmployeeManualBalance_Details">' +
|
||||
'</li>' +
|
||||
'<input type="hidden" id="hdn_EmployeeManualBalanceControl" class="value-control" value=" Bizgaze.Apps.Hrms.Components.ManualBalance.Instance().EmployeeManualBalanceobj();">' +
|
||||
'</ul>';
|
||||
$("#" + containerid).html(html);
|
||||
}
|
||||
loadControlSettings(controlsettingjson, formpropertyid) {
|
||||
return null;
|
||||
}
|
||||
loadPropertySettings(propertysettings, formpropertyid) {
|
||||
return null;
|
||||
}
|
||||
bindEditFormDetails(formpropertyid, propval, DocPropertyName) {
|
||||
var manualbalanceid = Number(propval);
|
||||
var instance = this;
|
||||
}
|
||||
getManualBalance(employeeid) {
|
||||
var instance = this;
|
||||
var jsfiles = ['apps/hrms/managers/leavemanager.js'];
|
||||
$(".EmployeeManaulBalance").remove();
|
||||
$("#div_employeealert").remove();
|
||||
instance.fileCacheHelper.loadJsFiles(jsfiles, function (response) {
|
||||
Bizgaze.Apps.Hrms.Managers.LeaveManager.Instance().getEmployeeExistingBalance(Number(employeeid)).then(function (response) {
|
||||
var dt = response.result;
|
||||
if (dt.length > 0) {
|
||||
for (var i = 0; i < dt.length; i++) {
|
||||
var data = dt[i];
|
||||
instance.EmployeeManualBalanceTemplate(data);
|
||||
}
|
||||
}
|
||||
else {
|
||||
$("#EmployeeManual_Balance").removeClass("hidden");
|
||||
$('#Employee_ManualBalance').after('<div class="alert alert-danger ma-0" id="div_employeealert"> No Data Found</div>');
|
||||
}
|
||||
});
|
||||
});
|
||||
}
|
||||
EmployeeManualBalanceTemplate(data) {
|
||||
let instance = this;
|
||||
let manualdate = moment(new Date($.now())).format("DD/MM/YYYY");
|
||||
var html = '<li class="list-group-item EmployeeManaulBalance" id="li_EmployeeManaulBalance_">' +
|
||||
'<div class="row">' +
|
||||
'<input type ="hidden" class="hf_employeeid" value = "' + data.userid + '" id = "employeeid" />' +
|
||||
'<input type ="hidden" class="hf_leavetypeid" value = "' + data.leavetypeid + '" id ="leavetypeid" /> ' +
|
||||
'<input type ="hidden" class="hf_existingbalance" value = "' + data.availableleaves + '" id ="existingbalance" /> ' +
|
||||
'<input type ="hidden" class="hf_manualbalancedate" value = "' + manualdate + '" id ="manualbalancedate" />' +
|
||||
'<div class="col-sm-2" id="txt_leavetypename"> ' + data.leavetypename + ' </div>' +
|
||||
'<div class="col-sm-2" id="manualbalancedate" > ' + manualdate + ' </div>' +
|
||||
'<div class="col-sm-2" id="txt_existingbalance" > ' + data.availableleaves + ' </div>' +
|
||||
'<div class="col-sm-3" ><input type ="number" class="form-control floating-label-control txt_newbalance" id="txt_newbalance" data-isdynamic="false" placeholder="New Balance" data-placeholder="Please Enter New Balance" data-label="New Balance" ></div >' + '<div class="col-sm-3" ><input type ="text" class="form-control floating-label-control txt_reason" id="txt_Reason" data-isdynamic="false" placeholder="Reason" data-placeholder="Please Enter Reason" data-label="Reason"></div >' +
|
||||
'</div></li>';
|
||||
$("#EmployeeManual_Balance").removeClass("hidden");
|
||||
$("#li_EmployeeManualBalance_Details").after(html);
|
||||
}
|
||||
EmployeeManualBalanceobj() {
|
||||
var employeeManualBlance = new Array();
|
||||
$('.EmployeeManaulBalance').each(function (index) {
|
||||
var element = $(this);
|
||||
employeeManualBlance.push({
|
||||
EmployeeId: Number(element.find('.hf_employeeid').val()),
|
||||
LeaveTypeId: Number(element.find('.hf_leavetypeid').val()),
|
||||
ExistingBalance: Number(element.find('.hf_existingbalance').val()),
|
||||
ManualBalanceDate: new Date(moment(element.find(".hf_manualbalancedate").val(), "DD/MM/YYYY").format("YYYY/MM/DD")),
|
||||
NewBalance: Number(element.find('.txt_newbalance').val()),
|
||||
Reason: element.find('.txt_reason').val()
|
||||
});
|
||||
});
|
||||
return employeeManualBlance;
|
||||
}
|
||||
static Instance() {
|
||||
if (this.instance === undefined)
|
||||
this.instance = new ManualBalance();
|
||||
return this.instance;
|
||||
}
|
||||
}
|
||||
Components.ManualBalance = ManualBalance;
|
||||
})(Components = Hrms.Components || (Hrms.Components = {}));
|
||||
})(Hrms = Apps.Hrms || (Apps.Hrms = {}));
|
||||
})(Apps = Bizgaze.Apps || (Bizgaze.Apps = {}));
|
||||
})(Bizgaze || (Bizgaze = {}));
|
||||
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"manualbalance.js","sourceRoot":"","sources":["manualbalance.ts"],"names":[],"mappings":";;;;;;;;;AAEA,IAAU,OAAO,CA8IhB;AA9ID,WAAU,OAAO;IACb,IAAiB,IAAI,CA4IpB;IA5ID,WAAiB,IAAI;QACjB,IAAiB,IAAI,CA0IpB;QA1ID,WAAiB,IAAI;YACjB,IAAiB,UAAU,CAuI1B;YAvID,WAAiB,UAAU;gBACvB,MAAa,aAAc,SAAQ,OAAO,C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ACX,IAAI,IAAI,CAAC,QAAQ,KAAK,SAAS;4BAC3B,IAAI,CAAC,QAAQ,GAAG,IAAI,aAAa,EAAE,CAAC;wBACxC,OAAO,IAAI,CAAC,QAAQ,CAAC;oBACzB,CAAC;iBACJ;gBApIY,wBAAa,gBAoIzB,CAAA;YAEL,CAAC,EAvIgB,UAAU,GAAV,eAAU,KAAV,eAAU,QAuI1B;QAEL,CAAC,EA1IgB,IAAI,GAAJ,SAAI,KAAJ,SAAI,QA0IpB;IACL,CAAC,EA5IgB,IAAI,GAAJ,YAAI,KAAJ,YAAI,QA4IpB;AACL,CAAC,EA9IS,OAAO,KAAP,OAAO,QA8IhB"}
|
||||
@@ -0,0 +1,40 @@
|
||||
var Bizgaze;
|
||||
(function (Bizgaze) {
|
||||
let Apps;
|
||||
(function (Apps) {
|
||||
let Hrms;
|
||||
(function (Hrms) {
|
||||
let Components;
|
||||
(function (Components) {
|
||||
class ManualBalance_Settings {
|
||||
loadControlPropertiesHtml(controlpropList, container) {
|
||||
return ``;
|
||||
}
|
||||
bindPropertySettings(prop) {
|
||||
var propertySettings = prop.PropertySettings;
|
||||
return "";
|
||||
}
|
||||
savePropertySettings(prop) {
|
||||
var propertySettings = prop.PropertySettings;
|
||||
return "";
|
||||
}
|
||||
loadSettingHtml() {
|
||||
return null;
|
||||
}
|
||||
bindControlData(controldatajson) {
|
||||
return null;
|
||||
}
|
||||
SaveControlData(controldatajson) {
|
||||
return controldatajson;
|
||||
}
|
||||
static Instance() {
|
||||
if (this._instance === undefined)
|
||||
this._instance = new ManualBalance_Settings();
|
||||
return this._instance;
|
||||
}
|
||||
}
|
||||
Components.ManualBalance_Settings = ManualBalance_Settings;
|
||||
})(Components = Hrms.Components || (Hrms.Components = {}));
|
||||
})(Hrms = Apps.Hrms || (Apps.Hrms = {}));
|
||||
})(Apps = Bizgaze.Apps || (Bizgaze.Apps = {}));
|
||||
})(Bizgaze || (Bizgaze = {}));
|
||||
@@ -0,0 +1 @@
|
||||
{"version":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,40 @@
|
||||
var Bizgaze;
|
||||
(function (Bizgaze) {
|
||||
let Apps;
|
||||
(function (Apps) {
|
||||
let HRMS;
|
||||
(function (HRMS) {
|
||||
let Components;
|
||||
(function (Components) {
|
||||
class ShiftCalendar_Settings {
|
||||
loadControlPropertiesHtml(controlpropList, container) {
|
||||
return ``;
|
||||
}
|
||||
bindPropertySettings(prop) {
|
||||
var propertySettings = prop.PropertySettings;
|
||||
return "";
|
||||
}
|
||||
savePropertySettings(prop) {
|
||||
var propertySettings = prop.PropertySettings;
|
||||
return "";
|
||||
}
|
||||
loadSettingHtml() {
|
||||
return null;
|
||||
}
|
||||
bindControlData(controldatajson) {
|
||||
return null;
|
||||
}
|
||||
SaveControlData(controldatajson) {
|
||||
return controldatajson;
|
||||
}
|
||||
static Instance() {
|
||||
if (this._instance === undefined)
|
||||
this._instance = new ShiftCalendar_Settings();
|
||||
return this._instance;
|
||||
}
|
||||
}
|
||||
Components.ShiftCalendar_Settings = ShiftCalendar_Settings;
|
||||
})(Components = HRMS.Components || (HRMS.Components = {}));
|
||||
})(HRMS = Apps.HRMS || (Apps.HRMS = {}));
|
||||
})(Apps = Bizgaze.Apps || (Bizgaze.Apps = {}));
|
||||
})(Bizgaze || (Bizgaze = {}));
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"shiftcalendar.settings.js","sourceRoot":"","sources":["shiftcalendar.settings.ts"],"names":[],"mappings":"AACA,IAAU,OAAO,CAmChB;AAnCD,WAAU,OAAO;IACb,IAAiB,IAAI,CAiCpB;IAjCD,WAAiB,IAAI;QACjB,IAAiB,IAAI,CA+BpB;QA/BD,WAAiB,IAAI;YACjB,IAAiB,UAAU,CA6B1B;YA7BD,WAAiB,UAAU;gBACvB,MAAa,sBAAsB;oBAC/B,yBAAyB,CAAC,eAAsC,EAAE,SAAS;wBACvE,OAAO,EAAE,CAAC;oBACd,CAAC;oBACD,oBAAoB,CAAC,IAAgB;wBACjC,IAAI,gBAAgB,GAA6B,IAAI,CAAC,gBAAgB,CAAC;wBACvE,OAAO,EAAE,CAAC;oBACd,CAAC;oBACD,oBAAoB,CAAC,IAAgB;wBACjC,IAAI,gBAAgB,GAA6B,IAAI,CAAC,gBAAgB,CAAC;wBACvE,OAAO,EAAE,CAAC;oBACd,CAAC;oBACD,eAAe;wBACX,OAAO,IAAI,CAAC;oBAChB,CAAC;oBACD,eAAe,CAAC,eAAoB;wBAChC,OAAO,IAAI,CAAC;oBAChB,CAAC;oBACD,eAAe,CAAC,eAAoB;wBAChC,OAAO,eAAe,CAAC;oBAC3B,CAAC;oBAED,MAAM,CAAC,QAAQ;wBACX,IAAI,IAAI,CAAC,SAAS,KAAK,SAAS;4BAC5B,IAAI,CAAC,SAAS,GAAG,IAAI,sBAAsB,EAAE,CAAC;wBAClD,OAAO,IAAI,CAAC,SAAS,CAAC;oBAC1B,CAAC;iBACJ;gBA3BY,iCAAsB,yBA2BlC,CAAA;YACL,CAAC,EA7BgB,UAAU,GAAV,eAAU,KAAV,eAAU,QA6B1B;QACL,CAAC,EA/BgB,IAAI,GAAJ,SAAI,KAAJ,SAAI,QA+BpB;IACL,CAAC,EAjCgB,IAAI,GAAJ,YAAI,KAAJ,YAAI,QAiCpB;AACL,CAAC,EAnCS,OAAO,KAAP,OAAO,QAmChB"}
|
||||
@@ -0,0 +1,729 @@
|
||||
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
||||
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
||||
return new (P || (P = Promise))(function (resolve, reject) {
|
||||
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
||||
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
||||
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
||||
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
||||
});
|
||||
};
|
||||
var Bizgaze;
|
||||
(function (Bizgaze) {
|
||||
let Apps;
|
||||
(function (Apps) {
|
||||
let Hrms;
|
||||
(function (Hrms) {
|
||||
let Components;
|
||||
(function (Components) {
|
||||
class ShiftCalender extends Unibase.Platform.Core.BaseComponent {
|
||||
constructor() {
|
||||
super(...arguments);
|
||||
this.holidaycalendar = new Array();
|
||||
this.firstweekcheckedarray = [];
|
||||
this.secondweekcheckedarray = [];
|
||||
this.thirdweekcheckedarray = [];
|
||||
this.fourthweekcheckedarray = [];
|
||||
this.fifththweekcheckedarray = [];
|
||||
}
|
||||
init(formpropertyid, prop, callback) {
|
||||
var instance = this;
|
||||
this.holidaycalendar = [];
|
||||
this.firstweekcheckedarray = [];
|
||||
this.secondweekcheckedarray = [];
|
||||
this.thirdweekcheckedarray = [];
|
||||
this.fourthweekcheckedarray = [];
|
||||
this.fifththweekcheckedarray = [];
|
||||
$('#SelectAllSunday').change(function () {
|
||||
let checkelemnt = $(this).is(':checked');
|
||||
if (checkelemnt == true) {
|
||||
$(".Sunday").prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(".Sunday").prop("checked", false);
|
||||
}
|
||||
});
|
||||
$(".Sunday").click(function () {
|
||||
let checkelemnt = $(this).is(':checked');
|
||||
if (checkelemnt == true) {
|
||||
$(this).prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(this).prop("checked", false);
|
||||
}
|
||||
});
|
||||
$('#SelectAllMonday').change(function () {
|
||||
let checkelemnt = $(this).is(':checked');
|
||||
if (checkelemnt == true) {
|
||||
$(".Monday").prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(".Monday").prop("checked", false);
|
||||
}
|
||||
});
|
||||
$(".Monday").click(function () {
|
||||
let checkelemnt = $(this).is(':checked');
|
||||
if (checkelemnt == true) {
|
||||
$(this).prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(this).prop("checked", false);
|
||||
}
|
||||
});
|
||||
$('#SelectAllTuesday').change(function () {
|
||||
let checkelemnt = $(this).is(':checked');
|
||||
if (checkelemnt == true) {
|
||||
$(".Tuesday").prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(".Tuesday").prop("checked", false);
|
||||
}
|
||||
});
|
||||
$(".Tuesday").click(function () {
|
||||
let checkelemnt = $(this).is(':checked');
|
||||
if (checkelemnt == true) {
|
||||
$(this).prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(this).prop("checked", false);
|
||||
}
|
||||
});
|
||||
$('#SelectAllWednesday').change(function () {
|
||||
let checkelemnt = $(this).is(':checked');
|
||||
if (checkelemnt == true) {
|
||||
$(".Wednesday").prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(".Wednesday").prop("checked", false);
|
||||
}
|
||||
});
|
||||
$(".Wednesday").click(function () {
|
||||
let checkelemnt = $(this).is(':checked');
|
||||
if (checkelemnt == true) {
|
||||
$(this).prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(this).prop("checked", false);
|
||||
}
|
||||
});
|
||||
$('#SelectAllThursday').change(function () {
|
||||
let checkelemnt = $(this).is(':checked');
|
||||
if (checkelemnt == true) {
|
||||
$(".Thursday").prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(".Thursday").prop("checked", false);
|
||||
}
|
||||
});
|
||||
$(".Thursday").click(function () {
|
||||
let checkelemnt = $(this).is(':checked');
|
||||
if (checkelemnt == true) {
|
||||
$(this).prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(this).prop("checked", false);
|
||||
}
|
||||
});
|
||||
$('#SelectAllFriday').change(function () {
|
||||
let checkelemnt = $(this).is(':checked');
|
||||
if (checkelemnt == true) {
|
||||
$(".Friday").prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(".Friday").prop("checked", false);
|
||||
}
|
||||
});
|
||||
$(".Friday").click(function () {
|
||||
let checkelemnt = $(this).is(':checked');
|
||||
if (checkelemnt == true) {
|
||||
$(this).prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(this).prop("checked", false);
|
||||
}
|
||||
});
|
||||
$('#SelectAllSaturday').change(function () {
|
||||
let checkelemnt = $(this).is(':checked');
|
||||
if (checkelemnt == true) {
|
||||
$(".Saturday").prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(".Saturday").prop("checked", false);
|
||||
}
|
||||
});
|
||||
$(".Saturday").click(function () {
|
||||
let checkelemnt = $(this).is(':checked');
|
||||
if (checkelemnt == true) {
|
||||
$(this).prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(this).prop("checked", false);
|
||||
}
|
||||
});
|
||||
$(".fifthweek").click(function () {
|
||||
let checkelemnt = $(this).is(':checked');
|
||||
let day = $(this).val();
|
||||
var splt = day.toString().split(':');
|
||||
let dayname = splt[0];
|
||||
let dayval = Boolean(splt[1]);
|
||||
let weekday = { [dayname]: dayval };
|
||||
if (checkelemnt == true) {
|
||||
$(this).prop("checked", true);
|
||||
instance.fifththweekcheckedarray.push({ [dayname]: dayval });
|
||||
console.log(instance.fifththweekcheckedarray);
|
||||
}
|
||||
else {
|
||||
$(this).prop("checked", false);
|
||||
let newArray = [];
|
||||
for (let i = 0; i < instance.fifththweekcheckedarray.length; i++) {
|
||||
if (JSON.stringify(instance.fifththweekcheckedarray[i]) !== JSON.stringify(weekday)) {
|
||||
newArray.push(instance.fifththweekcheckedarray[i]);
|
||||
}
|
||||
}
|
||||
instance.fifththweekcheckedarray = [];
|
||||
instance.fifththweekcheckedarray = newArray;
|
||||
console.log(instance.fifththweekcheckedarray);
|
||||
}
|
||||
});
|
||||
$(".firstweek").click(function () {
|
||||
let checkelemnt = $(this).is(':checked');
|
||||
let day = $(this).val();
|
||||
var splt = day.toString().split(':');
|
||||
let dayname = splt[0];
|
||||
let dayval = Boolean(splt[1]);
|
||||
let weekday = { [dayname]: dayval };
|
||||
if (checkelemnt == true) {
|
||||
$(this).prop("checked", true);
|
||||
instance.firstweekcheckedarray.push({ [dayname]: dayval });
|
||||
console.log(instance.firstweekcheckedarray);
|
||||
}
|
||||
else {
|
||||
$(this).prop("checked", false);
|
||||
let newArray = [];
|
||||
for (let i = 0; i < instance.firstweekcheckedarray.length; i++) {
|
||||
if (JSON.stringify(instance.firstweekcheckedarray[i]) != JSON.stringify(weekday)) {
|
||||
newArray.push(instance.firstweekcheckedarray[i]);
|
||||
}
|
||||
}
|
||||
instance.firstweekcheckedarray = [];
|
||||
instance.firstweekcheckedarray = newArray;
|
||||
console.log(instance.firstweekcheckedarray);
|
||||
}
|
||||
});
|
||||
$(".secondweek").click(function () {
|
||||
let checkelemnt = $(this).is(':checked');
|
||||
let day = $(this).val();
|
||||
var splt = day.toString().split(':');
|
||||
let dayname = splt[0];
|
||||
let dayval = Boolean(splt[1]);
|
||||
let weekday = { [dayname]: dayval };
|
||||
if (checkelemnt == true) {
|
||||
$(this).prop("checked", true);
|
||||
instance.secondweekcheckedarray.push({ [dayname]: dayval });
|
||||
console.log(instance.secondweekcheckedarray);
|
||||
}
|
||||
else {
|
||||
$(this).prop("checked", false);
|
||||
let newArray = [];
|
||||
for (let i = 0; i < instance.secondweekcheckedarray.length; i++) {
|
||||
if (JSON.stringify(instance.secondweekcheckedarray[i]) !== JSON.stringify(weekday)) {
|
||||
newArray.push(instance.secondweekcheckedarray[i]);
|
||||
}
|
||||
}
|
||||
instance.secondweekcheckedarray = [];
|
||||
instance.secondweekcheckedarray = newArray;
|
||||
console.log(instance.secondweekcheckedarray);
|
||||
}
|
||||
});
|
||||
$(".thirdweek").click(function () {
|
||||
let checkelemnt = $(this).is(':checked');
|
||||
let day = $(this).val();
|
||||
var splt = day.toString().split(':');
|
||||
let dayname = splt[0];
|
||||
let dayval = Boolean(splt[1]);
|
||||
let weekday = { [dayname]: dayval };
|
||||
if (checkelemnt == true) {
|
||||
$(this).prop("checked", true);
|
||||
instance.thirdweekcheckedarray.push({ [dayname]: dayval });
|
||||
console.log(instance.thirdweekcheckedarray);
|
||||
}
|
||||
else {
|
||||
$(this).prop("checked", false);
|
||||
let newArray = [];
|
||||
for (let i = 0; i < instance.thirdweekcheckedarray.length; i++) {
|
||||
if (JSON.stringify(instance.thirdweekcheckedarray[i]) !== JSON.stringify(weekday)) {
|
||||
newArray.push(instance.thirdweekcheckedarray[i]);
|
||||
}
|
||||
}
|
||||
instance.thirdweekcheckedarray = [];
|
||||
instance.thirdweekcheckedarray = newArray;
|
||||
console.log(instance.thirdweekcheckedarray);
|
||||
}
|
||||
});
|
||||
$(".fourthweek").click(function () {
|
||||
let checkelemnt = $(this).is(':checked');
|
||||
let day = $(this).val();
|
||||
var splt = day.toString().split(':');
|
||||
let dayname = splt[0];
|
||||
let dayval = Boolean(splt[1]);
|
||||
let weekday = { [dayname]: dayval };
|
||||
if (checkelemnt == true) {
|
||||
$(this).prop("checked", true);
|
||||
instance.fourthweekcheckedarray.push({ [dayname]: dayval });
|
||||
console.log(instance.fourthweekcheckedarray);
|
||||
}
|
||||
else {
|
||||
$(this).prop("checked", false);
|
||||
let newArray = [];
|
||||
for (let i = 0; i < instance.fourthweekcheckedarray.length; i++) {
|
||||
if (JSON.stringify(instance.fourthweekcheckedarray[i]) !== JSON.stringify(weekday)) {
|
||||
newArray.push(instance.fourthweekcheckedarray[i]);
|
||||
}
|
||||
}
|
||||
instance.fourthweekcheckedarray = [];
|
||||
instance.fourthweekcheckedarray = newArray;
|
||||
console.log(instance.fourthweekcheckedarray);
|
||||
}
|
||||
});
|
||||
if (callback != null) {
|
||||
callback();
|
||||
}
|
||||
}
|
||||
loadControl(containerid, prop) {
|
||||
$("." + containerid).empty();
|
||||
let html = `<div class="card">
|
||||
<div class="card-header card-header-action">
|
||||
<div class="col-12">
|
||||
<span class="h6 ml-10">
|
||||
Weekend Definition
|
||||
</span>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body" style="overflow-x:auto;">
|
||||
|
||||
<table class="bg-white" id="bizgazecrm_Routes_tbl_DayWise" style="border: 1px solid #c6c6c6;text-align: left; border-collapse: collapse;width: 100%; ">
|
||||
<thead>
|
||||
<tr style="border: 1px solid #c6c6c6;" class="list-item-main-title">
|
||||
<td style="border: 1px solid #c6c6c6;padding: 15px;" rowspan="2"> Days</td>
|
||||
<td style="text-align:center;border: 1px solid #c6c6c6;padding:10px" colspan="6">Weeks</td>
|
||||
</tr>
|
||||
<tr style="border: 1px solid #c6c6c6;text-align;font-weight:500" >
|
||||
<td style="text-align:center;border: 1px solid #c6c6c6;padding: 5px;">All</td>
|
||||
<td style="text-align:center;border: 1px solid #c6c6c6;padding: 5px;">1st</td>
|
||||
<td style="text-align:center;border: 1px solid #c6c6c6;padding: 5px;">2nd</td>
|
||||
<td style="text-align:center;border: 1px solid #c6c6c6;padding: 5px;">3rd</td>
|
||||
<td style="text-align:center;border: 1px solid #c6c6c6;padding: 5px;">4th</td>
|
||||
<td style="text-align:center;border: 1px solid #c6c6c6;padding: 5px;">5th</td>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
<tr>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: left;padding: 15px;" class="list-item-main-title">Sunday</td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"> <input type="checkbox" id="SelectAllSunday" name="Sunday" value="" class="SelectAllSunday"></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"> <input type="checkbox" class="Sunday firstweek" id="1stSunday" name="1stSunday" value=Sunday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Sunday secondweek" id="2ndSunday" name="2ndSunday" value=Sunday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Sunday thirdweek" id="3rdSunday" name="3rdSunday" value=Sunday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Sunday fourthweek" id="4thSunday" name="4thSunday" value=Sunday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Sunday fifthweek" id="5thSunday" name="5thSunday" value=Sunday:true></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: left;padding: 15px;" class="list-item-main-title">Monday</td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"> <input type="checkbox" id="SelectAllMonday" name="Monday" value="" class="SelectAllMonday"></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"> <input type="checkbox" class="Monday firstweek" id="1stMonday" name="1stMonday" value=Monday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Monday secondweek" id="2ndMonday" name="2ndMonday" value=Monday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Monday thirdweek" id="3rdMonday" name="3rdMonday" value=Monday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Monday fourthweek" id="4thMonday" name="4thMonday" value=Monday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Monday fifthweek" id="5thMonday" name="5thMonday" value=Monday:true></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: left;padding: 15px;" class="list-item-main-title">Tuesday</td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"> <input type="checkbox" id="SelectAllTuesday" name="Tuesday" value="" class="SelectAllTuesday"></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"> <input type="checkbox" class="Tuesday firstweek" id="1stTuesday" name="1stTuesday" value=Tuesday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Tuesday secondweek" id="2ndTuesday" name="2ndTuesday" value=Tuesday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Tuesday thirdweek" id="3rdTuesday" name="3rdTuesday" value=Tuesday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Tuesday fourthweek" id="4thTuesday" name="4thTuesday" value=Tuesday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Tuesday fifthweek" id="5thTuesday" name="5thTuesday" value=Tuesday:true></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: left;padding: 15px;" class="list-item-main-title">Wednesday</td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"> <input type="checkbox" id="SelectAllWednesday" name="Wednesday" value="" class="SelectAllWednesday"></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"> <input type="checkbox" class="Wednesday firstweek" id="1stWednesday" name="1stWednesday" value=Wednesday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Wednesday secondweek" id="2ndWednesday" name="2ndWednesday" value=Wednesday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Wednesday thirdweek" id="3rdWednesday" name="3rdWednesday" value=Wednesday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Wednesday fourthweek" id="4thWednesday" name="4thWednesday" value=Wednesday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Wednesday fifthweek" id="5thWednesday" name="5thWednesday" value=Wednesday:true></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: left;padding: 15px;" class="list-item-main-title">Thursday</td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"> <input type="checkbox" id="SelectAllThursday" name="Thursday" value="" class="SelectAllThursday"></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"> <input type="checkbox" class="Thursday firstweek" id="1stThursday" name="1stThursday" value=Thursday:1></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Thursday secondweek" id="2ndThursday" name="2ndThursday" value=Thursday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Thursday thirdweek" id="3rdThursday" name="3rdThursday" value=Thursday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Thursday fourthweek" id="4thThursday" name="4thThursday" value=Thursday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Thursday fifthweek" id="5thThursday" name="5thThursday" value=Thursday:true></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: left;padding: 15px;" class="list-item-main-title">Friday</td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"> <input type="checkbox" id="SelectAllFriday" name="Friday" value="" class="SelectAllFriday"></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"> <input type="checkbox" class="Friday firstweek" id="1stFriday" name="1stFriday" value=Friday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Friday secondweek" id="2ndFriday" name="2ndFriday" value=Friday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Friday thirdweek" id="3rdFriday" name="3rdFriday" value=Friday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Friday fourthweek" id="4thFriday" name="4thFriday" value=Friday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Friday fifthweek" id="5thFriday" name="5thFriday" value=Friday:true></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: left;padding: 15px;" class="list-item-main-title">Saturday</td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"> <input type="checkbox" id="SelectAllSaturday" name="Saturday" value="AllSundays" class="SelectAllSaturday"></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"> <input type="checkbox" class="Saturday firstweek" id="1stSaturday" name="1stSaturday" value=Saturday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Saturday secondweek" id="2ndSaturday" name="2ndSaturday" value=Saturday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Saturday thirdweek" id="3rdSaturday" name="3rdSaturday" value=Saturday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Saturday fourthweek" id="4thSaturday" name="4thSaturday" value=Saturday:true></td>
|
||||
<td style="cursor:pointer;text-align:center;border: 1px solid #c6c6c6;text-align: center;padding: 15px;"><input type="checkbox" class="Saturday fifthweek" id="5thSaturday" name="5thSaturday" value=Saturday:true></td>
|
||||
</tr>
|
||||
<input type="hidden" id="hdn_HolidayCalendarControl" class="value-control" value=" Bizgaze.Apps.Hrms.Components.ShiftCalender.Instance().HolidayCalendarobjitems();">
|
||||
|
||||
|
||||
</table>
|
||||
</div>
|
||||
</div>`;
|
||||
$("#" + containerid).html(html);
|
||||
}
|
||||
loadControlSettings(controlsettingjson, formpropertyid) {
|
||||
return null;
|
||||
}
|
||||
loadPropertySettings(propertysettings, formpropertyid, DocPropertyName) {
|
||||
return null;
|
||||
}
|
||||
bindEditFormDetails(formpropertyid, propval, DocPropertyName) {
|
||||
var id = Number(propval);
|
||||
var instance = this;
|
||||
var jsfiles = ['apps/hrms/managers/holidaymanager.js'];
|
||||
instance.fileCacheHelper.loadJsFiles(jsfiles, function (response) {
|
||||
Bizgaze.Apps.Hrms.Managers.HolidayManager.Instance().getHolidayCalendar(id).then(function (response) {
|
||||
if (response.result.length > 0) {
|
||||
var data = response.result;
|
||||
var everysunday = data[0].everysunday;
|
||||
var everymonday = data[0].everymonday;
|
||||
var everytuesday = data[0].everytuesday;
|
||||
var everywednesday = data[0].everywednesday;
|
||||
var everythursday = data[0].everythursday;
|
||||
var everyfriday = data[0].everyfriday;
|
||||
var everysaturday = data[0].everysaturday;
|
||||
if (everysunday == true) {
|
||||
$(".Sunday").prop("checked", true);
|
||||
$("#SelectAllSunday").prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(".Sunday").prop("checked", false);
|
||||
$("#SelectAllSunday").prop("checked", false);
|
||||
}
|
||||
if (everymonday == true) {
|
||||
$(".Monday").prop("checked", true);
|
||||
$("#SelectAllMonday").prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(".Monday").prop("checked", false);
|
||||
$("#SelectAllMonday").prop("checked", false);
|
||||
}
|
||||
if (everytuesday == true) {
|
||||
$(".Tuesday").prop("checked", true);
|
||||
$("#SelectAllTuesday").prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(".Tuesday").prop("checked", false);
|
||||
$("#SelectAllTuesday").prop("checked", false);
|
||||
}
|
||||
if (everywednesday == true) {
|
||||
$(".Wednesday").prop("checked", true);
|
||||
$("#SelectAllWednesday").prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(".Wednesday").prop("checked", false);
|
||||
$("#SelectAllWednesday").prop("checked", false);
|
||||
}
|
||||
if (everythursday == true) {
|
||||
$(".Thursday").prop("checked", true);
|
||||
$("#SelectAllThursday").prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(".Thursday").prop("checked", false);
|
||||
$("#SelectAllThursday").prop("checked", false);
|
||||
}
|
||||
if (everyfriday == true) {
|
||||
$(".Friday").prop("checked", true);
|
||||
$("#SelectAllFriday").prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(".Friday").prop("checked", false);
|
||||
$("#SelectAllFriday").prop("checked", false);
|
||||
}
|
||||
if (everysaturday == true) {
|
||||
$(".Saturday").prop("checked", true);
|
||||
$("#SelectAllSaturday").prop("checked", true);
|
||||
}
|
||||
else {
|
||||
$(".Saturday").prop("checked", false);
|
||||
$("#SelectAllSaturday").prop("checked", false);
|
||||
}
|
||||
}
|
||||
instance.getCalenderWeekItems(id);
|
||||
});
|
||||
});
|
||||
}
|
||||
getCalenderWeekItems(id) {
|
||||
return __awaiter(this, void 0, void 0, function* () {
|
||||
let instance = this;
|
||||
yield Bizgaze.Apps.Hrms.Managers.HolidayManager.Instance().getCalendarWeekItems(id).then(function (response) {
|
||||
if (response.result.length > 0) {
|
||||
for (var i = 0; i < response.result.length; i++) {
|
||||
var data = response.result[i];
|
||||
let weekid = data.weekid;
|
||||
var sunday = data.sunday;
|
||||
var monday = data.monday;
|
||||
var tuesday = data.tuesday;
|
||||
var wednesday = data.wednesday;
|
||||
var thursday = data.thursday;
|
||||
var friday = data.friday;
|
||||
var saturday = data.saturday;
|
||||
if (weekid == 1) {
|
||||
if (sunday == true) {
|
||||
$("#1stSunday").prop("checked", true);
|
||||
instance.firstweekcheckedarray.push({ Sunday: true });
|
||||
}
|
||||
if (monday == true) {
|
||||
$("#1stMonday").prop("checked", true);
|
||||
instance.firstweekcheckedarray.push({ Monday: true });
|
||||
}
|
||||
if (tuesday == true) {
|
||||
$("#1stTuesday").prop("checked", true);
|
||||
instance.firstweekcheckedarray.push({ Tuesday: true });
|
||||
}
|
||||
if (wednesday == true) {
|
||||
$("#1stWednesday").prop("checked", true);
|
||||
instance.firstweekcheckedarray.push({ Wednesday: true });
|
||||
}
|
||||
if (thursday == true) {
|
||||
$("#1stThursday").prop("checked", true);
|
||||
instance.firstweekcheckedarray.push({ Thursday: true });
|
||||
}
|
||||
if (friday == true) {
|
||||
$("#1stFriday").prop("checked", true);
|
||||
instance.firstweekcheckedarray.push({ Friday: true });
|
||||
}
|
||||
if (saturday == true) {
|
||||
$("#1stSaturday").prop("checked", true);
|
||||
instance.firstweekcheckedarray.push({ Saturday: true });
|
||||
}
|
||||
}
|
||||
else if (weekid == 2) {
|
||||
if (sunday == true) {
|
||||
$("#2ndSunday").prop("checked", true);
|
||||
instance.secondweekcheckedarray.push({ Sunday: true });
|
||||
}
|
||||
if (monday == true) {
|
||||
$("#2ndMonday").prop("checked", true);
|
||||
instance.secondweekcheckedarray.push({ Monday: true });
|
||||
}
|
||||
if (tuesday == true) {
|
||||
$("#2ndTuesday").prop("checked", true);
|
||||
instance.secondweekcheckedarray.push({ Tuesday: true });
|
||||
}
|
||||
if (wednesday == true) {
|
||||
$("#2ndWednesday").prop("checked", true);
|
||||
instance.secondweekcheckedarray.push({ Wednesday: true });
|
||||
}
|
||||
if (thursday == true) {
|
||||
$("#2ndThursday").prop("checked", true);
|
||||
instance.secondweekcheckedarray.push({ Thursday: true });
|
||||
}
|
||||
if (friday == true) {
|
||||
$("#2ndFriday").prop("checked", true);
|
||||
instance.secondweekcheckedarray.push({ Friday: true });
|
||||
}
|
||||
if (saturday == true) {
|
||||
$("#2ndSaturday").prop("checked", true);
|
||||
instance.secondweekcheckedarray.push({ Saturday: true });
|
||||
}
|
||||
}
|
||||
else if (weekid == 3) {
|
||||
if (sunday == true) {
|
||||
$("#3rdSunday").prop("checked", true);
|
||||
instance.thirdweekcheckedarray.push({ Sunday: true });
|
||||
}
|
||||
if (monday == true) {
|
||||
$("#3rdMonday").prop("checked", true);
|
||||
instance.thirdweekcheckedarray.push({ Monday: true });
|
||||
}
|
||||
if (tuesday == true) {
|
||||
$("#3rdTuesday").prop("checked", true);
|
||||
instance.thirdweekcheckedarray.push({ Tuesday: true });
|
||||
}
|
||||
if (wednesday == true) {
|
||||
$("#3rdWednesday").prop("checked", true);
|
||||
instance.thirdweekcheckedarray.push({ Wednesday: true });
|
||||
}
|
||||
if (thursday == true) {
|
||||
$("#3rdThursday").prop("checked", true);
|
||||
instance.thirdweekcheckedarray.push({ Thursday: true });
|
||||
}
|
||||
if (friday == true) {
|
||||
$("#3rdFriday").prop("checked", true);
|
||||
instance.thirdweekcheckedarray.push({ Friday: true });
|
||||
}
|
||||
if (saturday == true) {
|
||||
$("#3rdSaturday").prop("checked", true);
|
||||
instance.thirdweekcheckedarray.push({ Saturday: true });
|
||||
}
|
||||
}
|
||||
else if (weekid == 4) {
|
||||
if (sunday == true) {
|
||||
$("#4thSunday").prop("checked", true);
|
||||
instance.fourthweekcheckedarray.push({ Sunday: true });
|
||||
}
|
||||
if (monday == true) {
|
||||
$("#4thMonday").prop("checked", true);
|
||||
instance.fourthweekcheckedarray.push({ Monday: true });
|
||||
}
|
||||
if (tuesday == true) {
|
||||
$("#4thTuesday").prop("checked", true);
|
||||
instance.fourthweekcheckedarray.push({ Tuesday: true });
|
||||
}
|
||||
if (wednesday == true) {
|
||||
$("#4thWednesday").prop("checked", true);
|
||||
instance.fourthweekcheckedarray.push({ Wednesday: true });
|
||||
}
|
||||
if (thursday == true) {
|
||||
$("#4thThursday").prop("checked", true);
|
||||
instance.fourthweekcheckedarray.push({ Thursday: true });
|
||||
}
|
||||
if (friday == true) {
|
||||
$("#4thFriday").prop("checked", true);
|
||||
instance.fourthweekcheckedarray.push({ Friday: true });
|
||||
}
|
||||
if (saturday == true) {
|
||||
$("#4thSaturday").prop("checked", true);
|
||||
instance.fourthweekcheckedarray.push({ Saturday: true });
|
||||
}
|
||||
}
|
||||
else if (weekid == 5) {
|
||||
if (sunday == true) {
|
||||
$("#5thSunday").prop("checked", true);
|
||||
instance.fifththweekcheckedarray.push({ Sunday: true });
|
||||
}
|
||||
if (monday == true) {
|
||||
$("#5thMonday").prop("checked", true);
|
||||
instance.fifththweekcheckedarray.push({ Monday: true });
|
||||
}
|
||||
if (tuesday == true) {
|
||||
$("#5thTuesday").prop("checked", true);
|
||||
instance.fifththweekcheckedarray.push({ Tuesday: true });
|
||||
}
|
||||
if (wednesday == true) {
|
||||
$("#5thWednesday").prop("checked", true);
|
||||
instance.fifththweekcheckedarray.push({ Wednesday: true });
|
||||
}
|
||||
if (thursday == true) {
|
||||
$("#5thThursday").prop("checked", true);
|
||||
instance.fifththweekcheckedarray.push({ Thursday: true });
|
||||
}
|
||||
if (friday == true) {
|
||||
$("#5thFriday").prop("checked", true);
|
||||
instance.fifththweekcheckedarray.push({ Friday: true });
|
||||
}
|
||||
if (saturday == true) {
|
||||
$("#5thSaturday").prop("checked", true);
|
||||
instance.fifththweekcheckedarray.push({ Saturday: true });
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
}
|
||||
HolidayCalendarobj() {
|
||||
let instance = this;
|
||||
var allsundays;
|
||||
var allmondays;
|
||||
var alltuesdays;
|
||||
var allwednesdays;
|
||||
var allthursdays;
|
||||
var allfridays;
|
||||
var allsaturdays;
|
||||
if ($("#SelectAllSunday").is(':checked')) {
|
||||
allsundays = true;
|
||||
}
|
||||
else {
|
||||
allsundays = false;
|
||||
}
|
||||
if ($("#SelectAllMonday").is(':checked')) {
|
||||
allmondays = true;
|
||||
}
|
||||
else {
|
||||
allmondays = false;
|
||||
}
|
||||
if ($("#SelectAllTuesday").is(':checked')) {
|
||||
alltuesdays = true;
|
||||
}
|
||||
else {
|
||||
alltuesdays = false;
|
||||
}
|
||||
if ($("#SelectAllWednesday").is(':checked')) {
|
||||
allwednesdays = true;
|
||||
}
|
||||
else {
|
||||
allwednesdays = false;
|
||||
}
|
||||
if ($("#SelectAllThursday").is(':checked')) {
|
||||
allthursdays = true;
|
||||
}
|
||||
else {
|
||||
allthursdays = false;
|
||||
}
|
||||
if ($("#SelectAllFriday").is(':checked')) {
|
||||
allfridays = true;
|
||||
}
|
||||
else {
|
||||
allfridays = false;
|
||||
}
|
||||
if ($("#SelectAllSaturday").is(':checked')) {
|
||||
allsaturdays = true;
|
||||
}
|
||||
else {
|
||||
allsaturdays = false;
|
||||
}
|
||||
instance.holidaycalendar.push({
|
||||
AllSundays: allsundays,
|
||||
AllMondays: allmondays,
|
||||
AllTuesdays: alltuesdays,
|
||||
AllWednesdays: allwednesdays,
|
||||
AllThursdays: allthursdays,
|
||||
AllFridays: allfridays,
|
||||
AllSaturdays: allsaturdays
|
||||
});
|
||||
}
|
||||
HolidayCalendarobjitems() {
|
||||
let instance = this;
|
||||
instance.HolidayCalendarobj();
|
||||
var holidaycalendaritems = new Array();
|
||||
holidaycalendaritems.push({
|
||||
AllWeeks: instance.holidaycalendar,
|
||||
FirstWeek: instance.firstweekcheckedarray,
|
||||
SecondWeek: instance.secondweekcheckedarray,
|
||||
ThirdWeek: instance.thirdweekcheckedarray,
|
||||
FourthWeek: instance.fourthweekcheckedarray,
|
||||
FifthWeek: instance.fifththweekcheckedarray
|
||||
});
|
||||
return holidaycalendaritems;
|
||||
}
|
||||
static Instance() {
|
||||
if (this.instance === undefined) {
|
||||
this.instance = new ShiftCalender();
|
||||
}
|
||||
return this.instance;
|
||||
}
|
||||
}
|
||||
Components.ShiftCalender = ShiftCalender;
|
||||
})(Components = Hrms.Components || (Hrms.Components = {}));
|
||||
})(Hrms = Apps.Hrms || (Apps.Hrms = {}));
|
||||
})(Apps = Bizgaze.Apps || (Bizgaze.Apps = {}));
|
||||
})(Bizgaze || (Bizgaze = {}));
|
||||
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"shiftcalender.js","sourceRoot":"","sources":["shiftcalender.ts"],"names":[],"mappings":";;;;;;;;;AAAA,IAAU,OAAO,CAgvBhB;AAhvBD,WAAU,OAAO;IACb,IAAiB,IAAI,CA8uBpB;IA9uBD,WAAiB,IAAI;QACjB,IAAiB,IAAI,CA4uBpB;QA5uBD,WAAiB,IAAI;YACjB,IAAiB,UAAU,CA0uB1B;YA1uBD,WAAiB,UAAU;gBACvB,MAAa,aAAc,SAAQ,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAC,aAAa;oBAAtE;;wBACK,oBAAe,GAAG,IAAI,KAAK,EAAE,CAAC;wBAC/B,0BAAqB,GAAG,EAAE,CAAC;wBAC3B,2BAAsB,GAAG,EAAE,CAAC;wBAC5B,0BAAqB,GAAG,EAAE,CAAC;wBAC3B,2BAAsB,GAAG,EAAE,CAAC;wBAC5B,4BAAuB,GAAG,EAAE,CAAC;oBAkuBjC,CAAC;oBAjuBG,IAAI,CAAC,cAAsB,EAAE,IAAgB,EAAE,QAAa;wBACxD,IAAI,QAAQ,GAAG,IAAI,CAAC;wBACpB,IAAI,CAAC,eAAe,GAAG,EAAE,CAAC;wBAC1B,IAAI,CAAC,qBAAqB,GAAG,EAAE,CAAC;wBAChC,IAAI,CAAC,sBAAsB,GAAG,EAAE,CAAC;wBACjC,IAAI,CAAC,qBAAqB,GAAG,EAAE,CAAC;wBAChC,IAAI,CAAC,sBAAsB,GAAG,EAAE,CAAC;wBACjC,IAAI,CAAC,uBAAuB,GAAG,EAAE,CAAC;wBAClC,CAAC,CAAC,kBAAkB,CAAC,CAAC,MAAM,CAAC;4BAEzB,I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