using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Data; using Ease.Core; namespace HRM.BO { [Serializable] public class BadliDailyPayment : BasicBaseObject { #region Constructor public BadliDailyPayment() { _itemID = 0; _description = string.Empty; _amount = 0; _changedAmount = 0; _paidDate = DateTime.MinValue; _badliRecruitID = 0; _badliProcessID = 0; } #endregion #region Properties #region ItemID : ID private int _itemID; public int ItemID { get { return _itemID; } set { //base.OnPropertyChange("ItemID", _itemID, value); _itemID = value; } } #endregion #region ItemType : EnumPayrollComponentType private enumPayrollComponentType _itemType; public enumPayrollComponentType ItemType { get { return _itemType; } set { //base.OnPropertyChange("ItemType", (short)_itemType, (short)value); _itemType = value; } } #endregion #region Description : string private string _description; public string Description { get { return _description; } set { //base.OnPropertyChange("Description", _description, value); _description = value; } } #endregion #region ChangedAmount : double private double _changedAmount; public double ChangedAmount { get { return _changedAmount; } set { //base.OnPropertyChange("ChangedAmount", _changedAmount, value); _changedAmount = value; } } #endregion #region Amount : double private double _amount; public double Amount { get { return _amount; } set { //base.OnPropertyChange("Amount", _amount, value); _amount = value; } } #endregion #region BadliRecruitID : ID private int _badliRecruitID; public int BadliRecruitID { get { return _badliRecruitID; } set { //base.OnPropertyChange("BadliRecruitID", _badliRecruitID, value); _badliRecruitID = value; } } #endregion #region BadliProcessID : ID private int _badliProcessID; public int BadliProcessID { get { return _badliProcessID; } set { //base.OnPropertyChange("BadliProcessID", _badliProcessID, value); _badliProcessID = value; } } #endregion #region PaidDate : DateTime private DateTime _paidDate; public DateTime PaidDate { get { return _paidDate; } set { //base.OnPropertyChange("PaidDate", _paidDate, value); _paidDate = value; } } #endregion #endregion //#region Service Factory IBadliDailyPaymentService : IAccessCardService //internal static IBadliDailyPaymentService Service //{ // get { return Services.Factory.CreateService(typeof(IBadliDailyPaymentService)); } //} //#endregion //public static ObjectsTemplate Get() //{ // #region Cache Header // ObjectsTemplate oBadliDailyPayments = _cache["Get"] as ObjectsTemplate; // if (oBadliDailyPayments != null) // return oBadliDailyPayments; // #endregion // try // { // oBadliDailyPayments = Service.Get(); // } // catch (ServiceException e) // { // throw new Exception(e.Message, e); // } // #region Cache Footer // _cache.Add(oBadliDailyPayments, "Get"); // #endregion // return oBadliDailyPayments; //} //public static ObjectsTemplate Get(ID badliRecruitId) //{ // #region Cache Header // ObjectsTemplate oBadliDailyPayments = _cache["Get"] as ObjectsTemplate; // if (oBadliDailyPayments != null) // return oBadliDailyPayments; // #endregion // try // { // oBadliDailyPayments = Service.Get(badliRecruitId); // } // catch (ServiceException e) // { // throw new Exception(e.Message, e); // } // #region Cache Footer // _cache.Add(oBadliDailyPayments, "Get"); // #endregion // return oBadliDailyPayments; //} //public static ObjectsTemplate Get(DateTime paymentDate) //{ // #region Cache Header // ObjectsTemplate oBadliDailyPayments = _cache["Get"] as ObjectsTemplate; // if (oBadliDailyPayments != null) // return oBadliDailyPayments; // #endregion // try // { // oBadliDailyPayments = Service.Get(paymentDate); // } // catch (ServiceException e) // { // throw new Exception(e.Message, e); // } // #region Cache Footer // _cache.Add(oBadliDailyPayments, "Get"); // #endregion // return oBadliDailyPayments; //} //public static ObjectsTemplate Get(ID employeeID, DateTime paymentDate) //{ // #region Cache Header // ObjectsTemplate oBadliDailyPayments = _cache["Get"] as ObjectsTemplate; // if (oBadliDailyPayments != null) // return oBadliDailyPayments; // #endregion // try // { // oBadliDailyPayments = Service.Get(employeeID, paymentDate); // } // catch (ServiceException e) // { // throw new Exception(e.Message, e); // } // #region Cache Footer // _cache.Add(oBadliDailyPayments, "Get"); // #endregion // return oBadliDailyPayments; //} //public static ObjectsTemplate Get(DateTime fromDate, DateTime todate, string badliRecruitId) //{ // #region Cache Header // ObjectsTemplate oBadliDailyPayments = _cache["Get"] as ObjectsTemplate; // if (oBadliDailyPayments != null) // return oBadliDailyPayments; // #endregion // try // { // oBadliDailyPayments = Service.Get(fromDate, todate, badliRecruitId); // } // catch (ServiceException e) // { // throw new Exception(e.Message, e); // } // #region Cache Footer // _cache.Add(oBadliDailyPayments, "Get"); // #endregion // return oBadliDailyPayments; //} //public static ObjectsTemplate Get(DateTime fromDate, DateTime todate) //{ // #region Cache Header // ObjectsTemplate oBadliDailyPayments = _cache["Get"] as ObjectsTemplate; // if (oBadliDailyPayments != null) // return oBadliDailyPayments; // #endregion // try // { // oBadliDailyPayments = Service.Get(fromDate, todate); // } // catch (ServiceException e) // { // throw new Exception(e.Message, e); // } // #region Cache Footer // _cache.Add(oBadliDailyPayments, "Get"); // #endregion // return oBadliDailyPayments; //} //public static ObjectsTemplate Get(DateTime paidDate, string badliRecruitId) //{ // #region Cache Header // ObjectsTemplate oBadliDailyPayments = _cache["Get"] as ObjectsTemplate; // if (oBadliDailyPayments != null) // return oBadliDailyPayments; // #endregion // try // { // oBadliDailyPayments = Service.Get(paidDate, badliRecruitId); // } // catch (ServiceException e) // { // throw new Exception(e.Message, e); // } // #region Cache Footer // _cache.Add(oBadliDailyPayments, "Get"); // #endregion // return oBadliDailyPayments; //} //public static DataSet GetBadliWeeklyPaymentSheet(string Ids, DateTime fromDate, DateTime toDate) //{ // DataSet ds = null; // try // { // ds = Service.GetBadliWeeklyPaymentSheet(Ids, fromDate, toDate); // } // catch (Exception e) // { // throw new Exception(e.Message, e); // } // return ds; //} //public void Save(ObjectsTemplate oBadliDailyPayments) //{ // oBadliDailyPayments.ForEach(x => x.SetAuditTrailProperties()); // BadliDailyPayment.Service.Save(oBadliDailyPayments); //} //public static void SaveAuto(ObjectsTemplate oBadliDailyPayments, ObjectsTemplate badliRecruit) //{ // foreach (BadliDailyPayment bPayment in oBadliDailyPayments) // { // bPayment.SetAuditTrailProperties(); // } // BadliDailyPayment.Service.SaveAuto(oBadliDailyPayments, badliRecruit); //} } //public interface IBadliDailyPaymentService //{ // ObjectsTemplate Get(); // ObjectsTemplate Get(ID badliRecruitId); // DataSet GetBadliWeeklyPaymentSheet(string ids, DateTime fromDate, DateTime toDate); // ObjectsTemplate Get(DateTime paymentDate); // ObjectsTemplate Get(DateTime fromDate, DateTime todate); // ObjectsTemplate Get(DateTime fromDate, DateTime todate, string badliRecruitId); // ObjectsTemplate Get(ID employeeID, DateTime paymentDate); // void Save(ObjectsTemplate oBadliDailyPayments); // ObjectsTemplate Get(DateTime paidDate, string badliRecruitId); // void SaveAuto(ObjectsTemplate oBadliDailyPayments, ObjectsTemplate badliRecruit); //} }