public IActionResult Post([FromBody] StoreViewModel ViewModel) { if (!ModelState.IsValid) { return(BadRequest(ViewModel)); } try { _appService.Insert(ViewModel); return(Ok(ViewModel)); } catch (Exception) { return(BadRequest(ViewModel)); } }
public IActionResult Post([FromBody] StoreViewModel ViewModel) { if (!ModelState.IsValid) { return(BadRequest(ViewModel)); } try { _appService.Insert(ViewModel); return(Ok(ViewModel)); } catch (Exception) { return(BadRequest(ViewModel)); } }