View Full Version : [CLOSED] b360 - HtmlEditor and allowBlank
5 Apr 2012, 9:59 PM
I think HtmlEditor should have allowBlank config option.
6 Apr 2012, 1:43 PM
What makes you say that? The ExtJS 4.0 API docs do not list allowBlank as a valid config for HtmlEditor: http://docs.sencha.com/ext-js/4-0/#!/api/Ext.form.field.HtmlEditor
7 Apr 2012, 5:55 AM
Yes, I've checked docs before creating the post, but first: it is common sense, I should have a possibility to define any field on a form as mandatory or not, and second: if I add allowBlank manually as custom field it works! so it is just a question of updating docs and config list in designer : )
7 Apr 2012, 7:44 AM
I'm not disagreeing with you that it makes sense, but can you clarify when you say it works? I've tried it and it does not seem to work, and in fact looking at the ExtJS source code there doesn't seem to be any way it could work (HtmlEditor does not have any logic to honor allowBlank, that's only supported in text field.)
I'm attaching the project I created to verify this. The HtmlEditor component has allowBlank:false and it is not highlighted as having an error if I leave it blank, and calling isValid on the form returns true if I leave it blank. Both of these behave as expected for the text field.
Please clarify if there's something I'm not seeing.
11 Apr 2012, 6:20 AM
I am completely disappointed, sorry but I could not recreate the issue!
Nethertheless is it possible to add allowBlank config to HtmlEditor?
11 Apr 2012, 8:51 AM
"Nethertheless is it possible to add allowBlank config to HtmlEditor?"
Do you mean implementing it in the Ext JS framework? I would imagine this is possible, but you should put a request for it in the Ext JS forums. It doesn't make sense for us to add it in Designer until it exists in the framework.
11 Apr 2012, 9:58 PM
I agree! Thanks a lot!
Powered by vBulletin® Version 4.1.5 Copyright © 2016 vBulletin Solutions, Inc. All rights reserved.