diff options
| author | Xavier Morel <xmo@openerp.com> | 2013-06-10 09:11:51 +0200 |
|---|---|---|
| committer | Xavier Morel <xmo@openerp.com> | 2013-06-10 09:11:51 +0200 |
| commit | ea7d79443b4262e0bd01cdf9473e8087f41c5e7b (patch) | |
| tree | e8364f1d553116d3099133df23f57b3980e09a87 /addons/web_graph | |
| parent | aa416a9951e57bb86c78df355c9441edf27dff5f (diff) | |
| parent | 9c6a184fb5aa77561655ae1ea21d34b6ecb8aa5e (diff) | |
[FIX] display 'undefined' in case of falsy graph value rather than empty label
bzr revid: xmo@openerp.com-20130610071151-15lhz4o95tl4clak
Diffstat (limited to 'addons/web_graph')
| -rw-r--r-- | addons/web_graph/static/src/js/graph.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/addons/web_graph/static/src/js/graph.js b/addons/web_graph/static/src/js/graph.js index 55ce776fa60..a84bb53fc85 100644 --- a/addons/web_graph/static/src/js/graph.js +++ b/addons/web_graph/static/src/js/graph.js @@ -5,6 +5,7 @@ openerp.web_graph = function (instance) { var _lt = instance.web._lt; +var _t = instance.web._t; // removed ``undefined`` values var filter_values = function (o) { @@ -365,7 +366,7 @@ instance.web_graph.GraphView = instance.web.View.extend({ }).then(function() { var res = { 'data': result, - 'ticks': _.map(ticks, function(el, key) { return [el, key] }) + 'ticks': _.map(ticks, function(el, key) { return [el, key || _t("Undefined")] }) }; return res; })); |
