add description option to FormItem
This commit is contained in:
parent
8c34d09861
commit
ec4a1c0605
1 changed files with 9 additions and 2 deletions
|
@ -22,9 +22,16 @@ Ox.FormItem = function(options, self) {
|
||||||
error: '',
|
error: '',
|
||||||
})
|
})
|
||||||
.options(options || {})
|
.options(options || {})
|
||||||
.addClass('OxFormItem')
|
.addClass('OxFormItem');
|
||||||
.append(self.options.element);
|
|
||||||
|
|
||||||
|
self.description = self.options.element.options('description');
|
||||||
|
if (self.description) {
|
||||||
|
$('<div>')
|
||||||
|
.addClass('OxFormDescription')
|
||||||
|
.html(self.description)
|
||||||
|
.appendTo(that);
|
||||||
|
}
|
||||||
|
that.append(self.options.element);
|
||||||
self.$message = Ox.Element()
|
self.$message = Ox.Element()
|
||||||
.addClass('OxFormMessage')
|
.addClass('OxFormMessage')
|
||||||
.appendTo(that);
|
.appendTo(that);
|
||||||
|
|
Loading…
Reference in a new issue