Exemplo n.º 1
0
        public async Task <ActionResult <IssuModel> > Post([FromBody] IssuModel issu)
        {
            var lxRslt = await IssuBO.Create(issu);

            if (lxRslt.Err != null)
            {
                return(BadRequest(issu));
            }

            return(CreatedAtAction(nameof(Get), new { id = issu.IssuId }, issu));
        }
Exemplo n.º 2
0
        public async Task <IActionResult> OnPost()
        {
            Issu.LstLbl = LstLbl;

            var lxRslt = await IssuBO.Create(Issu);

            if (lxRslt.Err != null)
            {
                TempData["ExErr"] = lxRslt.Err;
                return(Page());
            }

            return(RedirectToPage("./Index"));
        }