public TagDto AddTag(Guid articleId, TagAddDto tag)
        {
            var t = _tagDomainService.Add(Mapper.Map <Tag>(tag));

            _articleTagRelationDomainService.Add(articleId, t.Id);
            return(Mapper.Map <TagDto>(t));     //*** where to get the Name field?
        }
Beispiel #2
0
 public TagDto AddTag(Guid articleId, [FromBody] TagAddDto dto)
 {
     return(_articleAppService.AddTag(articleId, dto));
 }
 public IActionResult AddTag(Guid articleId, TagAddDto dto)
 {
     _articleAppService.AddTag(articleId, dto);
     return(RedirectToAction("Index"));
 }