EchoTex_Payroll/HRM.BO/Basic/SystemInformation.cs
2024-10-14 10:01:49 +06:00

164 lines
4.8 KiB
C#

using System;
using System.Collections.Generic;
using System.Data;
using Ease.Core.Utility;
namespace HRM.BO
{
public interface IworkflowInterface
{
string ObjectDescription { get; }
int SetupID { get; }
int ObjectID { get; }
}
#region SystemInformation
public class SystemInformation : AuditTrailBase
{
#region Constructor
private ISystemInformationService systemInformationService;
public SystemInformation()
{
Code = string.Empty;
name = string.Empty;
corporateAddress = string.Empty;
factoryAddress = string.Empty;
TelephoneNo = string.Empty;
email = string.Empty;
webAddress = string.Empty;
systemStartDate = DateTime.MinValue;
TaxYearEndDate = DateTime.MinValue;
NextPayProcessDate = DateTime.MinValue;
maxYearOfService = 0;
pFContriStaff = 0;
pFContriCompany = 0;
pFInterest = 0;
TaxParamID = 0;
oTFilePath = string.Empty;
PFYearEndDate = DateTime.MinValue;
PayrollTypeID = 0;
//CurrentSysInfo = null;
}
#endregion
#region Properties
public SystemInformation CurrentSysInfo;
public string Code { get; set; }
public string name { get; set; }
public string corporateAddress { get; set; }
public string factoryAddress { get; set; }
public string TelephoneNo { get; set; }
public string email { get; set; }
public string webAddress { get; set; }
public DateTime systemStartDate { get; set; }
public DateTime TaxYearEndDate { get; set; }
public DateTime NextPayProcessDate { get; set; }
public DateTime LastPayProcessDate
{
get { return Global.DateFunctions.LastDateOfMonth(NextPayProcessDate.AddMonths(-1)); }
}
public int maxYearOfService { get; set; }
public double pFContriStaff { get; set; }
public double pFContriCompany { get; set; }
public double pFInterest { get; set; }
public int TaxParamID { get; set; }
public string oTFilePath { get; set; }
public DateTime PFYearEndDate { get; set; }
public int PayrollTypeID { get; set; }
#region PayrollTypeID : Int
//private static PayrollType _payrollType;
//public static PayrollType payrollType
//{
// get
// {
// if (SystemInformation.CurrentSysInfo.PayrollTypeID != null)
// {
// _payrollType = PayrollType.Get(SystemInformation.CurrentSysInfo.PayrollTypeID);
// }
// return _payrollType;
// }
// set
// {
// _payrollType = null;
// }
//}
//public static PayrollType payrollType
//{
// get
// {
// if (SystemInformation.CurrentSysInfo.PayrollTypeID != 0)
// {
// payrollType = PayrollType.Get(SystemInformation.CurrentSysInfo.PayrollTypeID);
// }
// return payrollType;
// }
// set
// {
// }
//}
#endregion
//#region Service Factory ISystemInformationService : ISystemInformationService
//internal static ISystemInformationService Service
//{
// get { return Services.Factory.CreateService<ISystemInformationService>(typeof(ISystemInformationService)); }
//}
//#endregion
#endregion
}
public class HardPasswordSetup
{
public int MaxLength { get; set; }
public int MinLength { get; set; }
public bool ContainUppercase { get; set; }
public bool ContainLowercase { get; set; }
public bool ContainSpecialCharacter { get; set; }
public bool ContainNumber { get; set; }
public bool ContainLetter { get; set; }
public bool UserPasswordSame { get; set; }
public int PasswordExpireNotificationDays { get; set; }
public int PasswordExpireDays { get; set; }
}
#endregion
#region ISystemInformation Service
public interface ISystemInformationService
{
SystemInformation Get();
int Update(SystemInformation item);
DateTime GetServerDate();
string GetConnectionString();
void UpdCurrYerTaxParamter(int taxParameterID, int payrollTypeID);
DataTable GetPasswordSetup();
string GetDatabaseName();
void Save(HardPasswordSetup oItem);
}
#endregion
public class PendingJobDetail
{
public string Type { get; set; }
public string Value { get; set; }
}
}