EchoTex_Payroll/HRM.BO/Leave/ShortLeave.cs

87 lines
3.1 KiB
C#
Raw Normal View History

2024-10-14 10:01:49 +06:00
using Ease.Core;
using Ease.Core.DataAccess;
using Org.BouncyCastle.Asn1.Cms;
using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace HRM.BO
{
public class ShortLeave : BasicBaseObject
{
#region Constructor
public ShortLeave()
{
}
#endregion
#region Properties
public string TelephoneNo { get; set; }
public string ALTEMPID { get; set; }
public DateTime EntryDate { get; set; }
public double TotalHour { get; set; } = 0;
public TimeSpan DepartureTime { get; set; }
public int? DepartureEntryByID { get; set; }
public TimeSpan? ReturnTime { get; set; }
public int? ReturnEntryByID { get; set; }
public TimeSpan? ActualInTime { get; set; }
public TimeSpan? ActualOutTime { get; set; }
public TimeSpan? ExpectedReturnTime { get; set; }
public EnumGatePassStatus GatePassStatus { get; set; }
public int LineManagerID { get; set; }
public int? ApprovedBy { get; set; }
public DateTime? ApprovedDate { get; set; }
public Employee Employee { get; set; }
public int EmployeeID { get; set; }
public int PayrollTypeID { get; set; }
public string Remarks { get; set; }
public string PlaceOfVisit { get; set; }
public string PurposeOfVisit { get; set; }
/// <summary>
/// this property is used for work flow, it's a constant value
/// </summary>
public int SetupID
{
get
{
if (this.GatePassStatus != EnumGatePassStatus.Rejected)
{
return 1;
}
else return 2;
}
}
#endregion
}
#region IShort Service
public interface IShortLeaveService
{
ShortLeave Get(int id);
ShortLeave GetByDate(int empid, DateTime date);
//List<ShortLeave> Get(int empid, int payrollTypeID, int status, DateTime fromDate, DateTime toDate);
//List<ShortLeave> Get(EnumStatus status, string code, string name, int payrollTypeID);
//List<ShortLeave> Get(EnumStatus status, int payrollTypeID);
//List<ShortLeave> getEmpApplicableShortLeave(int employeeid);
DataTable Get(int empid, int payrollTypeID, EnumGatePassStatus status, DateTime fromDate, DateTime toDate);
DataTable GetAppliedSortLeave(int lmId, EnumGatePassStatus status);
DataTable GetApprovedShortLeave(int lmId, EnumGatePassStatus status, DateTime fromDate, DateTime toDate);
int Save(ShortLeave oShortLeave);
void Delete(int id);
void ApproveOrRejectShortLeave(int shortLeaveid, EnumGatePassStatus status, int approver);
void ApproveMultipleShortLeave(string sID, EnumGatePassStatus status, int approver);
DataTable getGatemanShortLeave(EnumGatePassStatus status, DateTime fromDate, DateTime toDate);
void UpdateInAndOutTime(ShortLeave oShortleave, Employee oEmp);
//bool IsAttachmentAplicable(ShortLeave ShortLeave, decimal totalDays);
}
#endregion
}