private IEnumerable<BehaviorChain> getChainsWithoutOutput()
 {
     var filter = new JsonGridFilter {ColumnName = _viewFilter.Column.Name(), Values = new[] {ViewColumn.None}};
     return _graph
         .Behaviors
         .Where(chain => _viewFilter.AppliesTo(chain, filter)
                         && _viewFilter.Matches(chain, filter));
 }
Ejemplo n.º 2
0
 public static JsonGridQuery ForFilter(JsonGridFilter filter)
 {
     return new JsonGridQuery
            	{
                 Filters = new List<JsonGridFilter> { filter },
                 page = 0,
                 rows = -1,
                 sidx = filter.ColumnName,
                 sord = JsonGridQuery.ASCENDING
            	};
 }
Ejemplo n.º 3
0
 public static JsonGridQuery ForFilter(JsonGridFilter filter)
 {
     return(new JsonGridQuery
     {
         Filters = new List <JsonGridFilter> {
             filter
         },
         page = 0,
         rows = -1,
         sidx = filter.ColumnName,
         sord = JsonGridQuery.ASCENDING
     });
 }
Ejemplo n.º 4
0
 public JsonAutocompleteResultModel Execute(AutocompleteRequestModel<BehaviorGraph> request)
 {
     var filter = new JsonGridFilter {ColumnName = request.Column, Values = new List<string> {request.Query}};
     var query = JsonGridQuery.ForFilter(filter);
     return new JsonAutocompleteResultModel
                {
                    Values = _gridService
                        .GridFor(_behaviorGraph, query)
                        .Rows
                        .SelectMany(r => r.Columns.Where(c => c.Name.Equals(request.Column, StringComparison.OrdinalIgnoreCase)))
                        .Distinct()
                };
 }
Ejemplo n.º 5
0
 public JsonAutocompleteResultModel Post(AutocompleteRequestModel<RequestCacheModel> request)
 {
     var model = _modelBuilder.Build();
     var filter = new JsonGridFilter { ColumnName = request.Column, Values = new List<string> { request.Query } };
     var query = JsonGridQuery.ForFilter(filter);
     return new JsonAutocompleteResultModel
     {
         Values = _gridService
             .GridFor(model, query)
             .Rows
             .SelectMany(r => r.Columns.Where(c => c.Name.Equals(request.Column, StringComparison.OrdinalIgnoreCase)))
             .Distinct()
     };
 }