public async Task <ResponseResult> Handle(Necessary request, CancellationToken cancellationToken)
            {
                using (var scope = _databaseScopeFactory.CreateWithTransaction())
                {
                    await _materialTypeRepository.SetPropertyNecessary(
                        request.Id,
                        request.IsNecessary,
                        string.IsNullOrWhiteSpace(request.UserId)?null : request.UserId);

                    scope.SaveChanges();

                    return(ResponseResult.Ok());
                }
            }
Exemple #2
0
 public NodeFromMapping(string mainXpath, string necXpath)
 {
     this.mainXpath = mainXpath;
     Necessary Necnode = new Necessary(necXpath);
 }