Skip to content

Commit f812170

Browse files
hitsvilleusatuupola
authored andcommitted
adding a datepicker based on the jquery ui
1 parent 70dadc6 commit f812170

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
/* Create an inline datepicker which leverages the
2+
jQuery UI datepicker
3+
*/
4+
$.editable.addInputType('datepicker', {
5+
element: function(settings, original) {
6+
var input = $('<input />');
7+
8+
input.datepicker({
9+
onSelect: function(dateText, inst) {
10+
$(this).parents("form").submit();
11+
}
12+
});
13+
14+
$(this).append(input);
15+
return (input);
16+
}
17+
});

0 commit comments

Comments
 (0)