예제 #1
0
        /// <summary>
        /// Delete method,
        /// deletes VehicleMake using VehicleMake Repository.
        /// </summary>
        /// <param name="Id">VehicleMake Id, type of int.</param>
        /// <returns>Returns boolean to controller, so controller knows if VehicleMake was deleted or not.</returns>
        public async Task <Boolean> DeleteVehicleMakeAsync(int Id)
        {
            var entity = await repository.GetVehicleMakeAsync((int)Id);

            if (entity != null)
            {
                await repository.DeleteVehicleMakeAsync(entity);

                return(true);
            }
            else
            {
                return(false);
            }
        }
예제 #2
0
        /// <summary>
        /// REMOVE VEHICLE MAKE
        /// </summary>

        public async Task DeleteVehicleMakeAsync(int id)
        {
            await _repository.DeleteVehicleMakeAsync(id);
        }
예제 #3
0
 public Task <int> DeleteVehicleMakeAsync(Guid id)
 {
     return(vehicleMakeRepository.DeleteVehicleMakeAsync(id));
 }