public async Task <IActionResult> Post([FromBody] CartModel model) { if (model is null) { return(BadRequest()); } var result = await _services.Save(model); return(result > 0 ? (IActionResult)Ok(result) : (IActionResult)BadRequest()); }