Class ResultMatrix
Object
AbstractPortletDto
ResultMatrix
- All Implemented Interfaces:
Serializable
,AppPages
,Portlet
,ResultMatrix
,ComplexCalculationResult
Deprecated.
- See Also:
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
Deprecated.better use the shorterResultMatrix.Cell
static interface
Deprecated.static interface
Deprecated.static interface
Deprecated.static interface
Deprecated.static interface
Deprecated.static interface
Deprecated.static interface
Deprecated.static interface
Deprecated.static class
Deprecated.better use the shorterResultMatrix.BackEndAction
static class
Deprecated.better use the shorterResultMatrix.BackEndCell
static class
Deprecated.better use the shorterResultMatrix.Cells
static class
Deprecated.better use the shorterResultMatrix.DownloadCell
static class
Deprecated.better use the shorterResultMatrix.ImageCell
static class
Deprecated.better use the shorterResultMatrix.LinkCell
class
Deprecated.better use the shorterResultMatrix.OnRowSelection
static class
Deprecated.better use the shorterResultMatrix.StyledCell
static interface
Deprecated.Nested classes/interfaces inherited from interface ResultMatrix
ResultMatrix.LinkButtonCell
-
Field Summary
Fields inherited from class AbstractPortletDto
dragDropEnabled, layout, resizingEnabled
Fields inherited from interface AppPages
CM_MAIN_PAGE, CM_RECORDS_PAGE, CM_TYPES_PAGE, CONFIG_WIZARDS_PAGE, CUSTOM_FORMS_NEW, CUSTOM_FORMS_PAGE, CUSTOM_FORMS_TYPE_PAGE, DB_DASHBOARDS_PAGE, DP_PAGE, DP_TYPES_PAGE, MD_BOM_PAGE, MD_COMPETITION_PAGE, MD_CUSTOMERS_PAGE, MD_CX_PAGE, MD_DCR_PAGE, MD_PP_PAGE, MD_PRODUCTS_PAGE, MD_PX_PAGE, MD_SELLER_EXTENSIONS_PAGE, MD_SELLERS_PAGE, MD_WIZARD_PAGE, PA_CHART_BARLINE_PAGE, PA_CHART_BOXPLOT_PAGE, PA_CHART_BUBBLE_PAGE, PA_CHART_COMPARISONWF_PAGE, PA_CHART_DATATABLE_PAGE, PA_CHART_DETAILEDTIME_PAGE, PA_CHART_HEATMAP_PAGE, PA_CHART_HISTOGRAM_PAGE, PA_CHART_PAGE, PA_CHART_PIE_PAGE, PA_CHART_SCATTER_PAGE, PA_CHART_TIMESCATTER_PAGE, PA_CHART_TIMESERIES_PAGE, PA_CHART_WATERFALL_PAGE, PA_DATASOURCES_PAGE, PA_ROLLUPS_PAGE, PB_LPG_PAGE, PB_MPL_PAGE, PB_PL_PAGE, PB_SIMULATION_PAGE, PM_CONTRACTS_PAGE, PM_NEW_CONTRACT, PO_NEW_MODEL, QC_DETAILS_PAGE, QC_NEW_QUOTE, QC_TYPES_PAGE, RM_DETAILS_PAGE, RM_MAIN_PAGE, RM_NEW_REBATE_AGREEMENT, RM_RECORDS_PAGE, RM_TEMPLATES_PAGE, SC_ACCRUAL_RECORDS_PAGE, SC_CALCULATIONS_PAGE, SC_COMPENSATION_RECORDS_PAGE, SC_COMPENSATION_TYPES_PAGE, SC_CONDITION_TYPES_PAGE, SC_NEW_PLAN, SC_PLANS_PAGE, SELLER_EXTENSIONS_PAGE, SELLERS_PAGE, USER_ACTIONS_PAGE, USER_NEW_ACTION_PAGE
-
Constructor Summary
ModifierConstructorDescriptionDeprecated.better use the shorterPublicGroovyAPI.newMatrix()
ResultMatrix
(String... columns) Deprecated.better use the shorterPublicGroovyAPI.newMatrix(String...)
ResultMatrix
(Collection<String> columns) Deprecated.better use the shorterPublicGroovyAPI.newMatrix(Collection)
ResultMatrix
(Map jsonMap) Deprecated.better use the shorterPublicGroovyAPI.newMatrix()
protected
ResultMatrix
(ResultMatrix origin) Deprecated. -
Method Summary
Modifier and TypeMethodDescriptionvoid
Deprecated.void
Deprecated.Adds a data row.void
Deprecated.Adds a data row.Deprecated.Deprecated.Proceed grouping with groupBy columns (if missingResultMatrixGroupingException.NullOrEmptyException
is thrown) for numeric columns and aggregation strategy passed byResultMatrix.withColumnAggregation(String, Object)
orResultMatrix.withColumnAggregation(String, AggregateFunctionType)
orResultMatrix.withColumnAggregations(Map)
.Deprecated.protected FieldFormatType
decideFormat
(Object input) Deprecated.downloadButton
(String label, String url, String payload) Deprecated.Deprecated.Deprecated.Retrieves a particular row based on a value checkDeprecated.Deprecated.Gets individual column formats (if specified)Deprecated.Gets a list of defined columnsDeprecated.Gets the currently assigned column tooltipsDeprecated.Gets current column translations in raw formatDeprecated.Gets the default formatDeprecated.Returns the current list entries as a list (=the rows) of maps (= the row content)Deprecated.Deprecated.Deprecated.Gets the preference namegetTitle()
Deprecated.Gets the current titleDeprecated.Creates an image cell that can then be added as row value.boolean
Deprecated.boolean
Deprecated.Is HTML escaping enabled?boolean
Deprecated.Tells whether saving of matrix grid preferences is disabled.boolean
Deprecated.UI sorting of matrix gridlibraryImage
(String mainName, String statusName) Deprecated.linkButtonCell
(Object value, String targetPage, Object targetPageState, Object buttonState) Deprecated.better use the shorterResultMatrix.LinkButtonCell
Deprecated.void
Deprecated.Search for non nullFieldFormatType.DATETIME
columns and convert them intoDateTime
Deprecated.Configures a client-side UI event.Deprecated.Allows UI users to select multiple rows and adds an action button next to the ResultMatrix.styledCell
(Object value) Deprecated.Creates a styled cell that can then be added as row valuestyledCell
(Object value, String textColor, String bgColor) Deprecated.Creates a styled cell that can then be added as row valuestyledCell
(Object value, String textColor, String bgColor, String weight) Deprecated.Creates a styled cell that can then be added as row valueDeprecated.Creates a styled cell that can then be added as row valuetoString()
Deprecated.withColumn
(String column) Deprecated.Adds a column to the existing set of columnswithColumn
(String column, String tooltip) Deprecated.Adds a column to the existing set of columns including a tooltipwithColumnAggregation
(String column, Object aggregateValue) Deprecated.Aggregation strategy definition done by column name and aggregation value (ex.withColumnAggregation
(String numericColumn, ResultMatrixGrouping.AggregateFunctionType aggregateFunctionType) Deprecated.Aggregation strategy definition done by column-name-holding-numeric-values only (numericColumn) and aggregation type (aggregateFunctionType).withColumnAggregations
(Map<String, Object> columnAggregations) Deprecated.Aggregation strategy definition done by Map with numeric columns' name and aggregation type or value.withColumnFormat
(String column, FieldFormatType fft) Deprecated.Sets a column format for a specified columnwithColumns
(Collection<String> columns) Deprecated.Adds columns to the existing set of columnswithColumnTooltip
(String column, String tooltip) Deprecated.Adds a tooltip to a columnwithColumnTranslation
(String column, Map<String, String> translations) Deprecated.Adds translated labels for the given column.Deprecated.Sets a default column formatwithDisablePreferences
(boolean disablePreferences) Deprecated.Allows to disable saving preferences of the matrix grid (columns, sorting, filtering).withDisableSorting
(boolean disableSorting) Deprecated.Set sorting capability in UI gridwithEnableClientFilter
(boolean enableClientFilter) Deprecated.withEscapeHTML
(boolean escapeHTML) Deprecated.Set HTML escaping flag.withGroupBy
(Collection<String> columns) Deprecated.Definition of columns' names dedicated for grouping.withPreferenceName
(String preferenceName) Deprecated.Sets the so-called preference name.Deprecated.Adds a data row.Deprecated.Adds multiple data rows.Deprecated.Sets the title that will be shown as window title of the result matrix in the clientMethods inherited from class AbstractPortletDto
layout, setLayout, value, withDragDrop, withHeight, withHeight, withLayout, withLayout, withLayout, withResizing, withWidth, withWidth
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface Portlet
withDragDrop, withHeight, withHeight, withLayout, withLayout, withResizing, withWidth, withWidth
Methods inherited from interface ResultMatrix
addColumn, addColumn, addColumns, addColumnTranslation, addRow, getResultType, linkToPriceGrid, linkToPriceList, linkToPriceParameter, setColumnFormat, setColumnTooltip, setDefaultFormat, setDisablePreferences, setDisableSorting, setEnableClientFilter, setEscapeHTML, setPreferenceName, setTitle, toMatrix2D, transpose, transpose, withColumnFormats
-
Constructor Details
-
ResultMatrix
Deprecated.better use the shorterPublicGroovyAPI.newMatrix()
-
ResultMatrix
Deprecated.better use the shorterPublicGroovyAPI.newMatrix()
-
ResultMatrix
Deprecated. -
ResultMatrix
Deprecated.better use the shorterPublicGroovyAPI.newMatrix(String...)
-
ResultMatrix
Deprecated.better use the shorterPublicGroovyAPI.newMatrix(Collection)
-
-
Method Details
-
getTitle
Deprecated.Description copied from interface:ResultMatrix
Gets the current title- Specified by:
getTitle
in interfaceResultMatrix
- Returns:
- The current title
-
withTitle
Deprecated.Description copied from interface:ResultMatrix
Sets the title that will be shown as window title of the result matrix in the client- Specified by:
withTitle
in interfaceResultMatrix
- Parameters:
title
- The title
-
getPreferenceName
Deprecated.Description copied from interface:ResultMatrix
Gets the preference name- Specified by:
getPreferenceName
in interfaceResultMatrix
- Returns:
- The preference name
-
isPreferencesDisabled
public boolean isPreferencesDisabled()Deprecated.Description copied from interface:ResultMatrix
Tells whether saving of matrix grid preferences is disabled.- Specified by:
isPreferencesDisabled
in interfaceResultMatrix
- Returns:
- true if saving of grid preferences is disabled. Default is false
-
withDisablePreferences
Deprecated.Description copied from interface:ResultMatrix
Allows to disable saving preferences of the matrix grid (columns, sorting, filtering). If not disabled, the preferences may be be saved with the global dashboard preferences or attached to a specific preferences name defined with setPreferenceName()/withPreferenceName()- Specified by:
withDisablePreferences
in interfaceResultMatrix
- Parameters:
disablePreferences
- true means saving grid preferences is disabled. Default is false
-
isSortingDisabled
public boolean isSortingDisabled()Deprecated.Description copied from interface:ResultMatrix
UI sorting of matrix grid- Specified by:
isSortingDisabled
in interfaceResultMatrix
- Returns:
- true if sorting is disabled on all columns. Default is false
-
withDisableSorting
Deprecated.Description copied from interface:ResultMatrix
Set sorting capability in UI grid- Specified by:
withDisableSorting
in interfaceResultMatrix
- Parameters:
disableSorting
- true: sorting is disabled in UI on all columns
-
isEscapeHTML
public boolean isEscapeHTML()Deprecated.Description copied from interface:ResultMatrix
Is HTML escaping enabled?- Specified by:
isEscapeHTML
in interfaceResultMatrix
- Returns:
- true if the matrix should display raw text as is (i.e. not try to interpret it as HTML)
-
withEscapeHTML
Deprecated.Description copied from interface:ResultMatrix
Set HTML escaping flag. Default: false (i.e. values will be interpreted as HTML)- Specified by:
withEscapeHTML
in interfaceResultMatrix
-
withPreferenceName
Deprecated.Description copied from interface:ResultMatrix
Sets the so-called preference name. I.e. all result matrixes with the same preference name will share the same preference setting. The preference setting can be managed as usual in the client and can be set as global to predefine a good setting- Specified by:
withPreferenceName
in interfaceResultMatrix
- Parameters:
preferenceName
- The preference name
-
withColumnTranslation
Deprecated.Description copied from interface:ResultMatrix
Adds translated labels for the given column.- Specified by:
withColumnTranslation
in interfaceResultMatrix
- Parameters:
column
- The column name (as defined e.g. in the constructor)translations
- A map with the translations. The key of the map is the locale, like "de".
-
getColumnTranslations
Deprecated.Description copied from interface:ResultMatrix
Gets current column translations in raw format- Specified by:
getColumnTranslations
in interfaceResultMatrix
- Returns:
-
withColumn
Deprecated.Description copied from interface:ResultMatrix
Adds a column to the existing set of columns- Specified by:
withColumn
in interfaceResultMatrix
- Parameters:
column
- The columns name
-
withColumn
Deprecated.Description copied from interface:ResultMatrix
Adds a column to the existing set of columns including a tooltip- Specified by:
withColumn
in interfaceResultMatrix
- Parameters:
column
- The columns name
-
withColumns
Deprecated.Description copied from interface:ResultMatrix
Adds columns to the existing set of columns- Specified by:
withColumns
in interfaceResultMatrix
- Parameters:
columns
- Collection of columns names
-
addRow
Deprecated.Description copied from interface:ResultMatrix
Adds a data row. The keys of the row-map should match the column names defined earlier- Specified by:
addRow
in interfaceResultMatrix
-
getGroupBy
Deprecated.- Specified by:
getGroupBy
in interfaceResultMatrix
- Returns:
- immutable list of columns' names dedicated for grouping
- See Also:
-
getGroupByData
Deprecated.- Specified by:
getGroupByData
in interfaceResultMatrix
- Returns:
- immutable collection of data grouped by predefined columns
- See Also:
-
getAggregationStrategy
Deprecated.- Specified by:
getAggregationStrategy
in interfaceResultMatrix
- Returns:
- immutable Map of numeric column's name with aggregation value assigned to it
- See Also:
-
withGroupBy
Deprecated.Description copied from interface:ResultMatrix
Definition of columns' names dedicated for grouping. Columns passed in the collection need to be present inResultMatrix
columns' attribute. If, at least one column, is not part of theResultMatrix
columns' attribute, theResultMatrixGroupingException.NotPartOfColumnsAttributeException
will be thrown. Repetitive columns' names are removed.Example:
def resultMatrix = api.newMatrix('TextColumn1', 'TextColumn2', 'NumericColumn3', 'NumericColumn4') resultMatrix.withRows(entries) resultMatrix.withGroupBy(['TextColumn1', 'TextColumn2']) // TextColumn1 and TextColumn2 are now columns by which grouping will be done // The groupBy columns can be accessed by
ResultMatrix.getGroupBy()
def groupByColumns = resultMatrix.getGroupBy()- Specified by:
withGroupBy
in interfaceResultMatrix
- Parameters:
columns
- collection of columns' names for grouping, if null or empty theResultMatrixGroupingException.NullOrEmptyException
will be thrown.- Returns:
ResultMatrix
with groupBy columns.- See Also:
-
withColumnAggregation
public ResultMatrix withColumnAggregation(String numericColumn, ResultMatrixGrouping.AggregateFunctionType aggregateFunctionType) Deprecated.Description copied from interface:ResultMatrix
Aggregation strategy definition done by column-name-holding-numeric-values only (numericColumn) and aggregation type (aggregateFunctionType). Static import allowing for enum recognition is needed here:ResultMatrixGrouping.AggregateFunctionType
. Aggregation type can be set by one of the AggregateFunctionTypes: AVG, SUM, COUNT, MAX or MINExample:
// static import is needed to use predefined enum with aggregation type import static net.pricefx.server.dto.calculation.ResultMatrixGrouping.AggregateFunctionType.SUM // ResultMatrix with predefined columns, entries and groupBy columns def resultMatrix = api.newMatrix('TextColumn1', 'TextColumn2', 'NumericColumn3', 'NumericColumn4') resultMatrix.withRows(entries) resultMatrix.withGroupBy(['TextColumn1', 'TextColumn2']) resultMatrix.withColumnAggregation('NumericColumn3', SUM])
- Specified by:
withColumnAggregation
in interfaceResultMatrix
- Parameters:
numericColumn
- column with numeric data to proceed aggregation. If column contains non-numeric data or is not present inResultMatrix
's columns collection, theResultMatrixGroupingException.NotPartOfColumnsAttributeException
will be thrownaggregateFunctionType
- predefined aggregation type: AggregateFunctionType.AVG, AggregateFunctionType.SUM, AggregateFunctionType.COUNT, AggregateFunctionType.MAX or AggregateFunctionType.MIN- Returns:
ResultMatrix
with aggregation strategy updated- See Also:
-
withColumnAggregation
Deprecated.Description copied from interface:ResultMatrix
Aggregation strategy definition done by column name and aggregation value (ex. some constantString
). Aggregation value can be set as anyObject
.Example:
// ResultMatrix with predefined columns, entries and groupBy columns def resultMatrix = api.newMatrix('TextColumn1', 'TextColumn2', 'NumericColumn3', 'NumericColumn4') resultMatrix.withRows(entries) resultMatrix.withGroupBy(['TextColumn1', 'TextColumn2']) resultMatrix.withColumnAggregation('TextColumn1', 'some text'])
- Specified by:
withColumnAggregation
in interfaceResultMatrix
- Parameters:
column
- column name, needs to be part of the ResultMatrix columns attributeaggregateValue
- any object, which will be presented in the groupBy record- See Also:
-
withColumnAggregations
Deprecated.Description copied from interface:ResultMatrix
Aggregation strategy definition done by Map with numeric columns' name and aggregation type or value. Aggregation value can be set as anyObject
or aggregation functionResultMatrixGrouping.AggregateFunctionType
(AVG, SUM, COUNT, MAX or MIN)Example:
// static import is needed to use predefined enum with aggregation types import static net.pricefx.server.dto.calculation.ResultMatrixGrouping.AggregateFunctionType.SUM // ResultMatrix with predefined columns, entries and groupBy columns def resultMatrix = api.newMatrix('TextColumn1', 'TextColumn2', 'NumericColumn3', 'NumericColumn4') resultMatrix.withRows(entries) resultMatrix.withGroupBy(['TextColumn1', 'TextColumn2']) // Key in the columnAggregations needs to be the column's name which contains only numbers // Value in the columnAggregations can be any object or one of the AggregateFunctionType enum resultMatrix.withColumnAggregation([NumericColumn3 : SUM])
- Specified by:
withColumnAggregations
in interfaceResultMatrix
- Parameters:
columnAggregations
- Map with numeric-column-name and aggregation type or value- Returns:
ResultMatrix
with aggregation strategy updated- See Also:
-
calculateGroupByData
Deprecated.Description copied from interface:ResultMatrix
Proceed grouping with groupBy columns (if missingResultMatrixGroupingException.NullOrEmptyException
is thrown) for numeric columns and aggregation strategy passed byResultMatrix.withColumnAggregation(String, Object)
orResultMatrix.withColumnAggregation(String, AggregateFunctionType)
orResultMatrix.withColumnAggregations(Map)
. If AggregateType has one of the predefined keywords (ie.: SUM, AVG, COUNT, MAX or MIN), the numeric operation will be proceeded on the numeric columns. This is terminal operation, which means, it needs to be called as the last one (after setting columns and groupBy)Example:
// (1) static import is needed to use predefined enum with aggregation types import static net.pricefx.server.dto.calculation.ResultMatrixGrouping.AggregateFunctionType.SUM // (2) new ResultMatrix with predefined columns def resultMatrix = api.newMatrix('TextColumn1', 'TextColumn2', 'NumericColumn3', 'NumericColumn4') // (3) add entries to the above ResultMatrix resultMatrix.withRows(entries) // (4) set groupBy columns, which needs to be a part of columns' collection from (1) resultMatrix.withGroupBy(['TextColumn1', 'TextColumn2']) // (5) set aggregation strategy for numericColumn3 as SUM, numericColumn3 needs to contains only numbers resultMatrix.withColumnAggregation('NumericColumn3', SUM) // (6) do the grouping and aggregation calculations, which also adds data to groupByData ResultMatrix property resultMatrix.calculateGroupByData() // (7) grouped and aggregated data can be accessed by the getter def groupByData = resultMatrix.getGroupByData() // Other getters allow for access to groupBy columns and aggregation strategy def groupByColumns = resultMatrix.getGroupBy() def aggregationStrategy = resultMatrix.getAggregationStrategy()
// All operations can be chained to get the final groupBy data import static net.pricefx.server.dto.calculation.ResultMatrixGrouping.AggregateFunctionType.SUM def groupByData = api.newMatrix() .withColumns('TextColumn1', 'TextColumn2', 'NumericColumn3', 'NumericColumn4') .withRows(entries) .withGroupBy(['TextColumn1', 'TextColumn2']) .withColumnAggregation('NumericColumn3', SUM) .calculateGroupByData() .getGroupByData()
ResultMatrix
is created.
When aggregated rows arenull
theRESULT_MATRIX_NULL_ENTRIES_EXCEPTION
exception is thrown.- Specified by:
calculateGroupByData
in interfaceResultMatrix
- Returns:
ResultMatrix
with grouped and aggregated data (can be accessed byResultMatrix.getGroupByData()
- See Also:
-
withRow
Deprecated.Description copied from interface:ResultMatrix
Adds a data row. The order of the values is assumed to be the same as the matrix column order.- Specified by:
withRow
in interfaceResultMatrix
- Parameters:
row
- Row as List
-
withRows
Deprecated.Description copied from interface:ResultMatrix
Adds multiple data rows. The keys of the row-map should match the column names defined earlier- Specified by:
withRows
in interfaceResultMatrix
- Parameters:
rows
- Row as List of Maps
-
addRow
Deprecated.Description copied from interface:ResultMatrix
Adds a data row. The order of the values is assumed to be the same as the matrix column order.- Specified by:
addRow
in interfaceResultMatrix
- Parameters:
values
- Row as Array
-
getColumns
Deprecated.Description copied from interface:ResultMatrix
Gets a list of defined columns- Specified by:
getColumns
in interfaceResultMatrix
- Returns:
- The columns
-
getEntries
Deprecated.Description copied from interface:ResultMatrix
Returns the current list entries as a list (=the rows) of maps (= the row content)- Specified by:
getEntries
in interfaceResultMatrix
- Returns:
- List of maps
-
findRow
Deprecated.Description copied from interface:ResultMatrix
Retrieves a particular row based on a value check- Specified by:
findRow
in interfaceResultMatrix
- Parameters:
key
- The column name to search onvalue
- The value to match the row's column value to- Returns:
- The row
-
withDefaultFormat
Deprecated.Description copied from interface:ResultMatrix
Sets a default column format- Specified by:
withDefaultFormat
in interfaceResultMatrix
-
getDefaultFormat
Deprecated.Description copied from interface:ResultMatrix
Gets the default format- Specified by:
getDefaultFormat
in interfaceResultMatrix
- Returns:
- Default format
-
getColumnFormats
Deprecated.Description copied from interface:ResultMatrix
Gets individual column formats (if specified)- Specified by:
getColumnFormats
in interfaceResultMatrix
- Returns:
- A Map with column name and format
-
withColumnFormat
Deprecated.Description copied from interface:ResultMatrix
Sets a column format for a specified column- Specified by:
withColumnFormat
in interfaceResultMatrix
- Parameters:
column
- The column namefft
- The format
-
getColumnTooltips
Deprecated.Description copied from interface:ResultMatrix
Gets the currently assigned column tooltips- Specified by:
getColumnTooltips
in interfaceResultMatrix
- Returns:
-
withColumnTooltip
Deprecated.Description copied from interface:ResultMatrix
Adds a tooltip to a column- Specified by:
withColumnTooltip
in interfaceResultMatrix
- Parameters:
column
- The column nametooltip
- The tooltip text
-
isEnableClientFilter
public boolean isEnableClientFilter()Deprecated.- Specified by:
isEnableClientFilter
in interfaceResultMatrix
-
withEnableClientFilter
Deprecated.- Specified by:
withEnableClientFilter
in interfaceResultMatrix
-
styledCell
Deprecated.Description copied from interface:ResultMatrix
Creates a styled cell that can then be added as row value- Specified by:
styledCell
in interfaceResultMatrix
- Parameters:
value
- The value of the cell- Returns:
- The styled cell object that can then be further styled with e.g. the flow pattern .withXXX() methods
-
styledCell
public ResultMatrix.ResultMatrixStyledCell styledCell(Object value, String textColor, String bgColor) Deprecated.Description copied from interface:ResultMatrix
Creates a styled cell that can then be added as row value- Specified by:
styledCell
in interfaceResultMatrix
- Parameters:
value
- The value of the celltextColor
- The text color of the cellbgColor
- The background color of the cell (HTML hex value)- Returns:
- The styled cell object
-
styledCell
public ResultMatrix.ResultMatrixStyledCell styledCell(Object value, String textColor, String bgColor, String weight) Deprecated.Description copied from interface:ResultMatrix
Creates a styled cell that can then be added as row value- Specified by:
styledCell
in interfaceResultMatrix
- Parameters:
value
- The value of the celltextColor
- The text color of the cellbgColor
- The background color of the cell (HTML hex value)weight
- The font weight- Returns:
- The styled cell object
-
styledCell
public ResultMatrix.ResultMatrixStyledCell styledCell(Object value, String textColor, String bgColor, String weight, String alignment) Deprecated.Description copied from interface:ResultMatrix
Creates a styled cell that can then be added as row value- Specified by:
styledCell
in interfaceResultMatrix
- Parameters:
value
- The value of the celltextColor
- The text color of the cellbgColor
- The background color of the cell (HTML hex value)weight
- The font weightalignment
- Cell alignement value (valid CSS)- Returns:
- The styled cell object
-
imageCell
Deprecated.Description copied from interface:ResultMatrix
Creates an image cell that can then be added as row value. Value should be a valid image URL- Specified by:
imageCell
in interfaceResultMatrix
- Parameters:
value
- The image URL- Returns:
- The image cell object
-
libraryImage
Deprecated.- Specified by:
libraryImage
in interfaceResultMatrix
-
linkCell
public ResultMatrix.ResultMatrixLinkCell linkCell(Object value, String targetPage, Object targetPageState) Deprecated.- Specified by:
linkCell
in interfaceResultMatrix
-
linkButtonCell
public ResultMatrix.LinkButtonCell linkButtonCell(Object value, String targetPage, Object targetPageState, Object buttonState) Deprecated.better use the shorterResultMatrix.LinkButtonCell
Description copied from interface:ResultMatrix
Displays a button inside a cell of the table.
Simple button example:
def targetPageState = [quoteType: 'Quote with Inputs in Header', Customer: 'custId'] def cell = matrix.linkButtonCell('New Quote', AppPages.QC_NEW_QUOTE, targetPageState, null) matrix.addRow('Customer A', 'Value X', cell)
Advanced button example:
def customerPageState = [Customer: 'custId'] def groupPageState = [customerFieldName:'customerId', customerFieldValue:custId] def builder = api.inputBuilderFactory() .createQuoteType("New quote") .buildContextParameter() def cell = matrix.linkButtonCell('cell value' /*not displayed*/, AppPages.QC_NEW_QUOTE, groupPageState, builder) matrix.addRow('Customer A', 'Value X', cell)
Note: This is available in Unity UI only. No backporting planned for the Classic UI.
- Specified by:
linkButtonCell
in interfaceResultMatrix
-
backEndAction
public ResultMatrix.ResultMatrixBackEndCell backEndAction(String label, String url, String payload, String successMessage, String failMessage) Deprecated.- Specified by:
backEndAction
in interfaceResultMatrix
-
rowSelectionBackEndAction
Deprecated.Description copied from interface:ResultMatrix
Allows UI users to select multiple rows and adds an action button next to the ResultMatrix. Multiple such action buttons can be defined, identified by the provided
id String
.The action will be handled by a dedicated logic, which receives an
InputMatrix
parameter named after the providedid
and featuring the row values of a subset of the columns.Example:
def matrix = api.newMatrix("col1", "col2", "col3") matrix.addRow(1, "a", "f") matrix.addRow(2, "b", "g") matrix.rowSelectionBackEndAction("actionId") .withLogicName("action_handler") .withColumns("col2", "col3") .withButtonLabel("Click here") .withSuccessMessage("Success") .withFailureMessage("Sorry")
Note: This is available in Unity UI only. No backporting planned for the Classic UI.
See
ResultMatrix.BackEndAction
to explore the full list of methods allowing to configure an action.- Specified by:
rowSelectionBackEndAction
in interfaceResultMatrix
- Parameters:
id
- aString
identifying the action- Returns:
- a customizable object representing an action button, which the UI will then render and make functional
-
downloadButton
public ResultMatrix.ResultMatrixDownloadCell downloadButton(String label, String url, String payload) Deprecated.- Specified by:
downloadButton
in interfaceResultMatrix
-
cells
Deprecated.- Specified by:
cells
in interfaceResultMatrix
-
onRowSelection
Deprecated.Description copied from interface:ResultMatrix
Configures a client-side UI event. Use case is usually a refresh of some sort when a result matrix row is selected Example:
The embedded dashboard that receives the event could then look like:matrix.onRowSelection().triggerEvent(api.dashboardWideEvent("CustomerIdChanged-ED")).withColValueAsEventDataAttr("CustomerID", "customerId")
return api.dashboard("EmbeddedDashboard") // Here the user can assign values to the embedded // dashboard inputs common to all three modes .setParam("Customer Id", input."Customer Id") .setParam("Year", input.Year) // Show the dashboard embedded ... .showEmbedded() // ... and reevaluate it on "CustomerIdChanged-ED" // Note: "dashboardWideEvent()" fce makes the event local // to the containing dashboard instance .andRecalculateOn(api.dashboardWideEvent("CustomerIdChanged-ED")) // Pull the "customerId" attribute out of the event payload and expose it // as the "Customer Id" input to the embedded dashboard .withEventDataAttr("customerId").asParam("Customer Id")
- Specified by:
onRowSelection
in interfaceResultMatrix
- Returns:
- The selection event to further configure it in a flow pattern
-
toString
Deprecated. -
decideFormat
Deprecated. -
addFormatsToResultMatrix
public void addFormatsToResultMatrix()Deprecated.- Specified by:
addFormatsToResultMatrix
in interfaceResultMatrix
-
normalizeDateTimes
public void normalizeDateTimes()Deprecated.Description copied from interface:ResultMatrix
Search for non nullFieldFormatType.DATETIME
columns and convert them intoDateTime
- Specified by:
normalizeDateTimes
in interfaceResultMatrix
-
filter
Deprecated.
-
ResultMatrix