This follow-up to the original patch offers an alternative method
to handle the width of the table and form fields:

- Reduce the font size of the filter input fields
- Make the filter inputs' width 100% instead of fixed
- Add "'bAutoWidth': false" to the datatables initialization
  to prevent the table width from being set to the browser window
  width on load. This allows the browser to be re-sized and have
  the table re-flow with it.
---
 koha-tmpl/intranet-tmpl/prog/en/css/datatables.css |    5 +++++
 .../prog/en/modules/catalogue/detail.tt            |    3 ++-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/koha-tmpl/intranet-tmpl/prog/en/css/datatables.css 
b/koha-tmpl/intranet-tmpl/prog/en/css/datatables.css
index 214e543..92e1768 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/css/datatables.css
+++ b/koha-tmpl/intranet-tmpl/prog/en/css/datatables.css
@@ -225,3 +225,8 @@ tr.even.selected td {
     background-color: #D3D3D3;
 }
 
+/* ColumnFilter */
+span.filter_column > input.text_filter {
+    font-size: 80%;
+    width: 100%;
+}
diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt 
b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt
index 8abd060..dd2098f 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt
+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt
@@ -54,7 +54,8 @@ function verify_images() {
     $(document).ready(function() {
         $("#itemstable").dataTable($.extend(true, {}, dataTablesDefaults, {
             'sDom': 't',
-            'bPaginate': false
+            'bPaginate': false,
+            'bAutoWidth': false
         })).columnFilter({
             'sPlaceHolder': 'head:after'
         });
-- 
1.7.9.5
_______________________________________________
Koha-patches mailing list
[email protected]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-patches
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to