I have created a LinkDialogOverride.js and need to change the default:
{ "itemId": "targetBlank", "name": "targetBlank", "xtype": "checkbox", "boxLabel": CQ.I18n.getMessage("Open in new window"), "value": "targetBlank" }
To a select dropdown or combo box. I see how it can be added to a dialog through .content.xml but not for the LinkDialog.js. Thank you in advance.
Solved! Go to Solution.
Views
Replies
Total Likes
Hi. For the dropdown you have to use the correct variables for a dropdown.
There are different forms of selection xtypes.You have the combo box, checkbox, dropdown menu and the radio buttons.
Xtype needs to be set to selection and the type of selection needs to be set to select (dropdown).
Then of course you also need to add the selectable values to that widget.
Here's a basic example with just two options:
this.myField = new CQ.form.Selection({ "fieldLabel": "MySelection", "name": this.componentName + "/" + selectionName, "type": "select", "ignoreData": true, "options": [{ "value": "true", "text": "Yes" },{ "value": "false", "text": "No" } ] });
Hope this will make some sense
/Johan
Views
Replies
Total Likes
All default values are set by assigning values to the using values to the xtype node. I am unclear - you have set the default value using a dialog - correct?
Views
Replies
Total Likes
Hi. For the dropdown you have to use the correct variables for a dropdown.
There are different forms of selection xtypes.You have the combo box, checkbox, dropdown menu and the radio buttons.
Xtype needs to be set to selection and the type of selection needs to be set to select (dropdown).
Then of course you also need to add the selectable values to that widget.
Here's a basic example with just two options:
this.myField = new CQ.form.Selection({ "fieldLabel": "MySelection", "name": this.componentName + "/" + selectionName, "type": "select", "ignoreData": true, "options": [{ "value": "true", "text": "Yes" },{ "value": "false", "text": "No" } ] });
Hope this will make some sense
/Johan
Views
Replies
Total Likes
Views
Likes
Replies
Views
Like
Replies