using System; using System.Collections.Generic; using System.Linq; using System.Text; using Ease.Core; namespace HRM.BO { #region AutoWorkPlan [Serializable] public class AutoWorkPlan : AuditTrailBase { #region Constructor public AutoWorkPlan() { _employeeID = 0; _shiftID = 0; _startDate = DateTime.MinValue; } #endregion #region Properties #region employeeID : ID private int _employeeID; public int EmployeeID { get { return _employeeID; } set { //base.OnPropertyChange("employeeID", _employeeID, value); _employeeID = value; } } #endregion #region shiftID : ID private int _shiftID; public int ShiftID { get { return _shiftID; } set { //base.OnPropertyChange("shiftID", _shiftID, value); _shiftID = value; } } #endregion #region StartDate : DateTime private DateTime _startDate; public DateTime StartDate { get { return _startDate; } set { //base.OnPropertyChange("StartDate", _startDate, value); _startDate = value; } } #endregion //#region Service Factory IAutoWorkPlanService : IAutoWorkPlanService //internal static IAutoWorkPlanService Service //{ // get { return Services.Factory.CreateService(typeof(IAutoWorkPlanService)); } //} //#endregion #endregion //#region Functions //public static AutoWorkPlan Get(ID nID) //{ // AutoWorkPlan oAutoWorkPlan = null; // #region Cache Header // oAutoWorkPlan = (AutoWorkPlan)_cache["Get", nID]; // if (oAutoWorkPlan != null) // return oAutoWorkPlan; // #endregion // oAutoWorkPlan = AutoWorkPlan.Service.Get(nID); // #region Cache Footer // _cache.Add(oAutoWorkPlan, "Get", nID); // #endregion // return oAutoWorkPlan; //} //public static ObjectsTemplate Get() //{ // #region Cache Header // ObjectsTemplate autoWorkPlans = _cache["Get"] as ObjectsTemplate; // if (autoWorkPlans != null) // return autoWorkPlans; // #endregion // try // { // autoWorkPlans = Service.Get(); // } // catch (ServiceException e) // { // throw new Exception(e.Message, e); // } // #region Cache Footer // _cache.Add(autoWorkPlans, "Get"); // #endregion // return autoWorkPlans; //} //public ID Save() //{ // this.SetAuditTrailProperties(); // return AutoWorkPlan.Service.Save(this); //} //public void Delete() //{ // AutoWorkPlan.Service.Delete(ID); //} //#endregion } #endregion //#region IAutoWorkPlan Service //public interface IAutoWorkPlanService //{ // AutoWorkPlan Get(ID id); // ObjectsTemplate Get(); // ID Save(AutoWorkPlan item); // void Delete(ID id); //} //#endregion }