mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
Change the old VisibilityCondition format with the new one (#4934)
This commit is contained in:
committed by
Eugenio Romano
parent
76c938800f
commit
0226a7a3bd
@@ -24,7 +24,7 @@ import { UsersActions } from '../../actions/users.actions';
|
||||
import { FormCloudDemoPage } from '../../pages/adf/demo-shell/process-services-cloud/cloudFormDemoPage';
|
||||
import { checkboxVisibilityForm } from '../../resources/forms/checkbox-visibility-condition';
|
||||
|
||||
describe('Visibility conditions', () => {
|
||||
describe('Visibility conditions - cloud', () => {
|
||||
|
||||
const loginPage = new LoginPage();
|
||||
const navigationBarPage = new NavigationBarPage();
|
@@ -17,206 +17,196 @@
|
||||
|
||||
/* tslint:disable */
|
||||
export const checkboxVisibilityForm = `{
|
||||
"formRepresentation": {
|
||||
"id": "form-412cdeab-de90-4099-875f-676366e48fc9",
|
||||
"name": "test",
|
||||
"description": "",
|
||||
"version": 0,
|
||||
"formDefinition": {
|
||||
"tabs": [],
|
||||
"fields": [
|
||||
{
|
||||
"id": "85a4f564-2c70-438a-ae0f-b9c8af4887c2",
|
||||
"name": "Label",
|
||||
"type": "container",
|
||||
"tab": null,
|
||||
"numberOfColumns": 2,
|
||||
"fields": {
|
||||
"1": [
|
||||
{
|
||||
"id": "CheckboxFieldField",
|
||||
"name": "CheckboxFieldField",
|
||||
"type": "boolean",
|
||||
"required": false,
|
||||
"colspan": 1,
|
||||
"visibilityCondition": {
|
||||
"leftFormFieldId": "textOne",
|
||||
"leftRestResponseId": "",
|
||||
"operator": "==",
|
||||
"rightValue": "",
|
||||
"rightType": null,
|
||||
"rightFormFieldId": "textTwo",
|
||||
"rightRestResponseId": "",
|
||||
"nextConditionOperator": ""
|
||||
},
|
||||
"params": {
|
||||
"existingColspan": 1,
|
||||
"maxColspan": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "CheckboxFieldVariable",
|
||||
"name": "CheckboxFieldVariable",
|
||||
"type": "boolean",
|
||||
"required": false,
|
||||
"colspan": 1,
|
||||
"visibilityCondition": {
|
||||
"leftFormFieldId": "textOne",
|
||||
"leftRestResponseId": "",
|
||||
"operator": "==",
|
||||
"rightValue": "",
|
||||
"rightType": null,
|
||||
"rightFormFieldId": "",
|
||||
"rightRestResponseId": "cbc51284-04c4-462f-ab72-2b9f8b14907b",
|
||||
"nextConditionOperator": ""
|
||||
},
|
||||
"params": {
|
||||
"existingColspan": 1,
|
||||
"maxColspan": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "CheckboxFieldValue",
|
||||
"name": "CheckboxFieldValue",
|
||||
"type": "boolean",
|
||||
"required": false,
|
||||
"colspan": 1,
|
||||
"visibilityCondition": {
|
||||
"leftFormFieldId": "textOne",
|
||||
"leftRestResponseId": "",
|
||||
"operator": "==",
|
||||
"rightValue": "showCheckbox",
|
||||
"rightType": null,
|
||||
"rightFormFieldId": "",
|
||||
"rightRestResponseId": "",
|
||||
"nextConditionOperator": "",
|
||||
"nextCondition": null
|
||||
},
|
||||
"params": {
|
||||
"existingColspan": 1,
|
||||
"maxColspan": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "CheckboxVariableValue",
|
||||
"name": "CheckboxVariableValue",
|
||||
"type": "boolean",
|
||||
"required": false,
|
||||
"colspan": 1,
|
||||
"visibilityCondition": {
|
||||
"leftFormFieldId": "",
|
||||
"leftRestResponseId": "cbc51284-04c4-462f-ab72-2b9f8b14907b",
|
||||
"operator": "==",
|
||||
"rightValue": "showCheckbox",
|
||||
"rightType": null,
|
||||
"rightFormFieldId": "",
|
||||
"rightRestResponseId": "",
|
||||
"nextConditionOperator": "",
|
||||
"nextCondition": null
|
||||
},
|
||||
"params": {
|
||||
"existingColspan": 1,
|
||||
"maxColspan": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "CheckboxVariableVariable",
|
||||
"name": "CheckboxVariableVariable",
|
||||
"type": "boolean",
|
||||
"required": false,
|
||||
"colspan": 1,
|
||||
"visibilityCondition": {
|
||||
"leftFormFieldId": "",
|
||||
"leftRestResponseId": "cbc51284-04c4-462f-ab72-2b9f8b14907b",
|
||||
"operator": "==",
|
||||
"rightValue": "",
|
||||
"rightType": null,
|
||||
"rightFormFieldId": "",
|
||||
"rightRestResponseId": "87df371a-4238-43f8-92e5-ef3f6a19f379",
|
||||
"nextConditionOperator": "",
|
||||
"nextCondition": null
|
||||
},
|
||||
"params": {
|
||||
"existingColspan": 1,
|
||||
"maxColspan": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "CheckboxVariableField",
|
||||
"name": "CheckboxVariableField",
|
||||
"type": "boolean",
|
||||
"required": false,
|
||||
"colspan": 1,
|
||||
"visibilityCondition": {
|
||||
"leftFormFieldId": "",
|
||||
"leftRestResponseId": "cbc51284-04c4-462f-ab72-2b9f8b14907b",
|
||||
"operator": "==",
|
||||
"rightValue": "",
|
||||
"rightType": null,
|
||||
"rightFormFieldId": "textOne",
|
||||
"rightRestResponseId": "",
|
||||
"nextConditionOperator": "",
|
||||
"nextCondition": null
|
||||
},
|
||||
"params": {
|
||||
"existingColspan": 1,
|
||||
"maxColspan": 2
|
||||
}
|
||||
}
|
||||
],
|
||||
"2": [
|
||||
{
|
||||
"id": "textOne",
|
||||
"name": "textOne",
|
||||
"type": "text",
|
||||
"required": false,
|
||||
"colspan": 1,
|
||||
"placeholder": null,
|
||||
"minLength": 0,
|
||||
"maxLength": 0,
|
||||
"regexPattern": null,
|
||||
"visibilityCondition": null,
|
||||
"params": {
|
||||
"existingColspan": 1,
|
||||
"maxColspan": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "textTwo",
|
||||
"name": "textTwo",
|
||||
"type": "text",
|
||||
"required": false,
|
||||
"colspan": 1,
|
||||
"placeholder": null,
|
||||
"minLength": 0,
|
||||
"maxLength": 0,
|
||||
"regexPattern": null,
|
||||
"visibilityCondition": null,
|
||||
"params": {
|
||||
"existingColspan": 1,
|
||||
"maxColspan": 2
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"outcomes": [],
|
||||
"metadata": {},
|
||||
"variables": [
|
||||
{
|
||||
"id": "cbc51284-04c4-462f-ab72-2b9f8b14907b",
|
||||
"name": "varString1",
|
||||
"type": "string",
|
||||
"value": "showCheckbox"
|
||||
},
|
||||
{
|
||||
"id": "87df371a-4238-43f8-92e5-ef3f6a19f379",
|
||||
"name": "varString2",
|
||||
"type": "string",
|
||||
"value": "showCheckbox"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
"formRepresentation": {
|
||||
"id": "form-fb9245f6-1132-47bd-b0b3-823bb85002da",
|
||||
"name": "test",
|
||||
"description": "",
|
||||
"version": 0,
|
||||
"standAlone": true,
|
||||
"formDefinition": {
|
||||
"tabs": [],
|
||||
"fields": [
|
||||
{
|
||||
"id": "f3445185-b9af-41f7-a836-3b5712abeb0f",
|
||||
"name": "Label",
|
||||
"type": "container",
|
||||
"tab": null,
|
||||
"numberOfColumns": 2,
|
||||
"fields": {
|
||||
"1": [
|
||||
{
|
||||
"id": "CheckboxFieldField",
|
||||
"name": "CheckboxFieldField",
|
||||
"type": "boolean",
|
||||
"required": false,
|
||||
"colspan": 1,
|
||||
"visibilityCondition": {
|
||||
"leftType": "field",
|
||||
"leftValue": "textOne",
|
||||
"operator": "==",
|
||||
"rightValue": "textTwo",
|
||||
"rightType": "field",
|
||||
"nextConditionOperator": "",
|
||||
"nextCondition": null
|
||||
},
|
||||
"params": {
|
||||
"existingColspan": 1,
|
||||
"maxColspan": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "CheckboxFieldVariable",
|
||||
"name": "CheckboxFieldVariable",
|
||||
"type": "boolean",
|
||||
"required": false,
|
||||
"colspan": 1,
|
||||
"visibilityCondition": {
|
||||
"leftType": "field",
|
||||
"leftValue": "textOne",
|
||||
"operator": "==",
|
||||
"rightValue": "33c60b43-2d44-4f25-bdc4-62b34ae11b43",
|
||||
"rightType": "variable",
|
||||
"nextConditionOperator": ""
|
||||
},
|
||||
"params": {
|
||||
"existingColspan": 1,
|
||||
"maxColspan": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "CheckboxFieldValue",
|
||||
"name": "CheckboxFieldValue",
|
||||
"type": "boolean",
|
||||
"required": false,
|
||||
"colspan": 1,
|
||||
"visibilityCondition": {
|
||||
"leftType": "field",
|
||||
"leftValue": "textOne",
|
||||
"operator": "==",
|
||||
"rightValue": "showCheckbox",
|
||||
"rightType": "value",
|
||||
"nextConditionOperator": "",
|
||||
"nextCondition": null
|
||||
},
|
||||
"params": {
|
||||
"existingColspan": 1,
|
||||
"maxColspan": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "CheckboxVariableValue",
|
||||
"name": "CheckboxVariableValue",
|
||||
"type": "boolean",
|
||||
"required": false,
|
||||
"colspan": 1,
|
||||
"visibilityCondition": {
|
||||
"leftType": "variable",
|
||||
"leftValue": "33c60b43-2d44-4f25-bdc4-62b34ae11b43",
|
||||
"operator": "==",
|
||||
"rightValue": "showCheckbox",
|
||||
"rightType": "value",
|
||||
"nextConditionOperator": "",
|
||||
"nextCondition": null
|
||||
},
|
||||
"params": {
|
||||
"existingColspan": 1,
|
||||
"maxColspan": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "CheckboxVariableVariable",
|
||||
"name": "CheckboxVariableVariable",
|
||||
"type": "boolean",
|
||||
"required": false,
|
||||
"colspan": 1,
|
||||
"visibilityCondition": {
|
||||
"leftType": "variable",
|
||||
"leftValue": "33c60b43-2d44-4f25-bdc4-62b34ae11b43",
|
||||
"operator": "==",
|
||||
"rightValue": "0e67eb99-46f7-424e-9a78-6df0faa5844d",
|
||||
"rightType": "variable",
|
||||
"nextConditionOperator": "",
|
||||
"nextCondition": null
|
||||
},
|
||||
"params": {
|
||||
"existingColspan": 1,
|
||||
"maxColspan": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "CheckboxVariableField",
|
||||
"name": "CheckboxVariableField",
|
||||
"type": "boolean",
|
||||
"required": false,
|
||||
"colspan": 1,
|
||||
"visibilityCondition": {
|
||||
"leftType": "variable",
|
||||
"leftValue": "33c60b43-2d44-4f25-bdc4-62b34ae11b43",
|
||||
"operator": "==",
|
||||
"rightValue": "textOne",
|
||||
"rightType": "field",
|
||||
"nextConditionOperator": "",
|
||||
"nextCondition": null
|
||||
},
|
||||
"params": {
|
||||
"existingColspan": 1,
|
||||
"maxColspan": 2
|
||||
}
|
||||
}
|
||||
],
|
||||
"2": [
|
||||
{
|
||||
"id": "textOne",
|
||||
"name": "textOne",
|
||||
"type": "text",
|
||||
"required": false,
|
||||
"colspan": 1,
|
||||
"placeholder": null,
|
||||
"minLength": 0,
|
||||
"maxLength": 0,
|
||||
"regexPattern": null,
|
||||
"visibilityCondition": null,
|
||||
"params": {
|
||||
"existingColspan": 1,
|
||||
"maxColspan": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "textTwo",
|
||||
"name": "textTwo",
|
||||
"type": "text",
|
||||
"required": false,
|
||||
"colspan": 1,
|
||||
"placeholder": null,
|
||||
"minLength": 0,
|
||||
"maxLength": 0,
|
||||
"regexPattern": null,
|
||||
"visibilityCondition": null,
|
||||
"params": {
|
||||
"existingColspan": 1,
|
||||
"maxColspan": 2
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"outcomes": [],
|
||||
"metadata": {},
|
||||
"variables": [
|
||||
{
|
||||
"id": "33c60b43-2d44-4f25-bdc4-62b34ae11b43",
|
||||
"name": "varString1",
|
||||
"type": "string",
|
||||
"value": "showCheckbox"
|
||||
},
|
||||
{
|
||||
"id": "0e67eb99-46f7-424e-9a78-6df0faa5844d",
|
||||
"name": "varString2",
|
||||
"type": "string",
|
||||
"value": "showCheckbox"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}`;
|
||||
|
Reference in New Issue
Block a user