getAutoCreate : function(){
var cls = "";
+
if (!this.allowBlank) {
cls = "visible";
}
-
+
var cfg = {
tag : this.tag,
cls : 'roo-bootstrap-field-label ' + this.cls,
for : this.target,
cn : [
- {
- tag : 'i',
- cls : 'roo-required-indicator left-indicator text-danger fa fa-lg fa-star ' + cls,
- tooltip : this.iconTooltip
- },
{
tag : 'span',
html : this.html
]
};
- if(this.indicatorpos == 'right'){
+ if(!this.allowBlank){
+
var cfg = {
tag : this.tag,
cls : 'roo-bootstrap-field-label ' + this.cls,
for : this.target,
cn : [
- {
- tag : 'span',
- html : this.html
- },
{
tag : 'i',
- cls : 'roo-required-indicator right-indicator text-danger fa fa-lg fa-star '+ cls,
+ cls : 'roo-required-indicator left-indicator text-danger fa fa-lg fa-star ' + cls,
tooltip : this.iconTooltip
+ },
+ {
+ tag : 'span',
+ html : this.html
}
]
};
+
+ if(this.indicatorpos == 'right'){
+ var cfg = {
+ tag : this.tag,
+ cls : 'roo-bootstrap-field-label ' + this.cls,
+ for : this.target,
+ cn : [
+ {
+ tag : 'span',
+ html : this.html
+ },
+ {
+ tag : 'i',
+ cls : 'roo-required-indicator right-indicator text-danger fa fa-lg fa-star '+ cls,
+ tooltip : this.iconTooltip
+ }
+ ]
+ };
+ }
}
-
+
return cfg;
},