Beispiel #1
0
 public void Insert(RegisterViewModel model)
 {
     using (var db = new BusinessAdminRepository())
     {
         db.Insert(ConvertToBusinessModel(model));
     }
 }
Beispiel #2
0
 public IEnumerable <RegisterViewModel> GetAllBusinessAdmin()
 {
     using (var db = new BusinessAdminRepository())
     {
         return(db.GetAll().Select(model => new RegisterViewModel
         {
             IdNumber = model.IdNumber,
             Id = model.BusAdminId,
             Email = model.Email,
             fullNames = model.fullNames,
             phoneNumber = model.phoneNumber,
             PostalAddress = model.PostalAddress,
             Password = model.Password,
             Role = model.Role,
             ConfirmPassword = model.ConfirmPassword,
             RegistrationDate = model.RegistrationDate,
             userName = model.userName,
         }));
     }
 }