public static async Task <IEnumerable <DepartmentRecord> > GetDepartmentsAsync(AdpClient adp) => (await adp.GetValidationTablesAsync("department", "/BXC", x => new DepartmentRecord { Id = (string)x["code"], Title = ((string)x["description"]).Trim(), Disabled = !(bool)x["active"], })).ToList();
public static async Task <IEnumerable <PositionRecord> > GetPositionsAsync(AdpClient adp) => await adp.GetValidationTablesAsync("jobtitle", "/allData", x => new PositionRecord { Id = (string)x["code"], Title = ((string)x["description"])?.Trim(), Disabled = !(bool)x["active"], });
public static async Task <IEnumerable <LocationRecord> > GetLocationsAsync(AdpClient adp) => (await adp.GetValidationTablesAsync("location", null, x => new LocationRecord { Id = (string)x["code"], Name = ((string)x["description"]).Trim(), Disabled = !(bool)x["active"], })).ToList();