Commit d2fa065faf0e482c49bd4edfddb4ef6f380fa769
1 parent
0f60e502
include minified version of "datetimepicker.js" and remove the non minified version
call to "CalexiumToolBox.jq_tab_activate" if it exist whenever a jquery ui tab is activated add scrollx parameter to jquery_datatable call change initialization call from dataTable to DataTable (non-deprecated version)
Showing
3 changed files
with
12 additions
and
9 deletions
Show diff stats
web/jQuery/CXM_jquery_datatable.anubis
| @@ -67,7 +67,7 @@ public define HTML_Partial_Content | @@ -67,7 +67,7 @@ public define HTML_Partial_Content | ||
| 67 | ) | 67 | ) |
| 68 | = | 68 | = |
| 69 | partial_content(jquery_datatables_1_10_init + | 69 | partial_content(jquery_datatables_1_10_init + |
| 70 | - [ js_inline(jquery_ready("$('#"+table_id+"').dataTable();")) ], | 70 | + [ js_inline(jquery_ready("$('#"+table_id+"').DataTable();")) ], |
| 71 | table | 71 | table |
| 72 | ) | 72 | ) |
| 73 | . | 73 | . |
| @@ -82,7 +82,7 @@ public define HTML_Partial_Content | @@ -82,7 +82,7 @@ public define HTML_Partial_Content | ||
| 82 | = | 82 | = |
| 83 | if enable_jqueryui then | 83 | if enable_jqueryui then |
| 84 | partial_content( jquery_datatables_1_10_init + | 84 | partial_content( jquery_datatables_1_10_init + |
| 85 | - [ js_inline(jquery_ready("$('#"+table_id+"').dataTable({\"jQueryUI\":true});")) ], | 85 | + [ js_inline(jquery_ready("$('#"+table_id+"').DataTable({\"jQueryUI\":true});")) ], |
| 86 | table | 86 | table |
| 87 | ) | 87 | ) |
| 88 | else | 88 | else |
| @@ -98,6 +98,7 @@ public define HTML_Partial_Content | @@ -98,6 +98,7 @@ public define HTML_Partial_Content | ||
| 98 | Bool enable_jqueryui, | 98 | Bool enable_jqueryui, |
| 99 | Bool enable_pagination, | 99 | Bool enable_pagination, |
| 100 | JQuery_datatable_pagination_type pagination_type, | 100 | JQuery_datatable_pagination_type pagination_type, |
| 101 | + Bool scrollX, | ||
| 101 | JQuery_datatable_scrollY_type scrollY, | 102 | JQuery_datatable_scrollY_type scrollY, |
| 102 | Bool enable_change_page_length, // if true, "enable_pagination" must be true too. | 103 | Bool enable_change_page_length, // if true, "enable_pagination" must be true too. |
| 103 | Bool enable_search_field, | 104 | Bool enable_search_field, |
| @@ -111,14 +112,14 @@ public define HTML_Partial_Content | @@ -111,14 +112,14 @@ public define HTML_Partial_Content | ||
| 111 | [ | 112 | [ |
| 112 | js_inline(jquery_ready(" | 113 | js_inline(jquery_ready(" |
| 113 | $.fn.dataTable.ext.legacy.ajax = true; | 114 | $.fn.dataTable.ext.legacy.ajax = true; |
| 114 | - $('#"+table_id+"').dataTable( | 115 | + $('#"+table_id+"').DataTable( |
| 115 | { | 116 | { |
| 116 | \"jQueryUI\":"+to_String(enable_jqueryui)+", | 117 | \"jQueryUI\":"+to_String(enable_jqueryui)+", |
| 117 | \"pagingType\":'"+jquery_datatable_pagination_type_to_string(pagination_type)+"', | 118 | \"pagingType\":'"+jquery_datatable_pagination_type_to_string(pagination_type)+"', |
| 118 | \"searching\":"+to_String(enable_search_field)+", | 119 | \"searching\":"+to_String(enable_search_field)+", |
| 119 | \"paging\":"+to_String(enable_pagination)+","+ | 120 | \"paging\":"+to_String(enable_pagination)+","+ |
| 120 | // responsive: true,"+ | 121 | // responsive: true,"+ |
| 121 | - | 122 | + "\"scrollX\": " + to_String(scrollX) + ","+ |
| 122 | if scrollY is | 123 | if scrollY is |
| 123 | { | 124 | { |
| 124 | no_scroll then "", | 125 | no_scroll then "", |
| @@ -152,7 +153,7 @@ public define HTML_Partial_Content | @@ -152,7 +153,7 @@ public define HTML_Partial_Content | ||
| 152 | Bool enable_columns_sorting, | 153 | Bool enable_columns_sorting, |
| 153 | String web_dir | 154 | String web_dir |
| 154 | ) = | 155 | ) = |
| 155 | - jquery_datatable(table_id, partial_content(table), enable_jqueryui, enable_pagination, pagination_type, scrollY, enable_change_page_length, enable_search_field, enable_columns_sorting, "en", no_extra, web_dir). | 156 | + jquery_datatable(table_id, partial_content(table), enable_jqueryui, enable_pagination, pagination_type, false, scrollY, enable_change_page_length, enable_search_field, enable_columns_sorting, "en", no_extra, web_dir). |
| 156 | 157 | ||
| 157 | public define HTML_Partial_Content | 158 | public define HTML_Partial_Content |
| 158 | jquery_datatable | 159 | jquery_datatable |
| @@ -168,4 +169,4 @@ public define HTML_Partial_Content | @@ -168,4 +169,4 @@ public define HTML_Partial_Content | ||
| 168 | Bool enable_columns_sorting, | 169 | Bool enable_columns_sorting, |
| 169 | String web_dir | 170 | String web_dir |
| 170 | ) = | 171 | ) = |
| 171 | - jquery_datatable(table_id, table, enable_jqueryui, enable_pagination, pagination_type, scrollY, enable_change_page_length, enable_search_field, enable_columns_sorting, "en", no_extra, web_dir). | 172 | + jquery_datatable(table_id, table, enable_jqueryui, enable_pagination, pagination_type, false, scrollY, enable_change_page_length, enable_search_field, enable_columns_sorting, "en", no_extra, web_dir). |
web/jQuery/CXM_jquery_tabs.anubis
| @@ -93,13 +93,15 @@ public define HTML_Partial_Content | @@ -93,13 +93,15 @@ public define HTML_Partial_Content | ||
| 93 | ui.newPanel.find('input[name=jq_tabs_" + tabs_container_id + "]').each(function () { | 93 | ui.newPanel.find('input[name=jq_tabs_" + tabs_container_id + "]').each(function () { |
| 94 | $(this).attr('value', ui.newTab.index()); | 94 | $(this).attr('value', ui.newTab.index()); |
| 95 | }); | 95 | }); |
| 96 | + | ||
| 97 | + if (typeof CalexiumToolBox !== 'undefined' && typeof CalexiumToolBox.jq_tab_activate !== 'undefined') { | ||
| 98 | + CalexiumToolBox.jq_tab_activate(event, ui); | ||
| 99 | + } | ||
| 96 | }, | 100 | }, |
| 97 | create: function( event, ui ) { | 101 | create: function( event, ui ) { |
| 98 | $('#"+tabs_container_id+"').find('form').prepend('<input type=\"hidden\" name=\"jq_tabs_" + tabs_container_id + "\" value=\"'+ui.tab.index()+'\">'); | 102 | $('#"+tabs_container_id+"').find('form').prepend('<input type=\"hidden\" name=\"jq_tabs_" + tabs_container_id + "\" value=\"'+ui.tab.index()+'\">'); |
| 99 | } | 103 | } |
| 100 | }); | 104 | }); |
| 101 | - | ||
| 102 | - | ||
| 103 | ")) | 105 | ")) |
| 104 | . | 106 | . |
| 105 | tags | 107 | tags |
web/jQuery/ui-addon/datetimepicker.anubis
| @@ -34,7 +34,7 @@ public define List(HTML_Head_Tag) | @@ -34,7 +34,7 @@ public define List(HTML_Head_Tag) | ||
| 34 | = | 34 | = |
| 35 | [ | 35 | [ |
| 36 | css(css_file("js/jquery/plug-in/datetimepicker/datetimepicker.css")), | 36 | css(css_file("js/jquery/plug-in/datetimepicker/datetimepicker.css")), |
| 37 | - js(js_file("js/jquery/plug-in/datetimepicker/datetimepicker.js")), | 37 | + js(js_file("js/jquery/plug-in/datetimepicker/datetimepicker.min.js")), |
| 38 | js_inline(jquery_ready("// Datetimepicker\n | 38 | js_inline(jquery_ready("// Datetimepicker\n |
| 39 | $('.datepicker').datetimepicker({lang:'"+lang+"',timepicker:false,format:'d/m/Y'}); | 39 | $('.datepicker').datetimepicker({lang:'"+lang+"',timepicker:false,format:'d/m/Y'}); |
| 40 | $('.datetimepicker').datetimepicker({lang:'"+lang+"',format:'Y-m-d H:i'}); | 40 | $('.datetimepicker').datetimepicker({lang:'"+lang+"',format:'Y-m-d H:i'}); |