on 2021 Feb 24 3:57 PM
I want to set the default value of the 'Vertical Alignment' to 'Top' property present in the Cell Properties dialogbox of the CKEditor in the hybris backoffice. Such that when the user open up the dailog box the value 'Top' get automatically pre-populated in the Vertical Alignment field. (added screenshot).
I'm using the below code: (This works for setting defaults for normal textbox fields. but not working for select dropdowns).
CKEDITOR.on('dialogDefinition', function(ev) {
var dialogName = ev.data.name;
var dialogDefinition = ev.data.definition;
if (dialogName === 'cellProperties') {
var infoTab = dialogDefinition.getContents('info');
var vAlign = infoTab.get('vAlign'); //attached the screenshot of the object that I get here.
vAlign.selectedIndex = 1;
infoTab.get('vAlign')['default'] = 'Top';
}
});
vAlign value that I get in the console.


Please provide the complete solution if possible as I'm new to this. Thanks.
Request clarification before answering.
| User | Count |
|---|---|
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.