本文整理汇总了TypeScript中igniteui-angular.IgxGridComponent类的典型用法代码示例。如果您正苦于以下问题:TypeScript IgxGridComponent类的具体用法?TypeScript IgxGridComponent怎么用?TypeScript IgxGridComponent使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了IgxGridComponent类的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的TypeScript代码示例。
示例1: onInput
public onInput(input: any, column: IgxColumnComponent) {
let operand = null;
switch (column.dataType) {
case DataType.Number:
operand = IgxNumberFilteringOperand.instance().condition('equals');
case DataType.Date:
operand = IgxDateFilteringOperand.instance().condition('equals');
default:
operand = IgxStringFilteringOperand.instance().condition('contains');
}
this.grid1.filter(column.field, input.value, operand, column.filteringIgnoreCase);
}
示例2: toggleVisibility
toggleVisibility(name: string) {
const col = this.grid1.getColumnByName(name);
col.hidden = !col.hidden;
}
示例3: toggleColumn
toggleColumn(name: string) {
const col = this.grid1.getColumnByName(name);
col.pinned = !col.pinned;
}
示例4: toggleColumn
toggleColumn(name: string) {
const col = this.grid1.getColumnByName(name);
col.pinned ? col.pinned = false : col.pinned = true;
}
示例5: clearInput
public clearInput(input: any, column: any) {
input.value = null;
this.grid1.clearFilter(column.field);
}
示例6: filter
public filter(term) {
this.grid1.filter("ProductName", term, IgxStringFilteringOperand.instance().condition("contains"));
}