public async Task <ActionResult> AddAsync([FromBody] RuleBO model)
        {
            var rule = await _rulesService
                       .AddAsync(model);

            if (rule != null)
            {
                return(CreatedAtAction("Get", new { id = rule.Id }, rule));
            }

            return(BadRequest());
        }
Beispiel #2
0
        public async Task <IActionResult> Add([FromBody] RuleReplyDto model)
        {
            var res = await ruleService.AddAsync(model);

            return(Ok(res));
        }