Skip to content

Commit

Permalink
updated survey-library docs [azurepipelines skip]
Browse files Browse the repository at this point in the history
  • Loading branch information
dmitry-kurmanov committed Jun 6, 2024
1 parent 9050151 commit 6320ce0
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions docs/design-survey-conditional-logic.md
Original file line number Diff line number Diff line change
Expand Up @@ -482,7 +482,7 @@ Returns the sum of numbers taken from a specified data field. This data field is
The following code sums up values from a `"total"` matrix column but includes only the rows with a `"categoryId"` column equaling 1:
*Example*: `"expression": "sumInArray({matrixdynamic}, 'total', '{categoryId} = 1')"`
*Example*: `"expression": "sumInArray({matrixdynamic}, 'total', {categoryId} = 1)"`
[View Source Code](https://github.com/surveyjs/survey-library/blob/68eb0054dc83d2f45a6daa1042bf7440c8faf007/src/functionsfactory.ts#L164-L171 (linkStyle))
Expand All @@ -496,7 +496,7 @@ Returns the maximum of numbers taken from a specified data field. This data fiel
The following code finds a maximum value within a `"quantity"` matrix column, but the value should be under 100:
*Example*: `"expression": "maxInArray({matrixdynamic}, 'quantity', '{quantity} < 100')"`
*Example*: `"expression": "maxInArray({matrixdynamic}, 'quantity', {quantity} < 100)"`
[View Source Code](https://github.com/surveyjs/survey-library/blob/68eb0054dc83d2f45a6daa1042bf7440c8faf007/src/functionsfactory.ts#L181-L187 (linkStyle))
Expand All @@ -510,7 +510,7 @@ Returns the minimum of numbers taken from a specified data field. This data fiel
The following code finds a minimum value within a `"quantity"` matrix column but searches for it only in the rows with a `"categoryId"` column equaling 1 and includes only positive values:
*Example*: `"expression": "minInArray({matrixdynamic}, 'quantity', '{quantity} > 0 and {categoryId} = 1')"`
*Example*: `"expression": "minInArray({matrixdynamic}, 'quantity', {quantity} > 0 and {categoryId} = 1)"`
[View Source Code](https://github.com/surveyjs/survey-library/blob/68eb0054dc83d2f45a6daa1042bf7440c8faf007/src/functionsfactory.ts#L173-L179 (linkStyle))
Expand All @@ -524,7 +524,7 @@ Returns the average of numbers taken from a specified data field. This data fiel
The following code finds an average of values within a `"quantity"` matrix column, excluding zeroes:
*Example*: `"expression": "avgInArray({matrixdynamic}, 'quantity', '{quantity} > 0')"`
*Example*: `"expression": "avgInArray({matrixdynamic}, 'quantity', {quantity} > 0)"`
[View Source Code](https://github.com/surveyjs/survey-library/blob/68eb0054dc83d2f45a6daa1042bf7440c8faf007/src/functionsfactory.ts#L198-L203 (linkStyle))
Expand All @@ -538,7 +538,7 @@ Returns the total number of array items in which a specified data field has a va
The following code finds the total number of matrix rows with a `"quantity"` column value greater than zero but includes only the rows with a `"categoryId"` column equaling 1:
*Example*: `"expression": "countInArray({matrixdynamic}, 'quantity', '{quantity} > 0 and {categoryId} = 1')"`
*Example*: `"expression": "countInArray({matrixdynamic}, 'quantity', {quantity} > 0 and {categoryId} = 1)"`
[View Source Code](https://github.com/surveyjs/survey-library/blob/68eb0054dc83d2f45a6daa1042bf7440c8faf007/src/functionsfactory.ts#L189-L196 (linkStyle))
Expand Down

0 comments on commit 6320ce0

Please sign in to comment.