Example #1
0
 public EmployeeViewModel(Employee employee)
 {
     employeeID        = employee.EmployeeID;
     name              = MyStringFormatter.Capitalize(employee.Name);
     surname           = MyStringFormatter.Capitalize(employee.Surname);
     technicalID       = employee.UserId;
     localPlus         = employee.LocalPlus?.Description;
     workingLocation   = employee.location?.Description;
     employeeCategory  = employee.standardEmployeeCategory?.Description;
     organizationUnit  = employee.organisationUnit?.Description;
     costCentre        = employee.workingCostCentre?.ID + " | " + employee.workingCostCentre?.Description;
     position          = employee.position?.Description;
     professionalArea  = employee.professionalArea?.Description;
     companyHiringDate = employee.CompanyHiringDate;
     homeCompany       = employee.homeCompany?.Description;
     yearsInEni        = employee.NumberofYearsInEni;
     gender            = employee.GenderString;
     birthDate         = employee.BirthDate;
     age               = employee.Age;
     countryOfBirth    = employee.CountryofBirth?.CountryName;
     nationality       = employee.Nationality?.CountryName;
     familyStatus      = employee.familyStatus?.Description;
     followingPartner  = employee.FollowingPartner;
     followingChildren = employee.FollowingChildren;
     spouseNationality = employee.SpouseNationality?.CountryName;
     typeOfVisa        = employee.typeOfVISA?.Description;
     visaExpiryDate    = employee.VISAExpirayDate;
     emailAddress      = employee.EmailAddress;
     activityStatus    = employee.activityStatus?.Description;
     terminationDate   = employee.TerminationDate;
 }
Example #2
0
        public HousingViewModel(Housing housing)
        {
            employeeID               = housing.employee.EmployeeID;
            name                     = MyStringFormatter.Capitalize(housing.employee.Name);
            surname                  = MyStringFormatter.Capitalize(housing.employee.Surname);
            localPlus                = housing.employee.LocalPlus?.Description;
            technicalID              = housing.employee.UserId;
            workingLocation          = housing.employee.location?.Description;
            employeeCategory         = housing.employee.standardEmployeeCategory?.Description;
            costCentre               = housing.employee.workingCostCentre?.ID + " | " + housing.employee.workingCostCentre?.Description;
            familyStatus             = housing.employee.familyStatus?.Description;
            followingPartner         = housing.employee.FollowingPartner;
            followingChildren        = housing.employee.FollowingChildren;
            activityStatus           = housing.employee.activityStatus?.Description;
            homeAddress              = housing.HomeAddressUK;
            entitledBedrooms         = housing.EntitledNumberofBedrooms;
            actualBedrooms           = housing.ActualNumberofBedrooms;
            typeofProperty           = housing.TypeOfProperty;
            rentDueDate              = housing.RentDueDate;
            tenancyStartDate         = housing.TenancyAgreementStartDate;
            tenancyEndDate           = housing.TenancyAgreementEndDate;
            monthNoticePeriod        = housing.MonthNoticePeriod;
            initialRent              = housing.InitialHouseContractRent;
            currentRental            = housing.CurrentHouseRental;
            unfurnishedAllowanceWeek = housing.EntitledUnFurnishedAllowanceWeek;

            differenceAllowanceMonthlyCostsPaid = housing.DifferenceAllowanceMonthlyCostsPaid;
            furnitureAllowance      = housing.FurnitureAllowance;
            actualFurnitureCosts    = housing.ActualFurnitureCosts;
            parkingCharges          = housing.ParkingCharges;
            regularPayrollDeduction = housing.RegularPayrollDeduction;
            utilitiesIncluded       = housing.UtilitiesIncluded;
            furnishedUnFurnished    = housing.FurnishedUnFurnished;
            hrApproval = housing.HRApproval;

            deposit  = housing.Deposit;
            currency = housing.Currency;

            housingComments = housing.HousingComments;
        }