EchoTex_Payroll/HRM.BO/Bonus/ProdBonusSupervisor.cs

173 lines
4.0 KiB
C#
Raw Normal View History

2024-10-14 10:01:49 +06:00
using Ease.Core.Model;
using System;
using System.Collections.Generic;
using System.Data;
namespace HRM.BO
{
#region ProdBonusSupervisor
public class ProdBonusSupervisor : BasicBaseObject
{
#region Constructor
public ProdBonusSupervisor()
{
}
#endregion
#region Properties
#region ProdBonusSetupID : ID
private int _prodBonusSetupID;
public int ProdBonusSetupID
{
get { return _prodBonusSetupID; }
set { _prodBonusSetupID = value; }
}
#endregion
#region ProdBonusLineID : ID
private int _prodBonusLineID;
public int ProdBonusLineID
{
get { return _prodBonusLineID; }
set { _prodBonusLineID = value; }
}
#endregion
#region EmployeeID : ID
private int _employeeID;
public int EmployeeID
{
get { return _employeeID; }
set { _employeeID = value; }
}
#endregion
#region BonusPercent : double
private double _bonusPercent;
public double BonusPercent
{
get { return _bonusPercent; }
set { _bonusPercent = value; }
}
#endregion
#region Amount : double
private double _amount;
public double Amount
{
get { return _amount; }
set { _amount = value; }
}
#endregion
public string employeeNo { get; set; }
public string empName { get; set; }
//public Employee Employee { get; set; }
#region Service Factory IProdBonusSupervisorService : IProdBonusSupervisorService
internal static IProdBonusSupervisorService Service
{
get
{
return Services.Factory.CreateService<IProdBonusSupervisorService>(typeof(IProdBonusSupervisorService));
}
}
#endregion
#endregion
//#region Functions
//public static ProdBonusSupervisor Get(int nID)
//{
// ProdBonusSupervisor oProdBonusSupervisor = null;
// #region Cache Header
// oProdBonusSupervisor = (ProdBonusSupervisor)_cache["Get", nID];
// if (oProdBonusSupervisor != null)
// return oProdBonusSupervisor;
// #endregion
// oProdBonusSupervisor = ProdBonusSupervisor.Service.Get(nID);
// #region Cache Footer
// _cache.Add(oProdBonusSupervisor, "Get", nID);
// #endregion
// return oProdBonusSupervisor;
//}
//public static List<ProdBonusSupervisor> Get()
//{
// #region Cache Header
// List<ProdBonusSupervisor> ProdBonusSupervisors = _cache["Get"] as List<ProdBonusSupervisor>;
// if (ProdBonusSupervisors != null)
// return ProdBonusSupervisors;
// #endregion
// try
// {
// ProdBonusSupervisors = Service.Get();
// }
// catch (ServiceException e)
// {
// throw new Exception(e.Message, e);
// }
// #region Cache Footer
// _cache.Add(ProdBonusSupervisors, "Get");
// #endregion
// return ProdBonusSupervisors;
//}
//public int Save()
//{
// this.SetAuditTrailProperties();
// return ProdBonusSupervisor.Service.Save(this);
//}
//public void Delete(int id)
//{
// ProdBonusSupervisor.Service.Delete(id);
//}
//#endregion
}
#endregion
#region IProdBonusSupervisor Service
public interface IProdBonusSupervisorService
{
ProdBonusSupervisor Get(int id);
List<ProdBonusSupervisor> Get();
List<ProdBonusSupervisor> GetByLineID(int lineID);
int Save(ProdBonusSupervisor item);
void Delete(int id);
}
#endregion
}