P1_TrevorGraham/MvcStoreApplication/BusinessLogic/BusinessLogic.cs
/// <summary>
/// creates viewmodels for all admins based on admins in the db
/// </summary>
/// <returns></returns>
creates viewmodels for all admins based on admins in the db
creates viewmodels for all admins based on admins in the db
public List<AdministratorViewModel> GetAllAdminViewModels()
        {
            List<Administrator> allCustomers = _repository.GetAllAdministrators();
            List<AdministratorViewModel> allCustomerViewModels = new List<AdministratorViewModel>();
            foreach (Administrator admin in allCustomers)
            {
                var adminViewModel = _mapper.ConvertAdministratorToAdministratorViewModel(admin);
                allCustomerViewModels.Add(adminViewModel);
            }
            return allCustomerViewModels;
        }
public List < AdministratorViewModel > GetAllAdminViewModels ( ) { List < Administrator > allCustomers = _repository . GetAllAdministrators ( ) ; List < AdministratorViewModel > allCustomerViewModels = new List < AdministratorViewModel > ( ) ; foreach ( Administrator admin in allCustomers ) { var adminViewModel = _mapper . ConvertAdministratorToAdministratorViewModel ( admin ) ; allCustomerViewModels . Add ( adminViewModel ) ; } return allCustomerViewModels ; }
creates viewmodels for all admins based on admins in the db
creates viewmodels for all admins based on admins in the db
None