P1_TrevorGraham/MvcStoreApplication/BusinessLogic/BusinessLogic.cs
/// <summary>
/// attempts to create a new location in the db based on a viewmodel and returns whether or not it was successful
/// </summary>
/// <param name="newLocationViewModel"></param>
/// <returns></returns>
attempts to create a new location in the db based on a viewmodel and returns whether or not it was successful
attempts to create a new location in the db based on a viewmodel and returns whether or not it was successful
public bool CreateNewLocation(LocationViewModel newLocationViewModel)
        {
            Location newLocation = new Location()
            {
                Name = newLocationViewModel.Name
            };
            return _repository.AttemptAddLocationToDb(newLocation);
        }
public bool CreateNewLocation ( LocationViewModel newLocationViewModel ) { Location newLocation = new Location ( ) { Name = newLocationViewModel . Name } ; return _repository . AttemptAddLocationToDb ( newLocation ) ; }
attempts to create a new location in the db based on a viewmodel and returns whether or not it was successful
attempts to create a new location in the db based on a viewmodel and returns whether or not it was successful
None
newLocationViewModel
LocationViewModel
None