summaryrefslogtreecommitdiff
path: root/views
diff options
context:
space:
mode:
authorgebele <gebele@in-silico.ch>2016-01-31 13:15:08 +0100
committergebele <gebele@in-silico.ch>2016-01-31 13:15:08 +0100
commit111811340b889f0ad964ef8083de7981cf50bb5f (patch)
tree6c5966f61fcbf537551a2e46c5863241de35d22f /views
parent0aae6fb18ec24ff6ac843acd3ee31ef2ff0191cb (diff)
updated layout. works with FF,Chrome
Diffstat (limited to 'views')
-rw-r--r--views/layout.haml2
-rw-r--r--views/prediction.haml16
2 files changed, 12 insertions, 6 deletions
diff --git a/views/layout.haml b/views/layout.haml
index 78a8878..edf6e3e 100644
--- a/views/layout.haml
+++ b/views/layout.haml
@@ -14,7 +14,7 @@
%script{:src=>"/javascripts/jquery.tablesorter.widgets.js"}
%script{:src=>"/javascripts/jquery.tablesorter.staticrow.min.js"}
-#%script{:src=>"/javascripts/jquery.doubleScroll.js"}
- -#%script{:src=>"/javascripts/widget-scroller.js"}
+ %script{:src=>"/javascripts/widget-scroller.js"}
%script{:src=>"/javascripts/bootstrap.min.js"}
%body
%noscript
diff --git a/views/prediction.haml b/views/prediction.haml
index 29cba40..14fc75b 100644
--- a/views/prediction.haml
+++ b/views/prediction.haml
@@ -9,20 +9,27 @@
%hr
:javascript
$(document).ready(function(){
- $("table#neighbors").tablesorter({
+ $(".tablesorter").tablesorter({
debug: false,
theme: "bootstrap",
headerTemplate: '{content} {icon}',
- widgets: ['uitheme', 'staticRow'],
+ widgets: ['uitheme', 'staticRow', 'scroller'],
widgetOptions: {
+ scroller_upAfterSort: true,
+ scroller_jumpToHeader: true,
+ scroller_height : 300,
+ scroller_fixedColumns : 4,
+ scroller_addFixedOverlay : false,
+ scroller_barWidth : null
},
sortList: [[1,1]],
widthFixed: false,
});
});
- #results.table-responsive
- %table.tablesorter{:id=>"neighbors"}
+
+ #neighbors
+ %table.tablesorter{:id=>"fixed-columns-table"}
%thead
%tr
%th
@@ -125,4 +132,3 @@
%div{:style=>"display:inline-block;padding-right:20px;"}
/= k.gsub(/\sMean/, '')
%p= v.round(3)
-