public EmployeeData CustEnEmployee(DataTable dtEmployees, int i) { if (dtEmployees.Rows.Count > 0) { EmployeeData employeeData = new EmployeeData { employeeId = Convert.ToInt32(dtEmployees.Rows[i]["employeeId"]), employeeIdSymbol = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeIdSymbol"]), employeeNameEN = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeNameEN"]), employeeBirthDate = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeBirthDate"]), employeeEmail = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeEmail"]), employeeNationalityEN = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeNationalityEN"]), employeeCardBankNumber = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeCardBankNumber"]), employeeGender = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeGender"]), employeeMaritalStatusEN = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeMaritalStatusEN"]), employeeMilitaryStatusEN = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeMilitaryStatusEN"]), employeeLicenseNumber = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeLicenseNumber"]), employeeLicenseExpireDate = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeLicenseExpireDate"]), employeeIdentityNumber = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeIdentityNumber"]), employeeIdentityExpireDate = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeIdentityExpireDate"]), employeePassportNumber = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeePassportNumber"]), employeePassportExpireDate = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeePassportExpireDate"]), employeeEducation = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeEducation"]), employeeContractStartDate = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeContractStartDate"]), employeeContractEndDate = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeContractEndDate"]), employeeResidenceNumber = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeResidenceNumber"]), employeeResidenceExpireDate = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeResidenceExpireDate"]), employeeInsuranceNumber = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeInsuranceNumber"]), employeeJobDegree = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeJobDegree"]), employeeJobStatus = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeJobStatus"]), employeeJobId = MethodesConvertalClass.ConvertToInt(dtEmployees.Rows[i]["employeeJobId"]), employeeSectorId = MethodesConvertalClass.ConvertToInt(dtEmployees.Rows[i]["employeeSectorId"]), employeeBranchId = MethodesConvertalClass.ConvertToInt(dtEmployees.Rows[i]["employeeBranchId"]), employeeCountry = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeCountry"]), employeeCity = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeCity"]), employeeRegion = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeRegion"]), employeeAdressDetailsEN = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeAdressDetailsEN"]), employeeFirstCountryCode = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeFirstCountryCode"]), employeeFirstCountryCodeName = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeFirstCountryCodeName"]), employeeFirstPhone = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeFirstPhone"]), employeeFirstPhoneWithCC = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeFirstPhoneWithCC"]), employeeSecondCountryCode = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeSecondCountryCode"]), employeeSecondCountryCodeName = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeSecondCountryCodeName"]), employeeSecondPhone = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeSecondPhone"]), employeeSecondPhoneWithCC = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeSecondPhoneWithCC"]), employeeNotes = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeNotes"]), emmployeeArchiveStatus = MethodesConvertalClass.ConvertToBool(dtEmployees.Rows[i]["emmployeeArchiveStatus"]), }; return(employeeData); } else { return(null); } }
private EmployeeData CustEnEmployee(DataTable dtEmployees, int i) { if (dtEmployees.Rows.Count > 0) { EmployeeData employeeData = new EmployeeData { employeeId = Convert.ToInt32(dtEmployees.Rows[i]["employeeId"]), employeeCountryCode = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeCountryCode"]), employeeCCName = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeCCName"]), employeePhone = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeePhone"]), employeePhoneCC = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeePhoneCC"]), emmployeeArchiveStatus = MethodesConvertalClass.ConvertToBool(dtEmployees.Rows[i]["emmployeeArchiveStatus"]), employNameEN = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employNameEN"]), employeeAddressEN = MethodesConvertalClass.ConvertToString(dtEmployees.Rows[i]["employeeAddressEN"]) }; return(employeeData); } else { return(null); } }