using System; using System.Collections.Generic; using System.Linq; using System.Text; using Ease.Core; using Ease.Core.Model; using System.Data; namespace HRM.BO { #region TaxAdjustment public class TaxAdjustment : BasicBaseObject { #region Constructor public TaxAdjustment() { Name = string.Empty; TaxType = EnumIncomeTaxSide.Tax_Info_Item; } #endregion #region Properties public string Name { get; set; } public EnumIncomeTaxSide TaxType { get; set; } //#region Service Factory ITaxAdjustmentService : ITaxAdjustmentService //internal static ITaxAdjustmentService Service //{ // get { return Services.Factory.CreateService(typeof(ITaxAdjustmentService)); } //} //#endregion #endregion //#region Functions //public static TaxAdjustment Get(int nID) //{ // TaxAdjustment oTaxAdjustment = null; // #region Cache Header // oTaxAdjustment = (TaxAdjustment)_cache["Get", nID]; // if (oTaxAdjustment != null) // return oTaxAdjustment; // #endregion // oTaxAdjustment = TaxAdjustment.Service.Get(nID); // #region Cache Footer // _cache.Add(oTaxAdjustment, "Get", nID); // #endregion // return oTaxAdjustment; //} //public static List Get() //{ // #region Cache Header // List taxAdjustments = _cache["Get"] as List; // if (taxAdjustments != null) // return taxAdjustments; // #endregion // try // { // taxAdjustments = Service.Get(); // } // catch (ServiceException e) // { // throw new Exception(e.Message, e); // } // #region Cache Footer // _cache.Add(taxAdjustments, "Get"); // #endregion // return taxAdjustments; //} //public static List Get(EnumStatus status) //{ // #region Cache Header // List TaxAdjustments = _cache["Get", status] as List; // if (TaxAdjustments != null) // return TaxAdjustments; // #endregion // try // { // TaxAdjustments = Service.Get(status); // } // catch (ServiceException e) // { // throw new Exception(e.Message, e); // } // #region Cache Footer // _cache.Add(TaxAdjustments, "Get", status); // #endregion // return TaxAdjustments; //} //public int Save() //{ // this.SetAuditTrailProperties(); // return TaxAdjustment.Service.Save(this); //} //public void Delete(int ID) //{ // TaxAdjustment.Service.Delete(ID); //} //#endregion } #endregion #region ITaxAdjustment Service public interface ITaxAdjustmentService { TaxAdjustment Get(int id); List Get(); List Get(EnumStatus status); int Save(TaxAdjustment item); void Delete(int id); } #endregion }