EchoTex_Payroll/HRM.BO/Recruitement/WebAPPFormParam.cs

291 lines
7.7 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 WebAPPFormParam
public class WebAPPFormParam : BasicBaseObject
{
public delegate void ItemChanged();
#region Constructor
public WebAPPFormParam()
{
_nformObjectID = 0;
_assessmentBy = (0);
_nobjectID = 0;
_dAssessmentDate = DateTime.MinValue;
}
#endregion
#region Properties
#region DataType : EnumAssessmentFormType
private EnumAssessmentFormType _assessmentFormType;
public EnumAssessmentFormType AssessmentFormType
{
get { return _assessmentFormType; }
set
{
_assessmentFormType = value;
}
}
#endregion
#region FormID : int
private int _nformObjectID;
public int FormID
{
get { return _nformObjectID; }
set
{
_nformObjectID = value;
}
}
#endregion
#region AssessmentBy : ID
private int _assessmentBy;
public int AssessmentBy
{
get { return _assessmentBy; }
set
{
_assessmentBy = value;
}
}
#endregion
#region AssessmentDate : DateTime
private DateTime _dAssessmentDate;
public DateTime AssessmentDate
{
get { return _dAssessmentDate; }
set
{
_dAssessmentDate = value;
}
}
#endregion
#region ObjectID : int
private int _nobjectID;
public int ObjectID
{
get { return _nobjectID; }
set
{
_nobjectID = value;
}
}
#endregion
public List<WebAPPFormParamDetails> ParamDetails { get; set; }
#region AssessmentFor : EnumAssessmentFor
private EnumAssessmentFor _assessmentFor;
public EnumAssessmentFor AssessmentFor
{
get { return _assessmentFor; }
set
{
_assessmentFor = value;
}
}
#endregion
//#region WebAppFormParamDetails : List<WebAppFormParamDetails>
//private List<WebAPPFormParamDetails> _paramDetailes;
//public List<WebAPPFormParamDetails> ParamDetails
//{
// get
// {
// if (_paramDetailes == null && !this.ID.IsUnassigned)
// {
// _paramDetailes = WebAPPFormParamDetails.Service.GetParamDetails(this.ID.Integer);
// //_salaryEmpCostCenters = new List<SalaryEmpCostCenter>();
// }
// return _paramDetailes;
// }
// set
// {
// _paramDetailes = value;
// }
//}
//#endregion
#endregion
//#region Service Factory IWebAPPFormParamService : IWebAPPFormParamService
//internal static IWebAPPFormParamService Service
//{
// get { return Services.Factory.CreateService<IWebAPPFormParamService>(typeof(IWebAPPFormParamService)); }
//}
//#endregion
//#region Functions
//public static WebAPPFormParam Get(int id)
//{
// WebAPPFormParam webAPPFormParam = null;
// #region Cache Header
// webAPPFormParam = (WebAPPFormParam)_cache["Get",id];
// if (webAPPFormParam != null)
// return webAPPFormParam;
// #endregion
// webAPPFormParam = WebAPPFormParam.Service.Get(id);
// #region Cache Footer
// _cache.Add(webAPPFormParam, "Get", id);
// #endregion
// return webAPPFormParam;
//}
//public static WebAPPFormParam Get(int formId, int objectID)
//{
// WebAPPFormParam webAPPFormParam = null;
// #region Cache Header
// webAPPFormParam = (WebAPPFormParam)_cache["Get", formId, objectID];
// if (webAPPFormParam != null)
// return webAPPFormParam;
// #endregion
// webAPPFormParam = WebAPPFormParam.Service.Get(formId, objectID);
// #region Cache Footer
// _cache.Add(webAPPFormParam, "Get", formId, objectID);
// #endregion
// return webAPPFormParam;
//}
//public static List<WebAPPFormParam> Get()
//{
// #region Cache Header
// List<WebAPPFormParam> webAPPFormParams = _cache["Get"] as List<WebAPPFormParam>;
// if (webAPPFormParams != null)
// return webAPPFormParams;
// #endregion
// try
// {
// webAPPFormParams = Service.Get();
// }
// catch (ServiceException e)
// {
// throw new Exception(e.Message, e);
// }
// #region Cache Footer
// _cache.Add(webAPPFormParams, "Get");
// #endregion
// return webAPPFormParams;
//}
//public static List<WebAPPFormParam> GetParams(int formId, int objectID)
//{
// #region Cache Header
// List<WebAPPFormParam> webAPPFormParams = _cache["Get"] as List<WebAPPFormParam>;
// if (webAPPFormParams != null)
// return webAPPFormParams;
// #endregion
// try
// {
// webAPPFormParams = Service.GetParams(formId, objectID);
// }
// catch (ServiceException e)
// {
// throw new Exception(e.Message, e);
// }
// #region Cache Footer
// _cache.Add(webAPPFormParams, "Get");
// #endregion
// return webAPPFormParams;
//}
//public int Save()
//{
// base.SetAuditTrailProperties();
// return WebAPPFormParam.Service.Save(this);
//}
//public void Delete(int formId, int objectID)
//{
// WebAPPFormParam.Service.Delete(formId, objectID);
//}
//public void Delete()
//{
// WebAPPFormParam.Service.Delete(this.ID);
//}
////public void DeleteOb(int id)
////{
//// WebAPPFormParam.Service.Delete(ID);
////}
//public void Save(List<WebAPPFormParam> webAPPFormParams)
//{
// base.SetAuditTrailProperties();
// foreach (var item in webAPPFormParams)
// {
// item.SetAuditTrailProperties();
// }
// WebAPPFormParam.Service.Save(webAPPFormParams);
//}
//public static List<WebAPPFormParamDetails> GetParamDetails(int ParamId)
//{
// List<WebAPPFormParamDetails> oWebAPPFormParamDetails = null;
// oWebAPPFormParamDetails = Service.GetParamDetails(ParamId);
// return oWebAPPFormParamDetails;
//}
//#endregion
}
#endregion
#region IWebAPPFormParamService
public interface IWebAPPFormParamService
{
WebAPPFormParam Get(int id);
WebAPPFormParam Get(int formId,int objectID);
List<WebAPPFormParam> GetParams(int formId, int objectID);
List<WebAPPFormParam> Get();
int Save(WebAPPFormParam item);
void Save(List<WebAPPFormParam> letters);
void Delete(int formId, int objectID);
void Delete(int id);
//void DeleteOb(int id);
List<WebAPPFormParamDetails> GetParamDetails(int ParamId);
}
#endregion
}