cpr.controls.provider.GridRowGroup

Hierarchy

Index

Properties
Name Type Description
endRowIndex Number Returns the row index of the end of the current rowgroup.
expanded Boolean Returns whether the current rowgroup is expanded.
groupCondition String Returns the group condition for a group of rows.
parent GridRowGroup
startRowIndex Number Returns the starting row index of the current rowgroup.
target GridRow Returns the GridRow object corresponding to the GridRowGroup.
Methods
Name Return Type Description
collapse Collapse the row group.
expand Expand the row group.
getAvg DecimalType Returns the average of the data in the column name entered in the rowgroup.
getConditionalAvg DecimalType Returns the average of the data of the column names received among the rows that meet the conditions in the rowgroup.
getConditionalMax Object Returns the maximum value of the column name data entered among the rows that meet the conditions in the rowgroup.
getConditionalMin Object Returns the minimum value of the column name data among the rows that meet the conditions in the rowgroup.
getConditionalRowCount Number Returns the number of rows in the rowgroup that match the condition.
getConditionalSum DecimalType Returns the sum of the column name data among the rows that meet the conditions in the rowgroup.
getLocalIndex Number Returns the index of the current group row.
getMax Object Returns the maximum value of the column name data input from the rowgroup.
getMin Object Returns the minimum value among the data of the column name input from the rowgroup.
getRowCount Number Returns the current number of rows.
getSum DecimalType Returns the sum of the data of the column names entered in the rowgroup.
getValue Object Returns the value of a specific column.

Constructor

GridRowGroup(grid, dataControl, targetRow, parent, option)
Parameters
name type description
grid Grid
dataControl DataCollection
targetRow GridRow
parent GridRowGroup
option {[key:string]: Object}

Properties

endRowIndex
type Number
readonly
Returns the row index of the end of the current rowgroup.
In the case of Tricell, since one row has one row group,
For rows without children, its row index is startRowIndex, endRowIndex.
expanded
type Boolean
get
Returns whether the current rowgroup is expanded.
set
Sets the expansion of the current rowgroup.
groupCondition
type String
readonly
Returns the group condition for a group of rows.
If multiple group conditions are set, blanks are removed, and column names are returned in ascending order.
parent
type GridRowGroup
startRowIndex
type Number
readonly
Returns the starting row index of the current rowgroup.
In the case of Tricell, since one row has one row group,
For rows without children, its row index is startRowIndex, endRowIndex.
target
type GridRow
readonly
Returns the GridRow object corresponding to the GridRowGroup.
In case of GridRowGroup created by TreeCell, it can have target.

Methods

collapse(deep)
Collapse the row group.
Parameters
name type description
deepoptional Boolean defaultfalse Whether to fold down to sub-depth rowgroups.
expand(deep)
Expand the row group.
Parameters
name type description
deepoptional Boolean defaultfalse Whether to expand to sub-depth rowgroups.
getAvg(columnName)
Returns the average of the data in the column name entered in the rowgroup.
It should be used only when the value of the input column name is of type Number.
Parameters
name type description
columnName #column Column name or expression to average.
return DecimalType The average of the values ​​of the input column names.
getConditionalAvg(condition, columnName)
Returns the average of the data of the column names received among the rows that meet the conditions in the rowgroup.
It should be used only when the value of the column name is of type Number.

※ Search for rows that meet the conditions in the view-based rows.
Parameters
name type description
condition #expression Filtering conditions.
columnName #column Column name or expression to average.
return DecimalType The average of the data of the column name input among the rows that meet the condition.
getConditionalMax(condition, columnName)
Returns the maximum value of the column name data entered among the rows that meet the conditions in the rowgroup.

※ Search for rows that meet the conditions in the view-based rows.
Parameters
name type description
condition #expression Filtering conditions.
columnName #column Column name or expression for which you want to find the maximum value.
return Object The maximum value of the column name data received among the rows that meet the conditions.
getConditionalMin(condition, columnName)
Returns the minimum value of the column name data among the rows that meet the conditions in the rowgroup.
※ Search for rows that meet the conditions in the view-based rows.
Parameters
name type description
condition #expression Filtering conditions.
columnName #column Column name or expression for which you want to find the maximum value.
return Object The minimum value of the column name data entered among the rows that meet the conditions.
getConditionalRowCount(condition)
Returns the number of rows in the rowgroup that match the condition.

※ Search for the row that matches the condition in the view base row.
Parameters
name type description
condition #expression Filtering conditions.
return Number Number of rows matching the condition.
getConditionalSum(condition, columnName)
Returns the sum of the column name data among the rows that meet the conditions in the rowgroup.
It should be used only when the value of the column name is of type Number.

※ Search for rows that meet the conditions in the row based on the view
Parameters
name type description
condition #expression Filtering conditions.
columnName #column Column name or expression for which you want to sum.
return DecimalType Sum of data of input column name of Row matching condition.
getLocalIndex()
declaring typeIGridRow
Returns the index of the current group row. Index within the parent group.
return Number The index of the current group row.
getMax(columnName)
Returns the maximum value of the column name data input from the rowgroup.
The comparison standard follows the dataType of the corresponding column.
Parameters
name type description
columnName #column Column name or Expression for which you want to find the maximum value.
return Object The maximum value of the input column name value.
getMin(columnName)
Returns the minimum value among the data of the column name input from the rowgroup.
The comparison standard follows the dataType of the corresponding column.
Parameters
name type description
columnName #column Column name or expression to find the minimum value.
return Object The minimum value of the input column name value.
getRowCount()
Returns the current number of rows.
return Number Number of rows.
getSum(columnName)
Returns the sum of the data of the column names entered in the rowgroup.
It should be used only when the value of the input column name is of type Number.
Parameters
name type description
columnName #column Column name or expression for which you want to sum.
return DecimalType Sum of input column name values.
getValue(rowIndex, columnName)
Returns the value of a specific column.
Parameters
name type description
rowIndex Number The row index of the row from which to retrieve the value.
columnName #column The columnName of the column for which to get the value.
return Object That data.