using System; using System.Collections.Generic; namespace HRM.BO { #region Grade public class Grade : BasicBaseObject { #region Constructor public Grade() { Code = string.Empty; Name = string.Empty; NameInBangla = string.Empty; MaxBasic = 0; MinBasic = 0; IsTransport = false; HasGrossConcept = false; BasicPercentOfGross = 0; HasPayscale = false; ConfirmMonthDuration = 0; GradeSegmentID = 1; //_gradeSegment = null; RequiredDays = 0; _status = EnumStatus.Active; ColorCode = "White"; InsuranceCoverage = 0; //#### PayrollTypeID = SystemInformation.CurrentSysInfo.PayrollTypeID; } #endregion #region Properties public string Code { get; set; } public string Name { get; set; } public string NameInBangla { get; set; } public string ColorCode { get; set; } public double MaxBasic { get; set; } public double MinBasic { get; set; } public double Increment { get; set; } public bool IsTransport { get; set; } public int PayrollTypeID { get; set; } public bool HasGrossConcept { get; set; } public double BasicPercentOfGross { get; set; } public bool HasPayscale { get; set; } public bool IsOTApplicable { get; set; } public int ConfirmMonthDuration { get; set; } public int GradeSegmentID { get; set; } public double RequiredDays { get; set; } //public GradeSegment GradeSegment { get; set; } public double MarketAnchor { get; set; } public double InsuranceCoverage { get; set; } //#region gradeSegment : GradeSegment //private GradeSegment _gradeSegment; //public GradeSegment GradeSegment //{ // get // { // if (_gradeSegmentID.Integer > 0 && _gradeSegment == null) // { // _gradeSegment = new GradeSegment(); // _gradeSegment = GradeSegment.Get(_gradeSegmentID); // } // return this._gradeSegment; // } // set // { // _gradeSegment = value; // } //} //#endregion //#region Service Factory IGradeService : IGradeService //internal static IGradeService Service //{ // get { return Services.Factory.CreateService(typeof(IGradeService)); } //} //#endregion #endregion } #endregion #region IGrade Service public interface IGradeService { Grade Get(int id); List Get(EnumStatus status, int payrollTypeID); List Get(EnumStatus status); List Get(EnumStatus status, string sIDs, string sTargetPropertyName); int GetMaxGradeID(); int Save(Grade item); void Delete(int id); Grade Get(string sCode); Grade GetByPayrollType(string sCode, int payrollTypeID); List GetAddableGrades(int nAllowDeductID, int nADParamID, int payrollTypeID); List GetAddableGradesForOT(int nTermID, int nTermParameterID, int payrollTypeID); List GetAddableGradesForBonus(int nBonusID, int payrollTypeID); List GetAllowableGrades(int nOpiItmeID, int nOpiParamID, int payrollTypeID); List GetAddableGradesForLoanParameter(int LoaniD, int LoanParameterId); List GetAllPayrollTypes(EnumStatus status); List GetAllGrade(int payrollTypeID, EnumStatus status, string code, string name); } #endregion }