243 lines
5.2 KiB
C#
243 lines
5.2 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using Ease.Core;
|
|
|
|
namespace HRM.BO
|
|
{
|
|
#region EmpFieldTrack
|
|
|
|
public class EmpFieldTrack : AuditTrailBase
|
|
{
|
|
#region Constructor
|
|
|
|
public EmpFieldTrack()
|
|
{
|
|
_IMENumber = string.Empty;
|
|
_longitude = 0;
|
|
_latitude = 0;
|
|
_employeeID = 0;
|
|
_nearLocation = string.Empty;
|
|
_client = string.Empty;
|
|
_remarks = string.Empty;
|
|
_tranDateTime = DateTime.Now;
|
|
_zipcode = string.Empty;
|
|
}
|
|
|
|
#endregion
|
|
|
|
#region Properties
|
|
|
|
#region IMENumber : string
|
|
|
|
private string _IMENumber;
|
|
|
|
public string IMENumber
|
|
{
|
|
get { return _IMENumber; }
|
|
set { _IMENumber = value; }
|
|
}
|
|
|
|
#endregion
|
|
|
|
public int LocationID { get; set; }
|
|
public string NearestAddress { get; set; }
|
|
public EnumTrackType TrackType { get; set; }
|
|
public string ZipCode { get; set; }
|
|
|
|
#region Latitude : decimal
|
|
|
|
private decimal _latitude;
|
|
|
|
public decimal Latitude
|
|
{
|
|
get { return _latitude; }
|
|
set { _latitude = value; }
|
|
}
|
|
|
|
#endregion
|
|
|
|
#region Longitude : decimal
|
|
|
|
private decimal _longitude;
|
|
|
|
public decimal Longitude
|
|
{
|
|
get { return _longitude; }
|
|
set { _longitude = value; }
|
|
}
|
|
|
|
#endregion
|
|
|
|
#region EmployeeID : ID
|
|
|
|
private int _employeeID;
|
|
|
|
public int EmployeeID
|
|
{
|
|
get { return _employeeID; }
|
|
set { _employeeID = value; }
|
|
}
|
|
|
|
#endregion
|
|
|
|
#region NearLocation : string
|
|
|
|
private string _nearLocation;
|
|
|
|
public string NearLocation
|
|
{
|
|
get { return _nearLocation; }
|
|
set { _nearLocation = value; }
|
|
}
|
|
|
|
#endregion
|
|
|
|
#region Client : string
|
|
|
|
private string _client;
|
|
|
|
public string Client
|
|
{
|
|
get { return _client; }
|
|
set { _client = value; }
|
|
}
|
|
|
|
#endregion
|
|
|
|
#region Remarks : string
|
|
|
|
private string _remarks;
|
|
|
|
public string Remarks
|
|
{
|
|
get { return _IMENumber; }
|
|
set { _IMENumber = value; }
|
|
}
|
|
|
|
#endregion
|
|
|
|
#region TranDateTime : DateTime
|
|
|
|
private DateTime _tranDateTime;
|
|
|
|
public DateTime TranDateTime
|
|
{
|
|
get { return _tranDateTime; }
|
|
set { _tranDateTime = value; }
|
|
}
|
|
|
|
#endregion
|
|
|
|
#region Zipcode : string
|
|
|
|
private string _zipcode;
|
|
|
|
public string Zipcode
|
|
{
|
|
get { return _zipcode; }
|
|
set { _zipcode = value; }
|
|
}
|
|
|
|
#endregion
|
|
|
|
//#region ServiceFactory Service : IEmpFieldTrackService
|
|
|
|
//internal static IEmpFieldTrackService Service
|
|
//{
|
|
// get
|
|
// {
|
|
// return Services.Factory.CreateService<IEmpFieldTrackService>(typeof(IEmpFieldTrackService));
|
|
// }
|
|
//}
|
|
|
|
//#endregion
|
|
|
|
#endregion
|
|
|
|
//#region Functions
|
|
|
|
//public static EmpFieldTrack Get(ID nID)
|
|
//{
|
|
// EmpFieldTrack oEmpFieldTrack = null;
|
|
// #region Cache Header
|
|
// oEmpFieldTrack = (EmpFieldTrack)_cache["Get", nID];
|
|
// if (oEmpFieldTrack != null)
|
|
// return oEmpFieldTrack;
|
|
// #endregion
|
|
// oEmpFieldTrack = Service.Get(nID);
|
|
// #region Cache Footer
|
|
// _cache.Add(oEmpFieldTrack, "Get", nID);
|
|
// #endregion
|
|
// return oEmpFieldTrack;
|
|
//}
|
|
|
|
//public static ObjectsTemplate<EmpFieldTrack> Get()
|
|
//{
|
|
// #region Cache Header
|
|
|
|
// ObjectsTemplate<EmpFieldTrack> oEmpFieldTracks = _cache["Get"] as ObjectsTemplate<EmpFieldTrack>;
|
|
// if (oEmpFieldTracks != null)
|
|
// return oEmpFieldTracks;
|
|
|
|
// #endregion
|
|
|
|
// try
|
|
// {
|
|
// oEmpFieldTracks = Service.Get();
|
|
// }
|
|
// catch (ServiceException e)
|
|
// {
|
|
// throw new Exception(e.Message, e);
|
|
// }
|
|
|
|
// #region Cache Footer
|
|
|
|
// _cache.Add(oEmpFieldTracks, "Get");
|
|
|
|
// #endregion
|
|
|
|
// return oEmpFieldTracks;
|
|
//}
|
|
|
|
//public static ObjectsTemplate<EmpFieldTrack> Get(DateTime tranDate)
|
|
//{
|
|
|
|
// try
|
|
// {
|
|
// return Service.Get(tranDate);
|
|
// }
|
|
// catch (ServiceException e)
|
|
// {
|
|
// throw new Exception(e.Message, e);
|
|
// }
|
|
|
|
//}
|
|
|
|
//public ID Save()
|
|
//{
|
|
// return Service.Save(this);
|
|
//}
|
|
|
|
//public void Delete()
|
|
//{
|
|
// Service.Delete(ID);
|
|
//}
|
|
|
|
//#endregion
|
|
}
|
|
|
|
#endregion
|
|
|
|
#region IEmpFieldTrackService Service
|
|
public interface IEmpFieldTrackService
|
|
{
|
|
EmpFieldTrack Get(int nID);
|
|
List<EmpFieldTrack> Get();
|
|
int Save(EmpFieldTrack empFieldTrack);
|
|
void Delete(int ID);
|
|
List<EmpFieldTrack> Get(DateTime tranDate);
|
|
}
|
|
#endregion
|
|
} |