public Solutions Create(Solutions solution) { _validator.ValidateAndThrowEx(solution, ruleSet: nameof(ISolutionsLogic.Create)); _modifier.ForCreate(solution); return(_datastore.Create(solution)); }
public virtual IActionResult ApiSolutionsPost([FromBody] Solution solution) { try { solution = _datastore.Create(solution); } catch (Crm.CrmApiException ex) { return(StatusCode((int)ex.HttpStatus, ex.Message)); } return(new ObjectResult(solution)); }