summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAleksander Machniak <machniak@kolabsys.com>2012-03-16 13:37:44 (GMT)
committerAleksander Machniak <machniak@kolabsys.com>2012-03-16 13:37:44 (GMT)
commit72fa65ee528f8ae291e7969faad36f4c5bdff7e4 (patch)
tree7bc7bc995af1d018000224ec36264d10018a7844
parent2effaae4b63e4dec5b3a8d5ac37a7651aa1ef81b (diff)
parent312fc2521b6a2a1097c877af755e4974ae26bc92 (diff)
downloadkolab-wap-72fa65ee528f8ae291e7969faad36f4c5bdff7e4.tar.gz
Merge branch 'master' of ssh://git.kolab.org/git/kolab-wap
-rw-r--r--lib/kolab_client_task.php4
-rw-r--r--public_html/skins/default/ui.js5
2 files changed, 7 insertions, 2 deletions
diff --git a/lib/kolab_client_task.php b/lib/kolab_client_task.php
index 4e1c90c..bd49cd3 100644
--- a/lib/kolab_client_task.php
+++ b/lib/kolab_client_task.php
@@ -614,6 +614,10 @@ class kolab_client_task
case 'list':
$result['type'] = kolab_form::INPUT_TEXTAREA;
$result['data-type'] = kolab_form::TYPE_LIST;
+
+ if (!empty($field['maxlength'])) {
+ $result['data-maxlength'] = $field['maxlength'];
+ }
break;
default:
diff --git a/public_html/skins/default/ui.js b/public_html/skins/default/ui.js
index 546c1dc..5645f7e 100644
--- a/public_html/skins/default/ui.js
+++ b/public_html/skins/default/ui.js
@@ -199,7 +199,8 @@ function form_element_wrapper(form_element)
elem = form_list_element(form_element.form, {
name: form_element.name+'['+i+']',
value: list[i],
- disabled: disabled
+ disabled: disabled,
+ maxlength: e.attr('data-maxlength')
});
elem.appendTo(area);
}
@@ -217,7 +218,7 @@ function form_list_element(form, data)
+ '<span title="" class="add"></span><span title="" class="reset"></span>'
+ '</span><input></span>');
- $('input', elem).attr({name: data.name, value: data.value, disabled: data.disabled});
+ $('input', elem).attr(data);
if (data.disabled)
return elem;