Handle the executor nodes, which are unknown to the Explain module,

gracefully by showing the 'ex_unknown.png' for such nodes.

Reported by: Murtuza
Refs #2706
pull/6/head
Ashesh Vashi 2017-09-15 10:51:10 +05:30
parent 788f7f3a69
commit 55e14e4d78
1 changed files with 6 additions and 4 deletions

View File

@ -260,12 +260,14 @@ var PlanModel = Backbone.Model.extend({
node_type = node_type.substring(0,7);
// Get the image information for current node
var mapperObj = (_.isFunction(imageMapper[node_type]) &&
var mappedImage = (_.isFunction(imageMapper[node_type]) &&
imageMapper[node_type].apply(undefined, [data])) ||
imageMapper[node_type] || 'Undefined';
imageMapper[node_type] || {
"image": "ex_unknown.png", "image_text": node_type
};
data["image"] = mapperObj["image"];
data["image_text"] = mapperObj["image_text"];
data["image"] = mappedImage["image"];
data["image_text"] = mappedImage["image_text"];
// Start calculating xpos, ypos, width and height for child plans if any
if ('Plans' in data) {