diff options
| author | Gery Debongnie <ged@openerp.com> | 2014-02-26 15:39:19 +0100 |
|---|---|---|
| committer | Gery Debongnie <ged@openerp.com> | 2014-02-26 15:39:19 +0100 |
| commit | b453252c2dc10b8361b557229eec85b8684a6858 (patch) | |
| tree | e53439f032b41f9c43c4ad6370b6a70e6baa8060 /addons/web_graph/static/src/js/graph_widget.js | |
| parent | eb1eb48ef39a7eabcf96a2d130ddf81c360b2b53 (diff) | |
[IMP] this commit adds two css classes (graph_pivot_mode and graph_chart_mode) to better separate the ui from the code in graph view (addon web_graph)
bzr revid: ged@openerp.com-20140226143919-cejqoq2kd4iwrq04
Diffstat (limited to 'addons/web_graph/static/src/js/graph_widget.js')
| -rw-r--r-- | addons/web_graph/static/src/js/graph_widget.js | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/addons/web_graph/static/src/js/graph_widget.js b/addons/web_graph/static/src/js/graph_widget.js index 9498fbfc93c..ac2a581616d 100644 --- a/addons/web_graph/static/src/js/graph_widget.js +++ b/addons/web_graph/static/src/js/graph_widget.js @@ -37,8 +37,9 @@ openerp.web_graph.Graph = openerp.web.Widget.extend({ if (this.mode !== 'pivot') { this.$('.graph_heatmap label').addClass('disabled'); + this.$('.graph_main_content').addClass('graph_chart_mode'); } else { - this.$('.graph_main_content').css('position', 'initial'); + this.$('.graph_main_content').addClass('graph_pivot_mode'); } return this.model.call('fields_get', []).then(function (f) { @@ -168,10 +169,10 @@ openerp.web_graph.Graph = openerp.web.Widget.extend({ if (mode === 'pivot') { this.$('.graph_heatmap label').removeClass('disabled'); - this.$('.graph_main_content').css('position', 'initial'); + this.$('.graph_main_content').removeClass('graph_chart_mode').addClass('graph_pivot_mode'); } else { this.$('.graph_heatmap label').addClass('disabled'); - this.$('.graph_main_content').css('position', 'relative'); + this.$('.graph_main_content').removeClass('graph_pivot_mode').addClass('graph_chart_mode'); } this.display_data(); }, |
