public async Task <bool> EditServiceProgramAsync(ServiceProgramViewModel entity, int id) { var ent = await _programRepository.GetById(id); if (ent != null) { ent.OpenHour = entity.OpenHour; ent.OpenMinute = entity.OpenMinute; ent.CloseHour = entity.CloseHour; ent.CloseMinute = entity.CloseMinute; return(await _programRepository.Update(ent)); } else { return(await Task.FromResult(false)); } }