/// <summary> ///Populates the instance using data from the datastore. ///The lookup of the data in the datastore is based on the instance's current ID value. /// </summary> private void Load() { List <Bar.Data.System_Users> dataEntityCollection = OxyData.Data.DataProvider <Bar.Data.DataProvider> .Current.GetSystem_UsersBySystem_User_Id(System_User_Id); if (dataEntityCollection.Count == 0) { throw new InvalidOperationException("Object can't be instantiated: key(s) may be invalid"); } Bar.Data.System_Users val = (Bar.Data.System_Users)(dataEntityCollection[0]); System_User_Id = val.System_User_Id; Company_Id = val.Company_Id; First_Name = val.First_Name; Last_Name = val.Last_Name; Email_Address = val.Email_Address; Login_Id = val.Login_Id; Hash = val.Hash; Salt = val.Salt; Active = val.Active; Created_Date = val.Created_Date; }
internal System_Users(Bar.Data.System_Users system_Users) { System_User_Id = system_Users.System_User_Id; Company_Id = system_Users.Company_Id; First_Name = system_Users.First_Name; Last_Name = system_Users.Last_Name; Email_Address = system_Users.Email_Address; Login_Id = system_Users.Login_Id; Hash = system_Users.Hash; Salt = system_Users.Salt; Active = system_Users.Active; Created_Date = system_Users.Created_Date; }