private RenderFragment CreateSubGridComponent(ICGrid grid) => builder => { Type gridComponentType = typeof(GridComponent <>).MakeGenericType(grid.Type); builder.OpenComponent(++_sequence, gridComponentType); builder.AddAttribute(++_sequence, "Grid", grid); builder.CloseComponent(); };
private RenderFragment CreateSubGridComponent(ICGrid grid, VariableReference reference) => builder => { Type gridComponentType = typeof(GridComponent <>).MakeGenericType(grid.Type); builder.OpenComponent(++_sequence, gridComponentType); builder.AddAttribute(++_sequence, "Grid", grid); builder.AddComponentReferenceCapture(++_sequence, r => reference.Variable = r); builder.CloseComponent(); };
public SortGridODataProcessor(ICGrid grid, IGridSortSettings settings) { if (settings == null) { throw new ArgumentNullException("settings"); } _grid = grid; _settings = settings; }
private RenderFragment CreateSubGridComponent(ICGrid grid, VariableReference reference) => builder => { Type gridComponentType = typeof(GridComponent <>).MakeGenericType(grid.Type); builder.OpenComponent(0, gridComponentType); builder.AddAttribute(1, "Grid", grid); builder.AddAttribute(2, "UseMemoryCrudDataService", true); builder.AddComponentReferenceCapture(3, r => reference.Variable = r); builder.CloseComponent(); };
public FilterGridODataProcessor(ICGrid grid, IGridFilterSettings settings, IGridSearchSettings searchSettings) { if (settings == null) { throw new ArgumentNullException("settings"); } _grid = grid; _settings = settings; _searchSettings = searchSettings; }
protected override async Task OnParametersSetAsync() { _visible = GridComponent.IsSubGridVisible[GridPosition]; _init = GridComponent.InitSubGrid[GridPosition]; if (_visible && (_grid == null || _init)) { GridComponent.InitSubGrid[GridPosition] = false; _grid = await GridComponent.Grid.SubGrids(Values); _subGridRender = CreateSubGridComponent(); } }
protected override async Task OnParametersSetAsync() { if (GridPosition < GridComponent.IsSubGridVisible.Length && GridPosition < GridComponent.InitSubGrid.Length) { _visible = GridComponent.IsSubGridVisible[GridPosition]; _init = GridComponent.InitSubGrid[GridPosition]; if (_visible && (_grid == null || _init)) { GridComponent.InitSubGrid[GridPosition] = false; _grid = await GridComponent.Grid.SubGrids(Values.Values.ToArray()); _grid.FixedValues = Values; _subGridRender = CreateSubGridComponent(); } } }
public HiddenGridColumn(Expression <Func <T, TDataType> > expression, ICGrid <T> grid) { _grid = grid; SortEnabled = false; Hidden = true; if (expression != null) { var expr = expression.Body as MemberExpression; if (expr == null) { throw new ArgumentException( string.Format("Expression '{0}' must be a member expression", expression), "expression"); } _constraint = expression.Compile(); Name = PropertiesHelper.BuildColumnNameFromMemberExpression(expr); } }
internal static string GetRowStringKeys <T>(this ICGrid grid, T item) { var keys = grid.GetPrimaryKeyValues(item); return(string.Join('_', keys)); }
public ExpandGridODataProcessor(ICGrid grid) { _grid = grid; }
public PagerGridODataProcessor(ICGrid grid) { _grid = grid; }