public async Task <IActionResult> Insert(SubRubroModel model)
        {
            if (!ModelState.IsValid)
            {
                return(BadRequest(ModelState));
            }
            var subRubro = _mapper.Map <SubRubroDto>(model);
            await _subRubroServicio.Insertar(subRubro);

            return(Ok(model));
        }
        public async Task <IActionResult> Edit(long id, SubRubroModel model)
        {
            if (!ModelState.IsValid)
            {
                return(BadRequest(ModelState));
            }

            var subRubro = _mapper.Map <SubRubroDto>(model);

            subRubro.Id = id;
            await _subRubroServicio.Modificar(subRubro);

            return(Ok(model));
        }